Bug 1393 - gettext do_compile fails on atom-pc
Summary: gettext do_compile fails on atom-pc
Status: RESOLVED WORKSFORME
Alias: None
Product: Meta-yocto
Classification: Build System, Metadata & Runtime
Component: meta-yocto (show other bugs)
Version: unspecified
Hardware: x86 x86
: High major
Target Milestone: 1.1
Assignee: Nitin Kamble
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2011-08-22 11:38 UTC by Gary Thomas
Modified: 2011-08-31 05:06 UTC (History)
5 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: ---


Attachments
Compile log file (651.33 KB, application/octet-stream)
2011-08-22 11:39 UTC, Gary Thomas
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gary Thomas 2011-08-22 11:38:11 UTC
OE Build Configuration:
BB_VERSION        = "1.13.3"
TARGET_ARCH       = "i586"
TARGET_OS         = "linux"
MACHINE           = "atom-pc"
DISTRO            = "poky"
DISTRO_VERSION    = "1.0+snapshot-20110822"
TUNE_FEATURES     = "m32 core2"
TARGET_FPU        = ""
meta              
meta-yocto        = "local_master:edd8e1e8b974eb3f0f9f66c2207aadf43612350b"

Fails building gettext - log attached.
Comment 1 Gary Thomas 2011-08-22 11:39:11 UTC
Created attachment 209 [details]
Compile log file
Comment 2 Darren Hart 2011-08-24 10:38:02 UTC
Updated summary to accurately reflect the issue. The relevant log section follows. There are some local paths involved in the library search path and the actual link fails.

Asking Nitin to have a look.

