meta-toolchain-sdk: /bin/perl is needed by some pkgs on FC 17
cover meta-toolchain-sdk: /bin/perl is needed by some pkgs on FC 17
Test info:
Tested on FC 13/16/17 64bit
1) $ bitbake meta-toolchain-sdk core-image-sato
2) untar the sdk, and use the sdk to build some pkgs (autoreconf, configure and make)
// Robert
The following changes since commit 4e1a8ed1ab7e7bd950e511c79ddfe072cb280a6e:
bitbake.conf: Include abi_version.conf in a early stage (2012-04-16 12:51:50 +0100)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib robert/fc17_sdk
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=robert/fc17_sdk
Robert Yang (3):
glib-2.0: fix builds on fedora 17
autoconf-nativesdk: fix builds on fedora 17
automake-nativesdk: fix builds on fedora 17
meta/recipes-core/glib-2.0/glib-2.0_2.30.3.bb | 12 +++++++++++- meta/recipes-devtools/autoconf/autoconf.inc | 16 +++++++++++++++- meta/recipes-devtools/autoconf/autoconf_2.68.bb | 2 +- meta/recipes-devtools/automake/automake_1.11.2.bb | 20 +++++++++++++++++--- 4 files changed, 44 insertions(+), 6 deletions(-)
PATCH 1/3 glib-2.0: fix builds on fedora 17
Generally distros keep perl at /sur/bin/perl
Fedora 17 also has /bin/perl
this causes glib-2.0 build on such distros to put perl interpreter path in the perl scripts as /bin/perl
But we set perl location for target as /usr/bin/perl
This mismatch of perl path causes failure of rootfs image creation like this:
| error: Failed dependencies:
| /bin/perl is needed by libglib-2.0-utils-2.30.3-r0.ppc603e
NOTE: package meta-toolchain-gmae-1.0-r7: task do_populate_sdk: Failed
[YOCTO #2304]
--- meta/recipes-core/glib-2.0/glib-2.0_2.30.3.bb | 12 +++++++++++- 1 files changed, 11 insertions(+), 1 deletions(-)
meta/recipes-core/glib-2.0/glib-2.0_2.30.3.bb +11 -1
@@ -1,6 +1,6 @@ require glib.inc -PR = "r0" +PR = "r1" PE = "1" DEPENDS += "libffi python-argparse-native zlib"
@@ -25,6 +25,10 @@ SRC_URI_append_libc-uclibc = " ${@['', 'file://no-iconv.patch']['${PN}' == '${BP SRC_URI_append_virtclass-native = " file://glib-gettextize-dir.patch" BBCLASSEXTEND = "native nativesdk" +PERLPATH = "${bindir}/env perl" +PERLPATH_virtclass-native = "/usr/bin/env perl" +PERLPATH_virtclass-nativesdk = "/usr/bin/env perl" + do_configure_prepend() { # missing ${topdir}/gtk-doc.make and --disable-gtk-doc* is not enough, because it calls gtkdocize (not provided by gtk-doc-native) sed -i '/^docs/d' ${S}/configure.ac
@@ -39,6 +43,12 @@ do_install_append() { # and empty dirs rmdir ${D}${libdir}/gio/modules/ rmdir ${D}${libdir}/gio/ + + # Some distros have both /bin/perl and /usr/bin/perl, but we set perl location + # for target as /usr/bin/perl, so fix it to /usr/bin/perl. + if [ -f ${D}${bindir}/glib-mkenums ]; then + sed -i -e '1s,#!.*perl,#! ${PERLPATH},' ${D}${bindir}/glib-mkenums + fi } PACKAGES += "${PN}-codegen"
Signature · 1 line
1.7.1
Re: [PATCH 1/3] glib-2.0: fix builds on fedora 17
Op 16 apr. 2012, om 15:38 heeft Robert Yang het volgende geschreven:
Quoted 1 line
Generally distros keep perl at /sur/bin/perl
/usr
Re: [PATCH 1/3] glib-2.0: fix builds on fedora 17
Quoted 6 lines · Koen Kooi
Op 16 apr. 2012, om 15:38 heeft Robert Yang het volgende geschreven:
Quoted 1 line
Generally distros keep perl at /sur/bin/perl
/usr
Good catch, thanks, I've pushed all the 3 new commits to:(based on oe-core)
git://git.pokylinux.org/poky-contrib robert/fc17_sdk
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=robert/fc17_sdk
// Robert
Quoted 6 lines
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core
PATCH 2/3 autoconf-nativesdk: fix builds on fedora 17
In reply to Robert YangGenerally distros keep perl at /sur/bin/perl
Fedora 17 also has /bin/perl
this causes autoconf-nativesdk build on such distros to put perl interpreter path in the perl scripts as /bin/perl
But we set perl location for target as /usr/bin/perl
This mismatch of perl path causes failure of rootfs image creation like this:
| error: Failed dependencies:
| /bin/perl is needed by autoconf-nativesdk-2.68-r6.x86_64.rpm
NOTE: package meta-toolchain-gmae-1.0-r7: task do_populate_sdk: Failed
The second sed command is for such a case:
eval 'case $# in 0) exec /bin/perl -S "$0";; *) exec /bin/perl -S "$0" "$@";; esac'
This line has two "/bin/perl" and we can't use a line number to tell sed which line it is since the line numbers in different files are defferent.
[YOCTO #2304]
--- meta/recipes-devtools/autoconf/autoconf.inc | 16 +++++++++++++++- meta/recipes-devtools/autoconf/autoconf_2.68.bb | 2 +- 2 files changed, 16 insertions(+), 2 deletions(-)
meta/recipes-devtools/autoconf/autoconf.inc +15 -1
@@ -17,6 +17,20 @@ SRC_URI = "${GNU_MIRROR}/autoconf/autoconf-${PV}.tar.bz2 \ inherit autotools +PERLPATH = "${bindir}/perl" +PERLPATH_virtclass-native = "/usr/bin/perl" +PERLPATH_virtclass-nativesdk = "/usr/bin/perl" + do_install_append() { - rm -rf ${D}${datadir}/emacs + rm -rf ${D}${datadir}/emacs + + # Some distros have both /bin/perl and /usr/bin/perl, but we set perl location + # for target as /usr/bin/perl, so fix it to /usr/bin/perl. + for i in autoheader autom4te autoreconf autoscan autoupdate ifnames; do + if [ -f ${D}${bindir}/$i ]; then + sed -i -e '1s,#!.*perl,#! ${PERLPATH},' \ + -e 's,exec .*/bin/perl \(.*\) exec .*/bin/perl \(.*\),exec ${PERLPATH} \1 exec ${PERLPATH} \2,' \ + ${D}${bindir}/$i + fi + done }
meta/recipes-devtools/autoconf/autoconf_2.68.bb +1 -1
@@ -1,6 +1,6 @@ require autoconf.inc -PR = "r6" +PR = "r7" PARALLEL_MAKE = ""
Signature · 1 line
1.7.1
PATCH 3/3 automake-nativesdk: fix builds on fedora 17
In reply to Robert YangGenerally distros keep perl at /sur/bin/perl
Fedora 17 also has /bin/perl
this causes automake-nativesdk build on such distros to put perl interpreter path in the perl scripts as /bin/perl
But we set perl location for target as /usr/bin/perl
This mismatch of perl path causes failure of rootfs image creation like this:
| error: Failed dependencies:
| /bin/perl is needed by automake-nativesdk-1.11.2-r2.x86_64
NOTE: package meta-toolchain-gmae-1.0-r7: task do_populate_sdk: Failed
The second sed command is for such a case:
eval 'case $# in 0) exec /bin/perl -S "$0";; *) exec /bin/perl -S "$0" "$@";; esac'
This line has two "/bin/perl" and we can't use a line number to tell sed which line it is since the line numbers in different files are defferent.
[YOCTO #2304]
--- meta/recipes-devtools/automake/automake_1.11.2.bb | 20 +++++++++++++++++--- 1 files changed, 17 insertions(+), 3 deletions(-)
meta/recipes-devtools/automake/automake_1.11.2.bb +17 -3
@@ -34,19 +34,33 @@ PATHFIXPATCH = "file://path_prog_fixes.patch" PATHFIXPATCH_virtclass-native = "" PATHFIXPATCH_virtclass-nativesdk = "" +PERLPATH = "${bindir}/perl" +PERLPATH_virtclass-native = "/usr/bin/perl" +PERLPATH_virtclass-nativesdk = "/usr/bin/perl" + SRC_URI += "${PATHFIXPATCH} \ file://prefer-cpio-over-pax-for-ustar-archives.patch \ file://python-libdir.patch \ file://automake_1.11.2_fix_for_pkglibexec_SCRIPTS.patch \ file://py-compile-compile-only-optimized-byte-code.patch" -PR = "r2" +PR = "r3" SRC_URI[md5sum] = "18194e804d415767bae8f703c963d456" SRC_URI[sha256sum] = "4f46d1f9380c8a3506280750f630e9fc915cb1a435b724be56b499d016368718" do_install () { - oe_runmake 'DESTDIR=${D}' install - install -d ${D}${datadir} + oe_runmake 'DESTDIR=${D}' install + install -d ${D}${datadir} + + # Some distros have both /bin/perl and /usr/bin/perl, but we set perl location + # for target as /usr/bin/perl, so fix it to /usr/bin/perl. + for i in aclocal aclocal-1.11 automake automake-1.11; do + if [ -f ${D}${bindir}/$i ]; then + sed -i -e '1s,#!.*perl,#! ${PERLPATH},' \ + -e 's,exec .*/bin/perl \(.*\) exec .*/bin/perl \(.*\),exec ${PERLPATH} \1 exec ${PERLPATH} \2,' \ + ${D}${bindir}/$i + fi + done } BBCLASSEXTEND = "native nativesdk"
Signature · 1 line
1.7.1
Quoted 27 lines · Robert Yang
Test info:
Tested on FC 13/16/17 64bit
1) $ bitbake meta-toolchain-sdk core-image-sato
2) untar the sdk, and use the sdk to build some pkgs (autoreconf, configure and make)// Robert
The following changes since commit
4e1a8ed1ab7e7bd950e511c79ddfe072cb280a6e:bitbake.conf: Include abi_version.conf in a early stage (2012-04-16 12:51:50 +0100)are available in the git repository at:
git://git.pokylinux.org/poky-contribrobert/fc17_sdk
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=robert/fc17_sdkRobert Yang (3):
glib-2.0: fix builds on fedora 17
autoconf-nativesdk: fix builds on fedora 17
automake-nativesdk: fix builds on fedora 17meta/recipes-core/glib-2.0/glib-2.0_2.30.3.bb | 12 +++++++++++- meta/recipes-devtools/autoconf/autoconf.inc | 16 +++++++++++++++- meta/recipes-devtools/autoconf/autoconf_2.68.bb | 2 +- meta/recipes-devtools/automake/automake_1.11.2.bb | 20 +++++++++++++++++--- 4 files changed, 44 insertions(+), 6 deletions(-)
Quoted 5 lines
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core
Merged updated version into OE-Core
Thanks
Sau!