Re: [meta-linaro-toolchain][PATCH 1/2] external-linaro-toolchain: work around 2015.05 release that moved libs
Ryan, Thanks, that sounds good. I can test your RC when it's ready. On Tue, Sep 01, 2015 at 04:31:52PM -0500, Ryan Arnold wrote: > Hi Denys, due to your bugzilla > (https://bugs.linaro.org/show_bug.cgi?id=1717) we're > strongly considering returning the directory layout to what was originally > in place: > > rtlddir=lib/ > libdir=lib/ > slibdir=usr/lib > > Can you please comment on your thoughts on the layout going forward? We'll > provide a release candidate build with this change for evaluation shortly. > > > > On Fri, Aug 28, 2015 at 11:35 AM, Denys Dmytriyenkowrote: > > > Ping. Can I get these backported to fido, please? Corresponding patches > > were > > already submitted 2 weeks ago. Thanks. > > > > -- > > Denys > > > > > > On Fri, Aug 14, 2015 at 02:55:06PM -0400, Denys Dmytriyenko wrote: > > > Thanks! I also submitted fido backports of the patches, for when these > > get > > > into the master... > > > > > > -- > > > Denys > > > > > > > > > On Fri, Aug 14, 2015 at 08:27:07PM +0200, Koen Kooi wrote: > > > > Added both patches into gerrit: > > > > > > > > https://review.linaro.org/7446 > > > > https://review.linaro.org/7447 > > > > > > > > > > > > > > > > > Op 14 aug. 2015, om 20:12 heeft Denys Dmytriyenko > > het volgende geschreven: > > > > > > > > > > From: Denys Dmytriyenko > > > > > > > > > > Starting with 2015.05 binary release, all the libraries have been > > moved from > > > > > /libc/lib/ to /libc/usr/lib/ that causes various toolchain issues in > > OE, > > > > > ranging from QA errors to build failures of other components. This > > patch > > > > > takes care of installing, updating and packaging libraries to match > > other > > > > > versions and satisfy OE toolchain requirements. > > > > > > > > > > Previous attempt at fixing it in > > 78df3a9646e35790ef8b429c84a912d336fd128b > > > > > wasn't complete and its conditional logic would never work: > > > > > https://bugs.linaro.org/show_bug.cgi?id=1717 > > > > > > > > > > * Update check to look where ld-*.so is installed, instead of simply > > > > > checking for /libc/lib/ presence, which exists in 2015.05 > > > > > * Only copy real *.so* libs from /libc/usr/lib to base_libdir, let > > the > > > > > rest (*.a, *.o, etc) go to libdir, as usual > > > > > * If we copy *.so* to base_libdir, remove them from libdir > > > > > * Update lib*.so -> lib*.so.* symlinking list with new libraries > > > > > * For all the lib*.so symlinks created in libdir, remove potential > > dups > > > > > from base_libdir > > > > > * Remove lib*-${ELT_VER_LIBC}.so duplicates > > > > > * When updating libc.so in base_libdir, no need to change path to > > ld-linux > > > > > that is also in base_libdir > > > > > * If both libc.so and libc.so.6 are in base_libdir, make sure the > > path to > > > > > libc.so.6 in libc.so is correct > > > > > * Same for libpthread.so > > > > > * Suppress ldflags/GNU_HASH QA warning for more lib packages > > > > > * Remove duplicate FILES_libstdc++ lines > > > > > > > > > > Signed-off-by: Denys Dmytriyenko > > > > > --- > > > > > .../external-linaro-toolchain.bb | 81 > > ++ > > > > > 1 file changed, 66 insertions(+), 15 deletions(-) > > > > > > > > > > diff --git > > a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/ > > external-linaro-toolchain.bb > > b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/ > > external-linaro-toolchain.bb > > > > > index 857e280..ea41179 100644 > > > > > --- > > a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/ > > external-linaro-toolchain.bb > > > > > +++ > > b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/ > > external-linaro-toolchain.bb > > > > > @@ -65,16 +65,19 @@ do_install() { > > > > > if [ -d > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS} ]; then > > > > > cp -a > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS}/* > > ${D}${base_libdir} > > > > > else > > > > > -if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib ]; > > then > > > > > - cp -a > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} > > > > > -else > > > > > - cp -a > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* ${D}${base_libdir} > > > > > -fi > > > > > + if [ -f > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so ]; > > then > > > > > + cp -a > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} > > > > > + else > > > > > + cp -a > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/*.so* > > ${D}${base_libdir} > > > > > + fi > > > > > fi > > > > > if [ -d > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS} ]; > > then > > > > > cp -a > >
Re: [meta-linaro-toolchain][PATCH 1/2] external-linaro-toolchain: work around 2015.05 release that moved libs
Thanks! On Wed, Sep 02, 2015 at 07:57:29AM +0200, Koen Kooi wrote: > Pushed to fido, sorry for the delay. > > On 28 August 2015 at 18:35, Denys Dmytriyenkowrote: > > Ping. Can I get these backported to fido, please? Corresponding patches were > > already submitted 2 weeks ago. Thanks. > > > > -- > > Denys > > > > > > On Fri, Aug 14, 2015 at 02:55:06PM -0400, Denys Dmytriyenko wrote: > >> Thanks! I also submitted fido backports of the patches, for when these get > >> into the master... > >> > >> -- > >> Denys > >> > >> > >> On Fri, Aug 14, 2015 at 08:27:07PM +0200, Koen Kooi wrote: > >> > Added both patches into gerrit: > >> > > >> > https://review.linaro.org/7446 > >> > https://review.linaro.org/7447 > >> > > >> > > >> > > >> > > Op 14 aug. 2015, om 20:12 heeft Denys Dmytriyenko > >> > > het volgende geschreven: > >> > > > >> > > From: Denys Dmytriyenko > >> > > > >> > > Starting with 2015.05 binary release, all the libraries have been > >> > > moved from > >> > > /libc/lib/ to /libc/usr/lib/ that causes various toolchain issues in > >> > > OE, > >> > > ranging from QA errors to build failures of other components. This > >> > > patch > >> > > takes care of installing, updating and packaging libraries to match > >> > > other > >> > > versions and satisfy OE toolchain requirements. > >> > > > >> > > Previous attempt at fixing it in > >> > > 78df3a9646e35790ef8b429c84a912d336fd128b > >> > > wasn't complete and its conditional logic would never work: > >> > > https://bugs.linaro.org/show_bug.cgi?id=1717 > >> > > > >> > > * Update check to look where ld-*.so is installed, instead of simply > >> > > checking for /libc/lib/ presence, which exists in 2015.05 > >> > > * Only copy real *.so* libs from /libc/usr/lib to base_libdir, let the > >> > > rest (*.a, *.o, etc) go to libdir, as usual > >> > > * If we copy *.so* to base_libdir, remove them from libdir > >> > > * Update lib*.so -> lib*.so.* symlinking list with new libraries > >> > > * For all the lib*.so symlinks created in libdir, remove potential dups > >> > > from base_libdir > >> > > * Remove lib*-${ELT_VER_LIBC}.so duplicates > >> > > * When updating libc.so in base_libdir, no need to change path to > >> > > ld-linux > >> > > that is also in base_libdir > >> > > * If both libc.so and libc.so.6 are in base_libdir, make sure the path > >> > > to > >> > > libc.so.6 in libc.so is correct > >> > > * Same for libpthread.so > >> > > * Suppress ldflags/GNU_HASH QA warning for more lib packages > >> > > * Remove duplicate FILES_libstdc++ lines > >> > > > >> > > Signed-off-by: Denys Dmytriyenko > >> > > --- > >> > > .../external-linaro-toolchain.bb | 81 > >> > > ++ > >> > > 1 file changed, 66 insertions(+), 15 deletions(-) > >> > > > >> > > diff --git > >> > > a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb > >> > > > >> > > b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb > >> > > index 857e280..ea41179 100644 > >> > > --- > >> > > a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb > >> > > +++ > >> > > b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb > >> > > @@ -65,16 +65,19 @@ do_install() { > >> > > if [ -d > >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS} ]; > >> > > then > >> > > cp -a > >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS}/* > >> > > ${D}${base_libdir} > >> > > else > >> > > -if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib ]; > >> > > then > >> > > - cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* > >> > > ${D}${base_libdir} > >> > > -else > >> > > - cp -a > >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* > >> > > ${D}${base_libdir} > >> > > -fi > >> > > + if [ -f > >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so > >> > > ]; then > >> > > + cp -a > >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} > >> > > + else > >> > > + cp -a > >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/*.so* > >> > > ${D}${base_libdir} > >> > > + fi > >> > > fi > >> > > if [ -d > >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS} > >> > > ]; then > >> > > cp -a > >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS}/* > >> > > ${D}${libdir} > >> > > else > >> > > cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* > >> > > ${D}${libdir} > >> > > + if [ ! -f > >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so > >> > > ]; then > >> > > +
Re: [meta-linaro-toolchain][PATCH 1/2] external-linaro-toolchain: work around 2015.05 release that moved libs
Pushed to fido, sorry for the delay. On 28 August 2015 at 18:35, Denys Dmytriyenkowrote: > Ping. Can I get these backported to fido, please? Corresponding patches were > already submitted 2 weeks ago. Thanks. > > -- > Denys > > > On Fri, Aug 14, 2015 at 02:55:06PM -0400, Denys Dmytriyenko wrote: >> Thanks! I also submitted fido backports of the patches, for when these get >> into the master... >> >> -- >> Denys >> >> >> On Fri, Aug 14, 2015 at 08:27:07PM +0200, Koen Kooi wrote: >> > Added both patches into gerrit: >> > >> > https://review.linaro.org/7446 >> > https://review.linaro.org/7447 >> > >> > >> > >> > > Op 14 aug. 2015, om 20:12 heeft Denys Dmytriyenko het >> > > volgende geschreven: >> > > >> > > From: Denys Dmytriyenko >> > > >> > > Starting with 2015.05 binary release, all the libraries have been moved >> > > from >> > > /libc/lib/ to /libc/usr/lib/ that causes various toolchain issues in OE, >> > > ranging from QA errors to build failures of other components. This patch >> > > takes care of installing, updating and packaging libraries to match other >> > > versions and satisfy OE toolchain requirements. >> > > >> > > Previous attempt at fixing it in 78df3a9646e35790ef8b429c84a912d336fd128b >> > > wasn't complete and its conditional logic would never work: >> > > https://bugs.linaro.org/show_bug.cgi?id=1717 >> > > >> > > * Update check to look where ld-*.so is installed, instead of simply >> > > checking for /libc/lib/ presence, which exists in 2015.05 >> > > * Only copy real *.so* libs from /libc/usr/lib to base_libdir, let the >> > > rest (*.a, *.o, etc) go to libdir, as usual >> > > * If we copy *.so* to base_libdir, remove them from libdir >> > > * Update lib*.so -> lib*.so.* symlinking list with new libraries >> > > * For all the lib*.so symlinks created in libdir, remove potential dups >> > > from base_libdir >> > > * Remove lib*-${ELT_VER_LIBC}.so duplicates >> > > * When updating libc.so in base_libdir, no need to change path to >> > > ld-linux >> > > that is also in base_libdir >> > > * If both libc.so and libc.so.6 are in base_libdir, make sure the path to >> > > libc.so.6 in libc.so is correct >> > > * Same for libpthread.so >> > > * Suppress ldflags/GNU_HASH QA warning for more lib packages >> > > * Remove duplicate FILES_libstdc++ lines >> > > >> > > Signed-off-by: Denys Dmytriyenko >> > > --- >> > > .../external-linaro-toolchain.bb | 81 >> > > ++ >> > > 1 file changed, 66 insertions(+), 15 deletions(-) >> > > >> > > diff --git >> > > a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb >> > > >> > > b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb >> > > index 857e280..ea41179 100644 >> > > --- >> > > a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb >> > > +++ >> > > b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb >> > > @@ -65,16 +65,19 @@ do_install() { >> > > if [ -d >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS} ]; >> > > then >> > > cp -a >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS}/* >> > > ${D}${base_libdir} >> > > else >> > > -if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib ]; then >> > > - cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* >> > > ${D}${base_libdir} >> > > -else >> > > - cp -a >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* >> > > ${D}${base_libdir} >> > > -fi >> > > + if [ -f >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so >> > > ]; then >> > > + cp -a >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} >> > > + else >> > > + cp -a >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/*.so* >> > > ${D}${base_libdir} >> > > + fi >> > > fi >> > > if [ -d >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS} >> > > ]; then >> > > cp -a >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS}/* >> > > ${D}${libdir} >> > > else >> > > cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* >> > > ${D}${libdir} >> > > + if [ ! -f >> > > ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so >> > > ]; then >> > > + rm -rf ${D}${libdir}/*.so* >> > > + fi >> > > fi >> > > cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/share/* >> > > ${D}${datadir} >> > > cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/include/* >> > > ${D}${includedir} >> > > @@ -100,10 +103,53 @@ do_install() { >> > > ln -sf ../../lib/libcidn.so.1
Re: [meta-linaro-toolchain][PATCH 1/2] external-linaro-toolchain: work around 2015.05 release that moved libs
Ping. Can I get these backported to fido, please? Corresponding patches were already submitted 2 weeks ago. Thanks. -- Denys On Fri, Aug 14, 2015 at 02:55:06PM -0400, Denys Dmytriyenko wrote: Thanks! I also submitted fido backports of the patches, for when these get into the master... -- Denys On Fri, Aug 14, 2015 at 08:27:07PM +0200, Koen Kooi wrote: Added both patches into gerrit: https://review.linaro.org/7446 https://review.linaro.org/7447 Op 14 aug. 2015, om 20:12 heeft Denys Dmytriyenko de...@denix.org het volgende geschreven: From: Denys Dmytriyenko de...@ti.com Starting with 2015.05 binary release, all the libraries have been moved from /libc/lib/ to /libc/usr/lib/ that causes various toolchain issues in OE, ranging from QA errors to build failures of other components. This patch takes care of installing, updating and packaging libraries to match other versions and satisfy OE toolchain requirements. Previous attempt at fixing it in 78df3a9646e35790ef8b429c84a912d336fd128b wasn't complete and its conditional logic would never work: https://bugs.linaro.org/show_bug.cgi?id=1717 * Update check to look where ld-*.so is installed, instead of simply checking for /libc/lib/ presence, which exists in 2015.05 * Only copy real *.so* libs from /libc/usr/lib to base_libdir, let the rest (*.a, *.o, etc) go to libdir, as usual * If we copy *.so* to base_libdir, remove them from libdir * Update lib*.so - lib*.so.* symlinking list with new libraries * For all the lib*.so symlinks created in libdir, remove potential dups from base_libdir * Remove lib*-${ELT_VER_LIBC}.so duplicates * When updating libc.so in base_libdir, no need to change path to ld-linux that is also in base_libdir * If both libc.so and libc.so.6 are in base_libdir, make sure the path to libc.so.6 in libc.so is correct * Same for libpthread.so * Suppress ldflags/GNU_HASH QA warning for more lib packages * Remove duplicate FILES_libstdc++ lines Signed-off-by: Denys Dmytriyenko de...@ti.com --- .../external-linaro-toolchain.bb | 81 ++ 1 file changed, 66 insertions(+), 15 deletions(-) diff --git a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb index 857e280..ea41179 100644 --- a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb +++ b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb @@ -65,16 +65,19 @@ do_install() { if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS} ]; then cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS}/* ${D}${base_libdir} else -if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib ]; then - cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} -else - cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* ${D}${base_libdir} -fi + if [ -f ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so ]; then + cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} + else + cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/*.so* ${D}${base_libdir} + fi fi if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS} ]; then cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS}/* ${D}${libdir} else cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* ${D}${libdir} + if [ ! -f ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so ]; then + rm -rf ${D}${libdir}/*.so* + fi fi cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/share/* ${D}${datadir} cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/include/* ${D}${includedir} @@ -100,10 +103,53 @@ do_install() { ln -sf ../../lib/libcidn.so.1 ${D}${libdir}/libcidn.so ln -sf ../../lib/libBrokenLocale.so.1 ${D}${libdir}/libBrokenLocale.so ln -sf ../../lib/libthread_db.so.1 ${D}${libdir}/libthread_db.so + ln -sf ../../lib/libthread_db.so.1 ${D}${libdir}/libthread_db-1.0.so ln -sf ../../lib/libanl.so.1 ${D}${libdir}/libanl.so ln -sf ../../lib/libdl.so.2 ${D}${libdir}/libdl.so ln -sf ../../lib/libnss_nisplus.so.2 ${D}${libdir}/libnss_nisplus.so + ln -sf ../../lib/libnss_db.so.2 ${D}${libdir}/libnss_db.so ln -sf ../../lib/libm.so.6
Re: [meta-linaro-toolchain][PATCH 1/2] external-linaro-toolchain: work around 2015.05 release that moved libs
Thanks! I also submitted fido backports of the patches, for when these get into the master... -- Denys On Fri, Aug 14, 2015 at 08:27:07PM +0200, Koen Kooi wrote: Added both patches into gerrit: https://review.linaro.org/7446 https://review.linaro.org/7447 Op 14 aug. 2015, om 20:12 heeft Denys Dmytriyenko de...@denix.org het volgende geschreven: From: Denys Dmytriyenko de...@ti.com Starting with 2015.05 binary release, all the libraries have been moved from /libc/lib/ to /libc/usr/lib/ that causes various toolchain issues in OE, ranging from QA errors to build failures of other components. This patch takes care of installing, updating and packaging libraries to match other versions and satisfy OE toolchain requirements. Previous attempt at fixing it in 78df3a9646e35790ef8b429c84a912d336fd128b wasn't complete and its conditional logic would never work: https://bugs.linaro.org/show_bug.cgi?id=1717 * Update check to look where ld-*.so is installed, instead of simply checking for /libc/lib/ presence, which exists in 2015.05 * Only copy real *.so* libs from /libc/usr/lib to base_libdir, let the rest (*.a, *.o, etc) go to libdir, as usual * If we copy *.so* to base_libdir, remove them from libdir * Update lib*.so - lib*.so.* symlinking list with new libraries * For all the lib*.so symlinks created in libdir, remove potential dups from base_libdir * Remove lib*-${ELT_VER_LIBC}.so duplicates * When updating libc.so in base_libdir, no need to change path to ld-linux that is also in base_libdir * If both libc.so and libc.so.6 are in base_libdir, make sure the path to libc.so.6 in libc.so is correct * Same for libpthread.so * Suppress ldflags/GNU_HASH QA warning for more lib packages * Remove duplicate FILES_libstdc++ lines Signed-off-by: Denys Dmytriyenko de...@ti.com --- .../external-linaro-toolchain.bb | 81 ++ 1 file changed, 66 insertions(+), 15 deletions(-) diff --git a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb index 857e280..ea41179 100644 --- a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb +++ b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb @@ -65,16 +65,19 @@ do_install() { if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS} ]; then cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS}/* ${D}${base_libdir} else -if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib ]; then - cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} -else - cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* ${D}${base_libdir} -fi + if [ -f ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so ]; then + cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} + else + cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/*.so* ${D}${base_libdir} + fi fi if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS} ]; then cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS}/* ${D}${libdir} else cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* ${D}${libdir} + if [ ! -f ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so ]; then + rm -rf ${D}${libdir}/*.so* + fi fi cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/share/* ${D}${datadir} cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/include/* ${D}${includedir} @@ -100,10 +103,53 @@ do_install() { ln -sf ../../lib/libcidn.so.1 ${D}${libdir}/libcidn.so ln -sf ../../lib/libBrokenLocale.so.1 ${D}${libdir}/libBrokenLocale.so ln -sf ../../lib/libthread_db.so.1 ${D}${libdir}/libthread_db.so + ln -sf ../../lib/libthread_db.so.1 ${D}${libdir}/libthread_db-1.0.so ln -sf ../../lib/libanl.so.1 ${D}${libdir}/libanl.so ln -sf ../../lib/libdl.so.2 ${D}${libdir}/libdl.so ln -sf ../../lib/libnss_nisplus.so.2 ${D}${libdir}/libnss_nisplus.so + ln -sf ../../lib/libnss_db.so.2 ${D}${libdir}/libnss_db.so ln -sf ../../lib/libm.so.6 ${D}${libdir}/libm.so + ln -sf ../../lib/libasan.so.1 ${D}${libdir}/libasan.so + ln -sf ../../lib/libatomic.so.1 ${D}${libdir}/libatomic.so + ln -sf ../../lib/libgomp.so.1 ${D}${libdir}/libgomp.so + ln -sf ../../lib/libitm.so.1 ${D}${libdir}/libitm.so +
[meta-linaro-toolchain][PATCH 1/2] external-linaro-toolchain: work around 2015.05 release that moved libs
From: Denys Dmytriyenko de...@ti.com Starting with 2015.05 binary release, all the libraries have been moved from /libc/lib/ to /libc/usr/lib/ that causes various toolchain issues in OE, ranging from QA errors to build failures of other components. This patch takes care of installing, updating and packaging libraries to match other versions and satisfy OE toolchain requirements. Previous attempt at fixing it in 78df3a9646e35790ef8b429c84a912d336fd128b wasn't complete and its conditional logic would never work: https://bugs.linaro.org/show_bug.cgi?id=1717 * Update check to look where ld-*.so is installed, instead of simply checking for /libc/lib/ presence, which exists in 2015.05 * Only copy real *.so* libs from /libc/usr/lib to base_libdir, let the rest (*.a, *.o, etc) go to libdir, as usual * If we copy *.so* to base_libdir, remove them from libdir * Update lib*.so - lib*.so.* symlinking list with new libraries * For all the lib*.so symlinks created in libdir, remove potential dups from base_libdir * Remove lib*-${ELT_VER_LIBC}.so duplicates * When updating libc.so in base_libdir, no need to change path to ld-linux that is also in base_libdir * If both libc.so and libc.so.6 are in base_libdir, make sure the path to libc.so.6 in libc.so is correct * Same for libpthread.so * Suppress ldflags/GNU_HASH QA warning for more lib packages * Remove duplicate FILES_libstdc++ lines Signed-off-by: Denys Dmytriyenko de...@ti.com --- .../external-linaro-toolchain.bb | 81 ++ 1 file changed, 66 insertions(+), 15 deletions(-) diff --git a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb index 857e280..ea41179 100644 --- a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb +++ b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb @@ -65,16 +65,19 @@ do_install() { if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS} ]; then cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS}/* ${D}${base_libdir} else -if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib ]; then - cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} -else - cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* ${D}${base_libdir} -fi + if [ -f ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so ]; then + cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} + else + cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/*.so* ${D}${base_libdir} + fi fi if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS} ]; then cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS}/* ${D}${libdir} else cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* ${D}${libdir} + if [ ! -f ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so ]; then + rm -rf ${D}${libdir}/*.so* + fi fi cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/share/* ${D}${datadir} cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/include/* ${D}${includedir} @@ -100,10 +103,53 @@ do_install() { ln -sf ../../lib/libcidn.so.1 ${D}${libdir}/libcidn.so ln -sf ../../lib/libBrokenLocale.so.1 ${D}${libdir}/libBrokenLocale.so ln -sf ../../lib/libthread_db.so.1 ${D}${libdir}/libthread_db.so + ln -sf ../../lib/libthread_db.so.1 ${D}${libdir}/libthread_db-1.0.so ln -sf ../../lib/libanl.so.1 ${D}${libdir}/libanl.so ln -sf ../../lib/libdl.so.2 ${D}${libdir}/libdl.so ln -sf ../../lib/libnss_nisplus.so.2 ${D}${libdir}/libnss_nisplus.so + ln -sf ../../lib/libnss_db.so.2 ${D}${libdir}/libnss_db.so ln -sf ../../lib/libm.so.6 ${D}${libdir}/libm.so + ln -sf ../../lib/libasan.so.1 ${D}${libdir}/libasan.so + ln -sf ../../lib/libatomic.so.1 ${D}${libdir}/libatomic.so + ln -sf ../../lib/libgomp.so.1 ${D}${libdir}/libgomp.so + ln -sf ../../lib/libitm.so.1 ${D}${libdir}/libitm.so + ln -sf ../../lib/libssp.so.0 ${D}${libdir}/libssp.so + ln -sf ../../lib/libstdc++.so.6 ${D}${libdir}/libstdc++.so + ln -sf ../../lib/libgfortran.so.6 ${D}${libdir}/libgfortran.so + ln -sf ../../lib/libubsan.so.0 ${D}${libdir}/libubsan.so + + # remove potential .so duplicates from base_libdir + # for all symlinks created above in libdir + rm -f ${D}${base_libdir}/libnsl.so + rm -f ${D}${base_libdir}/librt.so +
Re: [meta-linaro-toolchain][PATCH 1/2] external-linaro-toolchain: work around 2015.05 release that moved libs
Added both patches into gerrit: https://review.linaro.org/7446 https://review.linaro.org/7447 Op 14 aug. 2015, om 20:12 heeft Denys Dmytriyenko de...@denix.org het volgende geschreven: From: Denys Dmytriyenko de...@ti.com Starting with 2015.05 binary release, all the libraries have been moved from /libc/lib/ to /libc/usr/lib/ that causes various toolchain issues in OE, ranging from QA errors to build failures of other components. This patch takes care of installing, updating and packaging libraries to match other versions and satisfy OE toolchain requirements. Previous attempt at fixing it in 78df3a9646e35790ef8b429c84a912d336fd128b wasn't complete and its conditional logic would never work: https://bugs.linaro.org/show_bug.cgi?id=1717 * Update check to look where ld-*.so is installed, instead of simply checking for /libc/lib/ presence, which exists in 2015.05 * Only copy real *.so* libs from /libc/usr/lib to base_libdir, let the rest (*.a, *.o, etc) go to libdir, as usual * If we copy *.so* to base_libdir, remove them from libdir * Update lib*.so - lib*.so.* symlinking list with new libraries * For all the lib*.so symlinks created in libdir, remove potential dups from base_libdir * Remove lib*-${ELT_VER_LIBC}.so duplicates * When updating libc.so in base_libdir, no need to change path to ld-linux that is also in base_libdir * If both libc.so and libc.so.6 are in base_libdir, make sure the path to libc.so.6 in libc.so is correct * Same for libpthread.so * Suppress ldflags/GNU_HASH QA warning for more lib packages * Remove duplicate FILES_libstdc++ lines Signed-off-by: Denys Dmytriyenko de...@ti.com --- .../external-linaro-toolchain.bb | 81 ++ 1 file changed, 66 insertions(+), 15 deletions(-) diff --git a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb index 857e280..ea41179 100644 --- a/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb +++ b/meta-linaro-toolchain/recipes-devtools/external-linaro-toolchain/external-linaro-toolchain.bb @@ -65,16 +65,19 @@ do_install() { if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS} ]; then cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/${ELT_TARGET_SYS}/* ${D}${base_libdir} else -if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib ]; then - cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} -else - cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* ${D}${base_libdir} -fi + if [ -f ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so ]; then + cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/* ${D}${base_libdir} + else + cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/*.so* ${D}${base_libdir} + fi fi if [ -d ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS} ]; then cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/${ELT_TARGET_SYS}/* ${D}${libdir} else cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/lib/* ${D}${libdir} + if [ ! -f ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/lib/ld-${ELT_VER_LIBC}.so ]; then + rm -rf ${D}${libdir}/*.so* + fi fi cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/share/* ${D}${datadir} cp -a ${EXTERNAL_TOOLCHAIN}/${ELT_TARGET_SYS}/libc/usr/include/* ${D}${includedir} @@ -100,10 +103,53 @@ do_install() { ln -sf ../../lib/libcidn.so.1 ${D}${libdir}/libcidn.so ln -sf ../../lib/libBrokenLocale.so.1 ${D}${libdir}/libBrokenLocale.so ln -sf ../../lib/libthread_db.so.1 ${D}${libdir}/libthread_db.so + ln -sf ../../lib/libthread_db.so.1 ${D}${libdir}/libthread_db-1.0.so ln -sf ../../lib/libanl.so.1 ${D}${libdir}/libanl.so ln -sf ../../lib/libdl.so.2 ${D}${libdir}/libdl.so ln -sf ../../lib/libnss_nisplus.so.2 ${D}${libdir}/libnss_nisplus.so + ln -sf ../../lib/libnss_db.so.2 ${D}${libdir}/libnss_db.so ln -sf ../../lib/libm.so.6 ${D}${libdir}/libm.so + ln -sf ../../lib/libasan.so.1 ${D}${libdir}/libasan.so + ln -sf ../../lib/libatomic.so.1 ${D}${libdir}/libatomic.so + ln -sf ../../lib/libgomp.so.1 ${D}${libdir}/libgomp.so + ln -sf ../../lib/libitm.so.1 ${D}${libdir}/libitm.so + ln -sf ../../lib/libssp.so.0 ${D}${libdir}/libssp.so + ln -sf ../../lib/libstdc++.so.6 ${D}${libdir}/libstdc++.so + ln -sf ../../lib/libgfortran.so.6 ${D}${libdir}/libgfortran.so + ln -sf