/home/local/pc_poky/tmp/sysroots/i686-linux/usr/libexec/core2-poky-linux/gcc/i586-poky-linux/4.6.1/ld: warning: library search path "/usr/lib" is unsafe for cross-compilation
/home/local/pc_poky/tmp/sysroots/i686-linux/usr/libexec/core2-poky-linux/gcc/i586-poky-linux/4.6.1/ld: warning: library search path "/usr/lib" is unsafe for cross-compilation
/usr/lib/libm.so: undefined reference to `/bin/sh ../i586-poky-linux-libtool  --tag=CC   --mode=link ccache i586-poky-linux-gcc  -m32    -march=core2 -msse3 -mtune=generic -mfpmath=sse --sysroot=/home/local/pc_poky/tmp/sysroots/atom-pc -std=gnu99  -O2 -pipe -g -feliminate-unused-debug-types  -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -o msgattrib msgattrib-msgattrib.o libgettextsrc.la   
i586-poky-linux-libtool: link: ccache i586-poky-linux-gcc -m32 -march=core2 -msse3 -mtune=generic -mfpmath=sse --sysroot=/home/local/pc_poky/tmp/sysroots/atom-pc -std=gnu99 -O2 -pipe -g -feliminate-unused-debug-types -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -o .libs/xgettext xgettext-xgettext.o xgettext-x-c.o xgettext-x-po.o xgettext-x-sh.o xgettext-x-python.o xgettext-x-lisp.o xgettext-x-elisp.o xgettext-x-librep.o xgettext-x-scheme.o xgettext-x-smalltalk.o xgettext-x-java.o xgettext-x-csharp.o xgettext-x-awk.o xgettext-x-ycp.o xgettext-x-tcl.o xgettext-x-perl.o xgettext-x-php.o xgettext-x-rst.o xgettext-x-glade.o  ./.libs/libgettextsrc.so -L/usr/lib -L/home/local/pc_poky/tmp/sysroots/atom-pc/usr/lib/../lib /home/local/pc_poky/tmp/work/core2-poky-linux/gettext-0.18.1.1-r2/gettext-0.18.1.1/gettext-tools/gnulib-lib/.libs/libgettextlib.so -lxml2 -lncurses -lc -ldl
i586-poky-linux-libtool: link: ccache i586-poky-linux-gcc -m32 -march=core2 -msse3 -mtune=generic -mfpmath=sse --sysroot=/home/local/pc_poky/tmp/sysroots/atom-pc -std=gnu99 -O2 -pipe -g -feliminate-unused-debug-types -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -o .libs/msgattrib msgattrib-msgattrib.o  ./.libs/libgettextsrc.so -L/usr/lib -L/home/local/pc_poky/tmp/sysroots/atom-pc/usr/lib/../lib /home/local/pc_poky/tmp/work/core2-poky-linux/gettext-0.18.1.1-r2/gettext-0.18.1.1/gettext-tools/gnulib-lib/.libs/libgettextlib.so -lxml2 -lncurses -lc
__get_cpu_features@GLIBC_PRIVATE'
__get_cpu_features@GLIBC_PRIVATE'
collect2: ld returned 1 exit status
collect2: ld returned 1 exit status
make[4]: *** [msgcmp] Error 1
make[4]: *** Waiting for unfinished jobs....
make[4]: *** [msgmerge] Error 1
/home/local/pc_poky/tmp/sysroots/i686-linux/usr/libexec/core2-poky-linux/gcc/i586-poky-linux/4.6.1/ld: warning: library search path "/usr/lib" is unsafe for cross-compilation
/home/local/pc_poky/tmp/sysroots/i686-linux/usr/libexec/core2-poky-linux/gcc/i586-poky-linux/4.6.1/ld: warning: library search path "/usr/lib" is unsafe for cross-compilation
make[4]: Leaving directory `/home/local/pc_poky/tmp/work/core2-poky-linux/gettext-0.18.1.1-r2/gettext-0.18.1.1/gettext-tools/src'
make[3]: *** [all] Error 2
make[3]: Leaving directory `/home/local/pc_poky/tmp/work/core2-poky-linux/gettext-0.18.1.1-r2/gettext-0.18.1.1/gettext-tools/src'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/local/pc_poky/tmp/work/core2-poky-linux/gettext-0.18.1.1-r2/gettext-0.18.1.1/gettext-tools'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/local/pc_poky/tmp/work/core2-poky-linux/gettext-0.18.1.1-r2/gettext-0.18.1.1/gettext-tools'
make: *** [all-recursive] Error 1
ERROR: oe_runmake failed
ERROR: Function 'do_compile' failed (see /home/local/pc_poky/tmp/work/core2-poky-linux/gettext-0.18.1.1-r2/temp/log.do_compile.1723 for further information)
Comment 3 Darren Hart 2011-08-24 11:04:48 UTC
I was not able to reproduce with the following. No library search path warnings. Compile succeeded.

OE Build Configuration:
BB_VERSION        = "1.13.3"
TARGET_ARCH       = "i586"
TARGET_OS         = "linux"
MACHINE           = "atom-pc"
DISTRO            = "poky"
DISTRO_VERSION    = "1.0+snapshot-20110824"
TUNE_FEATURES     = "m32 core2"
TARGET_FPU        = ""
meta
meta-yocto        = "master:b2266beeb357bae938830f559845f5f3deb4f916"
Comment 4 Nitin Kamble 2011-08-24 14:39:57 UTC
I just built with this, and I did not see compilation failure for "bitbake gettext", it is running do_install for gettext recipe now.

so not able to reproduce the issue, or it works for me.
Nitin

OE Build Configuration:
BB_VERSION        = "1.13.3"
TARGET_ARCH       = "i586"
TARGET_OS         = "linux"
MACHINE           = "atom-pc"
DISTRO            = "poky"
DISTRO_VERSION    = "1.0+snapshot-20110824"
TUNE_FEATURES     = "m32 core2"
TARGET_FPU        = ""
meta              
meta-yocto        = "master:a21ff559e7c93e9da61104f4a33e42e6004189fd"
Comment 5 Gary Thomas 2011-08-24 15:15:50 UTC
(In reply to comment #4)
> I just built with this, and I did not see compilation failure for "bitbake
> gettext", it is running do_install for gettext recipe now.
> 
> so not able to reproduce the issue, or it works for me.
> Nitin
> 
> OE Build Configuration:
> BB_VERSION        = "1.13.3"
> TARGET_ARCH       = "i586"
> TARGET_OS         = "linux"
> MACHINE           = "atom-pc"
> DISTRO            = "poky"
> DISTRO_VERSION    = "1.0+snapshot-20110824"
> TUNE_FEATURES     = "m32 core2"
> TARGET_FPU        = ""
> meta              
> meta-yocto        = "master:a21ff559e7c93e9da61104f4a33e42e6004189fd"

I'm not sure what happened here, but I also am unable to reproduce the failure, even using the checkout I cited in the original report.

I'm happy for this to be closed.
Comment 6 Nitin Kamble 2011-08-24 17:45:15 UTC
The issue is not reproducible anymore. Hence closing the bug
Nitin
Comment 7 Gary Thomas 2011-08-26 07:44:18 UTC
Sadly, this is still happening for me for any x86 target.  Building:

OE Build Configuration:
BB_VERSION        = "1.13.3"
TARGET_ARCH       = "i586"
TARGET_OS         = "linux"
MACHINE           = "qemux86"
DISTRO            = "poky"
DISTRO_VERSION    = "1.0+snapshot-20110826"
TUNE_FEATURES     = "m32 i586"
TARGET_FPU        = ""
meta              
meta-yocto        = "master:6c2b7beac3cd23ed44bd3e195c6360a0932876bf"

I run 'bitbake core-image-sato' with
  BB_NUMBER_THREADS = "4"
  PARALLEL_MAKE = "-j 4"
on a 4-core machine

If I run this from scratch on Fedora 13, it fails as reported.
I don't see the same error (using the same metadata) when built on Ubuntu 11.04

Oddly, if I run just 'bitbake gettext' (from scratch) on the Fedora 13 machine,
it succeeds!!  I can then run 'bitbake core-image-sato' with no other errors.

Obviously this problem is somehow related to the particular machine/kernel/distribution combination as well as the actual target being built.

One more piece of data (not sure how it helps if it does), I routinely build full images from scratch for other targets, e.g. beagleboard, on the Fedora 13 machine (again with the same parallelism settings as above) and I've never had any problems.
Comment 8 Richard Purdie 2011-08-30 16:24:22 UTC
Gary, are you sure that "bitbake gettext" doesn't fail yet the image builds do. That is the only piece of this that really doesn't make any sense to me...

Secondly, in a failed build, could you tar up and share the gettext work directory please? That might give us some clues as to where the stray "/usr/lib" is coming from.
Comment 9 Gary Thomas 2011-08-30 16:59:26 UTC
(In reply to comment #8)
> Gary, are you sure that "bitbake gettext" doesn't fail yet the image builds do.
> That is the only piece of this that really doesn't make any sense to me...
> 
> Secondly, in a failed build, could you tar up and share the gettext work
> directory please? That might give us some clues as to where the stray
> "/usr/lib" is coming from.

I'll run through it again (both ways) on the failing machine and pack up
the relevant files.  Stand by :-)
Comment 10 Richard Purdie 2011-08-30 17:30:44 UTC
As another data point it looks suspiciously like libxml2 is causing issues in the attached compile log file but commit http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=a0abef4533337faeb2fd991d7ab67f0a94f59568 should have fixed that.
Comment 11 Gary Thomas 2011-08-31 05:06:14 UTC
I haven't touched anything on this host - same Poky master, etc.  Now, it refuses
to fail for me, although the identical setup failed 4 times in a row when I tried
it last Friday.

I'm about ready to blame this on solar storms...