Hilko Bengen
2013-May-28 18:44 UTC
[Libguestfs] hivex: revert much of " Build and test Perl bindings out-of-tree." (887466794a40f57b84ce32524e1a650d6674c7e6)?
While trying to build the official Debian packages for libguestfs 1.22, I noticed that instead of working around ExtUtils::MakeMaker's limitations, I had made quite a mess of building the Perl bindings. I have tried from different sides to fix things, but could not get it quite right: - EU::MM expects Makefile.PL to be in the same directory as the generated Makefile (We work around that using sed.) - In principle, there seem to be two ways to do things: 1. Call make -f builddir/Makefile-pl from srcdir (that's what we do now), override INST_*. Problems with this: - XS is still built in srcdir. - there is actually code in ExtUtils::Install which is used from the generated Makefile-pl that bases its decisions where to install *.pm files on whether there are any files within ./blib/arch/ (hard-coded)! I have found no way to override this. 2. Call make -f Makefile-pl from builddir. I tried that and thought that I would be able to patch absolute paths for source files (*.xs, lib/*) and generated files (*.c, *.xs, blib/*) into the generated Makefile-pl. Much of a perfectly good weekend went to waste over that attempt. I realized that I was actively working against ExtUtils::MakeMaker's design. Separating source and build trees has never been a concern. Even if I got it right once, I'd expect things to break in interesting ways in the future.>From a look at the documentation, Module::Build does not seem to have asolution, either. I give up and propose that we go back to the hackish, yet simple previous solution and adopt that for libguestfs as well: -[ $(srcdir) != $(builddir) ] && cp -rsu $(abs_srcdir)/. $(builddir)/. I agree that this is ugly, but works and it won't hurt when building libguestfs from within the source directory. Cheers, -Hilko
Richard W.M. Jones
2013-May-28 20:44 UTC
[Libguestfs] hivex: revert much of " Build and test Perl bindings out-of-tree." (887466794a40f57b84ce32524e1a650d6674c7e6)?
Is no patch attached or following this message? I don't seem to see it in my email nor on the mailing list archives on the web. Anyway, a straightforward 'git revert' is fine, ACKed. If the patch is more involved than that, I would prefer to see it first. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones virt-df lists disk usage of guests without needing to install any software inside the virtual machine. Supports Linux and Windows. http://people.redhat.com/~rjones/virt-df/
Hilko Bengen
2013-May-28 23:05 UTC
Re: [Libguestfs] hivex: revert much of " Build and test Perl bindings out-of-tree." (887466794a40f57b84ce32524e1a650d6674c7e6)?
* Richard W.M. Jones:> Is no patch attached or following this message? I don't seem to see it > in my email nor on the mailing list archives on the web. > > Anyway, a straightforward 'git revert' is fine, ACKed.No, other than expressing a bit of frustration, I just wanted to know if also using that symlink hack for libguestfs would be okay. Cheers, -Hilko
Seemingly Similar Threads
- [PATCH] Build and test Perl bindings out-of-tree.
- Re: hivex: revert much of " Build and test Perl bindings out-of-tree." (887466794a40f57b84ce32524e1a650d6674c7e6)?
- [PATCH 1/2] Revert "perl: Fix build and test to work with separated builds."
- Re: hivex: revert much of " Build and test Perl bindings out-of-tree." (887466794a40f57b84ce32524e1a650d6674c7e6)?
- hivex: Test failure for Perl, OCaml, Python bindings on sparc