summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2019-08-13 08:28:35 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2019-08-14 17:29:57 +0100
commite9e5744ba8b0d43c8b874d365f83071ce20bf0a1 (patch)
tree3c46a6631c103ac975784e559cb4be6f92027d9f /meta/recipes-devtools
parente54ecea0a7d309533973b31bdbda178d9af92632 (diff)
downloadopenembedded-core-contrib-e9e5744ba8b0d43c8b874d365f83071ce20bf0a1.tar.gz
gcc-runtime: Move content from gcclibdir into libdir
OE does not use the traditional /usr/lib/gcc prefix to store gcc-runtime it basically is moved into libdir, however some newer files were installed by newer versions of gcc especially libgomp ( omp.h openacc.h ) into gcclibdir, so we have content in both directories, this confuses other tools which are trying to guess the gcc installation and its runtime location, since now we have two directories, the tools either choose one or other and we get inconsistent behavior, e.g. clang for aarch64 uses /usr/lib but same clang for riscv64 chose /usr/lib/gcc This change ensures that OE ends up with single valid location for gcc runtime files Move more common bits into common inc file Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools')
-rw-r--r--meta/recipes-devtools/gcc/gcc-runtime.inc18
-rw-r--r--meta/recipes-devtools/gcc/gcc-runtime_8.3.bb10
-rw-r--r--meta/recipes-devtools/gcc/gcc-runtime_9.1.bb10
3 files changed, 15 insertions, 23 deletions
diff --git a/meta/recipes-devtools/gcc/gcc-runtime.inc b/meta/recipes-devtools/gcc/gcc-runtime.inc
index a5c2600d7f..22c1d78dd1 100644
--- a/meta/recipes-devtools/gcc/gcc-runtime.inc
+++ b/meta/recipes-devtools/gcc/gcc-runtime.inc
@@ -17,6 +17,12 @@ EXTRA_OECONF_PATHS = "\
EXTRA_OECONF_append_linuxstdbase = " --enable-clocale=gnu"
EXTRA_OECONF_append = " --cache-file=${B}/config.cache"
+# Disable ifuncs for libatomic on arm conflicts -march/-mcpu
+EXTRA_OECONF_append_arm = " libat_cv_have_ifunc=no "
+
+# Building with thumb enabled on armv6t fails
+ARM_INSTRUCTION_SET_armv6 = "arm"
+
RUNTIMELIBITM = "libitm"
RUNTIMELIBITM_arc = ""
RUNTIMELIBITM_mipsarch = ""
@@ -77,6 +83,11 @@ do_install () {
cd ${B}/${TARGET_SYS}/$d/
oe_runmake 'DESTDIR=${D}' MULTIBUILDTOP=${B}/${TARGET_SYS}/$d/ install
done
+ if [ -d ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/include ]; then
+ install -d ${D}${libdir}/${TARGET_SYS}/${BINV}/include
+ mv ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/include/* ${D}${libdir}/${TARGET_SYS}/${BINV}/include
+ rmdir --ignore-fail-on-non-empty -p ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/include
+ fi
rm -rf ${D}${infodir}/libgomp.info ${D}${infodir}/dir
rm -rf ${D}${infodir}/libitm.info ${D}${infodir}/dir
rm -rf ${D}${infodir}/libquadmath.info ${D}${infodir}/dir
@@ -205,7 +216,7 @@ FILES_libssp-dev = "\
${libdir}/libssp*.so \
${libdir}/libssp*_nonshared.a \
${libdir}/libssp*.la \
- ${libdir}/gcc/${TARGET_SYS}/${BINV}/include/ssp \
+ ${libdir}/${TARGET_SYS}/${BINV}/include/ssp \
"
SUMMARY_libssp-dev = "GNU stack smashing protection library - development files"
FILES_libssp-staticdev = "${libdir}/libssp*.a"
@@ -214,7 +225,7 @@ SUMMARY_libssp-staticdev = "GNU stack smashing protection library - static devel
FILES_libquadmath = "${libdir}/libquadmath*.so.*"
SUMMARY_libquadmath = "GNU quad-precision math library"
FILES_libquadmath-dev = "\
- ${libdir}/gcc/${TARGET_SYS}/${BINV}/include/quadmath* \
+ ${libdir}/${TARGET_SYS}/${BINV}/include/quadmath* \
${libdir}/libquadmath*.so \
${libdir}/libquadmath.la \
"
@@ -239,7 +250,8 @@ FILES_libgomp-dev = "\
${libdir}/libgomp*${SOLIBSDEV} \
${libdir}/libgomp*.la \
${libdir}/libgomp.spec \
- ${libdir}/gcc/${TARGET_SYS}/${BINV}/include/omp.h \
+ ${libdir}/${TARGET_SYS}/${BINV}/include/omp.h \
+ ${libdir}/${TARGET_SYS}/${BINV}/include/openacc.h \
"
SUMMARY_libgomp-dev = "GNU OpenMP parallel programming library - development files"
FILES_libgomp-staticdev = "${libdir}/libgomp*.a"
diff --git a/meta/recipes-devtools/gcc/gcc-runtime_8.3.bb b/meta/recipes-devtools/gcc/gcc-runtime_8.3.bb
index a1c7a76d0b..dd430b57eb 100644
--- a/meta/recipes-devtools/gcc/gcc-runtime_8.3.bb
+++ b/meta/recipes-devtools/gcc/gcc-runtime_8.3.bb
@@ -1,12 +1,2 @@
require recipes-devtools/gcc/gcc-${PV}.inc
require gcc-runtime.inc
-
-# Disable ifuncs for libatomic on arm conflicts -march/-mcpu
-EXTRA_OECONF_append_arm = " libat_cv_have_ifunc=no "
-
-FILES_libgomp-dev += "\
- ${libdir}/gcc/${TARGET_SYS}/${BINV}/include/openacc.h \
-"
-
-# Building with thumb enabled on armv6t fails
-ARM_INSTRUCTION_SET_armv6 = "arm"
diff --git a/meta/recipes-devtools/gcc/gcc-runtime_9.1.bb b/meta/recipes-devtools/gcc/gcc-runtime_9.1.bb
index a1c7a76d0b..dd430b57eb 100644
--- a/meta/recipes-devtools/gcc/gcc-runtime_9.1.bb
+++ b/meta/recipes-devtools/gcc/gcc-runtime_9.1.bb
@@ -1,12 +1,2 @@
require recipes-devtools/gcc/gcc-${PV}.inc
require gcc-runtime.inc
-
-# Disable ifuncs for libatomic on arm conflicts -march/-mcpu
-EXTRA_OECONF_append_arm = " libat_cv_have_ifunc=no "
-
-FILES_libgomp-dev += "\
- ${libdir}/gcc/${TARGET_SYS}/${BINV}/include/openacc.h \
-"
-
-# Building with thumb enabled on armv6t fails
-ARM_INSTRUCTION_SET_armv6 = "arm"