Error when compile libguestfs from source in Fedora-12
Hi all, I am trying to compile libguestfs from source in Fedora12, but failed with such error: cp: cannot stat `initramfs/fakeroot.log': No such file or directory make[2]: *** [../initramfs/fakeroot.log] Error 1 make[2]: Leaving directory `/home/yufang/Code/libguestfs/appliance' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/yufang/Code/libguestfs' make: *** [all] Error 2 I have installed all required packages listed in http://cvs.fedoraproject.org/viewvc/devel/libguestfs/libguestfs.spec?view=ma... but still cannot find the reason. Could anybody do me a favour to have a look at this issue? config.log and output of make(make.log) are uploaded in the attachment to track problems. Thanks. --Yufang
On Tue, Apr 20, 2010 at 02:59:23PM +0800, Yufang Zhang wrote:
Hi all, I am trying to compile libguestfs from source in Fedora12, but failed with such error:
It's not clear, but are you trying to compile from the SRPM? If so then you must add the following line to your ~/.rpmmacros file: %libguestfs_buildnet 1 See the top of the spec file for an explanation. If that's not the case, then make sure you have the latest febootstrap, and make sure you are building --with-repo set to the same name as the build host (eg. if --with-repo=fedora-12, then the build host must be Fedora 12 too). Does the initramfs directory exist? What's in it? Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming blog: http://rwmj.wordpress.com Fedora now supports 80 OCaml packages (the OPEN alternative to F#) http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora
On 04/20/2010 03:58 PM, Richard W.M. Jones wrote:
On Tue, Apr 20, 2010 at 02:59:23PM +0800, Yufang Zhang wrote:
Hi all, I am trying to compile libguestfs from source in Fedora12, but failed with such error:
It's not clear, but are you trying to compile from the SRPM? If so then you must add the following line to your ~/.rpmmacros file:
%libguestfs_buildnet 1
See the top of the spec file for an explanation.
I got the source code from git://git.annexia.org/git/libguestfs.git <http://git.annexia.org/?p=libguestfs.git;a=summary>, and tried to compile libguestfs within the directory.
If that's not the case, then make sure you have the latest febootstrap, and make sure you are building --with-repo set to the same name as the build host (eg. if --with-repo=fedora-12, then the build host must be Fedora 12 too).
Does the initramfs directory exist? What's in it?
Rich.
For the host: # rpm -qa | grep febootstrap febootstrap-2.6-1.fc12.noarch # cat /etc/redhat-release Fedora release 12 (Constantine) # uname -a Linux yuzhang 2.6.32.11-99.fc12.x86_64 #1 SMP Mon Apr 5 19:59:38 UTC 2010 x86_64 x86_64 x86_64 GNU/Linux And I use the following command before make: # ./autogen.sh --with-mirror=http://fileshare.englab.nay.redhat.com/redhat/fedora/linux/releases/12/x86_6... --with-updates=http://download.englab.nay.redhat.com/pub/fedora/linux/updates/12/x86_64/ --with-repo=fedora-12 Problem still exists.
On Tue, Apr 20, 2010 at 05:58:49PM +0800, Yufang Zhang wrote:
For the host: # rpm -qa | grep febootstrap febootstrap-2.6-1.fc12.noarch
# cat /etc/redhat-release Fedora release 12 (Constantine)
# uname -a Linux yuzhang 2.6.32.11-99.fc12.x86_64 #1 SMP Mon Apr 5 19:59:38 UTC 2010 x86_64 x86_64 x86_64 GNU/Linux
And I use the following command before make: # ./autogen.sh --with-mirror=http://fileshare.englab.nay.redhat.com/redhat/fedora/linux/releases/12/x86_6...
--with-updates=http://download.englab.nay.redhat.com/pub/fedora/linux/updates/12/x86_64/ --with-repo=fedora-12
Problem still exists.
OK, this all looks good to me. It's a very strange error. It looks like something in these commands deletes initramfs/fakeroot.log. That file is missing from the list of files in initramfs/ that you posted. + febootstrap-run initramfs -- touch /etc/fstab + echo nameserver 10.0.2.3 + febootstrap-install initramfs resolv.conf.new /etc/resolv.conf 0644 root.root cp: cannot stat `initramfs/fakeroot.log': No such file or directory I wonder if this is a LANG thing. Can you try setting: export LANG=C before compiling? If that fixes it, please file a bug (against febootstrap) since obviously it should be possible to compile with any LANG setting. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones New in Fedora 11: Fedora Windows cross-compiler. Compile Windows programs, test, and build Windows installers. Over 70 libraries supprt'd http://fedoraproject.org/wiki/MinGW http://www.annexia.org/fedora_mingw
The problem seems to be that you'd checked out and were compiling libguestfs as root. This is not a good idea as we discussed on IRC. I'm going to add a check in the configure script and Makefile to make it bomb out if people try that. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming blog: http://rwmj.wordpress.com Fedora now supports 80 OCaml packages (the OPEN alternative to F#) http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora
Redo all as a non-root user, everything works fine. ----- Original Message ----- From: "Richard W.M. Jones" <rjones@redhat.com> Cc: Libguestfs@redhat.com Sent: Tuesday, April 20, 2010 7:16:31 PM GMT +08:00 Beijing / Chongqing / Hong Kong / Urumqi Subject: Re: [Libguestfs] Error when compile libguestfs from source in Fedora-12 The problem seems to be that you'd checked out and were compiling libguestfs as root. This is not a good idea as we discussed on IRC. I'm going to add a check in the configure script and Makefile to make it bomb out if people try that. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming blog: http://rwmj.wordpress.com Fedora now supports 80 OCaml packages (the OPEN alternative to F#) http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora _______________________________________________ Libguestfs mailing list Libguestfs@redhat.com https://www.redhat.com/mailman/listinfo/libguestfs
On 04/20/2010 03:58 PM, Richard W.M. Jones wrote:
On Tue, Apr 20, 2010 at 02:59:23PM +0800, Yufang Zhang wrote:
Hi all, I am trying to compile libguestfs from source in Fedora12, but failed with such error:
It's not clear, but are you trying to compile from the SRPM? If so then you must add the following line to your ~/.rpmmacros file:
%libguestfs_buildnet 1
See the top of the spec file for an explanation.
If that's not the case, then make sure you have the latest febootstrap, and make sure you are building --with-repo set to the same name as the build host (eg. if --with-repo=fedora-12, then the build host must be Fedora 12 too).
Does the initramfs directory exist? What's in it?
Rich.
initramfs directory does exist: # ls initramfs bin dev etc home lib lib64 media mnt opt proc root sbin selinux srv sys sysroot tmp usr var And attachment is the structure of this directory.
participants (2)
-
Richard W.M. Jones -
Yufang Zhang