[Pkg-libvirt-commits] [SCM] Libguestfs Debian packaging branch, master, updated. debian/1.12.4-2
Hilko Bengen
bengen at debian.org
Sun Aug 21 11:55:36 UTC 2011
The following commit has been merged in the master branch:
commit 3168278f844530db46f0ece78208f249131145a3
Author: Hilko Bengen <bengen at hilluzination.de>
Date: Sun Aug 14 22:57:49 2011 +0200
Added patches for the build scripts to allow for a separate build directory
diff --git a/debian/patches/0001-Disable-fuse-tests-if-dev-fuse-doesn-t-exist.patch b/debian/patches/0001-Disable-fuse-tests-if-dev-fuse-doesn-t-exist.patch
index a0b1569..8e1929c 100644
--- a/debian/patches/0001-Disable-fuse-tests-if-dev-fuse-doesn-t-exist.patch
+++ b/debian/patches/0001-Disable-fuse-tests-if-dev-fuse-doesn-t-exist.patch
@@ -8,10 +8,10 @@ e.g. when running in a chroot.
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/fuse/test-fuse.sh b/fuse/test-fuse.sh
-index 0a429f7..b292677 100755
+index cfa277a..1b97966 100755
--- a/fuse/test-fuse.sh
+++ b/fuse/test-fuse.sh
-@@ -45,6 +45,11 @@ if [ ! -x "$guestfish" -o ! -x "$guestmount" ]; then
+@@ -49,6 +49,11 @@ if [ ! -x "$guestfish" -o ! -x "$guestmount" ]; then
exit 1
fi
diff --git a/debian/patches/0004-configure.ac-do-not-generate-debian-changelog.patch b/debian/patches/0004-configure.ac-do-not-generate-debian-changelog.patch
index a6f21c7..abea9f9 100644
--- a/debian/patches/0004-configure.ac-do-not-generate-debian-changelog.patch
+++ b/debian/patches/0004-configure.ac-do-not-generate-debian-changelog.patch
@@ -7,7 +7,7 @@ Subject: configure.ac: do not generate debian/changelog
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/configure.ac b/configure.ac
-index 135e9c1..e2563ec 100644
+index 94263f2..67669e2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -816,7 +816,6 @@ AC_CONFIG_FILES([Makefile
diff --git a/debian/patches/0005-Do-not-run-appliance-related-checks-if-not-building-.patch b/debian/patches/0005-Do-not-run-appliance-related-checks-if-not-building-.patch
index a014f89..f38fa44 100644
--- a/debian/patches/0005-Do-not-run-appliance-related-checks-if-not-building-.patch
+++ b/debian/patches/0005-Do-not-run-appliance-related-checks-if-not-building-.patch
@@ -1,5 +1,5 @@
From: Hilko Bengen <bengen at debian.org>
-Date: Thu, 21 Jul 2011 09:01:19 +0200
+Date: Sat, 20 Aug 2011 10:34:46 +0200
Subject: Do not run appliance-related checks if not building appliance
---
@@ -33,34 +33,34 @@ index ca31727..1c5e873 100644
# Guestfish.
SUBDIRS += fish
diff --git a/cat/Makefile.am b/cat/Makefile.am
-index bf1d57c..7796675 100644
+index 6022cd6..49320c6 100644
--- a/cat/Makefile.am
+++ b/cat/Makefile.am
-@@ -135,4 +135,6 @@ TESTS_ENVIRONMENT = \
- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
- LIBGUESTFS_PATH=$(top_builddir)/appliance
+@@ -136,4 +136,6 @@ TESTS_ENVIRONMENT = \
+ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+ TMPDIR=$(top_builddir)
+if ENABLE_APPLIANCE
TESTS = test-virt-cat.sh test-virt-filesystems.sh test-virt-ls.sh
+endif ENABLE_APPLIANCE
diff --git a/df/Makefile.am b/df/Makefile.am
-index 1711798..59350ff 100644
+index 88e32af..209d7ae 100644
--- a/df/Makefile.am
+++ b/df/Makefile.am
-@@ -81,4 +81,6 @@ TESTS_ENVIRONMENT = \
- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
- LIBGUESTFS_PATH=$(top_builddir)/appliance
+@@ -82,4 +82,6 @@ TESTS_ENVIRONMENT = \
+ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+ TMPDIR=$(top_builddir)
+if ENABLE_APPLIANCE
TESTS = test-virt-df.sh
+endif ENABLE_APPLIANCE
diff --git a/edit/Makefile.am b/edit/Makefile.am
-index 62b5376..c1f1272 100644
+index e33b33c..4fec4e1 100644
--- a/edit/Makefile.am
+++ b/edit/Makefile.am
-@@ -73,4 +73,6 @@ TESTS_ENVIRONMENT = \
- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
- LIBGUESTFS_PATH=$(top_builddir)/appliance
+@@ -74,4 +74,6 @@ TESTS_ENVIRONMENT = \
+ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+ TMPDIR=$(top_builddir)
+if ENABLE_APPLIANCE
TESTS = test-virt-edit.sh
@@ -82,7 +82,7 @@ index b7558ee..5439011 100644
-endif
+endif HAVE_FUSE
diff --git a/images/Makefile.am b/images/Makefile.am
-index 622d288..45df114 100644
+index 68eb550..956e242 100644
--- a/images/Makefile.am
+++ b/images/Makefile.am
@@ -56,7 +56,9 @@ noinst_DATA = test.iso
@@ -96,10 +96,10 @@ index 622d288..45df114 100644
CLEANFILES = \
test.iso test.sqsh \
diff --git a/ocaml/Makefile.am b/ocaml/Makefile.am
-index 252a337..d594b77 100644
+index 5813f84..ec419ef 100644
--- a/ocaml/Makefile.am
+++ b/ocaml/Makefile.am
-@@ -74,11 +74,15 @@ TESTS_ENVIRONMENT = \
+@@ -75,11 +75,15 @@ TESTS_ENVIRONMENT = \
TESTS = run-bindtests \
t/guestfs_005_load \
@@ -119,7 +119,7 @@ index 252a337..d594b77 100644
t/guestfs_005_load \
t/guestfs_010_basic \
diff --git a/perl/Makefile.am b/perl/Makefile.am
-index c192290..3e1c99a 100644
+index d8167d1..6212915 100644
--- a/perl/Makefile.am
+++ b/perl/Makefile.am
@@ -48,9 +48,15 @@ src_deps: $(top_builddir)/src/libguestfs.la $(generator_built)
@@ -141,12 +141,12 @@ index c192290..3e1c99a 100644
TESTS_ENVIRONMENT = \
LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
diff --git a/python/Makefile.am b/python/Makefile.am
-index e995927..94c400f 100644
+index 5884762..19f6e00 100644
--- a/python/Makefile.am
+++ b/python/Makefile.am
-@@ -49,6 +49,10 @@ TESTS_ENVIRONMENT = \
- LIBGUESTFS_PATH=$(top_builddir)/appliance \
- PYTHONPATH=$(builddir):$(builddir)/.libs
+@@ -50,6 +50,10 @@ TESTS_ENVIRONMENT = \
+ PYTHONPATH=$(builddir):$(builddir)/.libs \
+ TMPDIR=$(top_builddir)
-TESTS = run-bindtests run-python-tests
+TESTS = run-bindtests
@@ -158,12 +158,12 @@ index e995927..94c400f 100644
+
+endif HAVE_PYTHON
diff --git a/resize/Makefile.am b/resize/Makefile.am
-index 8418cb4..41749ba 100644
+index fd7f71a..1ed0d96 100644
--- a/resize/Makefile.am
+++ b/resize/Makefile.am
-@@ -85,7 +85,9 @@ TESTS_ENVIRONMENT = \
- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
- LIBGUESTFS_PATH=$(top_builddir)/appliance
+@@ -86,7 +86,9 @@ TESTS_ENVIRONMENT = \
+ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+ TMPDIR=$(top_builddir)
+if ENABLE_APPLIANCE
TESTS = test-virt-resize.sh
@@ -172,11 +172,11 @@ index 8418cb4..41749ba 100644
# Dependencies.
depend: .depend
diff --git a/tools/Makefile.am b/tools/Makefile.am
-index 7904f1c..04a4bba 100644
+index 6059d35..357459b 100644
--- a/tools/Makefile.am
+++ b/tools/Makefile.am
-@@ -63,9 +63,11 @@ TESTS_ENVIRONMENT = \
- LIBGUESTFS_PATH=$(top_builddir)/appliance \
+@@ -64,9 +64,11 @@ TESTS_ENVIRONMENT = \
+ TMPDIR=$(top_builddir) \
PERL5LIB=$(top_builddir)/perl/blib/lib:$(top_builddir)/perl/blib/arch
+if ENABLE_APPLIANCE
diff --git a/debian/patches/0006-check-for-febootstrap-etc.-even-if-not-building-appl.patch b/debian/patches/0006-check-for-febootstrap-etc.-even-if-not-building-appl.patch
index dd5f3f1..e1555d7 100644
--- a/debian/patches/0006-check-for-febootstrap-etc.-even-if-not-building-appl.patch
+++ b/debian/patches/0006-check-for-febootstrap-etc.-even-if-not-building-appl.patch
@@ -7,7 +7,7 @@ Subject: check for febootstrap etc. even if not building appliance
1 files changed, 32 insertions(+), 31 deletions(-)
diff --git a/configure.ac b/configure.ac
-index e2563ec..eeffeb2 100644
+index 67669e2..9ccf27c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -182,46 +182,47 @@ AC_ARG_ENABLE([appliance],
diff --git a/debian/patches/0007-python-don-t-build-static-library-python3-wants-prin.patch b/debian/patches/0007-python-don-t-build-static-library-python3-wants-prin.patch
new file mode 100644
index 0000000..5262598
--- /dev/null
+++ b/debian/patches/0007-python-don-t-build-static-library-python3-wants-prin.patch
@@ -0,0 +1,42 @@
+From: Hilko Bengen <bengen at debian.org>
+Date: Fri, 5 Aug 2011 10:18:02 +0100
+Subject: python: don't build static library; python3 wants print(x) instead
+ of print x
+
+---
+ configure.ac | 4 ++--
+ python/Makefile.am | 2 +-
+ 2 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 9ccf27c..571fe41 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -544,11 +544,11 @@ AS_IF([test "x$enable_python" != "xno"],
+
+ if test "x$PYTHON" != "xno"; then
+ AC_MSG_CHECKING([Python prefix])
+- PYTHON_PREFIX=`$PYTHON -c "import sys; print sys.prefix"`
++ PYTHON_PREFIX=`$PYTHON -c "import sys; print (sys.prefix)"`
+ AC_MSG_RESULT([$PYTHON_PREFIX])
+
+ AC_MSG_CHECKING([Python version])
+- PYTHON_VERSION=`$PYTHON -c "import sys; print sys.version[[0:3]]"`
++ PYTHON_VERSION=`$PYTHON -c "import sys; print (sys.version[[0:3]])"`
+ AC_MSG_RESULT([$PYTHON_VERSION])
+
+ AC_MSG_CHECKING([for Python include path])
+diff --git a/python/Makefile.am b/python/Makefile.am
+index 19f6e00..97fae83 100644
+--- a/python/Makefile.am
++++ b/python/Makefile.am
+@@ -43,7 +43,7 @@ libguestfsmod_la_SOURCES = guestfs-py.c guestfs-py.h guestfs-py-byhand.c
+ libguestfsmod_la_CFLAGS = -Wall -I$(PYTHON_INCLUDEDIR) \
+ -I$(top_srcdir)/src -I$(top_builddir)/src
+ libguestfsmod_la_LIBADD = $(top_builddir)/src/libguestfs.la
+-libguestfsmod_la_LDFLAGS = -avoid-version
++libguestfsmod_la_LDFLAGS = -avoid-version -shared
+
+ TESTS_ENVIRONMENT = \
+ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+--
diff --git a/debian/patches/0007-python-don-t-build-static-library.patch b/debian/patches/0007-python-don-t-build-static-library.patch
deleted file mode 100644
index fabadda..0000000
--- a/debian/patches/0007-python-don-t-build-static-library.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-From: Hilko Bengen <bengen at debian.org>
-Date: Fri, 5 Aug 2011 10:18:02 +0100
-Subject: python: don't build static library
-
----
- python/Makefile.am | 2 +-
- 1 files changed, 1 insertions(+), 1 deletions(-)
-
-diff --git a/python/Makefile.am b/python/Makefile.am
-index 94c400f..f6ad8da 100644
---- a/python/Makefile.am
-+++ b/python/Makefile.am
-@@ -43,7 +43,7 @@ libguestfsmod_la_SOURCES = guestfs-py.c guestfs-py.h guestfs-py-byhand.c
- libguestfsmod_la_CFLAGS = -Wall -I$(PYTHON_INCLUDEDIR) \
- -I$(top_srcdir)/src -I$(top_builddir)/src
- libguestfsmod_la_LIBADD = $(top_builddir)/src/libguestfs.la
--libguestfsmod_la_LDFLAGS = -avoid-version
-+libguestfsmod_la_LDFLAGS = -avoid-version -shared
-
- TESTS_ENVIRONMENT = \
- LIBGUESTFS_PATH=$(top_builddir)/appliance \
---
diff --git a/debian/patches/0009-patches-from-upstream-git-repository-for-out-of-tree.patch b/debian/patches/0009-patches-from-upstream-git-repository-for-out-of-tree.patch
new file mode 100644
index 0000000..3890456
--- /dev/null
+++ b/debian/patches/0009-patches-from-upstream-git-repository-for-out-of-tree.patch
@@ -0,0 +1,888 @@
+From: Hilko Bengen <bengen at debian.org>
+Date: Sat, 20 Aug 2011 11:25:46 +0200
+Subject: patches from upstream git repository for out-of-tree build
+
+This includes the following commits:
+
+ff101adf7ead7bcdb46bccdb227ef18d844b965f out-of-tree build: fix documentation generation
+36e0f35a5828458ebeaf72999b3461ab66a230d8 out-of-tree build: fix appliance
+900c9626b9d4f567b21aae433493b4b3b1d09f6d out-of-tree build: Fix up OCaml bindings and generator
+0241c753937e577d51a070f7db471260bf931f9c out-of-tree build: fix building library
+4baec012b1b09a888e570fc89dbaa9fbf9944f34 out-of-tree build: remove unneeded explicit paths
+8876b2d3764b42ebae3c5fdf61b1899095508169 out-of-tree build: fix documentation generation II
+0938e43a60f9d729d9795cf45498e60217fece0e out-of-tree build: fix make and make install
+70c033998e0e721dc4f9eb2a20348098b259752c out-of-tree build: generate ./run from template, fix image checks
+---
+ .gitignore | 1 +
+ appliance/Makefile.am | 1 +
+ cat/Makefile.am | 6 ++--
+ configure.ac | 2 +
+ df/Makefile.am | 2 +-
+ edit/Makefile.am | 2 +-
+ examples/Makefile.am | 10 +++---
+ fish/Makefile.am | 14 ++++----
+ fuse/Makefile.am | 2 +-
+ generator/Makefile.am | 8 ++--
+ images/Makefile.am | 14 ++++-----
+ images/guest-aux/make-debian-img.sh | 6 ++--
+ images/guest-aux/make-fedora-img.sh | 4 +-
+ images/guest-aux/make-ubuntu-img.sh | 6 ++--
+ images/guest-aux/make-windows-img.sh | 8 ++--
+ inspector/Makefile.am | 2 +-
+ java/examples/Makefile.am | 6 ++--
+ ocaml/Makefile.am | 20 ++++++------
+ ocaml/examples/Makefile.am | 6 ++--
+ perl/examples/Makefile.am | 6 ++--
+ po-docs/ja/Makefile.am | 18 ++++++------
+ po-docs/uk/Makefile.am | 18 ++++++------
+ podwrapper.sh.in | 1 +
+ python/examples/Makefile.am | 6 ++--
+ rescue/Makefile.am | 2 +-
+ resize/Makefile.am | 2 +-
+ ruby/examples/Makefile.am | 6 ++--
+ run | 52 ----------------------------------
+ run.in | 51 +++++++++++++++++++++++++++++++++
+ src/Makefile.am | 14 ++++----
+ test-tool/Makefile.am | 2 +-
+ tools/Makefile.am | 4 +-
+ 32 files changed, 152 insertions(+), 150 deletions(-)
+ delete mode 100755 run
+ create mode 100755 run.in
+
+diff --git a/.gitignore b/.gitignore
+index 38b42b2..2371687 100644
+--- a/.gitignore
++++ b/.gitignore
+@@ -305,6 +305,7 @@ ruby/ext/guestfs/_guestfs.c
+ ruby/ext/guestfs/_guestfs.so
+ ruby/ext/guestfs/mkmf.log
+ ruby/Rakefile
++run
+ src/actions.c
+ src/bindtests.c
+ src/errnostring_gperf.c
+diff --git a/appliance/Makefile.am b/appliance/Makefile.am
+index 503160e..bec2b48 100644
+--- a/appliance/Makefile.am
++++ b/appliance/Makefile.am
+@@ -69,6 +69,7 @@ supermin.d/daemon.img: ../daemon/guestfsd
+ mv $@-t $@
+
+ supermin.d/init.img: init
++ cmp -s $(srcdir)/init $(builddir)/init || cp $(srcdir)/init $(builddir)/init
+ mkdir -p supermin.d
+ rm -f $@ $@-t
+ echo "init" | cpio --quiet -o -H newc > $@-t
+diff --git a/cat/Makefile.am b/cat/Makefile.am
+index 49320c6..b1a672e 100644
+--- a/cat/Makefile.am
++++ b/cat/Makefile.am
+@@ -102,7 +102,7 @@ noinst_DATA = \
+ virt-cat.1 $(top_builddir)/html/virt-cat.1.html: stamp-virt-cat.pod
+
+ stamp-virt-cat.pod: virt-cat.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-cat.1 \
+ --html $(top_builddir)/html/virt-cat.1.html \
+ $<
+@@ -111,7 +111,7 @@ stamp-virt-cat.pod: virt-cat.pod
+ virt-ls.1 $(top_builddir)/html/virt-ls.1.html: stamp-virt-ls.pod
+
+ stamp-virt-ls.pod: virt-ls.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-ls.1 \
+ --html $(top_builddir)/html/virt-ls.1.html \
+ $<
+@@ -120,7 +120,7 @@ stamp-virt-ls.pod: virt-ls.pod
+ virt-filesystems.1 $(top_builddir)/html/virt-filesystems.1.html: stamp-virt-filesystems.pod
+
+ stamp-virt-filesystems.pod: virt-filesystems.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-filesystems.1 \
+ --html $(top_builddir)/html/virt-filesystems.1.html \
+ $<
+diff --git a/configure.ac b/configure.ac
+index 571fe41..eadfc45 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -811,6 +811,8 @@ AC_CONFIG_HEADERS([config.h])
+ dnl http://www.mail-archive.com/automake@gnu.org/msg10204.html
+ AC_CONFIG_FILES([podwrapper.sh],
+ [chmod +x podwrapper.sh])
++AC_CONFIG_FILES([run],
++ [chmod +x run])
+ AC_CONFIG_FILES([Makefile
+ appliance/Makefile
+ capitests/Makefile
+diff --git a/df/Makefile.am b/df/Makefile.am
+index 209d7ae..63ba403 100644
+--- a/df/Makefile.am
++++ b/df/Makefile.am
+@@ -66,7 +66,7 @@ noinst_DATA = $(top_builddir)/html/virt-df.1.html
+ virt-df.1 $(top_builddir)/html/virt-df.1.html: stamp-virt-df.pod
+
+ stamp-virt-df.pod: virt-df.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-df.1 \
+ --html $(top_builddir)/html/virt-df.1.html \
+ $<
+diff --git a/edit/Makefile.am b/edit/Makefile.am
+index 4fec4e1..426c372 100644
+--- a/edit/Makefile.am
++++ b/edit/Makefile.am
+@@ -58,7 +58,7 @@ noinst_DATA = $(top_builddir)/html/virt-edit.1.html
+ virt-edit.1 $(top_builddir)/html/virt-edit.1.html: stamp-virt-edit.pod
+
+ stamp-virt-edit.pod: virt-edit.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-edit.1 \
+ --html $(top_builddir)/html/virt-edit.1.html \
+ $<
+diff --git a/examples/Makefile.am b/examples/Makefile.am
+index b8a2ffe..03870cb 100644
+--- a/examples/Makefile.am
++++ b/examples/Makefile.am
+@@ -65,19 +65,19 @@ noinst_DATA = \
+ guestfs-examples.3 $(top_builddir)/html/guestfs-examples.3.html: stamp-guestfs-examples.pod
+
+ stamp-guestfs-examples.pod: guestfs-examples.pod create_disk.c inspect_vm.c
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-examples.3 \
+ --html $(top_builddir)/html/guestfs-examples.3.html \
+- --verbatim create_disk.c:@EXAMPLE1@ \
+- --verbatim inspect_vm.c:@EXAMPLE2@ \
++ --verbatim $(srcdir)/create_disk.c:@EXAMPLE1@ \
++ --verbatim $(srcdir)/inspect_vm.c:@EXAMPLE2@ \
+ $<
+ touch $@
+
+ guestfs-recipes.1 $(top_builddir)/html/guestfs-recipes.1.html: stamp-guestfs-recipes.pod
+
+-stamp-guestfs-recipes.pod: guestfs-recipes.pod create_disk.c inspect_vm.c
+- $(top_srcdir)/podwrapper.sh \
++stamp-guestfs-recipes.pod: guestfs-recipes.pod
++ $(top_builddir)/podwrapper.sh \
+ --section 1 \
+ --man guestfs-recipes.1 \
+ --html $(top_builddir)/html/guestfs-recipes.1.html \
+diff --git a/fish/Makefile.am b/fish/Makefile.am
+index 3089181..33a0fd7 100644
+--- a/fish/Makefile.am
++++ b/fish/Makefile.am
+@@ -170,18 +170,18 @@ noinst_DATA = \
+ guestfish.1 $(top_builddir)/html/guestfish.1.html: stamp-guestfish.pod
+
+ stamp-guestfish.pod: guestfish.pod guestfish-actions.pod guestfish-commands.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man guestfish.1 \
+ --html $(top_builddir)/html/guestfish.1.html \
+- --insert guestfish-actions.pod:@ACTIONS@ \
+- --insert guestfish-commands.pod:@FISH_COMMANDS@ \
++ --insert $(srcdir)/guestfish-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfish-commands.pod:@FISH_COMMANDS@ \
+ $<
+ touch $@
+
+ virt-copy-in.1 $(top_builddir)/html/virt-copy-in.1.html: stamp-virt-copy-in.pod
+
+ stamp-virt-copy-in.pod: virt-copy-in.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-copy-in.1 \
+ --html $(top_builddir)/html/virt-copy-in.1.html \
+ $<
+@@ -190,7 +190,7 @@ stamp-virt-copy-in.pod: virt-copy-in.pod
+ virt-copy-out.1 $(top_builddir)/html/virt-copy-out.1.html: stamp-virt-copy-out.pod
+
+ stamp-virt-copy-out.pod: virt-copy-out.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-copy-out.1 \
+ --html $(top_builddir)/html/virt-copy-out.1.html \
+ $<
+@@ -199,7 +199,7 @@ stamp-virt-copy-out.pod: virt-copy-out.pod
+ virt-tar-in.1 $(top_builddir)/html/virt-tar-in.1.html: stamp-virt-tar-in.pod
+
+ stamp-virt-tar-in.pod: virt-tar-in.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-tar-in.1 \
+ --html $(top_builddir)/html/virt-tar-in.1.html \
+ $<
+@@ -208,7 +208,7 @@ stamp-virt-tar-in.pod: virt-tar-in.pod
+ virt-tar-out.1 $(top_builddir)/html/virt-tar-out.1.html: stamp-virt-tar-out.pod
+
+ stamp-virt-tar-out.pod: virt-tar-out.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-tar-out.1 \
+ --html $(top_builddir)/html/virt-tar-out.1.html \
+ $<
+diff --git a/fuse/Makefile.am b/fuse/Makefile.am
+index 5439011..c83becd 100644
+--- a/fuse/Makefile.am
++++ b/fuse/Makefile.am
+@@ -66,7 +66,7 @@ noinst_DATA = $(top_builddir)/html/guestmount.1.html
+ guestmount.1 $(top_builddir)/html/guestmount.1.html: stamp-guestmount.pod
+
+ stamp-guestmount.pod: guestmount.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man guestmount.1 \
+ --html $(top_builddir)/html/guestmount.1.html \
+ $<
+diff --git a/generator/Makefile.am b/generator/Makefile.am
+index 112fc69..a127a87 100644
+--- a/generator/Makefile.am
++++ b/generator/Makefile.am
+@@ -62,14 +62,14 @@ noinst_PROGRAM = generator
+
+ if HAVE_OCAML
+
+-generator: $(OBJECTS)
+- $(OCAMLC) -o generator $(OCAMLCFLAGS) $(OCAMLCLIBS) $(OBJECTS)
++$(srcdir)/generator: $(OBJECTS)
++ $(OCAMLC) -I $(srcdir) -o $@ $(OCAMLCFLAGS) $(OCAMLCLIBS) $(OBJECTS)
+
+ .ml.cmo:
+- $(OCAMLC) $(OCAMLCFLAGS) -c $< -o $@
++ $(OCAMLC) -I $(srcdir) $(OCAMLCFLAGS) -c $< -o $@
+
+ .mli.cmi:
+- $(OCAMLC) $(OCAMLCFLAGS) -c $< -o $@
++ $(OCAMLC) -I $(srcdir) $(OCAMLCFLAGS) -c $< -o $@
+
+ depend: .depend
+
+diff --git a/images/Makefile.am b/images/Makefile.am
+index 956e242..1b554f4 100644
+--- a/images/Makefile.am
++++ b/images/Makefile.am
+@@ -175,41 +175,39 @@ $(builddir)/test-grep.txt.gz: test-grep.txt
+ fedora.img: guest-aux/make-fedora-img.sh \
+ guest-aux/fedora-name.db \
+ guest-aux/fedora-packages.db
+- LIBGUESTFS_PATH=$(top_builddir)/appliance \
+- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
+ TMPDIR=$(top_builddir) \
++ SRCDIR=$(srcdir) \
+ bash $<
+
+ guest-aux/fedora-name.db: guest-aux/fedora-name.db.txt
+ rm -f $@ $@-t
++ mkdir -p guest-aux
+ $(DB_LOAD) $@-t < $<
+ mv $@-t $@
+
+ guest-aux/fedora-packages.db: guest-aux/fedora-packages.db.txt
+ rm -f $@ $@-t
++ mkdir -p guest-aux
+ $(DB_LOAD) $@-t < $<
+ mv $@-t $@
+
+ # Make a (dummy) Debian image.
+ debian.img: guest-aux/make-debian-img.sh
+- LIBGUESTFS_PATH=$(top_builddir)/appliance \
+- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
+ TMPDIR=$(top_builddir) \
++ SRCDIR=$(srcdir) \
+ bash $<
+
+ # Make a (dummy) Ubuntu image.
+ ubuntu.img: guest-aux/make-ubuntu-img.sh
+- LIBGUESTFS_PATH=$(top_builddir)/appliance \
+- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
+ TMPDIR=$(top_builddir) \
++ SRCDIR=$(srcdir) \
+ bash $<
+
+ # Make a (dummy) Windows image.
+ windows.img: guest-aux/make-windows-img.sh \
+ guest-aux/windows-software guest-aux/windows-system
+- LIBGUESTFS_PATH=$(top_builddir)/appliance \
+- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
+ TMPDIR=$(top_builddir) \
++ SRCDIR=$(srcdir) \
+ bash $<
+
+ # Since users might not have the tools needed to create this, we
+diff --git a/images/guest-aux/make-debian-img.sh b/images/guest-aux/make-debian-img.sh
+index 9a01e93..4b0490d 100755
+--- a/images/guest-aux/make-debian-img.sh
++++ b/images/guest-aux/make-debian-img.sh
+@@ -31,7 +31,7 @@ LABEL=BOOT /boot ext2 default 0 0
+ EOF
+
+ # Create a disk image.
+-../run ../fish/guestfish <<'EOF'
++../run ../fish/guestfish <<EOF
+ sparse debian.img.tmp 512M
+ run
+
+@@ -80,9 +80,9 @@ upload fstab.tmp /etc/fstab
+ write /etc/debian_version "5.0.1"
+ write /etc/hostname "debian.invalid"
+
+-upload guest-aux/debian-packages /var/lib/dpkg/status
++upload ${SRCDIR}/guest-aux/debian-packages /var/lib/dpkg/status
+
+-upload bin-x86_64-dynamic /bin/ls
++upload ${SRCDIR}/bin-x86_64-dynamic /bin/ls
+
+ mkdir /boot/grub
+ touch /boot/grub/grub.conf
+diff --git a/images/guest-aux/make-fedora-img.sh b/images/guest-aux/make-fedora-img.sh
+index a038432..3d6c471 100755
+--- a/images/guest-aux/make-fedora-img.sh
++++ b/images/guest-aux/make-fedora-img.sh
+@@ -31,7 +31,7 @@ LABEL=ROOT / ext2 default 0 0
+ EOF
+
+ # Create a disk image.
+-../run ../fish/guestfish <<'EOF'
++../run ../fish/guestfish <<EOF
+ sparse fedora.img.tmp 512M
+ run
+
+@@ -75,7 +75,7 @@ write /etc/sysconfig/network "HOSTNAME=fedora.invalid"
+ upload guest-aux/fedora-name.db /var/lib/rpm/Name
+ upload guest-aux/fedora-packages.db /var/lib/rpm/Packages
+
+-upload bin-x86_64-dynamic /bin/ls
++upload ${SRCDIR}/bin-x86_64-dynamic /bin/ls
+
+ mkdir /boot/grub
+ touch /boot/grub/grub.conf
+diff --git a/images/guest-aux/make-ubuntu-img.sh b/images/guest-aux/make-ubuntu-img.sh
+index 4ddb40a..c48fd5d 100755
+--- a/images/guest-aux/make-ubuntu-img.sh
++++ b/images/guest-aux/make-ubuntu-img.sh
+@@ -36,7 +36,7 @@ DISTRIB_DESCRIPTION="Ubuntu 10.10 (Phony Pharaoh)"
+ EOF
+
+ # Create a disk image.
+-../run ../fish/guestfish <<'EOF'
++../run ../fish/guestfish <<EOF
+ sparse ubuntu.img.tmp 512M
+ run
+
+@@ -69,9 +69,9 @@ write /etc/debian_version "5.0.1"
+ upload release.tmp /etc/lsb-release
+ write /etc/hostname "ubuntu.invalid"
+
+-upload guest-aux/debian-packages /var/lib/dpkg/status
++upload ${SRCDIR}/guest-aux/debian-packages /var/lib/dpkg/status
+
+-upload bin-i586-dynamic /bin/ls
++upload ${SRCDIR}/bin-x86_64-dynamic /bin/ls
+
+ mkdir /boot/grub
+ touch /boot/grub/grub.conf
+diff --git a/images/guest-aux/make-windows-img.sh b/images/guest-aux/make-windows-img.sh
+index 3acb2b7..9e2152d 100755
+--- a/images/guest-aux/make-windows-img.sh
++++ b/images/guest-aux/make-windows-img.sh
+@@ -36,7 +36,7 @@ if ! ../run ../fish/guestfish -a /dev/null run : available "ntfs3g ntfsprogs"; t
+ fi
+
+ # Create a disk image.
+-../run ../fish/guestfish <<'EOF'
++../run ../fish/guestfish <<EOF
+ sparse windows.img.tmp 512M
+ run
+
+@@ -58,10 +58,10 @@ mkfs ntfs /dev/sda2
+ mount-options "" /dev/sda2 /
+ mkdir-p /Windows/System32/Config
+
+-upload guest-aux/windows-software /Windows/System32/Config/SOFTWARE
+-upload guest-aux/windows-system /Windows/System32/Config/SYSTEM
++upload ${SRCDIR}/guest-aux/windows-software /Windows/System32/Config/SOFTWARE
++upload ${SRCDIR}/guest-aux/windows-system /Windows/System32/Config/SYSTEM
+
+-upload bin-win32.exe /Windows/System32/cmd.exe
++upload ${SRCDIR}/bin-win32.exe /Windows/System32/cmd.exe
+
+ mkdir "/Program Files"
+ touch /autoexec.bat
+diff --git a/inspector/Makefile.am b/inspector/Makefile.am
+index 5c48724..03e13d8 100644
+--- a/inspector/Makefile.am
++++ b/inspector/Makefile.am
+@@ -81,7 +81,7 @@ noinst_DATA = $(top_builddir)/html/virt-inspector.1.html
+ virt-inspector.1 $(top_builddir)/html/virt-inspector.1.html: stamp-virt-inspector.pod
+
+ stamp-virt-inspector.pod: virt-inspector.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-inspector.1 \
+ --html $(top_builddir)/html/virt-inspector.1.html \
+ $<
+diff --git a/java/examples/Makefile.am b/java/examples/Makefile.am
+index 503b55d..60fd958 100644
+--- a/java/examples/Makefile.am
++++ b/java/examples/Makefile.am
+@@ -31,12 +31,12 @@ noinst_DATA = $(top_builddir)/html/guestfs-java.3.html
+ guestfs-java.3 $(top_builddir)/html/guestfs-java.3.html: stamp-guestfs-java.pod
+
+ stamp-guestfs-java.pod: guestfs-java.pod CreateDisk.java InspectVM.java
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-java.3 \
+ --html $(top_builddir)/html/guestfs-java.3.html \
+- --verbatim CreateDisk.java:@EXAMPLE1@ \
+- --verbatim InspectVM.java:@EXAMPLE2@ \
++ --verbatim $(srcdir)/CreateDisk.java:@EXAMPLE1@ \
++ --verbatim $(srcdir)/InspectVM.java:@EXAMPLE2@ \
+ $<
+ touch $@
+
+diff --git a/ocaml/Makefile.am b/ocaml/Makefile.am
+index ec419ef..ba9aee7 100644
+--- a/ocaml/Makefile.am
++++ b/ocaml/Makefile.am
+@@ -56,13 +56,13 @@ guestfs_c.o: guestfs_c.c
+ $(CC) $(AM_CPPFLAGS) $(CFLAGS) -fPIC -Wall -c $<
+
+ guestfs_c_actions.o: guestfs_c_actions.c
+- $(CC) $(AM_CPPFLAGS) $(CFLAGS) -fPIC -Wall -c $<
++ $(CC) $(AM_CPPFLAGS) $(CFLAGS) -fPIC -Wall -c $(srcdir)/$<
+
+ if HAVE_OCAMLDOC
+
+ noinst_DATA += html/index.html
+
+-html/index.html: guestfs*.mli guestfs*.ml
++html/index.html: $(srcdir)/guestfs*.mli $(srcdir)/guestfs*.ml
+ mkdir -p html
+ -$(OCAMLDOC) -d html -html $^
+ endif
+@@ -126,14 +126,14 @@ t/guestfs_070_threads.cmx: t/guestfs_070_threads.ml mlguestfs.cmxa
+ $(OCAMLFIND) ocamlopt -package unix,threads -thread -linkpkg -c $< -o $@
+
+ t/%.cmx: t/%.ml mlguestfs.cmxa
+- $(OCAMLFIND) ocamlopt -package unix -linkpkg -c $< -o $@
++ $(OCAMLFIND) ocamlopt -package unix -linkpkg -c $< -o $(builddir)/$@
+
+-.mli.cmi:
+- $(OCAMLFIND) ocamlc -package unix -c $< -o $@
+-.ml.cmo:
+- $(OCAMLFIND) ocamlc -package unix -c $< -o $@
+-.ml.cmx:
+- $(OCAMLFIND) ocamlopt -package unix -c $< -o $@
++%.cmi: %.mli
++ $(OCAMLFIND) ocamlc -package unix -c $< -o $(builddir)/$@
++%.cmo: %.ml
++ $(OCAMLFIND) ocamlc -package unix -c $< -o $(builddir)/$@
++%.cmx: %.ml
++ $(OCAMLFIND) ocamlopt -package unix -c $< -o $(builddir)/$@
+
+ depend: .depend
+
+@@ -153,7 +153,7 @@ install-data-hook:
+ $(OCAMLFIND) install \
+ -ldconf ignore -destdir $(DESTDIR)$(OCAMLLIB) \
+ guestfs \
+- META *.so *.a *.cma *.cmx *.cmxa *.cmi *.mli
++ META *.so *.a *.cma *.cmx *.cmxa *.cmi $(srcdir)/*.mli
+
+ CLEANFILES += $(noinst_DATA)
+
+diff --git a/ocaml/examples/Makefile.am b/ocaml/examples/Makefile.am
+index 61a94af..43e579c 100644
+--- a/ocaml/examples/Makefile.am
++++ b/ocaml/examples/Makefile.am
+@@ -31,12 +31,12 @@ noinst_DATA = $(top_builddir)/html/guestfs-ocaml.3.html
+ guestfs-ocaml.3 $(top_builddir)/html/guestfs-ocaml.3.html: stamp-guestfs-ocaml.pod
+
+ stamp-guestfs-ocaml.pod: guestfs-ocaml.pod create_disk.ml inspect_vm.ml
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-ocaml.3 \
+ --html $(top_builddir)/html/guestfs-ocaml.3.html \
+- --verbatim create_disk.ml:@EXAMPLE1@ \
+- --verbatim inspect_vm.ml:@EXAMPLE2@ \
++ --verbatim $(srcdir)/create_disk.ml:@EXAMPLE1@ \
++ --verbatim $(srcdir)/inspect_vm.ml:@EXAMPLE2@ \
+ $<
+ touch $@
+
+diff --git a/perl/examples/Makefile.am b/perl/examples/Makefile.am
+index 354531a..387cdf1 100644
+--- a/perl/examples/Makefile.am
++++ b/perl/examples/Makefile.am
+@@ -29,11 +29,11 @@ noinst_DATA = $(top_builddir)/html/guestfs-perl.3.html
+ guestfs-perl.3 $(top_builddir)/html/guestfs-perl.3.html: stamp-guestfs-perl.pod
+
+ stamp-guestfs-perl.pod: guestfs-perl.pod create_disk.pl inspect_vm.pl
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-perl.3 \
+ --html $(top_builddir)/html/guestfs-perl.3.html \
+- --verbatim create_disk.pl:@EXAMPLE1@ \
+- --verbatim inspect_vm.pl:@EXAMPLE2@ \
++ --verbatim $(srcdir)/create_disk.pl:@EXAMPLE1@ \
++ --verbatim $(srcdir)/inspect_vm.pl:@EXAMPLE2@ \
+ $<
+ touch $@
+diff --git a/po-docs/ja/Makefile.am b/po-docs/ja/Makefile.am
+index 4b149fe..07778b5 100644
+--- a/po-docs/ja/Makefile.am
++++ b/po-docs/ja/Makefile.am
+@@ -52,26 +52,26 @@ EXTRA_DIST = \
+ all-local: $(MANPAGES)
+
+ guestfs.3: guestfs.pod guestfs-actions.pod guestfs-availability.pod guestfs-structs.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man $@ \
+- --insert guestfs-actions.pod:@ACTIONS@ \
+- --insert guestfs-availability.pod:@AVAILABILITY@ \
+- --insert guestfs-structs.pod:@STRUCTS@ \
++ --insert $(srcdir)/guestfs-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfs-availability.pod:@AVAILABILITY@ \
++ --insert $(srcdir)/guestfs-structs.pod:@STRUCTS@ \
+ $<
+
+ guestfish.1: guestfish.pod guestfish-actions.pod guestfish-commands.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man $@ \
+- --insert guestfish-actions.pod:@ACTIONS@ \
+- --insert guestfish-commands.pod:@FISH_COMMANDS@ \
++ --insert $(srcdir)/guestfish-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfish-commands.pod:@FISH_COMMANDS@ \
+ $<
+
+ %.1: %.pod
+- $(top_srcdir)/podwrapper.sh --man $@ $<
++ $(top_builddir)/podwrapper.sh --man $@ $<
+
+ %.1: %.pl
+- $(top_srcdir)/podwrapper.sh --man $@ $<
++ $(top_builddir)/podwrapper.sh --man $@ $<
+
+ # XXX Can automake do this properly?
+ install-data-hook:
+diff --git a/po-docs/uk/Makefile.am b/po-docs/uk/Makefile.am
+index 4b149fe..07778b5 100644
+--- a/po-docs/uk/Makefile.am
++++ b/po-docs/uk/Makefile.am
+@@ -52,26 +52,26 @@ EXTRA_DIST = \
+ all-local: $(MANPAGES)
+
+ guestfs.3: guestfs.pod guestfs-actions.pod guestfs-availability.pod guestfs-structs.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man $@ \
+- --insert guestfs-actions.pod:@ACTIONS@ \
+- --insert guestfs-availability.pod:@AVAILABILITY@ \
+- --insert guestfs-structs.pod:@STRUCTS@ \
++ --insert $(srcdir)/guestfs-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfs-availability.pod:@AVAILABILITY@ \
++ --insert $(srcdir)/guestfs-structs.pod:@STRUCTS@ \
+ $<
+
+ guestfish.1: guestfish.pod guestfish-actions.pod guestfish-commands.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man $@ \
+- --insert guestfish-actions.pod:@ACTIONS@ \
+- --insert guestfish-commands.pod:@FISH_COMMANDS@ \
++ --insert $(srcdir)/guestfish-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfish-commands.pod:@FISH_COMMANDS@ \
+ $<
+
+ %.1: %.pod
+- $(top_srcdir)/podwrapper.sh --man $@ $<
++ $(top_builddir)/podwrapper.sh --man $@ $<
+
+ %.1: %.pl
+- $(top_srcdir)/podwrapper.sh --man $@ $<
++ $(top_builddir)/podwrapper.sh --man $@ $<
+
+ # XXX Can automake do this properly?
+ install-data-hook:
+diff --git a/podwrapper.sh.in b/podwrapper.sh.in
+index c883c6a..9accaf9 100755
+--- a/podwrapper.sh.in
++++ b/podwrapper.sh.in
+@@ -180,6 +180,7 @@ if [ -n "$text_output" ]; then
+ fi
+
+ if [ -n "$html_output" ]; then
++ mkdir -p "$abs_top_builddir/html"
+ "$POD2HTML" \
+ --css "pod.css" --htmldir "$abs_top_builddir/html" \
+ < $tmpdir/full.pod > "$html_output".tmp
+diff --git a/python/examples/Makefile.am b/python/examples/Makefile.am
+index 208fecd..434c8f7 100644
+--- a/python/examples/Makefile.am
++++ b/python/examples/Makefile.am
+@@ -29,11 +29,11 @@ noinst_DATA = $(top_builddir)/html/guestfs-python.3.html
+ guestfs-python.3 $(top_builddir)/html/guestfs-python.3.html: stamp-guestfs-python.pod
+
+ stamp-guestfs-python.pod: guestfs-python.pod create_disk.py inspect_vm.py
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-python.3 \
+ --html $(top_builddir)/html/guestfs-python.3.html \
+- --verbatim create_disk.py:@EXAMPLE1@ \
+- --verbatim inspect_vm.py:@EXAMPLE2@ \
++ --verbatim $(srcdir)/create_disk.py:@EXAMPLE1@ \
++ --verbatim $(srcdir)/inspect_vm.py:@EXAMPLE2@ \
+ $<
+ touch $@
+diff --git a/rescue/Makefile.am b/rescue/Makefile.am
+index d3783ae..85a70f9 100644
+--- a/rescue/Makefile.am
++++ b/rescue/Makefile.am
+@@ -57,7 +57,7 @@ noinst_DATA = $(top_builddir)/html/virt-rescue.1.html
+ virt-rescue.1 $(top_builddir)/html/virt-rescue.1.html: stamp-virt-rescue.pod
+
+ stamp-virt-rescue.pod: virt-rescue.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-rescue.1 \
+ --html $(top_builddir)/html/virt-rescue.1.html \
+ $<
+diff --git a/resize/Makefile.am b/resize/Makefile.am
+index 1ed0d96..395f32d 100644
+--- a/resize/Makefile.am
++++ b/resize/Makefile.am
+@@ -68,7 +68,7 @@ noinst_DATA = $(top_builddir)/html/virt-resize.1.html
+ virt-resize.1 $(top_builddir)/html/virt-resize.1.html: stamp-virt-resize.pod
+
+ stamp-virt-resize.pod: virt-resize.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-resize.1 \
+ --html $(top_builddir)/html/virt-resize.1.html \
+ $<
+diff --git a/ruby/examples/Makefile.am b/ruby/examples/Makefile.am
+index 6e94acf..7183e80 100644
+--- a/ruby/examples/Makefile.am
++++ b/ruby/examples/Makefile.am
+@@ -29,11 +29,11 @@ noinst_DATA = $(top_builddir)/html/guestfs-ruby.3.html
+ guestfs-ruby.3 $(top_builddir)/html/guestfs-ruby.3.html: stamp-guestfs-ruby.pod
+
+ stamp-guestfs-ruby.pod: guestfs-ruby.pod create_disk.rb inspect_vm.rb
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-ruby.3 \
+ --html $(top_builddir)/html/guestfs-ruby.3.html \
+- --verbatim create_disk.rb:@EXAMPLE1@ \
+- --verbatim inspect_vm.rb:@EXAMPLE2@ \
++ --verbatim $(srcdir)/create_disk.rb:@EXAMPLE1@ \
++ --verbatim $(srcdir)/inspect_vm.rb:@EXAMPLE2@ \
+ $<
+ touch $@
+diff --git a/run b/run
+deleted file mode 100755
+index 2945315..0000000
+--- a/run
++++ /dev/null
+@@ -1,52 +0,0 @@
+-#!/bin/bash -
+-# libguestfs 'run' programs locally script
+-# Copyright (C) 2011 Red Hat Inc.
+-#
+-# This program is free software; you can redistribute it and/or modify
+-# it under the terms of the GNU General Public License as published by
+-# the Free Software Foundation; either version 2 of the License, or
+-# (at your option) any later version.
+-#
+-# This program is distributed in the hope that it will be useful,
+-# but WITHOUT ANY WARRANTY; without even the implied warranty of
+-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+-# GNU General Public License for more details.
+-#
+-# You should have received a copy of the GNU General Public License
+-# along with this program; if not, write to the Free Software
+-# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+-
+-#----------------------------------------------------------------------
+-
+-# With this script you can run all the virt tools without needing to
+-# install them first. You just have to do for example:
+-#
+-# ./run ./inspector/virt-inspector [args ...]
+-#
+-# This works for any C, OCaml or Perl virt tools in the libguestfs
+-# distribution. Also you can make a symbolic link to this 'run'
+-# script from anywhere (eg. $HOME/bin/run) if you wish.
+-
+-#----------------------------------------------------------------------
+-
+-# Find this script.
+-run=$(readlink -f "$0")
+-b=$(dirname "$run")
+-
+-# Set TMPDIR so the appliance doesn't conflict with globally
+-# installed libguestfs.
+-export TMPDIR=$b
+-
+-# Set local environment relative to this script.
+-export LD_LIBRARY_PATH="$b/src/.libs"
+-export LIBGUESTFS_PATH="$b/appliance"
+-export PERL5LIB="$b/perl/blib/lib:$b/perl/blib/arch"
+-
+-# Do we have libtool? If we have it then we can use it to make
+-# running valgrind simpler. However don't depend on it.
+-if libtool --help >/dev/null 2>&1; then
+- libtool="libtool --mode=execute"
+-fi
+-
+-# Run the program.
+-exec $libtool "$@"
+diff --git a/run.in b/run.in
+new file mode 100755
+index 0000000..d7b91d4
+--- /dev/null
++++ b/run.in
+@@ -0,0 +1,51 @@
++#!/bin/bash -
++# libguestfs 'run' programs locally script
++# Copyright (C) 2011 Red Hat Inc.
++#
++# This program is free software; you can redistribute it and/or modify
++# it under the terms of the GNU General Public License as published by
++# the Free Software Foundation; either version 2 of the License, or
++# (at your option) any later version.
++#
++# This program is distributed in the hope that it will be useful,
++# but WITHOUT ANY WARRANTY; without even the implied warranty of
++# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
++# GNU General Public License for more details.
++#
++# You should have received a copy of the GNU General Public License
++# along with this program; if not, write to the Free Software
++# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
++
++#----------------------------------------------------------------------
++
++# With this script you can run all the virt tools without needing to
++# install them first. You just have to do for example:
++#
++# ./run ./inspector/virt-inspector [args ...]
++#
++# This works for any C, OCaml or Perl virt tools in the libguestfs
++# distribution. Also you can make a symbolic link to this 'run'
++# script from anywhere (eg. $HOME/bin/run) if you wish.
++
++#----------------------------------------------------------------------
++
++# Find this script.
++b=@abs_builddir@
++
++# Set TMPDIR so the appliance doesn't conflict with globally
++# installed libguestfs.
++export TMPDIR="$b"
++
++# Set local environment relative to this script.
++export LD_LIBRARY_PATH="$b/src/.libs"
++export LIBGUESTFS_PATH="$b/appliance"
++export PERL5LIB="$b/perl/blib/lib:$b/perl/blib/arch"
++
++# Do we have libtool? If we have it then we can use it to make
++# running valgrind simpler. However don't depend on it.
++if libtool --help >/dev/null 2>&1; then
++ libtool="libtool --mode=execute"
++fi
++
++# Run the program.
++exec $libtool "$@"
+diff --git a/src/Makefile.am b/src/Makefile.am
+index 6c0cc33..095e0c1 100644
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -113,7 +113,7 @@ errnostring_gperf.c: errnostring_gperf.gperf
+ # 'libguestfs.so.0.$(MAX_PROC_NR).0'.
+ libguestfs_la_LDFLAGS = -version-info $(MAX_PROC_NR):0:$(MAX_PROC_NR)
+
+-libguestfs_la_LDFLAGS += $(VERSION_SCRIPT_FLAGS)libguestfs.syms
++libguestfs_la_LDFLAGS += $(VERSION_SCRIPT_FLAGS)$(srcdir)/libguestfs.syms
+
+ libguestfs_la_SOURCES = \
+ guestfs.c \
+@@ -162,14 +162,14 @@ libguestfs_la_CPPFLAGS = -I$(top_srcdir)/gnulib/lib
+ if HAVE_RPCGEN
+ guestfs_protocol.c: guestfs_protocol.x
+ rm -f $@-t $@-t2
+- $(RPCGEN) -c -o $@-t $<
++ $(RPCGEN) -c -o $@-t $(srcdir)/$<
+ sed 's,\.\./\.\./src/,,' < $@-t > $@-t2
+ rm $@-t
+ mv $@-t2 $@
+
+ guestfs_protocol.h: guestfs_protocol.x
+ rm -f $@-t
+- $(RPCGEN) -h -o $@-t $<
++ $(RPCGEN) -h -o $@-t $(srcdir)/$<
+ mv $@-t $@
+ endif
+
+@@ -184,12 +184,12 @@ stamp-guestfs.pod: guestfs.pod \
+ guestfs-actions.pod \
+ guestfs-availability.pod \
+ guestfs-structs.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs.3 \
+ --html $(top_builddir)/html/guestfs.3.html \
+- --insert guestfs-actions.pod:@ACTIONS@ \
+- --insert guestfs-availability.pod:@AVAILABILITY@ \
+- --insert guestfs-structs.pod:@STRUCTS@ \
++ --insert $(srcdir)/guestfs-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfs-availability.pod:@AVAILABILITY@ \
++ --insert $(srcdir)/guestfs-structs.pod:@STRUCTS@ \
+ $<
+ touch $@
+diff --git a/test-tool/Makefile.am b/test-tool/Makefile.am
+index 9fa4033..16daa7f 100644
+--- a/test-tool/Makefile.am
++++ b/test-tool/Makefile.am
+@@ -34,6 +34,6 @@ libguestfs_test_tool_LDADD = \
+ $(top_builddir)/src/libguestfs.la
+
+ libguestfs-test-tool.1: libguestfs-test-tool.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man $@ \
+ $<
+diff --git a/tools/Makefile.am b/tools/Makefile.am
+index 357459b..60c4046 100644
+--- a/tools/Makefile.am
++++ b/tools/Makefile.am
+@@ -44,12 +44,12 @@ man_MANS = virt-tar.1 $(patsubst %,virt-%.1,$(filter-out tar,$(tools)))
+ noinst_DATA = $(tools:%=$(top_builddir)/html/virt-%.1.html)
+
+ virt-%.1: virt-%
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man $@ \
+ $<
+
+ $(top_builddir)/html/virt-%.1.html: virt-%
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --html $@ \
+ $<
+
+--
diff --git a/debian/patches/0009-regenerated-auto-related-files.patch b/debian/patches/0009-regenerated-auto-related-files.patch
deleted file mode 100644
index 2559519..0000000
--- a/debian/patches/0009-regenerated-auto-related-files.patch
+++ /dev/null
@@ -1,656 +0,0 @@
-From: Hilko Bengen <bengen at debian.org>
-Date: Thu, 21 Jul 2011 09:06:44 +0200
-Subject: regenerated auto*-related files
-
----
- Makefile.in | 51 +++++++++++++++-----------------
- aclocal.m4 | 14 +++++----
- cat/Makefile.in | 2 +-
- configure | 83 +++++++++++++++++++++++++++++----------------------
- df/Makefile.in | 2 +-
- edit/Makefile.in | 2 +-
- fuse/Makefile.in | 2 +-
- images/Makefile.in | 2 +-
- ocaml/Makefile.in | 19 +++++------
- perl/Makefile.in | 7 +++-
- python/Makefile.in | 5 ++-
- resize/Makefile.in | 2 +-
- tools/Makefile.in | 6 ++--
- 13 files changed, 105 insertions(+), 92 deletions(-)
-
-diff --git a/Makefile.in b/Makefile.in
-index 2eaf55f..30ac064 100644
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -70,33 +70,33 @@ host_triplet = @host@
- DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
- $(srcdir)/Makefile.in $(srcdir)/config.h.in \
- $(srcdir)/libguestfs.pc.in $(srcdir)/podwrapper.sh.in \
-- $(top_srcdir)/configure $(top_srcdir)/debian/changelog.in \
-- $(top_srcdir)/subdir-rules.mk ABOUT-NLS AUTHORS COPYING \
-- COPYING.LIB ChangeLog TODO build-aux/compile \
-- build-aux/config.guess build-aux/config.rpath \
-- build-aux/config.sub build-aux/depcomp build-aux/install-sh \
-- build-aux/ltmain.sh build-aux/missing
-+ $(top_srcdir)/configure $(top_srcdir)/subdir-rules.mk \
-+ ABOUT-NLS AUTHORS COPYING COPYING.LIB ChangeLog TODO \
-+ build-aux/compile build-aux/config.guess \
-+ build-aux/config.rpath build-aux/config.sub build-aux/depcomp \
-+ build-aux/install-sh build-aux/ltmain.sh build-aux/missing
- @ENABLE_DAEMON_TRUE at am__append_1 = daemon
- @ENABLE_APPLIANCE_TRUE at am__append_2 = appliance
-+ at ENABLE_APPLIANCE_TRUE@am__append_3 = capitests caution regressions
-
- # Language bindings.
-- at HAVE_PERL_TRUE@am__append_3 = perl perl/examples
-- at HAVE_OCAML_TRUE@am__append_4 = ocaml ocaml/examples
-- at HAVE_PYTHON_TRUE@am__append_5 = python python/examples
-- at HAVE_RUBY_TRUE@am__append_6 = ruby ruby/examples
-- at HAVE_JAVA_TRUE@am__append_7 = java java/examples
-- at HAVE_HASKELL_TRUE@am__append_8 = haskell
-- at HAVE_PHP_TRUE@am__append_9 = php
-+ at HAVE_PERL_TRUE@am__append_4 = perl perl/examples
-+ at HAVE_OCAML_TRUE@am__append_5 = ocaml ocaml/examples
-+ at HAVE_PYTHON_TRUE@am__append_6 = python python/examples
-+ at HAVE_RUBY_TRUE@am__append_7 = ruby ruby/examples
-+ at HAVE_JAVA_TRUE@am__append_8 = java java/examples
-+ at HAVE_HASKELL_TRUE@am__append_9 = haskell
-+ at HAVE_PHP_TRUE@am__append_10 = php
-
- # virt-resize 2.0 is written in OCaml.
-- at HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE at am__append_10 = resize
-+ at HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE at am__append_11 = resize
-
- # Perl tools and guestmount.
-- at HAVE_TOOLS_TRUE@am__append_11 = tools
-- at HAVE_FUSE_TRUE@am__append_12 = fuse
-+ at HAVE_TOOLS_TRUE@am__append_12 = tools
-+ at HAVE_FUSE_TRUE@am__append_13 = fuse
-
- # po-docs must come after tools, inspector.
-- at HAVE_PO4A_TRUE@am__append_13 = po-docs
-+ at HAVE_PO4A_TRUE@am__append_14 = po-docs
- subdir = .
- ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
- am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
-@@ -196,7 +196,7 @@ am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
- configure.lineno config.status.lineno
- mkinstalldirs = $(install_sh) -d
- CONFIG_HEADER = config.h
--CONFIG_CLEAN_FILES = podwrapper.sh debian/changelog libguestfs.pc
-+CONFIG_CLEAN_FILES = podwrapper.sh libguestfs.pc
- CONFIG_CLEAN_VPATH_FILES =
- AM_V_GEN = $(am__v_GEN_$(V))
- am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
-@@ -244,7 +244,7 @@ AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
- ETAGS = etags
- CTAGS = ctags
- DIST_SUBDIRS = gnulib/lib images generator src examples po daemon \
-- appliance gnulib/tests capitests caution regressions test-tool \
-+ appliance gnulib/tests test-tool capitests caution regressions \
- fish cat df edit inspector rescue perl perl/examples ocaml \
- ocaml/examples python python/examples ruby ruby/examples java \
- java/examples haskell php csharp resize tools fuse po-docs
-@@ -1181,12 +1181,11 @@ ACLOCAL_AMFLAGS = -I m4
-
- # Unconditional because nothing is built yet.
- SUBDIRS = gnulib/lib images generator src examples po $(am__append_1) \
-- $(am__append_2) gnulib/tests capitests caution regressions \
-- test-tool fish cat df edit inspector rescue $(am__append_3) \
-- $(am__append_4) $(am__append_5) $(am__append_6) \
-- $(am__append_7) $(am__append_8) $(am__append_9) csharp \
-- $(am__append_10) $(am__append_11) $(am__append_12) \
-- $(am__append_13)
-+ $(am__append_2) gnulib/tests test-tool $(am__append_3) fish \
-+ cat df edit inspector rescue $(am__append_4) $(am__append_5) \
-+ $(am__append_6) $(am__append_7) $(am__append_8) \
-+ $(am__append_9) $(am__append_10) csharp $(am__append_11) \
-+ $(am__append_12) $(am__append_13) $(am__append_14)
- EXTRA_DIST = \
- $(generator_built) \
- BUGS HACKING RELEASE-NOTES ROADMAP TODO \
-@@ -1331,8 +1330,6 @@ distclean-hdr:
- -rm -f config.h stamp-h1
- podwrapper.sh: $(top_builddir)/config.status $(srcdir)/podwrapper.sh.in
- cd $(top_builddir) && $(SHELL) ./config.status $@
--debian/changelog: $(top_builddir)/config.status $(top_srcdir)/debian/changelog.in
-- cd $(top_builddir) && $(SHELL) ./config.status $@
- libguestfs.pc: $(top_builddir)/config.status $(srcdir)/libguestfs.pc.in
- cd $(top_builddir) && $(SHELL) ./config.status $@
-
-diff --git a/aclocal.m4 b/aclocal.m4
-index 7ee8e1e..faf58b0 100644
---- a/aclocal.m4
-+++ b/aclocal.m4
-@@ -47,7 +47,8 @@ To do so, use the procedure documented by the package, typically `autoreconf'.])
- # ----------------------------------
- AC_DEFUN([PKG_PROG_PKG_CONFIG],
- [m4_pattern_forbid([^_?PKG_[A-Z_]+$])
--m4_pattern_allow([^PKG_CONFIG(_PATH)?$])
-+m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$])
-+m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$])
- AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
- AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
- AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
-@@ -93,7 +94,8 @@ m4_define([_PKG_CONFIG],
- pkg_cv_[]$1="$$1"
- elif test -n "$PKG_CONFIG"; then
- PKG_CHECK_EXISTS([$3],
-- [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
-+ [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes ],
- [pkg_failed=yes])
- else
- pkg_failed=untried
-@@ -141,9 +143,9 @@ if test $pkg_failed = yes; then
- AC_MSG_RESULT([no])
- _PKG_SHORT_ERRORS_SUPPORTED
- if test $_pkg_short_errors_supported = yes; then
-- $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1`
-+ $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
- else
-- $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1`
-+ $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
-@@ -156,7 +158,7 @@ $$1_PKG_ERRORS
- Consider adjusting the PKG_CONFIG_PATH environment variable if you
- installed software in a non-standard prefix.
-
--_PKG_TEXT])
-+_PKG_TEXT])[]dnl
- ])
- elif test $pkg_failed = untried; then
- AC_MSG_RESULT([no])
-@@ -167,7 +169,7 @@ path to pkg-config.
-
- _PKG_TEXT
-
--To get pkg-config, see <http://pkg-config.freedesktop.org/>.])
-+To get pkg-config, see <http://pkg-config.freedesktop.org/>.])[]dnl
- ])
- else
- $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
-diff --git a/cat/Makefile.in b/cat/Makefile.in
-index 3bb54a7..b9a3bf0 100644
---- a/cat/Makefile.in
-+++ b/cat/Makefile.in
-@@ -1243,7 +1243,7 @@ TESTS_ENVIRONMENT = \
- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
- LIBGUESTFS_PATH=$(top_builddir)/appliance
-
--TESTS = test-virt-cat.sh test-virt-filesystems.sh test-virt-ls.sh
-+ at ENABLE_APPLIANCE_TRUE@TESTS = test-virt-cat.sh test-virt-filesystems.sh test-virt-ls.sh
- all: all-am
-
- .SUFFIXES:
-diff --git a/configure b/configure
-index e562af3..ad18aba 100755
---- a/configure
-+++ b/configure
-@@ -36068,8 +36068,7 @@ fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_appliance" >&5
- $as_echo "$enable_appliance" >&6; }
-
--if test "x$enable_appliance" = "xyes"; then
-- # Extract the first word of "febootstrap", so it can be a program name with args.
-+# Extract the first word of "febootstrap", so it can be a program name with args.
- set dummy febootstrap; ac_word=$2
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
- $as_echo_n "checking for $ac_word... " >&6; }
-@@ -36107,12 +36106,8 @@ $as_echo "no" >&6; }
- fi
-
-
-- test "x$FEBOOTSTRAP" = "xno" &&
-- as_fn_error $? "febootstrap must be installed" "$LINENO" 5
-- $FEBOOTSTRAP --version >&5 2>&1 ||
-- as_fn_error $? "febootstrap >= 3.0 must be installed, your version is too old" "$LINENO" 5
-
-- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if user requested febootstrap --yum-config option" >&5
-+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if user requested febootstrap --yum-config option" >&5
- $as_echo_n "checking if user requested febootstrap --yum-config option... " >&6; }
-
- # Check whether --with-febootstrap-yum-config was given.
-@@ -36122,26 +36117,32 @@ else
- FEBOOTSTRAP_YUM_CONFIG=no
- fi
-
-- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FEBOOTSTRAP_YUM_CONFIG" >&5
-+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $FEBOOTSTRAP_YUM_CONFIG" >&5
- $as_echo "$FEBOOTSTRAP_YUM_CONFIG" >&6; }
-
-
-- { $as_echo "$as_me:${as_lineno-$LINENO}: checking which Linux distro for package names" >&5
-+if test "x$enable_appliance" = "xyes"; then
-+ test "x$FEBOOTSTRAP" = "xno" &&
-+ as_fn_error $? "febootstrap must be installed" "$LINENO" 5
-+ $FEBOOTSTRAP --version >&5 2>&1 ||
-+ as_fn_error $? "febootstrap >= 3.0 must be installed, your version is too old" "$LINENO" 5
-+fi
-+
-+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking which Linux distro for package names" >&5
- $as_echo_n "checking which Linux distro for package names... " >&6; }
-- DISTRO=REDHAT
-- if test -f /etc/debian_version; then
-- DISTRO=DEBIAN
-- if grep -q 'DISTRIB_ID=Ubuntu' /etc/lsb-release 2>&5; then
-- DISTRO=UBUNTU
-- fi
-+DISTRO=REDHAT
-+if test -f /etc/debian_version; then
-+ DISTRO=DEBIAN
-+ if grep -q 'DISTRIB_ID=Ubuntu' /etc/lsb-release 2>&5; then
-+ DISTRO=UBUNTU
- fi
-- if test -f /etc/arch-release; then
-- DISTRO=ARCHLINUX
-- fi
-- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DISTRO" >&5
-+fi
-+if test -f /etc/arch-release; then
-+ DISTRO=ARCHLINUX
-+fi
-+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DISTRO" >&5
- $as_echo "$DISTRO" >&6; }
-
--fi
-
- # Extract the first word of "rpcgen", so it can be a program name with args.
- set dummy rpcgen; ac_word=$2
-@@ -38791,6 +38792,7 @@ $as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
-
-
-
-+
- if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
-@@ -38919,6 +38921,7 @@ if test -n "$PCRE_CFLAGS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_PCRE_CFLAGS=`$PKG_CONFIG --cflags "libpcre" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -38935,6 +38938,7 @@ if test -n "$PCRE_LIBS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_PCRE_LIBS=`$PKG_CONFIG --libs "libpcre" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -38954,9 +38958,9 @@ else
- _pkg_short_errors_supported=no
- fi
- if test $_pkg_short_errors_supported = yes; then
-- PCRE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpcre" 2>&1`
-+ PCRE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libpcre" 2>&1`
- else
-- PCRE_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpcre" 2>&1`
-+ PCRE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libpcre" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$PCRE_PKG_ERRORS" >&5
-@@ -38971,7 +38975,6 @@ installed software in a non-standard prefix.
- Alternatively, you may set the environment variables PCRE_CFLAGS
- and PCRE_LIBS to avoid the need to call pkg-config.
- See the pkg-config man page for more details." "$LINENO" 5
--
- elif test $pkg_failed = untried; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
- $as_echo "no" >&6; }
-@@ -38987,7 +38990,6 @@ See the pkg-config man page for more details.
-
- To get pkg-config, see <http://pkg-config.freedesktop.org/>.
- See \`config.log' for more details" "$LINENO" 5; }
--
- else
- PCRE_CFLAGS=$pkg_cv_PCRE_CFLAGS
- PCRE_LIBS=$pkg_cv_PCRE_LIBS
-@@ -39066,6 +39068,7 @@ if test -n "$LIBVIRT_CFLAGS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_LIBVIRT_CFLAGS=`$PKG_CONFIG --cflags "libvirt" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -39082,6 +39085,7 @@ if test -n "$LIBVIRT_LIBS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_LIBVIRT_LIBS=`$PKG_CONFIG --libs "libvirt" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -39101,9 +39105,9 @@ else
- _pkg_short_errors_supported=no
- fi
- if test $_pkg_short_errors_supported = yes; then
-- LIBVIRT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libvirt" 2>&1`
-+ LIBVIRT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libvirt" 2>&1`
- else
-- LIBVIRT_PKG_ERRORS=`$PKG_CONFIG --print-errors "libvirt" 2>&1`
-+ LIBVIRT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libvirt" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$LIBVIRT_PKG_ERRORS" >&5
-@@ -39151,6 +39155,7 @@ if test -n "$LIBXML2_CFLAGS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -39167,6 +39172,7 @@ if test -n "$LIBXML2_LIBS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -39186,9 +39192,9 @@ else
- _pkg_short_errors_supported=no
- fi
- if test $_pkg_short_errors_supported = yes; then
-- LIBXML2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libxml-2.0" 2>&1`
-+ LIBXML2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxml-2.0" 2>&1`
- else
-- LIBXML2_PKG_ERRORS=`$PKG_CONFIG --print-errors "libxml-2.0" 2>&1`
-+ LIBXML2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxml-2.0" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$LIBXML2_PKG_ERRORS" >&5
-@@ -39236,6 +39242,7 @@ if test -n "$LIBCONFIG_CFLAGS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_LIBCONFIG_CFLAGS=`$PKG_CONFIG --cflags "libconfig" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -39252,6 +39259,7 @@ if test -n "$LIBCONFIG_LIBS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_LIBCONFIG_LIBS=`$PKG_CONFIG --libs "libconfig" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -39271,9 +39279,9 @@ else
- _pkg_short_errors_supported=no
- fi
- if test $_pkg_short_errors_supported = yes; then
-- LIBCONFIG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libconfig" 2>&1`
-+ LIBCONFIG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libconfig" 2>&1`
- else
-- LIBCONFIG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libconfig" 2>&1`
-+ LIBCONFIG_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libconfig" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$LIBCONFIG_PKG_ERRORS" >&5
-@@ -39321,6 +39329,7 @@ if test -n "$HIVEX_CFLAGS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_HIVEX_CFLAGS=`$PKG_CONFIG --cflags "hivex" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -39337,6 +39346,7 @@ if test -n "$HIVEX_LIBS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_HIVEX_LIBS=`$PKG_CONFIG --libs "hivex" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -39356,9 +39366,9 @@ else
- _pkg_short_errors_supported=no
- fi
- if test $_pkg_short_errors_supported = yes; then
-- HIVEX_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "hivex" 2>&1`
-+ HIVEX_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "hivex" 2>&1`
- else
-- HIVEX_PKG_ERRORS=`$PKG_CONFIG --print-errors "hivex" 2>&1`
-+ HIVEX_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "hivex" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$HIVEX_PKG_ERRORS" >&5
-@@ -39414,6 +39424,7 @@ if test -n "$FUSE_CFLAGS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_FUSE_CFLAGS=`$PKG_CONFIG --cflags "fuse" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -39430,6 +39441,7 @@ if test -n "$FUSE_LIBS"; then
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_FUSE_LIBS=`$PKG_CONFIG --libs "fuse" 2>/dev/null`
-+ test "x$?" != "x0" && pkg_failed=yes
- else
- pkg_failed=yes
- fi
-@@ -39449,9 +39461,9 @@ else
- _pkg_short_errors_supported=no
- fi
- if test $_pkg_short_errors_supported = yes; then
-- FUSE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "fuse" 2>&1`
-+ FUSE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "fuse" 2>&1`
- else
-- FUSE_PKG_ERRORS=`$PKG_CONFIG --print-errors "fuse" 2>&1`
-+ FUSE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "fuse" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$FUSE_PKG_ERRORS" >&5
-@@ -41221,7 +41233,7 @@ ac_config_headers="$ac_config_headers config.h"
-
- ac_config_files="$ac_config_files podwrapper.sh"
-
--ac_config_files="$ac_config_files Makefile appliance/Makefile capitests/Makefile cat/Makefile caution/Makefile csharp/Makefile debian/changelog df/Makefile edit/Makefile examples/Makefile fish/Makefile fuse/Makefile generator/Makefile gnulib/lib/Makefile gnulib/tests/Makefile haskell/Makefile images/Makefile inspector/Makefile java/Makefile java/examples/Makefile libguestfs.pc ocaml/META ocaml/Makefile ocaml/examples/Makefile perl/Makefile perl/Makefile.PL perl/examples/Makefile php/Makefile po-docs/Makefile po-docs/ja/Makefile po-docs/uk/Makefile po/Makefile.in python/Makefile python/examples/Makefile regressions/Makefile rescue/Makefile resize/Makefile ruby/Makefile ruby/Rakefile ruby/examples/Makefile src/Makefile test-tool/Makefile tools/Makefile"
-+ac_config_files="$ac_config_files Makefile appliance/Makefile capitests/Makefile cat/Makefile caution/Makefile csharp/Makefile df/Makefile edit/Makefile examples/Makefile fish/Makefile fuse/Makefile generator/Makefile gnulib/lib/Makefile gnulib/tests/Makefile haskell/Makefile images/Makefile inspector/Makefile java/Makefile java/examples/Makefile libguestfs.pc ocaml/META ocaml/Makefile ocaml/examples/Makefile perl/Makefile perl/Makefile.PL perl/examples/Makefile php/Makefile po-docs/Makefile po-docs/ja/Makefile po-docs/uk/Makefile po/Makefile.in python/Makefile python/examples/Makefile regressions/Makefile rescue/Makefile resize/Makefile ruby/Makefile ruby/Rakefile ruby/examples/Makefile src/Makefile test-tool/Makefile tools/Makefile"
-
- cat >confcache <<\_ACEOF
- # This file is a shell script that caches the results of configure
-@@ -42407,7 +42419,6 @@ do
- "cat/Makefile") CONFIG_FILES="$CONFIG_FILES cat/Makefile" ;;
- "caution/Makefile") CONFIG_FILES="$CONFIG_FILES caution/Makefile" ;;
- "csharp/Makefile") CONFIG_FILES="$CONFIG_FILES csharp/Makefile" ;;
-- "debian/changelog") CONFIG_FILES="$CONFIG_FILES debian/changelog" ;;
- "df/Makefile") CONFIG_FILES="$CONFIG_FILES df/Makefile" ;;
- "edit/Makefile") CONFIG_FILES="$CONFIG_FILES edit/Makefile" ;;
- "examples/Makefile") CONFIG_FILES="$CONFIG_FILES examples/Makefile" ;;
-diff --git a/df/Makefile.in b/df/Makefile.in
-index 37b04ce..aa84dd8 100644
---- a/df/Makefile.in
-+++ b/df/Makefile.in
-@@ -1183,7 +1183,7 @@ TESTS_ENVIRONMENT = \
- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
- LIBGUESTFS_PATH=$(top_builddir)/appliance
-
--TESTS = test-virt-df.sh
-+ at ENABLE_APPLIANCE_TRUE@TESTS = test-virt-df.sh
- all: all-am
-
- .SUFFIXES:
-diff --git a/edit/Makefile.in b/edit/Makefile.in
-index 12b0358..ea4ad87 100644
---- a/edit/Makefile.in
-+++ b/edit/Makefile.in
-@@ -1172,7 +1172,7 @@ TESTS_ENVIRONMENT = \
- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
- LIBGUESTFS_PATH=$(top_builddir)/appliance
-
--TESTS = test-virt-edit.sh
-+ at ENABLE_APPLIANCE_TRUE@TESTS = test-virt-edit.sh
- all: all-am
-
- .SUFFIXES:
-diff --git a/fuse/Makefile.in b/fuse/Makefile.in
-index 9d271ba..3211143 100644
---- a/fuse/Makefile.in
-+++ b/fuse/Makefile.in
-@@ -1180,7 +1180,7 @@ CLEANFILES = stamp-guestmount.pod
- @HAVE_FUSE_TRUE at noinst_DATA = $(top_builddir)/html/guestmount.1.html
-
- # Tests.
-- at HAVE_FUSE_TRUE@TESTS = test-fuse.sh
-+ at ENABLE_APPLIANCE_TRUE@@HAVE_FUSE_TRUE at TESTS = test-fuse.sh
- @HAVE_FUSE_TRUE at TESTS_ENVIRONMENT = \
- @HAVE_FUSE_TRUE@ top_builddir=..
-
-diff --git a/images/Makefile.in b/images/Makefile.in
-index 1d64a44..2ec4e3c 100644
---- a/images/Makefile.in
-+++ b/images/Makefile.in
-@@ -1099,7 +1099,7 @@ noinst_DATA = test.iso
-
- # This is 'check_DATA' because we don't need it until 'make check'
- # time and we need the tools we have built in order to make it.
--check_DATA = debian.img fedora.img ubuntu.img windows.img
-+ at ENABLE_APPLIANCE_TRUE@check_DATA = debian.img fedora.img ubuntu.img windows.img
- CLEANFILES = \
- test.iso test.sqsh \
- 100kallzeroes 100kallnewlines 100kallspaces 100krandom 10klines \
-diff --git a/ocaml/Makefile.in b/ocaml/Makefile.in
-index 84c0cfe..2050ce5 100644
---- a/ocaml/Makefile.in
-+++ b/ocaml/Makefile.in
-@@ -71,7 +71,11 @@ DIST_COMMON = $(srcdir)/.depend $(srcdir)/META.in \
- $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
- $(top_srcdir)/subdir-rules.mk
- @HAVE_OCAMLDOC_TRUE@@HAVE_OCAML_TRUE at am__append_1 = html/index.html
-- at HAVE_OCAML_TRUE@am__append_2 = $(noinst_DATA)
-+ at ENABLE_APPLIANCE_TRUE@@HAVE_OCAML_TRUE at am__append_2 = t/guestfs_010_basic \
-+ at ENABLE_APPLIANCE_TRUE@@HAVE_OCAML_TRUE@ t/guestfs_070_threads \
-+ at ENABLE_APPLIANCE_TRUE@@HAVE_OCAML_TRUE@ t/guestfs_400_progress
-+
-+ at HAVE_OCAML_TRUE@am__append_3 = $(noinst_DATA)
- subdir = ocaml
- ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
- am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
-@@ -1084,7 +1088,7 @@ EXTRA_DIST = \
- t/*.ml
-
- CLEANFILES = *.cmi *.cmo *.cmx *.cma *.cmxa *.o *.a *.so t/*.cmi \
-- t/*.cmo t/*.cmx t/*.o t/*.a t/*.so $(am__append_2)
-+ t/*.cmo t/*.cmx t/*.o t/*.a t/*.so $(am__append_3)
- AM_CPPFLAGS = -I$(top_builddir) -I$(OCAMLLIB) -I$(top_srcdir)/ocaml \
- -I$(top_srcdir)/src -I$(top_builddir)/src \
- $(WARN_CFLAGS) $(WERROR_CFLAGS)
-@@ -1101,14 +1105,9 @@ AM_CPPFLAGS = -I$(top_builddir) -I$(OCAMLLIB) -I$(top_srcdir)/ocaml \
- @HAVE_OCAML_TRUE@ LIBGUESTFS_PATH=$(top_builddir)/appliance \
- @HAVE_OCAML_TRUE@ $(VG)
-
-- at HAVE_OCAML_TRUE@TESTS = run-bindtests \
-- at HAVE_OCAML_TRUE@ t/guestfs_005_load \
-- at HAVE_OCAML_TRUE@ t/guestfs_010_basic \
-- at HAVE_OCAML_TRUE@ t/guestfs_070_threads \
-- at HAVE_OCAML_TRUE@ t/guestfs_080_optargs \
-- at HAVE_OCAML_TRUE@ t/guestfs_400_events \
-- at HAVE_OCAML_TRUE@ t/guestfs_400_progress
--
-+ at HAVE_OCAML_TRUE@TESTS = run-bindtests t/guestfs_005_load \
-+ at HAVE_OCAML_TRUE@ t/guestfs_080_optargs t/guestfs_400_events \
-+ at HAVE_OCAML_TRUE@ $(am__append_2)
- @HAVE_OCAML_TRUE at SUFFIXES = .cmo .cmi .cmx .ml .mli .mll .mly
- all: all-am
-
-diff --git a/perl/Makefile.in b/perl/Makefile.in
-index c2c04b8..087badf 100644
---- a/perl/Makefile.in
-+++ b/perl/Makefile.in
-@@ -68,6 +68,8 @@ build_triplet = @build@
- host_triplet = @host@
- DIST_COMMON = README $(srcdir)/Makefile.PL.in $(srcdir)/Makefile.am \
- $(srcdir)/Makefile.in $(top_srcdir)/subdir-rules.mk
-+ at ENABLE_APPLIANCE_TRUE@@HAVE_PERL_TRUE at am__append_1 = appliance
-+ at ENABLE_APPLIANCE_TRUE@@HAVE_PERL_TRUE at am__append_2 = run-perl-tests
- subdir = perl
- ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
- am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
-@@ -1080,7 +1082,8 @@ EXTRA_DIST = \
- t/*.t \
- typemap
-
-- at HAVE_PERL_TRUE@TESTS = run-bindtests run-perl-tests
-+ at HAVE_PERL_TRUE@TESTS = run-bindtests $(am__append_2)
-+ at HAVE_PERL_TRUE@test_prereq = src_deps all test_images $(am__append_1)
- @HAVE_PERL_TRUE at TESTS_ENVIRONMENT = \
- @HAVE_PERL_TRUE@ LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
- @HAVE_PERL_TRUE@ LIBGUESTFS_PATH=$(top_builddir)/appliance
-@@ -1404,7 +1407,7 @@ appliance: force
- @HAVE_PERL_TRUE at test_images:
- @HAVE_PERL_TRUE@ $(MAKE) -C $(top_builddir)/images
-
-- at HAVE_PERL_TRUE@$(TESTS): src_deps all appliance test_images
-+ at HAVE_PERL_TRUE@$(TESTS): $(test_prereq)
-
- @HAVE_PERL_TRUE at all: Makefile-pl src_deps
- @HAVE_PERL_TRUE@ $(MAKE) -f Makefile-pl
-diff --git a/python/Makefile.in b/python/Makefile.in
-index 9423103..4e9550d 100644
---- a/python/Makefile.in
-+++ b/python/Makefile.in
-@@ -70,6 +70,7 @@ build_triplet = @build@
- host_triplet = @host@
- DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
- $(top_srcdir)/subdir-rules.mk
-+ at ENABLE_APPLIANCE_TRUE@@HAVE_PYTHON_TRUE at am__append_1 = run-python-tests
- subdir = python
- ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
- am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
-@@ -1146,12 +1147,12 @@ EXTRA_DIST = \
- @HAVE_PYTHON_TRUE@ -I$(top_srcdir)/src -I$(top_builddir)/src
-
- @HAVE_PYTHON_TRUE at libguestfsmod_la_LIBADD = $(top_builddir)/src/libguestfs.la
-- at HAVE_PYTHON_TRUE@libguestfsmod_la_LDFLAGS = -avoid-version
-+ at HAVE_PYTHON_TRUE@libguestfsmod_la_LDFLAGS = -avoid-version -shared
- @HAVE_PYTHON_TRUE at TESTS_ENVIRONMENT = \
- @HAVE_PYTHON_TRUE@ LIBGUESTFS_PATH=$(top_builddir)/appliance \
- @HAVE_PYTHON_TRUE@ PYTHONPATH=$(builddir):$(builddir)/.libs
-
-- at HAVE_PYTHON_TRUE@TESTS = run-bindtests run-python-tests
-+ at HAVE_PYTHON_TRUE@TESTS = run-bindtests $(am__append_1)
- all: all-am
-
- .SUFFIXES:
-diff --git a/resize/Makefile.in b/resize/Makefile.in
-index 5204b2f..8414863 100644
---- a/resize/Makefile.in
-+++ b/resize/Makefile.in
-@@ -1134,7 +1134,7 @@ CLEANFILES = *~ *.cmi *.cmo *.cmx *.cmxa *.o virt-resize test.img \
- @HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE@ LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
- @HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE@ LIBGUESTFS_PATH=$(top_builddir)/appliance
-
-- at HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE at TESTS = test-virt-resize.sh
-+ at ENABLE_APPLIANCE_TRUE@@HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE at TESTS = test-virt-resize.sh
- all: all-am
-
- .SUFFIXES:
-diff --git a/tools/Makefile.in b/tools/Makefile.in
-index 67bfbea..ea9d8d6 100644
---- a/tools/Makefile.in
-+++ b/tools/Makefile.in
-@@ -1122,9 +1122,9 @@ CLEANFILES = test.img
- @HAVE_TOOLS_TRUE@ LIBGUESTFS_PATH=$(top_builddir)/appliance \
- @HAVE_TOOLS_TRUE@ PERL5LIB=$(top_builddir)/perl/blib/lib:$(top_builddir)/perl/blib/arch
-
-- at HAVE_TOOLS_TRUE@TESTS = test-virt-list-filesystems.sh \
-- at HAVE_TOOLS_TRUE@ test-virt-make-fs.sh \
-- at HAVE_TOOLS_TRUE@ test-virt-tar.sh
-+ at ENABLE_APPLIANCE_TRUE@@HAVE_TOOLS_TRUE at TESTS = test-virt-list-filesystems.sh \
-+ at ENABLE_APPLIANCE_TRUE@@HAVE_TOOLS_TRUE@ test-virt-make-fs.sh \
-+ at ENABLE_APPLIANCE_TRUE@@HAVE_TOOLS_TRUE@ test-virt-tar.sh
-
- all: all-am
-
---
diff --git a/debian/patches/0010-out-of-tree-build-fix-building-Perl-bindings.patch b/debian/patches/0010-out-of-tree-build-fix-building-Perl-bindings.patch
new file mode 100644
index 0000000..92f7ec3
--- /dev/null
+++ b/debian/patches/0010-out-of-tree-build-fix-building-Perl-bindings.patch
@@ -0,0 +1,21 @@
+From: Hilko Bengen <bengen at hilluzination.de>
+Date: Sat, 13 Aug 2011 22:11:10 +0200
+Subject: out-of-tree build: fix building Perl bindings
+
+---
+ perl/Makefile.am | 1 +
+ 1 files changed, 1 insertions(+), 0 deletions(-)
+
+diff --git a/perl/Makefile.am b/perl/Makefile.am
+index 6212915..24e54c2 100644
+--- a/perl/Makefile.am
++++ b/perl/Makefile.am
+@@ -69,6 +69,7 @@ all: Makefile-pl src_deps
+ $(MAKE) -f Makefile-pl
+
+ Makefile-pl: Makefile.PL
++ -[ $(srcdir) != $(builddir) ] && cp -rsu $(abs_srcdir)/. $(builddir)/.
+ perl Makefile.PL INSTALLDIRS=$(INSTALLDIRS) PREFIX=$(prefix)
+
+ # No! Otherwise it is deleted before the clean-local rule runs.
+--
diff --git a/debian/patches/0011-out-of-tree-build-daemon.patch b/debian/patches/0011-out-of-tree-build-daemon.patch
new file mode 100644
index 0000000..c16c4eb
--- /dev/null
+++ b/debian/patches/0011-out-of-tree-build-daemon.patch
@@ -0,0 +1,26 @@
+From: Hilko Bengen <bengen at hilluzination.de>
+Date: Mon, 15 Aug 2011 00:48:11 +0200
+Subject: out-of-tree build: daemon
+
+---
+ daemon/Makefile.am | 4 ++--
+ 1 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/daemon/Makefile.am b/daemon/Makefile.am
+index 3fe8c88..c6c3cef 100644
+--- a/daemon/Makefile.am
++++ b/daemon/Makefile.am
+@@ -52,10 +52,10 @@ noinst_LIBRARIES = libprotocol.a
+ libprotocol_a_SOURCES = guestfs_protocol.c guestfs_protocol.h
+ libprotocol_a_CFLAGS = -Wall -Wno-unused -fno-strict-aliasing
+
+-guestfs_protocol.c: $(libsrcdir)/guestfs_protocol.c
++guestfs_protocol.c: $(srcdir)/guestfs_protocol.c
+ rm -f $@
+ ln $< $@
+-guestfs_protocol.h: $(libsrcdir)/guestfs_protocol.h
++guestfs_protocol.h: $(srcdir)/guestfs_protocol.h
+ rm -f $@
+ ln $< $@
+ $(libsrcdir)/guestfs_protocol.c: force
+--
diff --git a/debian/patches/0012-autoreconf.patch b/debian/patches/0012-autoreconf.patch
new file mode 100644
index 0000000..c516559
--- /dev/null
+++ b/debian/patches/0012-autoreconf.patch
@@ -0,0 +1,1279 @@
+From: Hilko Bengen <bengen at debian.org>
+Date: Sat, 20 Aug 2011 20:43:22 +0200
+Subject: autoreconf
+
+---
+ Makefile.in | 42 ++++++++++----------
+ aclocal.m4 | 14 ++++---
+ appliance/Makefile.in | 1 +
+ cat/Makefile.in | 8 ++--
+ configure | 91 +++++++++++++++++++++++++------------------
+ daemon/Makefile.in | 4 +-
+ df/Makefile.in | 4 +-
+ edit/Makefile.in | 4 +-
+ examples/Makefile.in | 10 ++--
+ fish/Makefile.in | 14 +++---
+ fuse/Makefile.in | 4 +-
+ generator/Makefile.in | 8 ++--
+ images/Makefile.in | 16 +++----
+ inspector/Makefile.in | 2 +-
+ java/examples/Makefile.in | 6 +-
+ ocaml/Makefile.in | 39 +++++++++---------
+ ocaml/examples/Makefile.in | 6 +-
+ perl/Makefile.in | 8 +++-
+ perl/examples/Makefile.in | 6 +-
+ po-docs/ja/Makefile.in | 18 ++++----
+ po-docs/uk/Makefile.in | 18 ++++----
+ python/Makefile.in | 5 +-
+ python/examples/Makefile.in | 6 +-
+ rescue/Makefile.in | 2 +-
+ resize/Makefile.in | 4 +-
+ ruby/examples/Makefile.in | 6 +-
+ src/Makefile.in | 14 +++---
+ test-tool/Makefile.in | 2 +-
+ tools/Makefile.in | 10 ++--
+ 29 files changed, 196 insertions(+), 176 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index 2eaf55f..7066536 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -70,7 +70,7 @@ host_triplet = @host@
+ DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
+ $(srcdir)/Makefile.in $(srcdir)/config.h.in \
+ $(srcdir)/libguestfs.pc.in $(srcdir)/podwrapper.sh.in \
+- $(top_srcdir)/configure $(top_srcdir)/debian/changelog.in \
++ $(srcdir)/run.in $(top_srcdir)/configure \
+ $(top_srcdir)/subdir-rules.mk ABOUT-NLS AUTHORS COPYING \
+ COPYING.LIB ChangeLog TODO build-aux/compile \
+ build-aux/config.guess build-aux/config.rpath \
+@@ -78,25 +78,26 @@ DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
+ build-aux/ltmain.sh build-aux/missing
+ @ENABLE_DAEMON_TRUE at am__append_1 = daemon
+ @ENABLE_APPLIANCE_TRUE at am__append_2 = appliance
++ at ENABLE_APPLIANCE_TRUE@am__append_3 = capitests caution regressions
+
+ # Language bindings.
+- at HAVE_PERL_TRUE@am__append_3 = perl perl/examples
+- at HAVE_OCAML_TRUE@am__append_4 = ocaml ocaml/examples
+- at HAVE_PYTHON_TRUE@am__append_5 = python python/examples
+- at HAVE_RUBY_TRUE@am__append_6 = ruby ruby/examples
+- at HAVE_JAVA_TRUE@am__append_7 = java java/examples
+- at HAVE_HASKELL_TRUE@am__append_8 = haskell
+- at HAVE_PHP_TRUE@am__append_9 = php
++ at HAVE_PERL_TRUE@am__append_4 = perl perl/examples
++ at HAVE_OCAML_TRUE@am__append_5 = ocaml ocaml/examples
++ at HAVE_PYTHON_TRUE@am__append_6 = python python/examples
++ at HAVE_RUBY_TRUE@am__append_7 = ruby ruby/examples
++ at HAVE_JAVA_TRUE@am__append_8 = java java/examples
++ at HAVE_HASKELL_TRUE@am__append_9 = haskell
++ at HAVE_PHP_TRUE@am__append_10 = php
+
+ # virt-resize 2.0 is written in OCaml.
+- at HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE at am__append_10 = resize
++ at HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE at am__append_11 = resize
+
+ # Perl tools and guestmount.
+- at HAVE_TOOLS_TRUE@am__append_11 = tools
+- at HAVE_FUSE_TRUE@am__append_12 = fuse
++ at HAVE_TOOLS_TRUE@am__append_12 = tools
++ at HAVE_FUSE_TRUE@am__append_13 = fuse
+
+ # po-docs must come after tools, inspector.
+- at HAVE_PO4A_TRUE@am__append_13 = po-docs
++ at HAVE_PO4A_TRUE@am__append_14 = po-docs
+ subdir = .
+ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+ am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
+@@ -196,7 +197,7 @@ am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
+ configure.lineno config.status.lineno
+ mkinstalldirs = $(install_sh) -d
+ CONFIG_HEADER = config.h
+-CONFIG_CLEAN_FILES = podwrapper.sh debian/changelog libguestfs.pc
++CONFIG_CLEAN_FILES = podwrapper.sh run libguestfs.pc
+ CONFIG_CLEAN_VPATH_FILES =
+ AM_V_GEN = $(am__v_GEN_$(V))
+ am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+@@ -244,7 +245,7 @@ AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
+ ETAGS = etags
+ CTAGS = ctags
+ DIST_SUBDIRS = gnulib/lib images generator src examples po daemon \
+- appliance gnulib/tests capitests caution regressions test-tool \
++ appliance gnulib/tests test-tool capitests caution regressions \
+ fish cat df edit inspector rescue perl perl/examples ocaml \
+ ocaml/examples python python/examples ruby ruby/examples java \
+ java/examples haskell php csharp resize tools fuse po-docs
+@@ -1181,12 +1182,11 @@ ACLOCAL_AMFLAGS = -I m4
+
+ # Unconditional because nothing is built yet.
+ SUBDIRS = gnulib/lib images generator src examples po $(am__append_1) \
+- $(am__append_2) gnulib/tests capitests caution regressions \
+- test-tool fish cat df edit inspector rescue $(am__append_3) \
+- $(am__append_4) $(am__append_5) $(am__append_6) \
+- $(am__append_7) $(am__append_8) $(am__append_9) csharp \
+- $(am__append_10) $(am__append_11) $(am__append_12) \
+- $(am__append_13)
++ $(am__append_2) gnulib/tests test-tool $(am__append_3) fish \
++ cat df edit inspector rescue $(am__append_4) $(am__append_5) \
++ $(am__append_6) $(am__append_7) $(am__append_8) \
++ $(am__append_9) $(am__append_10) csharp $(am__append_11) \
++ $(am__append_12) $(am__append_13) $(am__append_14)
+ EXTRA_DIST = \
+ $(generator_built) \
+ BUGS HACKING RELEASE-NOTES ROADMAP TODO \
+@@ -1331,7 +1331,7 @@ distclean-hdr:
+ -rm -f config.h stamp-h1
+ podwrapper.sh: $(top_builddir)/config.status $(srcdir)/podwrapper.sh.in
+ cd $(top_builddir) && $(SHELL) ./config.status $@
+-debian/changelog: $(top_builddir)/config.status $(top_srcdir)/debian/changelog.in
++run: $(top_builddir)/config.status $(srcdir)/run.in
+ cd $(top_builddir) && $(SHELL) ./config.status $@
+ libguestfs.pc: $(top_builddir)/config.status $(srcdir)/libguestfs.pc.in
+ cd $(top_builddir) && $(SHELL) ./config.status $@
+diff --git a/aclocal.m4 b/aclocal.m4
+index 7ee8e1e..faf58b0 100644
+--- a/aclocal.m4
++++ b/aclocal.m4
+@@ -47,7 +47,8 @@ To do so, use the procedure documented by the package, typically `autoreconf'.])
+ # ----------------------------------
+ AC_DEFUN([PKG_PROG_PKG_CONFIG],
+ [m4_pattern_forbid([^_?PKG_[A-Z_]+$])
+-m4_pattern_allow([^PKG_CONFIG(_PATH)?$])
++m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$])
++m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$])
+ AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
+ AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
+ AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
+@@ -93,7 +94,8 @@ m4_define([_PKG_CONFIG],
+ pkg_cv_[]$1="$$1"
+ elif test -n "$PKG_CONFIG"; then
+ PKG_CHECK_EXISTS([$3],
+- [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
++ [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes ],
+ [pkg_failed=yes])
+ else
+ pkg_failed=untried
+@@ -141,9 +143,9 @@ if test $pkg_failed = yes; then
+ AC_MSG_RESULT([no])
+ _PKG_SHORT_ERRORS_SUPPORTED
+ if test $_pkg_short_errors_supported = yes; then
+- $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1`
++ $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
+ else
+- $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1`
++ $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
+@@ -156,7 +158,7 @@ $$1_PKG_ERRORS
+ Consider adjusting the PKG_CONFIG_PATH environment variable if you
+ installed software in a non-standard prefix.
+
+-_PKG_TEXT])
++_PKG_TEXT])[]dnl
+ ])
+ elif test $pkg_failed = untried; then
+ AC_MSG_RESULT([no])
+@@ -167,7 +169,7 @@ path to pkg-config.
+
+ _PKG_TEXT
+
+-To get pkg-config, see <http://pkg-config.freedesktop.org/>.])
++To get pkg-config, see <http://pkg-config.freedesktop.org/>.])[]dnl
+ ])
+ else
+ $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
+diff --git a/appliance/Makefile.in b/appliance/Makefile.in
+index 799a39c..ce88122 100644
+--- a/appliance/Makefile.in
++++ b/appliance/Makefile.in
+@@ -1392,6 +1392,7 @@ supermin.d/daemon.img: ../daemon/guestfsd
+ mv $@-t $@
+
+ supermin.d/init.img: init
++ cmp -s $(srcdir)/init $(builddir)/init || cp $(srcdir)/init $(builddir)/init
+ mkdir -p supermin.d
+ rm -f $@ $@-t
+ echo "init" | cpio --quiet -o -H newc > $@-t
+diff --git a/cat/Makefile.in b/cat/Makefile.in
+index 05ba2ae..e53b774 100644
+--- a/cat/Makefile.in
++++ b/cat/Makefile.in
+@@ -1244,7 +1244,7 @@ TESTS_ENVIRONMENT = \
+ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+ TMPDIR=$(top_builddir)
+
+-TESTS = test-virt-cat.sh test-virt-filesystems.sh test-virt-ls.sh
++ at ENABLE_APPLIANCE_TRUE@TESTS = test-virt-cat.sh test-virt-filesystems.sh test-virt-ls.sh
+ all: all-am
+
+ .SUFFIXES:
+@@ -2049,7 +2049,7 @@ appliance: force
+ virt-cat.1 $(top_builddir)/html/virt-cat.1.html: stamp-virt-cat.pod
+
+ stamp-virt-cat.pod: virt-cat.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-cat.1 \
+ --html $(top_builddir)/html/virt-cat.1.html \
+ $<
+@@ -2058,7 +2058,7 @@ stamp-virt-cat.pod: virt-cat.pod
+ virt-ls.1 $(top_builddir)/html/virt-ls.1.html: stamp-virt-ls.pod
+
+ stamp-virt-ls.pod: virt-ls.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-ls.1 \
+ --html $(top_builddir)/html/virt-ls.1.html \
+ $<
+@@ -2067,7 +2067,7 @@ stamp-virt-ls.pod: virt-ls.pod
+ virt-filesystems.1 $(top_builddir)/html/virt-filesystems.1.html: stamp-virt-filesystems.pod
+
+ stamp-virt-filesystems.pod: virt-filesystems.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-filesystems.1 \
+ --html $(top_builddir)/html/virt-filesystems.1.html \
+ $<
+diff --git a/configure b/configure
+index 4a72439..c1b1bb5 100755
+--- a/configure
++++ b/configure
+@@ -36068,8 +36068,7 @@ fi
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_appliance" >&5
+ $as_echo "$enable_appliance" >&6; }
+
+-if test "x$enable_appliance" = "xyes"; then
+- # Extract the first word of "febootstrap", so it can be a program name with args.
++# Extract the first word of "febootstrap", so it can be a program name with args.
+ set dummy febootstrap; ac_word=$2
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+ $as_echo_n "checking for $ac_word... " >&6; }
+@@ -36107,12 +36106,8 @@ $as_echo "no" >&6; }
+ fi
+
+
+- test "x$FEBOOTSTRAP" = "xno" &&
+- as_fn_error $? "febootstrap must be installed" "$LINENO" 5
+- $FEBOOTSTRAP --version >&5 2>&1 ||
+- as_fn_error $? "febootstrap >= 3.0 must be installed, your version is too old" "$LINENO" 5
+
+- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if user requested febootstrap --yum-config option" >&5
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if user requested febootstrap --yum-config option" >&5
+ $as_echo_n "checking if user requested febootstrap --yum-config option... " >&6; }
+
+ # Check whether --with-febootstrap-yum-config was given.
+@@ -36122,26 +36117,32 @@ else
+ FEBOOTSTRAP_YUM_CONFIG=no
+ fi
+
+- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FEBOOTSTRAP_YUM_CONFIG" >&5
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $FEBOOTSTRAP_YUM_CONFIG" >&5
+ $as_echo "$FEBOOTSTRAP_YUM_CONFIG" >&6; }
+
+
+- { $as_echo "$as_me:${as_lineno-$LINENO}: checking which Linux distro for package names" >&5
++if test "x$enable_appliance" = "xyes"; then
++ test "x$FEBOOTSTRAP" = "xno" &&
++ as_fn_error $? "febootstrap must be installed" "$LINENO" 5
++ $FEBOOTSTRAP --version >&5 2>&1 ||
++ as_fn_error $? "febootstrap >= 3.0 must be installed, your version is too old" "$LINENO" 5
++fi
++
++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking which Linux distro for package names" >&5
+ $as_echo_n "checking which Linux distro for package names... " >&6; }
+- DISTRO=REDHAT
+- if test -f /etc/debian_version; then
+- DISTRO=DEBIAN
+- if grep -q 'DISTRIB_ID=Ubuntu' /etc/lsb-release 2>&5; then
+- DISTRO=UBUNTU
+- fi
+- fi
+- if test -f /etc/arch-release; then
+- DISTRO=ARCHLINUX
++DISTRO=REDHAT
++if test -f /etc/debian_version; then
++ DISTRO=DEBIAN
++ if grep -q 'DISTRIB_ID=Ubuntu' /etc/lsb-release 2>&5; then
++ DISTRO=UBUNTU
+ fi
+- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DISTRO" >&5
++fi
++if test -f /etc/arch-release; then
++ DISTRO=ARCHLINUX
++fi
++{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DISTRO" >&5
+ $as_echo "$DISTRO" >&6; }
+
+-fi
+
+ # Extract the first word of "rpcgen", so it can be a program name with args.
+ set dummy rpcgen; ac_word=$2
+@@ -38791,6 +38792,7 @@ $as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
+
+
+
++
+ if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
+ if test -n "$ac_tool_prefix"; then
+ # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
+@@ -38919,6 +38921,7 @@ if test -n "$PCRE_CFLAGS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PCRE_CFLAGS=`$PKG_CONFIG --cflags "libpcre" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -38935,6 +38938,7 @@ if test -n "$PCRE_LIBS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_PCRE_LIBS=`$PKG_CONFIG --libs "libpcre" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -38954,9 +38958,9 @@ else
+ _pkg_short_errors_supported=no
+ fi
+ if test $_pkg_short_errors_supported = yes; then
+- PCRE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpcre" 2>&1`
++ PCRE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libpcre" 2>&1`
+ else
+- PCRE_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpcre" 2>&1`
++ PCRE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libpcre" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$PCRE_PKG_ERRORS" >&5
+@@ -38971,7 +38975,6 @@ installed software in a non-standard prefix.
+ Alternatively, you may set the environment variables PCRE_CFLAGS
+ and PCRE_LIBS to avoid the need to call pkg-config.
+ See the pkg-config man page for more details." "$LINENO" 5
+-
+ elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+ $as_echo "no" >&6; }
+@@ -38987,7 +38990,6 @@ See the pkg-config man page for more details.
+
+ To get pkg-config, see <http://pkg-config.freedesktop.org/>.
+ See \`config.log' for more details" "$LINENO" 5; }
+-
+ else
+ PCRE_CFLAGS=$pkg_cv_PCRE_CFLAGS
+ PCRE_LIBS=$pkg_cv_PCRE_LIBS
+@@ -39066,6 +39068,7 @@ if test -n "$LIBVIRT_CFLAGS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_LIBVIRT_CFLAGS=`$PKG_CONFIG --cflags "libvirt" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -39082,6 +39085,7 @@ if test -n "$LIBVIRT_LIBS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_LIBVIRT_LIBS=`$PKG_CONFIG --libs "libvirt" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -39101,9 +39105,9 @@ else
+ _pkg_short_errors_supported=no
+ fi
+ if test $_pkg_short_errors_supported = yes; then
+- LIBVIRT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libvirt" 2>&1`
++ LIBVIRT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libvirt" 2>&1`
+ else
+- LIBVIRT_PKG_ERRORS=`$PKG_CONFIG --print-errors "libvirt" 2>&1`
++ LIBVIRT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libvirt" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$LIBVIRT_PKG_ERRORS" >&5
+@@ -39151,6 +39155,7 @@ if test -n "$LIBXML2_CFLAGS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -39167,6 +39172,7 @@ if test -n "$LIBXML2_LIBS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -39186,9 +39192,9 @@ else
+ _pkg_short_errors_supported=no
+ fi
+ if test $_pkg_short_errors_supported = yes; then
+- LIBXML2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libxml-2.0" 2>&1`
++ LIBXML2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxml-2.0" 2>&1`
+ else
+- LIBXML2_PKG_ERRORS=`$PKG_CONFIG --print-errors "libxml-2.0" 2>&1`
++ LIBXML2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxml-2.0" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$LIBXML2_PKG_ERRORS" >&5
+@@ -39236,6 +39242,7 @@ if test -n "$LIBCONFIG_CFLAGS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_LIBCONFIG_CFLAGS=`$PKG_CONFIG --cflags "libconfig" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -39252,6 +39259,7 @@ if test -n "$LIBCONFIG_LIBS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_LIBCONFIG_LIBS=`$PKG_CONFIG --libs "libconfig" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -39271,9 +39279,9 @@ else
+ _pkg_short_errors_supported=no
+ fi
+ if test $_pkg_short_errors_supported = yes; then
+- LIBCONFIG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libconfig" 2>&1`
++ LIBCONFIG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libconfig" 2>&1`
+ else
+- LIBCONFIG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libconfig" 2>&1`
++ LIBCONFIG_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libconfig" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$LIBCONFIG_PKG_ERRORS" >&5
+@@ -39321,6 +39329,7 @@ if test -n "$HIVEX_CFLAGS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_HIVEX_CFLAGS=`$PKG_CONFIG --cflags "hivex" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -39337,6 +39346,7 @@ if test -n "$HIVEX_LIBS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_HIVEX_LIBS=`$PKG_CONFIG --libs "hivex" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -39356,9 +39366,9 @@ else
+ _pkg_short_errors_supported=no
+ fi
+ if test $_pkg_short_errors_supported = yes; then
+- HIVEX_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "hivex" 2>&1`
++ HIVEX_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "hivex" 2>&1`
+ else
+- HIVEX_PKG_ERRORS=`$PKG_CONFIG --print-errors "hivex" 2>&1`
++ HIVEX_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "hivex" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$HIVEX_PKG_ERRORS" >&5
+@@ -39414,6 +39424,7 @@ if test -n "$FUSE_CFLAGS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_FUSE_CFLAGS=`$PKG_CONFIG --cflags "fuse" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -39430,6 +39441,7 @@ if test -n "$FUSE_LIBS"; then
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_FUSE_LIBS=`$PKG_CONFIG --libs "fuse" 2>/dev/null`
++ test "x$?" != "x0" && pkg_failed=yes
+ else
+ pkg_failed=yes
+ fi
+@@ -39449,9 +39461,9 @@ else
+ _pkg_short_errors_supported=no
+ fi
+ if test $_pkg_short_errors_supported = yes; then
+- FUSE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "fuse" 2>&1`
++ FUSE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "fuse" 2>&1`
+ else
+- FUSE_PKG_ERRORS=`$PKG_CONFIG --print-errors "fuse" 2>&1`
++ FUSE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "fuse" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$FUSE_PKG_ERRORS" >&5
+@@ -40678,13 +40690,13 @@ fi
+ if test "x$PYTHON" != "xno"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python prefix" >&5
+ $as_echo_n "checking Python prefix... " >&6; }
+- PYTHON_PREFIX=`$PYTHON -c "import sys; print sys.prefix"`
++ PYTHON_PREFIX=`$PYTHON -c "import sys; print (sys.prefix)"`
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_PREFIX" >&5
+ $as_echo "$PYTHON_PREFIX" >&6; }
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python version" >&5
+ $as_echo_n "checking Python version... " >&6; }
+- PYTHON_VERSION=`$PYTHON -c "import sys; print sys.version[0:3]"`
++ PYTHON_VERSION=`$PYTHON -c "import sys; print (sys.version[0:3])"`
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_VERSION" >&5
+ $as_echo "$PYTHON_VERSION" >&6; }
+
+@@ -41221,7 +41233,9 @@ ac_config_headers="$ac_config_headers config.h"
+
+ ac_config_files="$ac_config_files podwrapper.sh"
+
+-ac_config_files="$ac_config_files Makefile appliance/Makefile capitests/Makefile cat/Makefile caution/Makefile csharp/Makefile debian/changelog df/Makefile edit/Makefile examples/Makefile fish/Makefile fuse/Makefile generator/Makefile gnulib/lib/Makefile gnulib/tests/Makefile haskell/Makefile images/Makefile inspector/Makefile java/Makefile java/examples/Makefile libguestfs.pc ocaml/META ocaml/Makefile ocaml/examples/Makefile perl/Makefile perl/Makefile.PL perl/examples/Makefile php/Makefile po-docs/Makefile po-docs/ja/Makefile po-docs/uk/Makefile po/Makefile.in python/Makefile python/examples/Makefile regressions/Makefile rescue/Makefile resize/Makefile ruby/Makefile ruby/Rakefile ruby/examples/Makefile src/Makefile test-tool/Makefile tools/Makefile"
++ac_config_files="$ac_config_files run"
++
++ac_config_files="$ac_config_files Makefile appliance/Makefile capitests/Makefile cat/Makefile caution/Makefile csharp/Makefile df/Makefile edit/Makefile examples/Makefile fish/Makefile fuse/Makefile generator/Makefile gnulib/lib/Makefile gnulib/tests/Makefile haskell/Makefile images/Makefile inspector/Makefile java/Makefile java/examples/Makefile libguestfs.pc ocaml/META ocaml/Makefile ocaml/examples/Makefile perl/Makefile perl/Makefile.PL perl/examples/Makefile php/Makefile po-docs/Makefile po-docs/ja/Makefile po-docs/uk/Makefile po/Makefile.in python/Makefile python/examples/Makefile regressions/Makefile rescue/Makefile resize/Makefile ruby/Makefile ruby/Rakefile ruby/examples/Makefile src/Makefile test-tool/Makefile tools/Makefile"
+
+ cat >confcache <<\_ACEOF
+ # This file is a shell script that caches the results of configure
+@@ -42401,13 +42415,13 @@ do
+ "po-directories") CONFIG_COMMANDS="$CONFIG_COMMANDS po-directories" ;;
+ "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
+ "podwrapper.sh") CONFIG_FILES="$CONFIG_FILES podwrapper.sh" ;;
++ "run") CONFIG_FILES="$CONFIG_FILES run" ;;
+ "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
+ "appliance/Makefile") CONFIG_FILES="$CONFIG_FILES appliance/Makefile" ;;
+ "capitests/Makefile") CONFIG_FILES="$CONFIG_FILES capitests/Makefile" ;;
+ "cat/Makefile") CONFIG_FILES="$CONFIG_FILES cat/Makefile" ;;
+ "caution/Makefile") CONFIG_FILES="$CONFIG_FILES caution/Makefile" ;;
+ "csharp/Makefile") CONFIG_FILES="$CONFIG_FILES csharp/Makefile" ;;
+- "debian/changelog") CONFIG_FILES="$CONFIG_FILES debian/changelog" ;;
+ "df/Makefile") CONFIG_FILES="$CONFIG_FILES df/Makefile" ;;
+ "edit/Makefile") CONFIG_FILES="$CONFIG_FILES edit/Makefile" ;;
+ "examples/Makefile") CONFIG_FILES="$CONFIG_FILES examples/Makefile" ;;
+@@ -43911,6 +43925,7 @@ fi
+ esac
+ done ;;
+ "podwrapper.sh":F) chmod +x podwrapper.sh ;;
++ "run":F) chmod +x run ;;
+
+ esac
+ done # for ac_tag
+diff --git a/daemon/Makefile.in b/daemon/Makefile.in
+index ab188ca..fa13869 100644
+--- a/daemon/Makefile.in
++++ b/daemon/Makefile.in
+@@ -3126,10 +3126,10 @@ $(generator_built): $(generatorsrcdir)/stamp-generator
+ $(generatorsrcdir)/stamp-generator: force
+ $(MAKE) -C $(generatorsrcdir) stamp-generator
+
+-guestfs_protocol.c: $(libsrcdir)/guestfs_protocol.c
++guestfs_protocol.c: $(srcdir)/guestfs_protocol.c
+ rm -f $@
+ ln $< $@
+-guestfs_protocol.h: $(libsrcdir)/guestfs_protocol.h
++guestfs_protocol.h: $(srcdir)/guestfs_protocol.h
+ rm -f $@
+ ln $< $@
+ $(libsrcdir)/guestfs_protocol.c: force
+diff --git a/df/Makefile.in b/df/Makefile.in
+index 5675a8d..e484854 100644
+--- a/df/Makefile.in
++++ b/df/Makefile.in
+@@ -1184,7 +1184,7 @@ TESTS_ENVIRONMENT = \
+ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+ TMPDIR=$(top_builddir)
+
+-TESTS = test-virt-df.sh
++ at ENABLE_APPLIANCE_TRUE@TESTS = test-virt-df.sh
+ all: all-am
+
+ .SUFFIXES:
+@@ -1830,7 +1830,7 @@ appliance: force
+ virt-df.1 $(top_builddir)/html/virt-df.1.html: stamp-virt-df.pod
+
+ stamp-virt-df.pod: virt-df.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-df.1 \
+ --html $(top_builddir)/html/virt-df.1.html \
+ $<
+diff --git a/edit/Makefile.in b/edit/Makefile.in
+index f0aa0a1..667f0bf 100644
+--- a/edit/Makefile.in
++++ b/edit/Makefile.in
+@@ -1173,7 +1173,7 @@ TESTS_ENVIRONMENT = \
+ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+ TMPDIR=$(top_builddir)
+
+-TESTS = test-virt-edit.sh
++ at ENABLE_APPLIANCE_TRUE@TESTS = test-virt-edit.sh
+ all: all-am
+
+ .SUFFIXES:
+@@ -1768,7 +1768,7 @@ appliance: force
+ virt-edit.1 $(top_builddir)/html/virt-edit.1.html: stamp-virt-edit.pod
+
+ stamp-virt-edit.pod: virt-edit.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-edit.1 \
+ --html $(top_builddir)/html/virt-edit.1.html \
+ $<
+diff --git a/examples/Makefile.in b/examples/Makefile.in
+index 8c3755f..fb2b708 100644
+--- a/examples/Makefile.in
++++ b/examples/Makefile.in
+@@ -1611,19 +1611,19 @@ uninstall-man: uninstall-man1 uninstall-man3
+ guestfs-examples.3 $(top_builddir)/html/guestfs-examples.3.html: stamp-guestfs-examples.pod
+
+ stamp-guestfs-examples.pod: guestfs-examples.pod create_disk.c inspect_vm.c
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-examples.3 \
+ --html $(top_builddir)/html/guestfs-examples.3.html \
+- --verbatim create_disk.c:@EXAMPLE1@ \
+- --verbatim inspect_vm.c:@EXAMPLE2@ \
++ --verbatim $(srcdir)/create_disk.c:@EXAMPLE1@ \
++ --verbatim $(srcdir)/inspect_vm.c:@EXAMPLE2@ \
+ $<
+ touch $@
+
+ guestfs-recipes.1 $(top_builddir)/html/guestfs-recipes.1.html: stamp-guestfs-recipes.pod
+
+-stamp-guestfs-recipes.pod: guestfs-recipes.pod create_disk.c inspect_vm.c
+- $(top_srcdir)/podwrapper.sh \
++stamp-guestfs-recipes.pod: guestfs-recipes.pod
++ $(top_builddir)/podwrapper.sh \
+ --section 1 \
+ --man guestfs-recipes.1 \
+ --html $(top_builddir)/html/guestfs-recipes.1.html \
+diff --git a/fish/Makefile.in b/fish/Makefile.in
+index 3a1b9b2..0cd95ab 100644
+--- a/fish/Makefile.in
++++ b/fish/Makefile.in
+@@ -2391,18 +2391,18 @@ cmds_gperf.c: cmds_gperf.gperf
+ guestfish.1 $(top_builddir)/html/guestfish.1.html: stamp-guestfish.pod
+
+ stamp-guestfish.pod: guestfish.pod guestfish-actions.pod guestfish-commands.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man guestfish.1 \
+ --html $(top_builddir)/html/guestfish.1.html \
+- --insert guestfish-actions.pod:@ACTIONS@ \
+- --insert guestfish-commands.pod:@FISH_COMMANDS@ \
++ --insert $(srcdir)/guestfish-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfish-commands.pod:@FISH_COMMANDS@ \
+ $<
+ touch $@
+
+ virt-copy-in.1 $(top_builddir)/html/virt-copy-in.1.html: stamp-virt-copy-in.pod
+
+ stamp-virt-copy-in.pod: virt-copy-in.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-copy-in.1 \
+ --html $(top_builddir)/html/virt-copy-in.1.html \
+ $<
+@@ -2411,7 +2411,7 @@ stamp-virt-copy-in.pod: virt-copy-in.pod
+ virt-copy-out.1 $(top_builddir)/html/virt-copy-out.1.html: stamp-virt-copy-out.pod
+
+ stamp-virt-copy-out.pod: virt-copy-out.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-copy-out.1 \
+ --html $(top_builddir)/html/virt-copy-out.1.html \
+ $<
+@@ -2420,7 +2420,7 @@ stamp-virt-copy-out.pod: virt-copy-out.pod
+ virt-tar-in.1 $(top_builddir)/html/virt-tar-in.1.html: stamp-virt-tar-in.pod
+
+ stamp-virt-tar-in.pod: virt-tar-in.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-tar-in.1 \
+ --html $(top_builddir)/html/virt-tar-in.1.html \
+ $<
+@@ -2429,7 +2429,7 @@ stamp-virt-tar-in.pod: virt-tar-in.pod
+ virt-tar-out.1 $(top_builddir)/html/virt-tar-out.1.html: stamp-virt-tar-out.pod
+
+ stamp-virt-tar-out.pod: virt-tar-out.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-tar-out.1 \
+ --html $(top_builddir)/html/virt-tar-out.1.html \
+ $<
+diff --git a/fuse/Makefile.in b/fuse/Makefile.in
+index 9d271ba..bd53845 100644
+--- a/fuse/Makefile.in
++++ b/fuse/Makefile.in
+@@ -1180,7 +1180,7 @@ CLEANFILES = stamp-guestmount.pod
+ @HAVE_FUSE_TRUE at noinst_DATA = $(top_builddir)/html/guestmount.1.html
+
+ # Tests.
+- at HAVE_FUSE_TRUE@TESTS = test-fuse.sh
++ at ENABLE_APPLIANCE_TRUE@@HAVE_FUSE_TRUE at TESTS = test-fuse.sh
+ @HAVE_FUSE_TRUE at TESTS_ENVIRONMENT = \
+ @HAVE_FUSE_TRUE@ top_builddir=..
+
+@@ -1795,7 +1795,7 @@ appliance: force
+ @HAVE_FUSE_TRUE at guestmount.1 $(top_builddir)/html/guestmount.1.html: stamp-guestmount.pod
+
+ @HAVE_FUSE_TRUE at stamp-guestmount.pod: guestmount.pod
+- at HAVE_FUSE_TRUE@ $(top_srcdir)/podwrapper.sh \
++ at HAVE_FUSE_TRUE@ $(top_builddir)/podwrapper.sh \
+ @HAVE_FUSE_TRUE@ --man guestmount.1 \
+ @HAVE_FUSE_TRUE@ --html $(top_builddir)/html/guestmount.1.html \
+ @HAVE_FUSE_TRUE@ $<
+diff --git a/generator/Makefile.in b/generator/Makefile.in
+index 0ffc04f..d7dbc16 100644
+--- a/generator/Makefile.in
++++ b/generator/Makefile.in
+@@ -1276,14 +1276,14 @@ uninstall-am:
+ mostlyclean-libtool pdf pdf-am ps ps-am uninstall uninstall-am
+
+
+- at HAVE_OCAML_TRUE@generator: $(OBJECTS)
+- at HAVE_OCAML_TRUE@ $(OCAMLC) -o generator $(OCAMLCFLAGS) $(OCAMLCLIBS) $(OBJECTS)
++ at HAVE_OCAML_TRUE@$(srcdir)/generator: $(OBJECTS)
++ at HAVE_OCAML_TRUE@ $(OCAMLC) -I $(srcdir) -o $@ $(OCAMLCFLAGS) $(OCAMLCLIBS) $(OBJECTS)
+
+ @HAVE_OCAML_TRUE at .ml.cmo:
+- at HAVE_OCAML_TRUE@ $(OCAMLC) $(OCAMLCFLAGS) -c $< -o $@
++ at HAVE_OCAML_TRUE@ $(OCAMLC) -I $(srcdir) $(OCAMLCFLAGS) -c $< -o $@
+
+ @HAVE_OCAML_TRUE at .mli.cmi:
+- at HAVE_OCAML_TRUE@ $(OCAMLC) $(OCAMLCFLAGS) -c $< -o $@
++ at HAVE_OCAML_TRUE@ $(OCAMLC) -I $(srcdir) $(OCAMLCFLAGS) -c $< -o $@
+
+ @HAVE_OCAML_TRUE at depend: .depend
+
+diff --git a/images/Makefile.in b/images/Makefile.in
+index c9adda6..35ed8ca 100644
+--- a/images/Makefile.in
++++ b/images/Makefile.in
+@@ -1099,7 +1099,7 @@ noinst_DATA = test.iso
+
+ # This is 'check_DATA' because we don't need it until 'make check'
+ # time and we need the tools we have built in order to make it.
+-check_DATA = debian.img fedora.img ubuntu.img windows.img
++ at ENABLE_APPLIANCE_TRUE@check_DATA = debian.img fedora.img ubuntu.img windows.img
+ CLEANFILES = \
+ test.iso test.sqsh \
+ 100kallzeroes 100kallnewlines 100kallspaces 100krandom 10klines \
+@@ -1426,41 +1426,39 @@ $(builddir)/test-grep.txt.gz: test-grep.txt
+ fedora.img: guest-aux/make-fedora-img.sh \
+ guest-aux/fedora-name.db \
+ guest-aux/fedora-packages.db
+- LIBGUESTFS_PATH=$(top_builddir)/appliance \
+- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
+ TMPDIR=$(top_builddir) \
++ SRCDIR=$(srcdir) \
+ bash $<
+
+ guest-aux/fedora-name.db: guest-aux/fedora-name.db.txt
+ rm -f $@ $@-t
++ mkdir -p guest-aux
+ $(DB_LOAD) $@-t < $<
+ mv $@-t $@
+
+ guest-aux/fedora-packages.db: guest-aux/fedora-packages.db.txt
+ rm -f $@ $@-t
++ mkdir -p guest-aux
+ $(DB_LOAD) $@-t < $<
+ mv $@-t $@
+
+ # Make a (dummy) Debian image.
+ debian.img: guest-aux/make-debian-img.sh
+- LIBGUESTFS_PATH=$(top_builddir)/appliance \
+- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
+ TMPDIR=$(top_builddir) \
++ SRCDIR=$(srcdir) \
+ bash $<
+
+ # Make a (dummy) Ubuntu image.
+ ubuntu.img: guest-aux/make-ubuntu-img.sh
+- LIBGUESTFS_PATH=$(top_builddir)/appliance \
+- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
+ TMPDIR=$(top_builddir) \
++ SRCDIR=$(srcdir) \
+ bash $<
+
+ # Make a (dummy) Windows image.
+ windows.img: guest-aux/make-windows-img.sh \
+ guest-aux/windows-software guest-aux/windows-system
+- LIBGUESTFS_PATH=$(top_builddir)/appliance \
+- LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
+ TMPDIR=$(top_builddir) \
++ SRCDIR=$(srcdir) \
+ bash $<
+
+ # Since users might not have the tools needed to create this, we
+diff --git a/inspector/Makefile.in b/inspector/Makefile.in
+index 31dd84e..e5835bd 100644
+--- a/inspector/Makefile.in
++++ b/inspector/Makefile.in
+@@ -1813,7 +1813,7 @@ appliance: force
+ @HAVE_LIBXML2_TRUE at virt-inspector.1 $(top_builddir)/html/virt-inspector.1.html: stamp-virt-inspector.pod
+
+ @HAVE_LIBXML2_TRUE at stamp-virt-inspector.pod: virt-inspector.pod
+- at HAVE_LIBXML2_TRUE@ $(top_srcdir)/podwrapper.sh \
++ at HAVE_LIBXML2_TRUE@ $(top_builddir)/podwrapper.sh \
+ @HAVE_LIBXML2_TRUE@ --man virt-inspector.1 \
+ @HAVE_LIBXML2_TRUE@ --html $(top_builddir)/html/virt-inspector.1.html \
+ @HAVE_LIBXML2_TRUE@ $<
+diff --git a/java/examples/Makefile.in b/java/examples/Makefile.in
+index 600bf7c..7107c8c 100644
+--- a/java/examples/Makefile.in
++++ b/java/examples/Makefile.in
+@@ -1331,12 +1331,12 @@ uninstall-man: uninstall-man3
+ guestfs-java.3 $(top_builddir)/html/guestfs-java.3.html: stamp-guestfs-java.pod
+
+ stamp-guestfs-java.pod: guestfs-java.pod CreateDisk.java InspectVM.java
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-java.3 \
+ --html $(top_builddir)/html/guestfs-java.3.html \
+- --verbatim CreateDisk.java:@EXAMPLE1@ \
+- --verbatim InspectVM.java:@EXAMPLE2@ \
++ --verbatim $(srcdir)/CreateDisk.java:@EXAMPLE1@ \
++ --verbatim $(srcdir)/InspectVM.java:@EXAMPLE2@ \
+ $<
+ touch $@
+
+diff --git a/ocaml/Makefile.in b/ocaml/Makefile.in
+index 387066f..a374682 100644
+--- a/ocaml/Makefile.in
++++ b/ocaml/Makefile.in
+@@ -71,7 +71,11 @@ DIST_COMMON = $(srcdir)/.depend $(srcdir)/META.in \
+ $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+ $(top_srcdir)/subdir-rules.mk
+ @HAVE_OCAMLDOC_TRUE@@HAVE_OCAML_TRUE at am__append_1 = html/index.html
+- at HAVE_OCAML_TRUE@am__append_2 = $(noinst_DATA)
++ at ENABLE_APPLIANCE_TRUE@@HAVE_OCAML_TRUE at am__append_2 = t/guestfs_010_basic \
++ at ENABLE_APPLIANCE_TRUE@@HAVE_OCAML_TRUE@ t/guestfs_070_threads \
++ at ENABLE_APPLIANCE_TRUE@@HAVE_OCAML_TRUE@ t/guestfs_400_progress
++
++ at HAVE_OCAML_TRUE@am__append_3 = $(noinst_DATA)
+ subdir = ocaml
+ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+ am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
+@@ -1084,7 +1088,7 @@ EXTRA_DIST = \
+ t/*.ml
+
+ CLEANFILES = *.cmi *.cmo *.cmx *.cma *.cmxa *.o *.a *.so t/*.cmi \
+- t/*.cmo t/*.cmx t/*.o t/*.a t/*.so $(am__append_2)
++ t/*.cmo t/*.cmx t/*.o t/*.a t/*.so $(am__append_3)
+ AM_CPPFLAGS = -I$(top_builddir) -I$(OCAMLLIB) -I$(top_srcdir)/ocaml \
+ -I$(top_srcdir)/src -I$(top_builddir)/src \
+ $(WARN_CFLAGS) $(WERROR_CFLAGS)
+@@ -1102,14 +1106,9 @@ AM_CPPFLAGS = -I$(top_builddir) -I$(OCAMLLIB) -I$(top_srcdir)/ocaml \
+ @HAVE_OCAML_TRUE@ TMPDIR=$(top_builddir) \
+ @HAVE_OCAML_TRUE@ $(VG)
+
+- at HAVE_OCAML_TRUE@TESTS = run-bindtests \
+- at HAVE_OCAML_TRUE@ t/guestfs_005_load \
+- at HAVE_OCAML_TRUE@ t/guestfs_010_basic \
+- at HAVE_OCAML_TRUE@ t/guestfs_070_threads \
+- at HAVE_OCAML_TRUE@ t/guestfs_080_optargs \
+- at HAVE_OCAML_TRUE@ t/guestfs_400_events \
+- at HAVE_OCAML_TRUE@ t/guestfs_400_progress
+-
++ at HAVE_OCAML_TRUE@TESTS = run-bindtests t/guestfs_005_load \
++ at HAVE_OCAML_TRUE@ t/guestfs_080_optargs t/guestfs_400_events \
++ at HAVE_OCAML_TRUE@ $(am__append_2)
+ @HAVE_OCAML_TRUE at SUFFIXES = .cmo .cmi .cmx .ml .mli .mll .mly
+ all: all-am
+
+@@ -1428,9 +1427,9 @@ appliance: force
+ @HAVE_OCAML_TRUE@ $(CC) $(AM_CPPFLAGS) $(CFLAGS) -fPIC -Wall -c $<
+
+ @HAVE_OCAML_TRUE at guestfs_c_actions.o: guestfs_c_actions.c
+- at HAVE_OCAML_TRUE@ $(CC) $(AM_CPPFLAGS) $(CFLAGS) -fPIC -Wall -c $<
++ at HAVE_OCAML_TRUE@ $(CC) $(AM_CPPFLAGS) $(CFLAGS) -fPIC -Wall -c $(srcdir)/$<
+
+- at HAVE_OCAMLDOC_TRUE@@HAVE_OCAML_TRUE at html/index.html: guestfs*.mli guestfs*.ml
++ at HAVE_OCAMLDOC_TRUE@@HAVE_OCAML_TRUE at html/index.html: $(srcdir)/guestfs*.mli $(srcdir)/guestfs*.ml
+ @HAVE_OCAMLDOC_TRUE@@HAVE_OCAML_TRUE@ mkdir -p html
+ @HAVE_OCAMLDOC_TRUE@@HAVE_OCAML_TRUE@ -$(OCAMLDOC) -d html -html $^
+
+@@ -1468,14 +1467,14 @@ appliance: force
+ @HAVE_OCAML_TRUE@ $(OCAMLFIND) ocamlopt -package unix,threads -thread -linkpkg -c $< -o $@
+
+ @HAVE_OCAML_TRUE at t/%.cmx: t/%.ml mlguestfs.cmxa
+- at HAVE_OCAML_TRUE@ $(OCAMLFIND) ocamlopt -package unix -linkpkg -c $< -o $@
++ at HAVE_OCAML_TRUE@ $(OCAMLFIND) ocamlopt -package unix -linkpkg -c $< -o $(builddir)/$@
+
+- at HAVE_OCAML_TRUE@.mli.cmi:
+- at HAVE_OCAML_TRUE@ $(OCAMLFIND) ocamlc -package unix -c $< -o $@
+- at HAVE_OCAML_TRUE@.ml.cmo:
+- at HAVE_OCAML_TRUE@ $(OCAMLFIND) ocamlc -package unix -c $< -o $@
+- at HAVE_OCAML_TRUE@.ml.cmx:
+- at HAVE_OCAML_TRUE@ $(OCAMLFIND) ocamlopt -package unix -c $< -o $@
++ at HAVE_OCAML_TRUE@%.cmi: %.mli
++ at HAVE_OCAML_TRUE@ $(OCAMLFIND) ocamlc -package unix -c $< -o $(builddir)/$@
++ at HAVE_OCAML_TRUE@%.cmo: %.ml
++ at HAVE_OCAML_TRUE@ $(OCAMLFIND) ocamlc -package unix -c $< -o $(builddir)/$@
++ at HAVE_OCAML_TRUE@%.cmx: %.ml
++ at HAVE_OCAML_TRUE@ $(OCAMLFIND) ocamlopt -package unix -c $< -o $(builddir)/$@
+
+ @HAVE_OCAML_TRUE at depend: .depend
+
+@@ -1496,7 +1495,7 @@ appliance: force
+ @HAVE_OCAML_TRUE@ $(OCAMLFIND) install \
+ @HAVE_OCAML_TRUE@ -ldconf ignore -destdir $(DESTDIR)$(OCAMLLIB) \
+ @HAVE_OCAML_TRUE@ guestfs \
+- at HAVE_OCAML_TRUE@ META *.so *.a *.cma *.cmx *.cmxa *.cmi *.mli
++ at HAVE_OCAML_TRUE@ META *.so *.a *.cma *.cmx *.cmxa *.cmi $(srcdir)/*.mli
+
+ # Tell version 3.79 and up of GNU make to not build goals in this
+ # directory in parallel. (Possible solution for RHBZ#502309).
+diff --git a/ocaml/examples/Makefile.in b/ocaml/examples/Makefile.in
+index 0fa57f5..c3a33e1 100644
+--- a/ocaml/examples/Makefile.in
++++ b/ocaml/examples/Makefile.in
+@@ -1332,12 +1332,12 @@ uninstall-man: uninstall-man3
+ guestfs-ocaml.3 $(top_builddir)/html/guestfs-ocaml.3.html: stamp-guestfs-ocaml.pod
+
+ stamp-guestfs-ocaml.pod: guestfs-ocaml.pod create_disk.ml inspect_vm.ml
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-ocaml.3 \
+ --html $(top_builddir)/html/guestfs-ocaml.3.html \
+- --verbatim create_disk.ml:@EXAMPLE1@ \
+- --verbatim inspect_vm.ml:@EXAMPLE2@ \
++ --verbatim $(srcdir)/create_disk.ml:@EXAMPLE1@ \
++ --verbatim $(srcdir)/inspect_vm.ml:@EXAMPLE2@ \
+ $<
+ touch $@
+
+diff --git a/perl/Makefile.in b/perl/Makefile.in
+index a1186ff..79dd8c4 100644
+--- a/perl/Makefile.in
++++ b/perl/Makefile.in
+@@ -68,6 +68,8 @@ build_triplet = @build@
+ host_triplet = @host@
+ DIST_COMMON = README $(srcdir)/Makefile.PL.in $(srcdir)/Makefile.am \
+ $(srcdir)/Makefile.in $(top_srcdir)/subdir-rules.mk
++ at ENABLE_APPLIANCE_TRUE@@HAVE_PERL_TRUE at am__append_1 = appliance
++ at ENABLE_APPLIANCE_TRUE@@HAVE_PERL_TRUE at am__append_2 = run-perl-tests
+ subdir = perl
+ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+ am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
+@@ -1080,7 +1082,8 @@ EXTRA_DIST = \
+ t/*.t \
+ typemap
+
+- at HAVE_PERL_TRUE@TESTS = run-bindtests run-perl-tests
++ at HAVE_PERL_TRUE@TESTS = run-bindtests $(am__append_2)
++ at HAVE_PERL_TRUE@test_prereq = src_deps all test_images $(am__append_1)
+ @HAVE_PERL_TRUE at TESTS_ENVIRONMENT = \
+ @HAVE_PERL_TRUE@ LD_LIBRARY_PATH=$(top_builddir)/src/.libs \
+ @HAVE_PERL_TRUE@ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+@@ -1405,12 +1408,13 @@ appliance: force
+ @HAVE_PERL_TRUE at test_images:
+ @HAVE_PERL_TRUE@ $(MAKE) -C $(top_builddir)/images
+
+- at HAVE_PERL_TRUE@$(TESTS): src_deps all appliance test_images
++ at HAVE_PERL_TRUE@$(TESTS): $(test_prereq)
+
+ @HAVE_PERL_TRUE at all: Makefile-pl src_deps
+ @HAVE_PERL_TRUE@ $(MAKE) -f Makefile-pl
+
+ @HAVE_PERL_TRUE at Makefile-pl: Makefile.PL
++ at HAVE_PERL_TRUE@ -[ $(srcdir) != $(builddir) ] && cp -rsu $(abs_srcdir)/. $(builddir)/.
+ @HAVE_PERL_TRUE@ perl Makefile.PL INSTALLDIRS=$(INSTALLDIRS) PREFIX=$(prefix)
+
+ # No! Otherwise it is deleted before the clean-local rule runs.
+diff --git a/perl/examples/Makefile.in b/perl/examples/Makefile.in
+index 22595aa..44423bc 100644
+--- a/perl/examples/Makefile.in
++++ b/perl/examples/Makefile.in
+@@ -1325,12 +1325,12 @@ uninstall-man: uninstall-man3
+ guestfs-perl.3 $(top_builddir)/html/guestfs-perl.3.html: stamp-guestfs-perl.pod
+
+ stamp-guestfs-perl.pod: guestfs-perl.pod create_disk.pl inspect_vm.pl
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-perl.3 \
+ --html $(top_builddir)/html/guestfs-perl.3.html \
+- --verbatim create_disk.pl:@EXAMPLE1@ \
+- --verbatim inspect_vm.pl:@EXAMPLE2@ \
++ --verbatim $(srcdir)/create_disk.pl:@EXAMPLE1@ \
++ --verbatim $(srcdir)/inspect_vm.pl:@EXAMPLE2@ \
+ $<
+ touch $@
+
+diff --git a/po-docs/ja/Makefile.in b/po-docs/ja/Makefile.in
+index d34497e..b561f68 100644
+--- a/po-docs/ja/Makefile.in
++++ b/po-docs/ja/Makefile.in
+@@ -1267,26 +1267,26 @@ uninstall-am:
+ all-local: $(MANPAGES)
+
+ guestfs.3: guestfs.pod guestfs-actions.pod guestfs-availability.pod guestfs-structs.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man $@ \
+- --insert guestfs-actions.pod:@ACTIONS@ \
+- --insert guestfs-availability.pod:@AVAILABILITY@ \
+- --insert guestfs-structs.pod:@STRUCTS@ \
++ --insert $(srcdir)/guestfs-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfs-availability.pod:@AVAILABILITY@ \
++ --insert $(srcdir)/guestfs-structs.pod:@STRUCTS@ \
+ $<
+
+ guestfish.1: guestfish.pod guestfish-actions.pod guestfish-commands.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man $@ \
+- --insert guestfish-actions.pod:@ACTIONS@ \
+- --insert guestfish-commands.pod:@FISH_COMMANDS@ \
++ --insert $(srcdir)/guestfish-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfish-commands.pod:@FISH_COMMANDS@ \
+ $<
+
+ %.1: %.pod
+- $(top_srcdir)/podwrapper.sh --man $@ $<
++ $(top_builddir)/podwrapper.sh --man $@ $<
+
+ %.1: %.pl
+- $(top_srcdir)/podwrapper.sh --man $@ $<
++ $(top_builddir)/podwrapper.sh --man $@ $<
+
+ # XXX Can automake do this properly?
+ install-data-hook:
+diff --git a/po-docs/uk/Makefile.in b/po-docs/uk/Makefile.in
+index de27c5a..8c20540 100644
+--- a/po-docs/uk/Makefile.in
++++ b/po-docs/uk/Makefile.in
+@@ -1267,26 +1267,26 @@ uninstall-am:
+ all-local: $(MANPAGES)
+
+ guestfs.3: guestfs.pod guestfs-actions.pod guestfs-availability.pod guestfs-structs.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man $@ \
+- --insert guestfs-actions.pod:@ACTIONS@ \
+- --insert guestfs-availability.pod:@AVAILABILITY@ \
+- --insert guestfs-structs.pod:@STRUCTS@ \
++ --insert $(srcdir)/guestfs-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfs-availability.pod:@AVAILABILITY@ \
++ --insert $(srcdir)/guestfs-structs.pod:@STRUCTS@ \
+ $<
+
+ guestfish.1: guestfish.pod guestfish-actions.pod guestfish-commands.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man $@ \
+- --insert guestfish-actions.pod:@ACTIONS@ \
+- --insert guestfish-commands.pod:@FISH_COMMANDS@ \
++ --insert $(srcdir)/guestfish-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfish-commands.pod:@FISH_COMMANDS@ \
+ $<
+
+ %.1: %.pod
+- $(top_srcdir)/podwrapper.sh --man $@ $<
++ $(top_builddir)/podwrapper.sh --man $@ $<
+
+ %.1: %.pl
+- $(top_srcdir)/podwrapper.sh --man $@ $<
++ $(top_builddir)/podwrapper.sh --man $@ $<
+
+ # XXX Can automake do this properly?
+ install-data-hook:
+diff --git a/python/Makefile.in b/python/Makefile.in
+index 1e73bf1..97948c8 100644
+--- a/python/Makefile.in
++++ b/python/Makefile.in
+@@ -70,6 +70,7 @@ build_triplet = @build@
+ host_triplet = @host@
+ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+ $(top_srcdir)/subdir-rules.mk
++ at ENABLE_APPLIANCE_TRUE@@HAVE_PYTHON_TRUE at am__append_1 = run-python-tests
+ subdir = python
+ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+ am__aclocal_m4_deps = $(top_srcdir)/m4/00gnulib.m4 \
+@@ -1146,13 +1147,13 @@ EXTRA_DIST = \
+ @HAVE_PYTHON_TRUE@ -I$(top_srcdir)/src -I$(top_builddir)/src
+
+ @HAVE_PYTHON_TRUE at libguestfsmod_la_LIBADD = $(top_builddir)/src/libguestfs.la
+- at HAVE_PYTHON_TRUE@libguestfsmod_la_LDFLAGS = -avoid-version
++ at HAVE_PYTHON_TRUE@libguestfsmod_la_LDFLAGS = -avoid-version -shared
+ @HAVE_PYTHON_TRUE at TESTS_ENVIRONMENT = \
+ @HAVE_PYTHON_TRUE@ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+ @HAVE_PYTHON_TRUE@ PYTHONPATH=$(builddir):$(builddir)/.libs \
+ @HAVE_PYTHON_TRUE@ TMPDIR=$(top_builddir)
+
+- at HAVE_PYTHON_TRUE@TESTS = run-bindtests run-python-tests
++ at HAVE_PYTHON_TRUE@TESTS = run-bindtests $(am__append_1)
+ all: all-am
+
+ .SUFFIXES:
+diff --git a/python/examples/Makefile.in b/python/examples/Makefile.in
+index 27e69f9..39588a0 100644
+--- a/python/examples/Makefile.in
++++ b/python/examples/Makefile.in
+@@ -1325,12 +1325,12 @@ uninstall-man: uninstall-man3
+ guestfs-python.3 $(top_builddir)/html/guestfs-python.3.html: stamp-guestfs-python.pod
+
+ stamp-guestfs-python.pod: guestfs-python.pod create_disk.py inspect_vm.py
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-python.3 \
+ --html $(top_builddir)/html/guestfs-python.3.html \
+- --verbatim create_disk.py:@EXAMPLE1@ \
+- --verbatim inspect_vm.py:@EXAMPLE2@ \
++ --verbatim $(srcdir)/create_disk.py:@EXAMPLE1@ \
++ --verbatim $(srcdir)/inspect_vm.py:@EXAMPLE2@ \
+ $<
+ touch $@
+
+diff --git a/rescue/Makefile.in b/rescue/Makefile.in
+index 966f1e2..dfd99dd 100644
+--- a/rescue/Makefile.in
++++ b/rescue/Makefile.in
+@@ -1663,7 +1663,7 @@ appliance: force
+ virt-rescue.1 $(top_builddir)/html/virt-rescue.1.html: stamp-virt-rescue.pod
+
+ stamp-virt-rescue.pod: virt-rescue.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man virt-rescue.1 \
+ --html $(top_builddir)/html/virt-rescue.1.html \
+ $<
+diff --git a/resize/Makefile.in b/resize/Makefile.in
+index 83d0724..436dc43 100644
+--- a/resize/Makefile.in
++++ b/resize/Makefile.in
+@@ -1135,7 +1135,7 @@ CLEANFILES = *~ *.cmi *.cmo *.cmx *.cmxa *.o virt-resize test.img \
+ @HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE@ LIBGUESTFS_PATH=$(top_builddir)/appliance \
+ @HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE@ TMPDIR=$(top_builddir)
+
+- at HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE at TESTS = test-virt-resize.sh
++ at ENABLE_APPLIANCE_TRUE@@HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE at TESTS = test-virt-resize.sh
+ all: all-am
+
+ .SUFFIXES:
+@@ -1543,7 +1543,7 @@ appliance: force
+ @HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE at virt-resize.1 $(top_builddir)/html/virt-resize.1.html: stamp-virt-resize.pod
+
+ @HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE at stamp-virt-resize.pod: virt-resize.pod
+- at HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE@ $(top_srcdir)/podwrapper.sh \
++ at HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE@ $(top_builddir)/podwrapper.sh \
+ @HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE@ --man virt-resize.1 \
+ @HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE@ --html $(top_builddir)/html/virt-resize.1.html \
+ @HAVE_OCAML_PCRE_TRUE@@HAVE_OCAML_TRUE@ $<
+diff --git a/ruby/examples/Makefile.in b/ruby/examples/Makefile.in
+index af07a36..9c9ebb2 100644
+--- a/ruby/examples/Makefile.in
++++ b/ruby/examples/Makefile.in
+@@ -1325,12 +1325,12 @@ uninstall-man: uninstall-man3
+ guestfs-ruby.3 $(top_builddir)/html/guestfs-ruby.3.html: stamp-guestfs-ruby.pod
+
+ stamp-guestfs-ruby.pod: guestfs-ruby.pod create_disk.rb inspect_vm.rb
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs-ruby.3 \
+ --html $(top_builddir)/html/guestfs-ruby.3.html \
+- --verbatim create_disk.rb:@EXAMPLE1@ \
+- --verbatim inspect_vm.rb:@EXAMPLE2@ \
++ --verbatim $(srcdir)/create_disk.rb:@EXAMPLE1@ \
++ --verbatim $(srcdir)/inspect_vm.rb:@EXAMPLE2@ \
+ $<
+ touch $@
+
+diff --git a/src/Makefile.in b/src/Makefile.in
+index ae1903a..37f8f31 100644
+--- a/src/Makefile.in
++++ b/src/Makefile.in
+@@ -1245,7 +1245,7 @@ liberrnostring_la_CFLAGS =
+ # Note that this scheme means the real library version will always be
+ # 'libguestfs.so.0.$(MAX_PROC_NR).0'.
+ libguestfs_la_LDFLAGS = -version-info $(MAX_PROC_NR):0:$(MAX_PROC_NR) \
+- $(VERSION_SCRIPT_FLAGS)libguestfs.syms
++ $(VERSION_SCRIPT_FLAGS)$(srcdir)/libguestfs.syms
+ libguestfs_la_SOURCES = \
+ guestfs.c \
+ guestfs.h \
+@@ -1918,14 +1918,14 @@ errnostring_gperf.c: errnostring_gperf.gperf
+
+ @HAVE_RPCGEN_TRUE at guestfs_protocol.c: guestfs_protocol.x
+ @HAVE_RPCGEN_TRUE@ rm -f $@-t $@-t2
+- at HAVE_RPCGEN_TRUE@ $(RPCGEN) -c -o $@-t $<
++ at HAVE_RPCGEN_TRUE@ $(RPCGEN) -c -o $@-t $(srcdir)/$<
+ @HAVE_RPCGEN_TRUE@ sed 's,\.\./\.\./src/,,' < $@-t > $@-t2
+ @HAVE_RPCGEN_TRUE@ rm $@-t
+ @HAVE_RPCGEN_TRUE@ mv $@-t2 $@
+
+ @HAVE_RPCGEN_TRUE at guestfs_protocol.h: guestfs_protocol.x
+ @HAVE_RPCGEN_TRUE@ rm -f $@-t
+- at HAVE_RPCGEN_TRUE@ $(RPCGEN) -h -o $@-t $<
++ at HAVE_RPCGEN_TRUE@ $(RPCGEN) -h -o $@-t $(srcdir)/$<
+ @HAVE_RPCGEN_TRUE@ mv $@-t $@
+
+ guestfs.3 $(top_builddir)/html/guestfs.3.html: stamp-guestfs.pod
+@@ -1934,13 +1934,13 @@ stamp-guestfs.pod: guestfs.pod \
+ guestfs-actions.pod \
+ guestfs-availability.pod \
+ guestfs-structs.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --section 3 \
+ --man guestfs.3 \
+ --html $(top_builddir)/html/guestfs.3.html \
+- --insert guestfs-actions.pod:@ACTIONS@ \
+- --insert guestfs-availability.pod:@AVAILABILITY@ \
+- --insert guestfs-structs.pod:@STRUCTS@ \
++ --insert $(srcdir)/guestfs-actions.pod:@ACTIONS@ \
++ --insert $(srcdir)/guestfs-availability.pod:@AVAILABILITY@ \
++ --insert $(srcdir)/guestfs-structs.pod:@STRUCTS@ \
+ $<
+ touch $@
+
+diff --git a/test-tool/Makefile.in b/test-tool/Makefile.in
+index b627c01..bf96517 100644
+--- a/test-tool/Makefile.in
++++ b/test-tool/Makefile.in
+@@ -1549,7 +1549,7 @@ appliance: force
+ $(MAKE) -C $(top_builddir)/appliance
+
+ libguestfs-test-tool.1: libguestfs-test-tool.pod
+- $(top_srcdir)/podwrapper.sh \
++ $(top_builddir)/podwrapper.sh \
+ --man $@ \
+ $<
+
+diff --git a/tools/Makefile.in b/tools/Makefile.in
+index 6e9f0df..0e2bd8f 100644
+--- a/tools/Makefile.in
++++ b/tools/Makefile.in
+@@ -1123,9 +1123,9 @@ CLEANFILES = test.img
+ @HAVE_TOOLS_TRUE@ TMPDIR=$(top_builddir) \
+ @HAVE_TOOLS_TRUE@ PERL5LIB=$(top_builddir)/perl/blib/lib:$(top_builddir)/perl/blib/arch
+
+- at HAVE_TOOLS_TRUE@TESTS = test-virt-list-filesystems.sh \
+- at HAVE_TOOLS_TRUE@ test-virt-make-fs.sh \
+- at HAVE_TOOLS_TRUE@ test-virt-tar.sh
++ at ENABLE_APPLIANCE_TRUE@@HAVE_TOOLS_TRUE at TESTS = test-virt-list-filesystems.sh \
++ at ENABLE_APPLIANCE_TRUE@@HAVE_TOOLS_TRUE@ test-virt-make-fs.sh \
++ at ENABLE_APPLIANCE_TRUE@@HAVE_TOOLS_TRUE@ test-virt-tar.sh
+
+ all: all-am
+
+@@ -1521,12 +1521,12 @@ appliance: force
+ $(MAKE) -C $(top_builddir)/appliance
+
+ @HAVE_TOOLS_TRUE at virt-%.1: virt-%
+- at HAVE_TOOLS_TRUE@ $(top_srcdir)/podwrapper.sh \
++ at HAVE_TOOLS_TRUE@ $(top_builddir)/podwrapper.sh \
+ @HAVE_TOOLS_TRUE@ --man $@ \
+ @HAVE_TOOLS_TRUE@ $<
+
+ @HAVE_TOOLS_TRUE@$(top_builddir)/html/virt-%.1.html: virt-%
+- at HAVE_TOOLS_TRUE@ $(top_srcdir)/podwrapper.sh \
++ at HAVE_TOOLS_TRUE@ $(top_builddir)/podwrapper.sh \
+ @HAVE_TOOLS_TRUE@ --html $@ \
+ @HAVE_TOOLS_TRUE@ $<
+
+--
diff --git a/debian/patches/series b/debian/patches/series
index 4874077..e6e389f 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -4,6 +4,9 @@
0004-configure.ac-do-not-generate-debian-changelog.patch
0005-Do-not-run-appliance-related-checks-if-not-building-.patch
0006-check-for-febootstrap-etc.-even-if-not-building-appl.patch
-0007-python-don-t-build-static-library.patch
+0007-python-don-t-build-static-library-python3-wants-prin.patch
0008-Fix-for-systemd-based-Debian-systems.patch
-0009-regenerated-auto-related-files.patch
+0009-patches-from-upstream-git-repository-for-out-of-tree.patch
+0010-out-of-tree-build-fix-building-Perl-bindings.patch
+0011-out-of-tree-build-daemon.patch
+0012-autoreconf.patch
--
Libguestfs Debian packaging
More information about the Pkg-libvirt-commits
mailing list