Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 1 | require gcc-configure-common.inc |
| 2 | |
Patrick Williams | c0f7c04 | 2017-02-23 20:41:17 -0600 | [diff] [blame] | 3 | SUMMARY = "Runtime libraries from GCC" |
| 4 | |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 5 | # Over-ride the LICENSE set by gcc-${PV}.inc to remove "& GPLv3" |
| 6 | # All gcc-runtime packages are now covered by the runtime exception. |
| 7 | LICENSE = "GPL-3.0-with-GCC-exception" |
| 8 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 9 | CXXFLAGS:remove = "-fvisibility-inlines-hidden" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 10 | |
| 11 | EXTRA_OECONF_PATHS = "\ |
| 12 | --with-gxx-include-dir=${includedir}/c++/${BINV} \ |
| 13 | --with-sysroot=/not/exist \ |
| 14 | --with-build-sysroot=${STAGING_DIR_TARGET} \ |
| 15 | " |
| 16 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 17 | EXTRA_OECONF:append:linuxstdbase = " --enable-clocale=gnu" |
| 18 | EXTRA_OECONF:append = " --cache-file=${B}/config.cache" |
| 19 | EXTRA_OECONF:append:libc-newlib = " --with-newlib" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 20 | |
Brad Bishop | 08902b0 | 2019-08-20 09:16:51 -0400 | [diff] [blame] | 21 | # Disable ifuncs for libatomic on arm conflicts -march/-mcpu |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 22 | EXTRA_OECONF:append:arm = " libat_cv_have_ifunc=no " |
| 23 | EXTRA_OECONF:append:armeb = " libat_cv_have_ifunc=no " |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 24 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 25 | DISABLE_STATIC:class-nativesdk ?= "" |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 26 | |
| 27 | # Newlib does not support symbol versioning on libsdtcc++ |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 28 | SYMVERS_CONF:libc-newlib = "" |
Brad Bishop | 08902b0 | 2019-08-20 09:16:51 -0400 | [diff] [blame] | 29 | |
| 30 | # Building with thumb enabled on armv6t fails |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 31 | ARM_INSTRUCTION_SET:armv6 = "arm" |
Brad Bishop | 08902b0 | 2019-08-20 09:16:51 -0400 | [diff] [blame] | 32 | |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 33 | RUNTIMELIBITM = "libitm" |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 34 | RUNTIMELIBITM:arc = "" |
| 35 | RUNTIMELIBITM:mipsarch = "" |
| 36 | RUNTIMELIBITM:nios2 = "" |
| 37 | RUNTIMELIBITM:microblaze = "" |
| 38 | RUNTIMELIBITM:riscv32 = "" |
| 39 | RUNTIMELIBITM:riscv64 = "" |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 40 | RUNTIMELIBSSP ?= "" |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 41 | RUNTIMELIBSSP:mingw32 ?= "libssp" |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 42 | |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 43 | RUNTIMETARGET = "${RUNTIMELIBSSP} libstdc++-v3 libgomp libatomic ${RUNTIMELIBITM} \ |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 44 | ${@bb.utils.contains_any('FORTRAN', [',fortran',',f77'], 'libquadmath', '', d)} \ |
| 45 | " |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 46 | # Only build libstdc++ for newlib |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 47 | RUNTIMETARGET:libc-newlib = "libstdc++-v3" |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 48 | |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 49 | # libiberty |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 50 | # libgfortran needs separate recipe due to libquadmath dependency |
| 51 | |
Andrew Geissler | c926e17 | 2021-05-07 16:11:35 -0500 | [diff] [blame] | 52 | # Relative path to be repaced into debug info |
| 53 | REL_S = "/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR}" |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 54 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 55 | DEBUG_PREFIX_MAP:class-target = " \ |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 56 | -fdebug-prefix-map=${WORKDIR}/recipe-sysroot= \ |
| 57 | -fdebug-prefix-map=${WORKDIR}/recipe-sysroot-native= \ |
Andrew Geissler | c926e17 | 2021-05-07 16:11:35 -0500 | [diff] [blame] | 58 | -fdebug-prefix-map=${S}=${REL_S} \ |
| 59 | -fdebug-prefix-map=${S}/include=${REL_S}/libstdc++-v3/../include \ |
| 60 | -fdebug-prefix-map=${S}/libiberty=${REL_S}/libstdc++-v3/../libiberty \ |
| 61 | -fdebug-prefix-map=${S}/libgcc=${REL_S}/libstdc++-v3/../libgcc \ |
| 62 | -fdebug-prefix-map=${B}=${REL_S} \ |
| 63 | -ffile-prefix-map=${B}/${HOST_SYS}/libstdc++-v3/include=${includedir}/c++/${BINV} \ |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 64 | " |
| 65 | |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 66 | do_configure () { |
| 67 | export CXX="${CXX} -nostdinc++ -nostdlib++" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 68 | for d in libgcc ${RUNTIMETARGET}; do |
| 69 | echo "Configuring $d" |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 70 | rm -rf ${B}/${TARGET_SYS}/$d/ |
| 71 | mkdir -p ${B}/${TARGET_SYS}/$d/ |
| 72 | cd ${B}/${TARGET_SYS}/$d/ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 73 | chmod a+x ${S}/$d/configure |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 74 | relpath=${@os.path.relpath("${S}/$d", "${B}/${TARGET_SYS}/$d")} |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 75 | $relpath/configure ${CONFIGUREOPTS} ${EXTRA_OECONF} |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 76 | if [ "$d" = "libgcc" ]; then |
| 77 | (cd ${B}/${TARGET_SYS}/libgcc; oe_runmake enable-execute-stack.c unwind.h md-unwind-support.h sfp-machine.h gthr-default.h) |
| 78 | fi |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 79 | done |
| 80 | } |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 81 | EXTRACONFFUNCS += "extract_stashed_builddir" |
| 82 | do_configure[depends] += "${COMPILERDEP}" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 83 | |
| 84 | do_compile () { |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 85 | for d in libgcc ${RUNTIMETARGET}; do |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 86 | cd ${B}/${TARGET_SYS}/$d/ |
| 87 | oe_runmake MULTIBUILDTOP=${B}/${TARGET_SYS}/$d/ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 88 | done |
| 89 | } |
| 90 | |
| 91 | do_install () { |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 92 | for d in ${RUNTIMETARGET}; do |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 93 | cd ${B}/${TARGET_SYS}/$d/ |
| 94 | oe_runmake 'DESTDIR=${D}' MULTIBUILDTOP=${B}/${TARGET_SYS}/$d/ install |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 95 | done |
Brad Bishop | 08902b0 | 2019-08-20 09:16:51 -0400 | [diff] [blame] | 96 | if [ -d ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/include ]; then |
| 97 | install -d ${D}${libdir}/${TARGET_SYS}/${BINV}/include |
| 98 | mv ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/include/* ${D}${libdir}/${TARGET_SYS}/${BINV}/include |
| 99 | rmdir --ignore-fail-on-non-empty -p ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/include |
| 100 | fi |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 101 | rm -rf ${D}${infodir}/libgomp.info ${D}${infodir}/dir |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 102 | rm -rf ${D}${infodir}/libitm.info ${D}${infodir}/dir |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 103 | rm -rf ${D}${infodir}/libquadmath.info ${D}${infodir}/dir |
| 104 | if [ -d ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/finclude ]; then |
| 105 | rmdir --ignore-fail-on-non-empty -p ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/finclude |
| 106 | fi |
| 107 | if [ -d ${D}${infodir} ]; then |
| 108 | rmdir --ignore-fail-on-non-empty -p ${D}${infodir} |
| 109 | fi |
Patrick Williams | c0f7c04 | 2017-02-23 20:41:17 -0600 | [diff] [blame] | 110 | } |
| 111 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 112 | do_install:append:class-target () { |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 113 | if [ "${TARGET_OS}" = "linux-gnuspe" ]; then |
| 114 | ln -s ${TARGET_SYS} ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR}-linux |
| 115 | fi |
Patrick Williams | c0f7c04 | 2017-02-23 20:41:17 -0600 | [diff] [blame] | 116 | |
| 117 | if [ "${TARGET_OS}" = "linux-gnun32" ]; then |
Brad Bishop | f3fd288 | 2019-06-21 08:06:37 -0400 | [diff] [blame] | 118 | if [ "${TARGET_VENDOR_MULTILIB_ORIGINAL}" != "" -a "${TARGET_VENDOR}" != "${TARGET_VENDOR_MULTILIB_ORIGINAL}" ]; then |
| 119 | mkdir ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR_MULTILIB_ORIGINAL}-linux |
| 120 | ln -s ../${TARGET_SYS} ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR_MULTILIB_ORIGINAL}-linux/32 |
| 121 | elif [ "${MULTILIB_VARIANTS}" != "" ]; then |
| 122 | mkdir ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR}-linux |
| 123 | ln -s ../${TARGET_SYS} ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR}-linux/32 |
Patrick Williams | c0f7c04 | 2017-02-23 20:41:17 -0600 | [diff] [blame] | 124 | else |
| 125 | ln -s ${TARGET_SYS} ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR}-linux |
| 126 | fi |
Brad Bishop | f3fd288 | 2019-06-21 08:06:37 -0400 | [diff] [blame] | 127 | elif [ "${TARGET_OS}" = "linux-gnux32" ]; then |
| 128 | if [ "${TARGET_VENDOR_MULTILIB_ORIGINAL}" != "" -a "${TARGET_VENDOR}" != "${TARGET_VENDOR_MULTILIB_ORIGINAL}" ]; then |
| 129 | mkdir ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR_MULTILIB_ORIGINAL}-linux |
| 130 | ln -s ../${TARGET_SYS} ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR_MULTILIB_ORIGINAL}-linux/x32 |
| 131 | elif [ "${MULTILIB_VARIANTS}" != "" ]; then |
| 132 | mkdir ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR}-linux |
| 133 | ln -s ../${TARGET_SYS} ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR}-linux/32 |
Patrick Williams | c0f7c04 | 2017-02-23 20:41:17 -0600 | [diff] [blame] | 134 | else |
| 135 | ln -s ${TARGET_SYS} ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR}-linux |
| 136 | fi |
Brad Bishop | f3fd288 | 2019-06-21 08:06:37 -0400 | [diff] [blame] | 137 | elif [ "${TARGET_VENDOR_MULTILIB_ORIGINAL}" != "" -a "${TARGET_VENDOR}" != "${TARGET_VENDOR_MULTILIB_ORIGINAL}" ]; then |
Brad Bishop | c8f4712 | 2019-06-24 09:36:18 -0400 | [diff] [blame] | 138 | mkdir ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR_MULTILIB_ORIGINAL}-${TARGET_OS} |
Brad Bishop | f3fd288 | 2019-06-21 08:06:37 -0400 | [diff] [blame] | 139 | ln -s ../${TARGET_SYS}/bits ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR_MULTILIB_ORIGINAL}-${TARGET_OS}/bits |
| 140 | ln -s ../${TARGET_SYS}/ext ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR_MULTILIB_ORIGINAL}-${TARGET_OS}/ext |
Patrick Williams | c0f7c04 | 2017-02-23 20:41:17 -0600 | [diff] [blame] | 141 | fi |
| 142 | |
Andrew Geissler | 635e0e4 | 2020-08-21 15:58:33 -0500 | [diff] [blame] | 143 | if [ "${TARGET_ARCH}" == "x86_64" -a "${MULTILIB_VARIANTS}" != "" ];then |
| 144 | ln -sf ../${X86ARCH32}${TARGET_VENDOR}-${TARGET_OS} ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR}-${TARGET_OS}/32 |
| 145 | fi |
| 146 | |
Patrick Williams | c0f7c04 | 2017-02-23 20:41:17 -0600 | [diff] [blame] | 147 | if [ "${TCLIBC}" != "glibc" ]; then |
| 148 | case "${TARGET_OS}" in |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 149 | "linux-musl" | "linux-*spe") extra_target_os="linux";; |
| 150 | "linux-musleabi") extra_target_os="linux-gnueabi";; |
Patrick Williams | c0f7c04 | 2017-02-23 20:41:17 -0600 | [diff] [blame] | 151 | *) extra_target_os="linux";; |
| 152 | esac |
| 153 | ln -s ${TARGET_SYS} ${D}${includedir}/c++/${BINV}/${TARGET_ARCH}${TARGET_VENDOR}-$extra_target_os |
| 154 | fi |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 155 | chown -R root:root ${D} |
| 156 | } |
| 157 | |
| 158 | INHIBIT_DEFAULT_DEPS = "1" |
Brad Bishop | 1932369 | 2019-04-05 15:28:33 -0400 | [diff] [blame] | 159 | DEPENDS = "virtual/${TARGET_PREFIX}gcc virtual/${TARGET_PREFIX}g++ libgcc virtual/${MLPREFIX}libc" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 160 | PROVIDES = "virtual/${TARGET_PREFIX}compilerlibs" |
| 161 | |
| 162 | BBCLASSEXTEND = "nativesdk" |
| 163 | |
| 164 | PACKAGES = "\ |
| 165 | ${PN}-dbg \ |
| 166 | libstdc++ \ |
| 167 | libstdc++-precompile-dev \ |
| 168 | libstdc++-dev \ |
| 169 | libstdc++-staticdev \ |
| 170 | libg2c \ |
| 171 | libg2c-dev \ |
| 172 | libssp \ |
| 173 | libssp-dev \ |
| 174 | libssp-staticdev \ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 175 | libquadmath \ |
| 176 | libquadmath-dev \ |
| 177 | libquadmath-staticdev \ |
| 178 | libgomp \ |
| 179 | libgomp-dev \ |
| 180 | libgomp-staticdev \ |
| 181 | libatomic \ |
| 182 | libatomic-dev \ |
| 183 | libatomic-staticdev \ |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 184 | libitm \ |
| 185 | libitm-dev \ |
| 186 | libitm-staticdev \ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 187 | " |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 188 | # The base package doesn't exist, so we clear the recommends. |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 189 | RRECOMMENDS:${PN}-dbg = "" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 190 | |
| 191 | # include python debugging scripts |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 192 | FILES:${PN}-dbg += "\ |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 193 | ${libdir}/libstdc++.*-gdb.py \ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 194 | ${datadir}/gcc-${BINV}/python/libstdcxx \ |
| 195 | " |
| 196 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 197 | FILES:libg2c = "${target_libdir}/libg2c.so.*" |
| 198 | SUMMARY:libg2c = "Companion runtime library for g77" |
| 199 | FILES:libg2c-dev = "\ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 200 | ${libdir}/libg2c.so \ |
| 201 | ${libdir}/libg2c.a \ |
| 202 | ${libdir}/libfrtbegin.a \ |
| 203 | " |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 204 | SUMMARY:libg2c-dev = "Companion runtime library for g77 - development files" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 205 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 206 | FILES:libstdc++ = "${libdir}/libstdc++.so.*" |
| 207 | SUMMARY:libstdc++ = "GNU standard C++ library" |
| 208 | FILES:libstdc++-dev = "\ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 209 | ${includedir}/c++/ \ |
| 210 | ${libdir}/libstdc++.so \ |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 211 | ${libdir}/libstdc++*.la \ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 212 | ${libdir}/libsupc++.la \ |
| 213 | " |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 214 | SUMMARY:libstdc++-dev = "GNU standard C++ library - development files" |
| 215 | FILES:libstdc++-staticdev = "\ |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 216 | ${libdir}/libstdc++*.a \ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 217 | ${libdir}/libsupc++.a \ |
| 218 | " |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 219 | SUMMARY:libstdc++-staticdev = "GNU standard C++ library - static development files" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 220 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 221 | FILES:libstdc++-precompile-dev = "${includedir}/c++/${TARGET_SYS}/bits/*.gch" |
| 222 | SUMMARY:libstdc++-precompile-dev = "GNU standard C++ library - precompiled header files" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 223 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 224 | FILES:libssp = "${libdir}/libssp.so.*" |
| 225 | SUMMARY:libssp = "GNU stack smashing protection library" |
| 226 | FILES:libssp-dev = "\ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 227 | ${libdir}/libssp*.so \ |
| 228 | ${libdir}/libssp*_nonshared.a \ |
| 229 | ${libdir}/libssp*.la \ |
Brad Bishop | 08902b0 | 2019-08-20 09:16:51 -0400 | [diff] [blame] | 230 | ${libdir}/${TARGET_SYS}/${BINV}/include/ssp \ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 231 | " |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 232 | SUMMARY:libssp-dev = "GNU stack smashing protection library - development files" |
| 233 | FILES:libssp-staticdev = "${libdir}/libssp*.a" |
| 234 | SUMMARY:libssp-staticdev = "GNU stack smashing protection library - static development files" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 235 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 236 | FILES:libquadmath = "${libdir}/libquadmath*.so.*" |
| 237 | SUMMARY:libquadmath = "GNU quad-precision math library" |
| 238 | FILES:libquadmath-dev = "\ |
Brad Bishop | 08902b0 | 2019-08-20 09:16:51 -0400 | [diff] [blame] | 239 | ${libdir}/${TARGET_SYS}/${BINV}/include/quadmath* \ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 240 | ${libdir}/libquadmath*.so \ |
| 241 | ${libdir}/libquadmath.la \ |
| 242 | " |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 243 | SUMMARY:libquadmath-dev = "GNU quad-precision math library - development files" |
| 244 | FILES:libquadmath-staticdev = "${libdir}/libquadmath.a" |
| 245 | SUMMARY:libquadmath-staticdev = "GNU quad-precision math library - static development files" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 246 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 247 | FILES:libgomp = "${libdir}/libgomp*${SOLIBS}" |
| 248 | SUMMARY:libgomp = "GNU OpenMP parallel programming library" |
| 249 | FILES:libgomp-dev = "\ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 250 | ${libdir}/libgomp*${SOLIBSDEV} \ |
| 251 | ${libdir}/libgomp*.la \ |
| 252 | ${libdir}/libgomp.spec \ |
Andrew Geissler | c182c62 | 2020-05-15 14:13:32 -0500 | [diff] [blame] | 253 | ${libdir}/${TARGET_SYS}/${BINV}/include/acc_prof.h \ |
Brad Bishop | 08902b0 | 2019-08-20 09:16:51 -0400 | [diff] [blame] | 254 | ${libdir}/${TARGET_SYS}/${BINV}/include/omp.h \ |
| 255 | ${libdir}/${TARGET_SYS}/${BINV}/include/openacc.h \ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 256 | " |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 257 | SUMMARY:libgomp-dev = "GNU OpenMP parallel programming library - development files" |
| 258 | FILES:libgomp-staticdev = "${libdir}/libgomp*.a" |
| 259 | SUMMARY:libgomp-staticdev = "GNU OpenMP parallel programming library - static development files" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 260 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 261 | FILES:libatomic = "${libdir}/libatomic.so.*" |
| 262 | SUMMARY:libatomic = "GNU C++11 atomics support library" |
| 263 | FILES:libatomic-dev = "\ |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 264 | ${libdir}/libatomic.so \ |
| 265 | ${libdir}/libatomic.la \ |
| 266 | " |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 267 | SUMMARY:libatomic-dev = "GNU C++11 atomics support library - development files" |
| 268 | FILES:libatomic-staticdev = "${libdir}/libatomic.a" |
| 269 | SUMMARY:libatomic-staticdev = "GNU C++11 atomics support library - static development files" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 270 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 271 | FILES:libitm = "${libdir}/libitm.so.*" |
| 272 | SUMMARY:libitm = "GNU transactional memory support library" |
| 273 | FILES:libitm-dev = "\ |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 274 | ${libdir}/libitm.so \ |
| 275 | ${libdir}/libitm.la \ |
| 276 | ${libdir}/libitm.spec \ |
| 277 | " |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 278 | SUMMARY:libitm-dev = "GNU transactional memory support library - development files" |
| 279 | FILES:libitm-staticdev = "${libdir}/libitm.a" |
| 280 | SUMMARY:libitm-staticdev = "GNU transactional memory support library - static development files" |
Brad Bishop | 79641f2 | 2019-09-10 07:20:22 -0400 | [diff] [blame] | 281 | |
| 282 | require gcc-testsuite.inc |
| 283 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 284 | EXTRA_OEMAKE:prepend:task-check = "${PARALLEL_MAKE} " |
Brad Bishop | 79641f2 | 2019-09-10 07:20:22 -0400 | [diff] [blame] | 285 | |
| 286 | MAKE_CHECK_TARGETS ??= "check-gcc ${@" ".join("check-target-" + i for i in d.getVar("RUNTIMETARGET").split())}" |
| 287 | # prettyprinters and xmethods require gdb tooling |
| 288 | MAKE_CHECK_IGNORE ??= "prettyprinters.exp xmethods.exp" |
| 289 | MAKE_CHECK_RUNTESTFLAGS ??= "${MAKE_CHECK_BOARDARGS} --ignore '${MAKE_CHECK_IGNORE}'" |
| 290 | |
| 291 | # specific host and target dependencies required for test suite running |
| 292 | do_check[depends] += "dejagnu-native:do_populate_sysroot expect-native:do_populate_sysroot" |
| 293 | do_check[depends] += "virtual/libc:do_populate_sysroot" |
| 294 | # only depend on qemu if targeting linux user execution |
| 295 | do_check[depends] += "${@'qemu-native:do_populate_sysroot' if "user" in d.getVar('TOOLCHAIN_TEST_TARGET') else ''}" |
| 296 | # extend the recipe sysroot to include the built libraries (for qemu usermode) |
| 297 | do_check[prefuncs] += "extend_recipe_sysroot" |
| 298 | do_check[prefuncs] += "check_prepare" |
| 299 | do_check[dirs] = "${WORKDIR}/dejagnu ${B}" |
| 300 | do_check[nostamp] = "1" |
| 301 | do_check() { |
| 302 | export DEJAGNU="${WORKDIR}/dejagnu/site.exp" |
| 303 | |
| 304 | # HACK: this works around the configure setting CXX with -nostd* args |
| 305 | sed -i 's/-nostdinc++ -nostdlib++//g' $(find ${B} -name testsuite_flags | head -1) |
Brad Bishop | 79641f2 | 2019-09-10 07:20:22 -0400 | [diff] [blame] | 306 | |
| 307 | if [ "${TOOLCHAIN_TEST_TARGET}" = "user" ]; then |
| 308 | # qemu user has issues allocating large amounts of memory |
| 309 | export G_SLICE=always-malloc |
| 310 | # no test should need more that 10G of memory, this prevents tests like pthread7-rope from leaking memory |
| 311 | ulimit -m 4194304 |
| 312 | ulimit -v 10485760 |
| 313 | fi |
| 314 | |
| 315 | oe_runmake -i ${MAKE_CHECK_TARGETS} RUNTESTFLAGS="${MAKE_CHECK_RUNTESTFLAGS}" |
| 316 | } |
| 317 | addtask check after do_compile do_populate_sysroot |
| 318 | |