| Summary: | bitbake error message truncation issue | ||
|---|---|---|---|
| Product: | [Build System, Metadata & Runtime] BitBake | Reporter: | Nitin Kamble <nitin.a.kamble> |
| Component: | bitbake | Assignee: | Richard Purdie <richard.purdie> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | Medium | CC: | jessica.zhang, kergoth, poky.bs.watcher, poky.watcher |
| Version: | unspecified | ||
| Target Milestone: | 1.2 | ||
| Hardware: | x86 | ||
| OS: | Multiple | ||
| Whiteboard: | |||
| OS type for building Yocto: | --- | Type of Regression: | --- |
| Verified: | Documentation change: | --- | |
The issue mentioned in this bug is fixed. If bitbake's error handling needs improvement, that's a separate issue. I asked Nitin to file this specifically for the error handling issue - reopening and retitling accordingly Confirmed, this error display issue was fixed in http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=ebc0d4252a19e6ab38052473e54138d29b172dfc and the error message is now correctly displayed with master. |
In my work-in-progress environment commented out lines in the recipe causes bitbake to hang: For example this change in my local tree causes bitbake to hang diff --git a/meta/recipes-devtools/gcc/libgcc_4.6.bb b/meta/recipes-devtools/gcc/libgcc_4.6.bb index 5048fd9..ad45936 100644 --- a/meta/recipes-devtools/gcc/libgcc_4.6.bb +++ b/meta/recipes-devtools/gcc/libgcc_4.6.bb @@ -44,10 +44,19 @@ do_install () { chown -R root:root ${D} chmod +x ${D}${base_libdir}/libgcc_s.so.* +# for ml in ${MULTILIB_VARIANTS} +# do +# set -x +# ml_tune=${@d.getVar('DEFAULTTUNE_virtclass-multilib-${ml}', True)} +# ml_baselib=${@d.getVar('BASE_LIB_tune-${ml_tune}', True)} +# ml_tune_features=${@d.getVar('TUNE_FEATURES_tune-${ml_tune}', True)} +# ml_arch= +# for feature in ${ml_tune_features} +# do +# ml_arch="${ml_arch} ${@d.getVar('TUNE_FEATURE_ARCH-${feature}', True)}" +# ln -s /usr/${ml_baselib}/${ml_feature_arch}-pokyml${ml}-linux/${BINV}/ ${D}${libdir}/${TARGET_SYS}/${BINV}/32 +# done + ln -s /usr/${ml_baselib}/${ml_feature_arch}-pokyml${ml}-linux/${BINV}/ ${D}${libdir}/${TARGET_SYS}/${BINV}/32 } Richard Suggested trying out these fixes From here: http://lists.linuxtogo.org/pipermail/bitbake-devel/2012-February/thread.html [bitbake-devel] [PATCHv2 0/2] Resolve parsing hang issues Christopher Larson [bitbake-devel] [PATCH 1/2] cooker: roll our own process pool Christopher Larson [bitbake-devel] [PATCH 2/2] knotty: shut down more cleanly Christopher Larson And they resolve the bitbake hang by giving out this error: Loaded 1619 entries from dependency cache. NOTE: Error expanding variable do_install | ETA: --:--:-- ERROR: Command execution failed: Exited with 1 Summary: There were 0 ERROR messages shown, returning a non-zero exit code. And other Hack which richard suggested was: --- a/bitbake/lib/bb/cooker.py +++ b/bitbake/lib/bb/cooker.py @@@ -1477,8 -1477,8 +1477,8 @@@ class CookerParser(object) self.virtuals, self.error, self.total) bb.event.fire(event, self.cfgdata) -- else: -- self.pool.terminate() ++# else: ++# self.pool.terminate() self.pool.join() sync = threading.Thread(target=self.bb_cache.sync) This hack gives error like this: $ bitbake gcc -f -c gcc_multilib_setup Loading cache: 100% |################################################################################################| ETA: 00:00:00 Loaded 1619 entries from dependency cache. NOTE: Error expanding variable do_install | ETA: --:--:-- ERROR: Failure expanding variable do_install, expression was target=`echo x86_64-poky-linux | sed -e s#-nativesdk##` # Install libgcc from our gcc-cross saved data install -d /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image/lib64 /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image/usr/lib64 cp -fpPR /srv/home/nitin/builds/build-multilib/tmp/sysroots/x86_64-linux/usr/include/gcc-build-internal-$target/* /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image # Move libgcc_s into /lib mkdir -p /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image/lib64 if [ -f /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image/usr/lib64/nof/libgcc_s.so ]; then mv /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image/usr/lib64/nof/libgcc* /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image/lib64 else mv /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image/usr/lib64/libgcc* /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image/lib64 || true fi chown -R root:root /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image chmod +x /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image/lib64/libgcc_s.so.* # for ml in lib32 # do # set -x # ml_tune=${@d.getVar('DEFAULTTUNE_virtclass-multilib-${ml}', True)} # ml_baselib=${@d.getVar('BASE_LIB_tune-${ml_tune}', True)} # ml_tune_features=${@d.getVar('TUNE_FEATURES_tune-${ml_tune}', True)} # ml_arch= # for feature in ${ml_tune_features} # do # ml_arch="${ml_arch} ${@d.getVar('TUNE_FEATURE_ARCH-${feature}', True)}" # ln -s /usr/${ml_baselib}/${ml_feature_arch}-pokyml${ml}-linux/4.6.3/ /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image/usr/lib64/x86_64-poky-linux/4.6.3/32 # done ln -s /usr/${ml_baselib}/${ml_feature_arch}-pokyml${ml}-linux/4.6.3/ /srv/home/nitin/builds/build-multilib/tmp/work/x86_64-poky-linux/libgcc-4.6.2+svnr181430-r23/image/usr/lib64/x86_64-poky-linux/4.6.3/32 which triggered exception SyntaxError: EOL while scanning string literal (do_install, line 1) ERROR: Command execution failed: Exited with 1 Summary: There was 1 ERROR message shown, returning a non-zero exit code. So the Christopher Larson's commits fix the issue, but the error reporting is not enough to debug the issue. Bitbake need to print more information about error so that end user can pinpoint the error location easily.