Bug 602 - Copying sstate-cache to another system results in build error due to perl library path (autoconf-native build)
Summary: Copying sstate-cache to another system results in build error due to perl lib...
Status: RESOLVED FIXED
Alias: None
Product: Meta-yocto
Classification: Build System, Metadata & Runtime
Component: meta-yocto (show other bugs)
Version: 1.0
Hardware: x86 Multiple
: Medium normal
Target Milestone: 1.0 M3
Assignee: Kevin Tian
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks: 507
  Show dependency tree
 
Reported: 2010-12-16 17:32 UTC by Scott Garman
Modified: 2011-01-18 06:02 UTC (History)
6 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Scott Garman 2010-12-16 17:32:56 UTC
Using Poky master from today (ac4364698618a541624d1a00f27b638815e5a3f5):

I built poky-image-lsb for qemux86 on one computer, then copied sstate-cache to my laptop in a Poky tree of the same master release.

I then did a bitbake poky-image-lsb. Things appeared to go well, but then autoconf-native was rebuilt, and complation failed with:

make  all-recursive
make[1]: Entering directory `/data/poky_builds/poky/build/tmp/work/x86_64-linux/autoconf-native-2.65-r2/autoconf-2.65'
Making all in bin
make[2]: Entering directory `/data/poky_builds/poky/build/tmp/work/x86_64-linux/autoconf-native-2.65-r2/autoconf-2.65/bin'
autom4te_perllibdir='..'/lib AUTOM4TE_CFG='../lib/autom4te.cfg'         ../bin/autom4te -B '..'/lib -B '..'/lib         --language M4sh --cache '' --melt ./autoconf.   as -o autoconf.in
Can't locate Data/Dumper.pm in @INC (@INC contains: ../lib /toastssd/poky/build/tmp/sysroots/x86_64-linux/usr/lib/perl/5.8.8 /toastssd/poky/build/tmp/sysroots/x86_64-  linux/usr/lib/perl/5.8.8 /toastssd/poky/build/tmp/sysroots/x86_64-linux/usr/lib/perl/5.8.8 /toastssd/poky/build/tmp/sysroots/x86_64-linux/usr/lib/perl /toastssd/    poky/build/tmp/sysroots/x86_64-linux/usr/lib/perl/5.8.8 /toastssd/poky/build/tmp/sysroots/x86_64-linux/usr/lib/perl/5.8.8 /toastssd/poky/build/tmp/sysroots/x86_64-  linux/usr/lib/perl .) at ../lib/Autom4te/C4che.pm line 33.
BEGIN failed--compilation aborted at ../lib/Autom4te/C4che.pm line 33.
Compilation failed in require at ../bin/autom4te line 38.
BEGIN failed--compilation aborted at ../bin/autom4te line 38.
make[2]: *** [autoconf.in] Error 2
make[2]: Leaving directory `/data/poky_builds/poky/build/tmp/work/x86_64-linux/autoconf-native-2.65-r2/autoconf-2.65/bin'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/data/poky_builds/poky/build/tmp/work/x86_64-linux/autoconf-native-2.65-r2/autoconf-2.65'
make: *** [all] Error 2
FATAL: oe_runmake failed
ERROR: Task failed: ('function do_compile failed', '/data/poky_builds/poky/build/tmp/work/x86_64-linux/autoconf-native-2.65-r2/temp/log.do_compile.18328')

The path /toastssd/poky/... was the path unique to the original build system.
Comment 1 Richard Purdie 2010-12-20 14:51:24 UTC
http://git.pokylinux.org/cgit.cgi/poky/commit/?h=master&id=9975c00c1a6a9ae1c39678dec0986f4c62418c96 should at least work around this. Its probably worth keeping the bug open until perl is made relocatable though.
Comment 2 Kevin Tian 2010-12-21 03:36:45 UTC
mark this as resolved after RP's commit. Now perl-native is always forced to rebuild in the new build dir. the list of impacted recipes on this change include:

perl-native -> openssl-native -> git-native -> pseudo-native -> libtool-cross
                              |             |> prelink-native
                              |             |> kern-tools-native
                              |> python-native -> libxml2-native -> libxslt-native

So 10 native recipes require rebuild consequently
Comment 3 Kevin Tian 2010-12-21 03:41:25 UTC
reopen as we want to track here for a better fix
Comment 4 Kevin Tian 2011-01-18 06:02:06 UTC
fixed by fad5c8a33284902f66a05d1df5c7b7617eabfded by RP