Brad Bishop | bec4ebc | 2022-08-03 09:55:16 -0400 | [diff] [blame] | 1 | require recipes-core/glibc/glibc-package.inc |
| 2 | |
| 3 | require license.inc |
| 4 | |
| 5 | INHIBIT_DEFAULT_DEPS = "1" |
| 6 | |
| 7 | LIC_FILES_CHKSUM = "\ |
| 8 | file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302 \ |
| 9 | file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420 \ |
| 10 | " |
| 11 | |
| 12 | PROVIDES += "\ |
| 13 | linux-libc-headers \ |
| 14 | virtual/${TARGET_PREFIX}gcc \ |
| 15 | virtual/${TARGET_PREFIX}g++ \ |
| 16 | virtual/${TARGET_PREFIX}gcc-initial \ |
| 17 | virtual/${TARGET_PREFIX}binutils \ |
| 18 | virtual/${TARGET_PREFIX}libc-for-gcc \ |
| 19 | virtual/${TARGET_PREFIX}compilerlibs \ |
| 20 | virtual/libc \ |
| 21 | virtual/libintl \ |
| 22 | virtual/libiconv \ |
| 23 | virtual/crypt \ |
| 24 | glibc-mtrace \ |
| 25 | glibc-thread-db \ |
| 26 | glibc \ |
| 27 | libc-mtrace \ |
| 28 | gcc-runtime \ |
| 29 | libgcc \ |
| 30 | libg2c \ |
| 31 | libg2c-dev \ |
| 32 | libssp \ |
| 33 | libssp-dev \ |
| 34 | libssp-staticdev \ |
| 35 | libgfortran \ |
| 36 | libgfortran-dev \ |
| 37 | libgfortran-staticdev \ |
| 38 | libmudflap \ |
| 39 | libmudflap-dev \ |
| 40 | libgomp \ |
| 41 | libgomp-dev \ |
| 42 | libgomp-staticdev \ |
| 43 | libitm \ |
| 44 | libitm-dev \ |
| 45 | libitm-staticdev \ |
| 46 | libquadmath \ |
| 47 | libquadmath-dev \ |
| 48 | libquadmath-staticdev \ |
| 49 | virtual/linux-libc-headers \ |
| 50 | libgcov-staticdev \ |
| 51 | virtual/libc-locale \ |
| 52 | " |
| 53 | |
| 54 | PV = "${EAT_VER_MAIN}" |
| 55 | |
| 56 | BINV = "${EAT_VER_GCC}" |
| 57 | |
| 58 | SRC_URI = "file://SUPPORTED" |
| 59 | |
| 60 | do_install() { |
| 61 | # Add stubs for files OE-core expects |
| 62 | install -d ${S}/nscd/ |
| 63 | touch ${S}/nscd/nscd.init |
| 64 | touch ${S}/nscd/nscd.conf |
| 65 | touch ${S}/nscd/nscd.service |
| 66 | touch ${S}/../makedbs.sh |
| 67 | |
| 68 | install -d ${D}${base_libdir} |
| 69 | install -d ${D}${base_sbindir} |
| 70 | install -d ${D}${bindir} |
| 71 | install -d ${D}${sbindir} |
| 72 | install -d ${D}${libdir} |
| 73 | install -d ${D}${libexecdir} |
| 74 | install -d ${D}${datadir} |
| 75 | install -d ${D}${includedir} |
| 76 | install -d ${D}/include |
| 77 | install -d ${D}${libdir}/${TARGET_SYS}/${EAT_VER_GCC} |
Patrick Williams | 8dd6848 | 2022-10-04 07:57:18 -0500 | [diff] [blame] | 78 | install -d ${D}${libdir}/gcc/${TARGET_SYS}/${EAT_VER_GCC}/include |
Brad Bishop | bec4ebc | 2022-08-03 09:55:16 -0400 | [diff] [blame] | 79 | |
| 80 | CP_ARGS="-Prf --preserve=mode,timestamps --no-preserve=ownership" |
| 81 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/${EAT_TARGET_SYS}/${EAT_LIBDIR}/* ${D}${base_libdir} |
| 82 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/${EAT_TARGET_SYS}/libc/${EAT_LIBDIR}/* ${D}${base_libdir} |
| 83 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/${EAT_TARGET_SYS}/libc/usr/${EAT_LIBDIR}/* ${D}${libdir} |
| 84 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/${EAT_TARGET_SYS}/libc/usr/share/* ${D}${datadir} |
| 85 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/${EAT_TARGET_SYS}/libc/usr/include/* ${D}${includedir} |
| 86 | |
| 87 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/${EAT_TARGET_SYS}/include/* ${D}${includedir} |
| 88 | if [ -d ${D}${includedir}/c++/${EAT_VER_GCC}/${EAT_TARGET_SYS} ]; then |
| 89 | mv ${D}${includedir}/c++/${EAT_VER_GCC}/${EAT_TARGET_SYS} ${D}${includedir}/c++/${EAT_VER_GCC}/${TARGET_SYS} |
| 90 | fi |
| 91 | ln -sf ../usr/include/c++ ${D}/include/c++ |
| 92 | |
| 93 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/${EAT_TARGET_SYS}/libc/usr/bin/* ${D}${bindir} |
| 94 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/${EAT_TARGET_SYS}/libc/usr/sbin/* ${D}${sbindir} |
| 95 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/${EAT_TARGET_SYS}/libc/sbin/* ${D}${base_sbindir} |
| 96 | rm -rf ${D}${bindir}/gdbserver |
| 97 | sed -i -e 's#/arm/tools/gnu/bash/4.2/rhe6-x86_64##' ${D}${bindir}/tzselect |
| 98 | sed -i -e 's#/arm/tools/gnu/bash/4.2/rhe6-x86_64##' ${D}${bindir}/ldd |
| 99 | sed -i -e 's#/usr/bin/bash#/bin/sh#' ${D}${bindir}/tzselect |
| 100 | sed -i -e 's#/usr/bin/bash#/bin/sh#' ${D}${bindir}/ldd |
| 101 | sed -i -e 's#/bin/bash#/bin/sh#' ${D}${bindir}/tzselect |
| 102 | sed -i -e 's#/bin/bash#/bin/sh#' ${D}${bindir}/ldd |
| 103 | |
| 104 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/lib/gcc/${EAT_TARGET_SYS}/${EAT_VER_GCC}/crt*.o ${D}${libdir}/${TARGET_SYS}/${EAT_VER_GCC}/ |
| 105 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/lib/gcc/${EAT_TARGET_SYS}/${EAT_VER_GCC}/libgcc* ${D}${libdir}/${TARGET_SYS}/${EAT_VER_GCC}/ |
| 106 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/lib/gcc/${EAT_TARGET_SYS}/${EAT_VER_GCC}/libgcov* ${D}${libdir}/gcc/${TARGET_SYS}/${EAT_VER_GCC}/ |
Patrick Williams | 8dd6848 | 2022-10-04 07:57:18 -0500 | [diff] [blame] | 107 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/lib/gcc/${EAT_TARGET_SYS}/${EAT_VER_GCC}/include/ssp ${D}${libdir}/gcc/${TARGET_SYS}/${EAT_VER_GCC}/include || true |
| 108 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/lib/gcc/${EAT_TARGET_SYS}/${EAT_VER_GCC}/include/sanitizers ${D}${libdir}/gcc/${TARGET_SYS}/${EAT_VER_GCC}/include || true |
| 109 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/lib/gcc/${EAT_TARGET_SYS}/${EAT_VER_GCC}/include/quadmath* ${D}${libdir}/gcc/${TARGET_SYS}/${EAT_VER_GCC}/include || true |
| 110 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/lib/gcc/${EAT_TARGET_SYS}/${EAT_VER_GCC}/include/omp.h ${D}${libdir}/gcc/${TARGET_SYS}/${EAT_VER_GCC}/include || true |
| 111 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/lib/gcc/${EAT_TARGET_SYS}/${EAT_VER_GCC}/include/openacc.h ${D}${libdir}/gcc/${TARGET_SYS}/${EAT_VER_GCC}/include || true |
Brad Bishop | bec4ebc | 2022-08-03 09:55:16 -0400 | [diff] [blame] | 112 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/lib/gcc/${EAT_TARGET_SYS}/${EAT_VER_GCC}/finclude ${D}${libdir}/gcc/${TARGET_SYS}/${EAT_VER_GCC}/ |
| 113 | |
| 114 | # fix up the copied symlinks (they are still pointing to the multiarch directory) |
| 115 | linker_name="${@bb.utils.contains("TUNE_FEATURES", "aarch64", "ld-linux-aarch64.so.1", bb.utils.contains("TUNE_FEATURES", "callconvention-hard", "ld-linux-armhf.so.3", "ld-linux.so.3",d), d)}" |
| 116 | if [ -f ${EXTERNAL_TOOLCHAIN}/${EAT_TARGET_SYS}/libc/${EAT_LIBDIR}/ld-${EAT_VER_LIBC}.so ]; then |
| 117 | ln -sf ld-${EAT_VER_LIBC}.so ${D}${base_libdir}/${linker_name} |
| 118 | else |
| 119 | cp ${CP_ARGS} ${EXTERNAL_TOOLCHAIN}/${EAT_TARGET_SYS}/libc/lib/${linker_name} ${D}${base_libdir}/ |
| 120 | fi |
| 121 | ln -sf ../../lib/librt.so.1 ${D}${libdir}/librt.so |
| 122 | ln -sf ../../lib/libcrypt.so.1 ${D}${libdir}/libcrypt.so |
| 123 | ln -sf ../../lib/libresolv.so.2 ${D}${libdir}/libresolv.so |
| 124 | ln -sf ../../lib/libnss_hesiod.so.2 ${D}${libdir}/libnss_hesiod.so |
| 125 | ln -sf ../../lib/libutil.so.1 ${D}${libdir}/libutil.so |
| 126 | ln -sf ../../lib/libBrokenLocale.so.1 ${D}${libdir}/libBrokenLocale.so |
| 127 | ln -sf ../../lib/libpthread.so.0 ${D}${libdir}/libpthread.so |
| 128 | ln -sf ../../lib/libthread_db.so.1 ${D}${libdir}/libthread_db.so |
| 129 | ln -sf ../../lib/libanl.so.1 ${D}${libdir}/libanl.so |
| 130 | ln -sf ../../lib/libdl.so.2 ${D}${libdir}/libdl.so |
| 131 | ln -sf ../../lib/libnss_db.so.2 ${D}${libdir}/libnss_db.so |
| 132 | ln -sf ../../lib/libnss_dns.so.2 ${D}${libdir}/libnss_dns.so |
| 133 | ln -sf ../../lib/libnss_files.so.2 ${D}${libdir}/libnss_files.so |
| 134 | ln -sf ../../lib/libnss_compat.so.2 ${D}${libdir}/libnss_compat.so |
| 135 | ln -sf ../../lib/libm.so.6 ${D}${libdir}/libm.so |
| 136 | ln -sf ../../lib/libc_malloc_debug.so.0 ${D}${libdir}/libc_malloc_debug.so |
| 137 | |
| 138 | # remove potential .so duplicates from base_libdir |
| 139 | # for all symlinks created above in libdir |
| 140 | rm -f ${D}${base_libdir}/librt.so |
| 141 | rm -f ${D}${base_libdir}/libcrypt.so |
| 142 | rm -f ${D}${base_libdir}/libresolv.so |
| 143 | rm -f ${D}${base_libdir}/libnss_hesiod.so |
| 144 | rm -f ${D}${base_libdir}/libutil.so |
| 145 | rm -f ${D}${base_libdir}/libBrokenLocale.so |
| 146 | rm -f ${D}${base_libdir}/libpthread.so |
| 147 | rm -f ${D}${base_libdir}/libthread_db.so |
| 148 | rm -f ${D}${base_libdir}/libanl.so |
| 149 | rm -f ${D}${base_libdir}/libdl.so |
| 150 | rm -f ${D}${base_libdir}/libnss_db.so |
| 151 | rm -f ${D}${base_libdir}/libnss_dns.so |
| 152 | rm -f ${D}${base_libdir}/libnss_files.so |
| 153 | rm -f ${D}${base_libdir}/libnss_compat.so |
| 154 | rm -f ${D}${base_libdir}/libm.so |
| 155 | |
| 156 | # Move these completely to ${libdir} and delete duplicates in ${base_libdir} |
| 157 | for lib in asan hwasan atomic gfortran gomp itm lsan sanitizer stdc++ tsan ubsan; do |
| 158 | if [ -e ${D}${base_libdir}/lib${lib}.spec ] ; then |
| 159 | mv ${D}${base_libdir}/lib${lib}.spec ${D}${libdir} |
| 160 | fi |
| 161 | if [ -e ${D}${base_libdir}/lib${lib}.a ] ; then |
| 162 | mv ${D}${base_libdir}/lib${lib}.a ${D}${libdir} |
| 163 | fi |
| 164 | rm -f ${D}${base_libdir}/lib${lib}* |
| 165 | done |
| 166 | |
| 167 | # Clean up duplicate libs that are both in base_libdir and libdir |
| 168 | rm -f ${D}${libdir}/libgcc* |
| 169 | |
| 170 | # Besides ld-${EAT_VER_LIBC}.so, other libs can have duplicates like lib*-${EAT_VER_LIBC}.so |
| 171 | # Only remove them if both are regular files and are identical |
| 172 | for i in ${D}${base_libdir}/lib*-${EAT_VER_LIBC}.so; do |
| 173 | if [ ! -e $i ] ; then |
| 174 | continue |
| 175 | fi |
| 176 | |
| 177 | f=$(echo $i | sed 's/-${EAT_VER_LIBC}//') |
| 178 | l=$(ls $f.*) |
| 179 | if [ $(readlink -f $i ) = $l ]; then |
| 180 | echo "$i is a symlink of $l, keep it" |
| 181 | elif [ $(readlink -f $l ) = $i ]; then |
| 182 | echo "$l is a symlink of $i, keep it" |
| 183 | else |
| 184 | cmp -s $i $l |
| 185 | if [ $? -eq 0 ]; then |
| 186 | echo "$i is a duplicate of $l, remove it" |
| 187 | rm $i |
| 188 | else |
| 189 | echo "$i and $l are different files, keep them both" |
| 190 | fi |
| 191 | fi |
| 192 | done |
| 193 | |
| 194 | if [ -d ${D}${base_libdir}/arm-linux-gnueabi ]; then |
| 195 | rm -rf ${D}${base_libdir}/arm-linux-gnueabi |
| 196 | fi |
| 197 | |
| 198 | if [ -d ${D}${base_libdir}/ldscripts ]; then |
| 199 | rm -rf ${D}${base_libdir}/ldscripts |
| 200 | fi |
| 201 | |
| 202 | # Provided by libnsl2 |
| 203 | rm -rf ${D}${includedir}/rpcsvc/yppasswd.* |
| 204 | # Provided by quota |
| 205 | rm -rf ${D}${includedir}/rpcsvc/rquota.* |
| 206 | |
| 207 | if [ -f ${D}${libdir}/libc.so ];then |
| 208 | sed -i -e "s# /${EAT_LIBDIR}/${EAT_TARGET_SYS}# ../../${EAT_LIBDIR}#g" -e "s# /usr/${EAT_LIBDIR}/# /usr/lib/#g" -e "s# /usr/${EAT_LIBDIR}/${EAT_TARGET_SYS}# .#g" -e "s# /${EAT_LIBDIR}/ld-linux# ../../${EAT_LIBDIR}/ld-linux#g" ${D}${libdir}/libc.so |
| 209 | sed -i -e "s# /${EAT_LIBDIR}/libc.so.6# /lib/libc.so.6#g" ${D}${libdir}/libc.so |
| 210 | sed -i -e "s# /lib# ../../lib#g" -e "s# /usr/lib# .#g" ${D}${libdir}/libc.so |
| 211 | fi |
| 212 | |
| 213 | if [ -f ${D}${base_libdir}/libc.so ];then |
| 214 | sed -i -e "s# /${EAT_LIBDIR}/${EAT_TARGET_SYS}# ../../lib#g" -e "s# /usr/${EAT_LIBDIR}/${EAT_TARGET_SYS}# .#g" -e "s# /${EAT_LIBDIR}/# /lib/#g" ${D}${base_libdir}/libc.so |
| 215 | if [ -f ${D}${base_libdir}/libc.so.6 ]; then |
| 216 | sed -i -e "s# /usr/${EAT_LIBDIR}/libc.so.6# /lib/libc.so.6#g" -e "s# /${EAT_LIBDIR}/libc.so.6# /lib/libc.so.6#g" ${D}${base_libdir}/libc.so.6 |
| 217 | fi |
| 218 | fi |
| 219 | |
| 220 | # Remove if empty |
| 221 | rmdir ${D}${bindir} || true |
| 222 | rmdir ${D}${sbindir} || true |
| 223 | rmdir ${D}${base_sbindir} || true |
| 224 | rmdir ${D}${libexecdir} || true |
| 225 | |
| 226 | # Remove unused /usr/share/info/dir |
| 227 | rm -f ${D}${infodir}/dir |
| 228 | } |
| 229 | |
| 230 | # External toolchain doesn't provide multilib support so make corresponding |
| 231 | # install API as an empty API to avoid an unnecessary errors. |
| 232 | oe_multilib_header () { |
| 233 | return |
| 234 | } |
| 235 | |
| 236 | PACKAGES_DYNAMIC = "^locale-base-.* \ |
| 237 | ^glibc-gconv-.* ^glibc-charmap-.* ^glibc-localedata-.* ^glibc-binary-localedata-.* \ |
| 238 | ^${MLPREFIX}glibc-gconv$" |
| 239 | |
| 240 | # PACKAGES is split up according to the 'source' recipes/includes in OE-core |
| 241 | # Stylistic differences are kept to make copy/pasting easier. |
| 242 | |
| 243 | # From gcc-runtime.inc |
| 244 | |
| 245 | PACKAGES += "\ |
| 246 | gcc-runtime-dbg \ |
| 247 | libstdc++ \ |
| 248 | libstdc++-precompile-dev \ |
| 249 | libstdc++-dev \ |
| 250 | libstdc++-staticdev \ |
| 251 | libg2c \ |
| 252 | libg2c-dev \ |
| 253 | libssp \ |
| 254 | libssp-dev \ |
| 255 | libssp-staticdev \ |
| 256 | libmudflap \ |
| 257 | libmudflap-dev \ |
| 258 | libmudflap-staticdev \ |
| 259 | libquadmath \ |
| 260 | libquadmath-dev \ |
| 261 | libquadmath-staticdev \ |
| 262 | libgomp \ |
| 263 | libgomp-dev \ |
| 264 | libgomp-staticdev \ |
| 265 | libatomic \ |
| 266 | libatomic-dev \ |
| 267 | libatomic-staticdev \ |
| 268 | libitm \ |
| 269 | libitm-dev \ |
| 270 | libitm-staticdev \ |
| 271 | " |
| 272 | |
| 273 | # From gcc-sanitizers.inc |
| 274 | |
| 275 | PACKAGES += "gcc-sanitizers gcc-sanitizers-dbg" |
| 276 | PACKAGES += "libasan libubsan liblsan libtsan" |
| 277 | PACKAGES += "libasan-dev libubsan-dev liblsan-dev libtsan-dev" |
| 278 | PACKAGES += "libasan-staticdev libubsan-staticdev liblsan-staticdev libtsan-staticdev" |
| 279 | |
| 280 | # From libgfortran.inc: |
| 281 | |
| 282 | PACKAGES += "\ |
| 283 | libgfortran-dbg \ |
| 284 | libgfortran \ |
| 285 | libgfortran-dev \ |
| 286 | libgfortran-staticdev \ |
| 287 | " |
| 288 | |
| 289 | # libgcc.inc uses ${PN}, so replace that |
| 290 | |
| 291 | PACKAGES += "\ |
| 292 | libgcc \ |
| 293 | libgcc-dev \ |
| 294 | libgcc-dbg \ |
| 295 | " |
| 296 | |
| 297 | # ... and the leftovers |
| 298 | |
| 299 | PACKAGES =+ "\ |
| 300 | ${PN}-mtrace \ |
| 301 | libgcov-staticdev \ |
| 302 | linux-libc-headers \ |
| 303 | linux-libc-headers-dev \ |
| 304 | " |
| 305 | |
| 306 | # Re-order PACKAGES list in order to shift ${PN}-dev towards the end as |
| 307 | # it is meant to pick up remaining dev libraries and headers that aren't |
| 308 | # picked up by other packages. And since some static libraries needs to |
| 309 | # be packaged in ${PN}-dev, so we need to keep ${PN}-staticdev later in |
| 310 | # order. |
| 311 | |
| 312 | PACKAGES := "${@oe.utils.str_filter_out('${PN}-dev', '${PACKAGES}', d)}" |
| 313 | PACKAGES := "${@oe.utils.str_filter_out('${PN}-staticdev', '${PACKAGES}', d)}" |
| 314 | PACKAGES += "\ |
| 315 | ${PN}-dev \ |
| 316 | ${PN}-staticdev \ |
| 317 | " |
| 318 | |
| 319 | INSANE_SKIP:${PN}-dbg = "staticdev" |
| 320 | INSANE_SKIP:${PN}-utils += "ldflags" |
| 321 | INSANE_SKIP:libstdc++ += "ldflags" |
| 322 | INSANE_SKIP:libgfortran += "ldflags" |
| 323 | INSANE_SKIP:libgcc += "ldflags dev-deps" |
| 324 | INSANE_SKIP:libgcc-dev += "staticdev" |
| 325 | INSANE_SKIP:libgfortran += "ldflags dev-deps" |
| 326 | INSANE_SKIP:libstdc++ += "ldflags dev-deps" |
| 327 | INSANE_SKIP:libatomic += "ldflags" |
| 328 | INSANE_SKIP:libasan += "ldflags" |
| 329 | INSANE_SKIP:libubsan += "ldflags" |
| 330 | INSANE_SKIP:libssp += "ldflags" |
| 331 | INSANE_SKIP:libgomp += "ldflags" |
| 332 | INSANE_SKIP:libitm += "ldflags" |
| 333 | INSANE_SKIP:gdbserver += "ldflags" |
| 334 | |
| 335 | # OE-core has literally listed 'glibc' in LIBC_DEPENDENCIES :/ |
| 336 | RPROVIDES:${PN} = "glibc rtld(GNU_HASH)" |
| 337 | # Add runtime provides for the other libc* packages as well |
| 338 | RPROVIDES:${PN}-dev = "glibc-dev" |
| 339 | RPROVIDES:${PN}-doc = "glibc-doc" |
| 340 | RPROVIDES:${PN}-dbg = "glibc-dbg" |
| 341 | RPROVIDES:${PN}-pic = "glibc-pic" |
| 342 | RPROVIDES:${PN}-utils = "glibc-utils" |
| 343 | RPROVIDES:${PN}-mtrace = "glibc-mtrace libc-mtrace" |
| 344 | |
| 345 | PKG:${PN} = "glibc" |
| 346 | PKG:${PN}-dev = "glibc-dev" |
| 347 | PKG:${PN}-doc = "glibc-doc" |
| 348 | PKG:${PN}-dbg = "glibc-dbg" |
| 349 | PKG:${PN}-pic = "glibc-pic" |
| 350 | PKG:${PN}-utils = "glibc-utils" |
| 351 | PKG:${PN}-mtrace = "glibc-mtrace" |
| 352 | PKG:${PN}-gconv = "glibc-gconv" |
| 353 | PKG:${PN}-extra-nss = "glibc-extra-nss" |
| 354 | PKG:${PN}-thread-db = "glibc-thread-db" |
| 355 | PKG:${PN}-pcprofile = "glibc-pcprofile" |
| 356 | PKG:${PN}-staticdev = "glibc-staticdev" |
| 357 | |
| 358 | PKGV = "${EAT_VER_LIBC}" |
| 359 | PKGV:${PN} = "${EAT_VER_LIBC}" |
| 360 | PKGV:${PN}-dev = "${EAT_VER_LIBC}" |
| 361 | PKGV:${PN}-doc = "${EAT_VER_LIBC}" |
| 362 | PKGV:${PN}-dbg = "${EAT_VER_LIBC}" |
| 363 | PKGV:${PN}-pic = "${EAT_VER_LIBC}" |
| 364 | PKGV:${PN}-utils = "${EAT_VER_LIBC}" |
| 365 | PKGV:${PN}-mtrace = "${EAT_VER_LIBC}" |
| 366 | PKGV:${PN}-gconv = "${EAT_VER_LIBC}" |
| 367 | PKGV:${PN}-extra-nss = "${EAT_VER_LIBC}" |
| 368 | PKGV:${PN}-thread-db = "${EAT_VER_LIBC}" |
| 369 | PKGV:${PN}-pcprofile = "${EAT_VER_LIBC}" |
| 370 | PKGV:${PN}-staticdev = "${EAT_VER_LIBC}" |
| 371 | PKGV:catchsegv = "${EAT_VER_LIBC}" |
| 372 | PKGV:glibc-extra-nss = "${EAT_VER_LIBC}" |
| 373 | PKGV:glibc-thread-db = "${EAT_VER_LIBC}" |
| 374 | |
| 375 | PKGV:libmemusage = "${EAT_VER_LIBC}" |
| 376 | PKGV:libsegfault = "${EAT_VER_LIBC}" |
| 377 | PKGV:libsotruss = "${EAT_VER_LIBC}" |
| 378 | PKGV:sln = "${EAT_VER_LIBC}" |
| 379 | PKGV:nscd = "${EAT_VER_LIBC}" |
| 380 | PKGV:ldd = "${EAT_VER_LIBC}" |
| 381 | |
| 382 | PKGV:libasan-dev = "${EAT_VER_GCC}" |
| 383 | PKGV:libasan = "${EAT_VER_GCC}" |
| 384 | PKGV:libasan-staticdev = "${EAT_VER_GCC}" |
| 385 | PKGV:libatomic-dev = "${EAT_VER_GCC}" |
| 386 | PKGV:libatomic = "${EAT_VER_GCC}" |
| 387 | PKGV:libatomic-staticdev = "${EAT_VER_GCC}" |
| 388 | PKGV:libg2c-dev = "${EAT_VER_GCC}" |
| 389 | PKGV:libg2c = "${EAT_VER_GCC}" |
| 390 | PKGV:libgcc-dev = "${EAT_VER_GCC}" |
| 391 | PKGV:libgcc = "${EAT_VER_GCC}" |
| 392 | PKGV:libgfortran-dbg = "${EAT_VER_GCC}" |
| 393 | PKGV:libgfortran-dev = "${EAT_VER_GCC}" |
| 394 | PKGV:libgfortran = "${EAT_VER_GCC}" |
| 395 | PKGV:libgfortran-staticdev = "${EAT_VER_GCC}" |
| 396 | PKGV:libgomp-dev = "${EAT_VER_GCC}" |
| 397 | PKGV:libgomp = "${EAT_VER_GCC}" |
| 398 | PKGV:libgomp-staticdev = "${EAT_VER_GCC}" |
| 399 | PKGV:libitm-dev = "${EAT_VER_GCC}" |
| 400 | PKGV:libitm = "${EAT_VER_GCC}" |
| 401 | PKGV:libitm-staticdev = "${EAT_VER_GCC}" |
| 402 | PKGV:liblsan-dev = "${EAT_VER_GCC}" |
| 403 | PKGV:liblsan = "${EAT_VER_GCC}" |
| 404 | PKGV:liblsan-staticdev = "${EAT_VER_GCC}" |
| 405 | PKGV:libmudflap-dev = "${EAT_VER_GCC}" |
| 406 | PKGV:libmudflap = "${EAT_VER_GCC}" |
| 407 | PKGV:libmudflap-staticdev = "${EAT_VER_GCC}" |
| 408 | PKGV:libquadmath-dev = "${EAT_VER_GCC}" |
| 409 | PKGV:libquadmath = "${EAT_VER_GCC}" |
| 410 | PKGV:libquadmath-staticdev = "${EAT_VER_GCC}" |
| 411 | PKGV:libssp-dev = "${EAT_VER_GCC}" |
| 412 | PKGV:libssp = "${EAT_VER_GCC}" |
| 413 | PKGV:libssp-staticdev = "${EAT_VER_GCC}" |
| 414 | PKGV:libstdc++-dbg = "${EAT_VER_GCC}" |
| 415 | PKGV:libstdc++-dev = "${EAT_VER_GCC}" |
| 416 | PKGV:libstdc++ = "${EAT_VER_GCC}" |
| 417 | PKGV:libstdc++-precompile-dev = "${EAT_VER_GCC}" |
| 418 | PKGV:libstdc++-staticdev = "${EAT_VER_GCC}" |
| 419 | PKGV:libtsan-dev = "${EAT_VER_GCC}" |
| 420 | PKGV:libtsan = "${EAT_VER_GCC}" |
| 421 | PKGV:libtsan-staticdev = "${EAT_VER_GCC}" |
| 422 | PKGV:libubsan-dev = "${EAT_VER_GCC}" |
| 423 | PKGV:libubsan = "${EAT_VER_GCC}" |
| 424 | PKGV:libubsan-staticdev = "${EAT_VER_GCC}" |
| 425 | |
| 426 | PKGV:linux-libc-headers-dev = "${EAT_VER_KERNEL}" |
| 427 | PKGV:linux-libc-headers = "${EAT_VER_KERNEL}" |
| 428 | |
| 429 | PKGV:gdbserver = "${EAT_VER_GDBSERVER}" |
| 430 | |
| 431 | ALLOW_EMPTY:${PN}-mtrace = "1" |
| 432 | FILES:${PN}-mtrace = "${bindir}/mtrace" |
| 433 | |
| 434 | FILES:libgcov-staticdev = "${libdir}/gcc/${TARGET_SYS}/${BINV}/libgcov.a" |
| 435 | |
| 436 | FILES:libsegfault = "${base_libdir}/libSegFault*" |
| 437 | |
| 438 | FILES:catchsegv = "${bindir}/catchsegv" |
| 439 | RDEPENDS:catchsegv = "libsegfault" |
| 440 | |
| 441 | # From libgfortran.inc: |
| 442 | |
| 443 | FILES:libgfortran = "${libdir}/libgfortran.so.*" |
| 444 | FILES:libgfortran-dev = "\ |
| 445 | ${libdir}/libgfortran*.so \ |
| 446 | ${libdir}/libgfortran.spec \ |
| 447 | ${libdir}/libgfortran.la \ |
| 448 | ${libdir}/gcc/${TARGET_SYS}/${BINV}/libgfortranbegin.* \ |
| 449 | ${libdir}/gcc/${TARGET_SYS}/${BINV}/libcaf_single* \ |
| 450 | ${libdir}/gcc/${TARGET_SYS}/${BINV}/finclude/ \ |
| 451 | " |
| 452 | FILES:libgfortran-staticdev = "${libdir}/libgfortran.a" |
| 453 | |
| 454 | |
| 455 | # From gcc-sanitizers.inc: |
| 456 | |
| 457 | FILES:libasan += "${libdir}/libasan.so.* ${libdir}/libhwasan.so.*" |
| 458 | FILES:libasan-dev += "\ |
| 459 | ${libdir}/libasan_preinit.o \ |
| 460 | ${libdir}/libasan.so \ |
| 461 | ${libdir}/libhwasan.so \ |
| 462 | ${libdir}/libasan.la \ |
| 463 | " |
| 464 | FILES:libasan-staticdev += "${libdir}/libasan.a \ |
| 465 | ${libdir}/libhwasan.a \ |
| 466 | " |
| 467 | |
| 468 | FILES:libubsan += "${libdir}/libubsan.so.*" |
| 469 | FILES:libubsan-dev += "\ |
| 470 | ${libdir}/libubsan.so \ |
| 471 | ${libdir}/libubsan.la \ |
| 472 | " |
| 473 | FILES:libubsan-staticdev += "${libdir}/libubsan.a" |
| 474 | |
| 475 | FILES:liblsan += "${libdir}/liblsan.so.*" |
| 476 | FILES:liblsan-dev += "\ |
| 477 | ${libdir}/liblsan.so \ |
| 478 | ${libdir}/liblsan.la \ |
| 479 | ${libdir}/liblsan_preinit.o \ |
| 480 | " |
| 481 | FILES:liblsan-staticdev += "${libdir}/liblsan.a" |
| 482 | |
| 483 | FILES:libtsan += "${libdir}/libtsan.so.*" |
| 484 | FILES:libtsan-dev += "\ |
| 485 | ${libdir}/libtsan.so \ |
| 486 | ${libdir}/libtsan.la \ |
| 487 | ${libdir}/libtsan_*.o \ |
| 488 | " |
| 489 | FILES:libtsan-staticdev += "${libdir}/libtsan.a" |
| 490 | |
| 491 | FILES:gcc-sanitizers = "${libdir}/*.spec ${libdir}/gcc/${TARGET_SYS}/${BINV}/include/sanitizer/*.h" |
| 492 | |
| 493 | # From libgcc.inc: |
| 494 | |
| 495 | FILES:libgcc = "${base_libdir}/libgcc_s.so.1" |
| 496 | |
| 497 | FILES:libgcc-dev = "\ |
| 498 | ${base_libdir}/libgcc*.so \ |
| 499 | ${@oe.utils.conditional('BASETARGET_SYS', '${TARGET_SYS}', '', '${libdir}/${BASETARGET_SYS}', d)} \ |
| 500 | ${libdir}/${TARGET_SYS}/${BINV}* \ |
| 501 | ${libdir}/${TARGET_ARCH}${TARGET_VENDOR}* \ |
Brad Bishop | bec4ebc | 2022-08-03 09:55:16 -0400 | [diff] [blame] | 502 | " |
| 503 | |
| 504 | FILES:linux-libc-headers = "" |
| 505 | FILES:linux-libc-headers-dev = "\ |
| 506 | ${includedir}/asm* \ |
| 507 | ${includedir}/linux \ |
| 508 | ${includedir}/mtd \ |
| 509 | ${includedir}/rdma \ |
| 510 | ${includedir}/scsi \ |
| 511 | ${includedir}/sound \ |
| 512 | ${includedir}/video \ |
| 513 | " |
| 514 | FILES:${PN} += "\ |
| 515 | ${libdir}/bin \ |
| 516 | ${libdir}/locale \ |
| 517 | ${libdir}/gconv/gconv-modules \ |
| 518 | ${datadir}/zoneinfo \ |
| 519 | ${base_libdir}/libcrypt*.so.* \ |
| 520 | ${base_libdir}/libcrypt-*.so \ |
| 521 | ${base_libdir}/libc.so.* \ |
| 522 | ${base_libdir}/libc-*.so \ |
| 523 | ${base_libdir}/libm.so.* \ |
| 524 | ${base_libdir}/libmemusage.so \ |
| 525 | ${base_libdir}/libm-*.so \ |
| 526 | ${base_libdir}/ld*.so.* \ |
| 527 | ${base_libdir}/ld-*.so \ |
| 528 | ${base_libdir}/libpthread*.so.* \ |
| 529 | ${base_libdir}/libpthread*.so \ |
| 530 | ${base_libdir}/libpthread-*.so \ |
| 531 | ${base_libdir}/libresolv*.so.* \ |
| 532 | ${base_libdir}/libresolv-*.so \ |
| 533 | ${base_libdir}/librt*.so.* \ |
| 534 | ${base_libdir}/librt-*.so \ |
| 535 | ${base_libdir}/libutil*.so.* \ |
| 536 | ${base_libdir}/libutil-*.so \ |
| 537 | ${base_libdir}/libnss_files*.so.* \ |
| 538 | ${base_libdir}/libnss_files-*.so \ |
| 539 | ${base_libdir}/libnss_compat*.so.* \ |
| 540 | ${base_libdir}/libnss_compat-*.so \ |
| 541 | ${base_libdir}/libnss_dns*.so.* \ |
| 542 | ${base_libdir}/libnss_dns-*.so \ |
| 543 | ${base_libdir}/libnss_nis*.so.* \ |
| 544 | ${base_libdir}/libnss_nisplus-*.so \ |
| 545 | ${base_libdir}/libnss_nisplus*.so.* \ |
| 546 | ${base_libdir}/libnss_nis-*.so \ |
| 547 | ${base_libdir}/libnss_hesiod*.so.* \ |
| 548 | ${base_libdir}/libnss_hesiod-*.so \ |
| 549 | ${base_libdir}/libdl*.so.* \ |
| 550 | ${base_libdir}/libdl-*.so \ |
| 551 | ${base_libdir}/libanl*.so.* \ |
| 552 | ${base_libdir}/libanl-*.so \ |
| 553 | ${base_libdir}/libBrokenLocale*.so.* \ |
| 554 | ${base_libdir}/libBrokenLocale-*.so \ |
| 555 | ${base_libdir}/libthread_db*.so.* \ |
| 556 | ${base_libdir}/libthread_db-*.so \ |
| 557 | ${base_libdir}/libmemusage.so \ |
| 558 | ${base_libdir}/libSegFault.so \ |
| 559 | ${base_libdir}/libpcprofile.so \ |
| 560 | " |
| 561 | |
| 562 | FILES:${PN}-dbg += "${base_libdir}/debug" |
| 563 | |
| 564 | # From gcc-runtime.inc |
| 565 | |
| 566 | # include python debugging scripts |
| 567 | FILES:gcc-runtime-dbg += "\ |
| 568 | ${libdir}/libstdc++.so.*-gdb.py \ |
| 569 | ${datadir}/gcc-${BINV}/python/libstdcxx \ |
| 570 | " |
| 571 | |
| 572 | FILES:libg2c = "${target_libdir}/libg2c.so.*" |
| 573 | SUMMARY:libg2c = "Companion runtime library for g77" |
| 574 | FILES:libg2c-dev = "\ |
| 575 | ${libdir}/libg2c.so \ |
| 576 | ${libdir}/libg2c.a \ |
| 577 | ${libdir}/libfrtbegin.a \ |
| 578 | " |
| 579 | SUMMARY:libg2c-dev = "Companion runtime library for g77 - development files" |
| 580 | |
| 581 | FILES:libstdc++ = "${libdir}/libstdc++.so.*" |
| 582 | SUMMARY:libstdc++ = "GNU standard C++ library" |
| 583 | FILES:libstdc++-dev = "\ |
| 584 | /include/c++ \ |
| 585 | ${includedir}/c++/ \ |
| 586 | ${libdir}/libstdc++.so \ |
| 587 | ${libdir}/libstdc++*.la \ |
| 588 | ${libdir}/libsupc++.la \ |
| 589 | " |
| 590 | SUMMARY:libstdc++-dev = "GNU standard C++ library - development files" |
| 591 | |
| 592 | FILES:libstdc++-staticdev = "\ |
| 593 | ${libdir}/libstdc++*.a \ |
| 594 | ${libdir}/libsupc++.a \ |
| 595 | " |
| 596 | SUMMARY:libstdc++-staticdev = "GNU standard C++ library - static development files" |
| 597 | |
| 598 | FILES:libstdc++-precompile-dev = "${includedir}/c++/${TARGET_SYS}/bits/*.gch" |
| 599 | SUMMARY:libstdc++-precompile-dev = "GNU standard C++ library - precompiled header files" |
| 600 | |
| 601 | FILES:libssp = "${libdir}/libssp.so.*" |
| 602 | SUMMARY:libssp = "GNU stack smashing protection library" |
| 603 | FILES:libssp-dev = "\ |
| 604 | ${libdir}/libssp*.so \ |
| 605 | ${libdir}/libssp*_nonshared.a \ |
| 606 | ${libdir}/libssp*.la \ |
| 607 | ${libdir}/gcc/${TARGET_SYS}/${BINV}/include/ssp \ |
| 608 | " |
| 609 | SUMMARY:libssp-dev = "GNU stack smashing protection library - development files" |
| 610 | FILES:libssp-staticdev = "${libdir}/libssp*.a" |
| 611 | SUMMARY:libssp-staticdev = "GNU stack smashing protection library - static development files" |
| 612 | |
| 613 | FILES:libquadmath = "${libdir}/libquadmath*.so.*" |
| 614 | SUMMARY:libquadmath = "GNU quad-precision math library" |
| 615 | FILES:libquadmath-dev = "\ |
| 616 | ${libdir}/gcc/${TARGET_SYS}/${BINV}/include/quadmath* \ |
| 617 | ${libdir}/libquadmath*.so \ |
| 618 | ${libdir}/libquadmath.la \ |
| 619 | " |
| 620 | SUMMARY:libquadmath-dev = "GNU quad-precision math library - development files" |
| 621 | FILES:libquadmath-staticdev = "${libdir}/libquadmath.a" |
| 622 | SUMMARY:libquadmath-staticdev = "GNU quad-precision math library - static development files" |
| 623 | |
| 624 | # NOTE: mudflap has been removed as of gcc 4.9 and has been superseded by the address sanitiser |
| 625 | FILES:libmudflap = "${libdir}/libmudflap*.so.*" |
| 626 | SUMMARY:libmudflap = "Pointer debugging library for gcc" |
| 627 | FILES:libmudflap-dev = "\ |
| 628 | ${libdir}/libmudflap*.so \ |
| 629 | ${libdir}/libmudflap.la \ |
| 630 | " |
| 631 | SUMMARY:libmudflap-dev = "Pointer debugging library for gcc - development files" |
| 632 | FILES:libmudflap-staticdev = "${libdir}/libmudflap.a" |
| 633 | SUMMARY:libmudflap-staticdev = "Pointer debugging library for gcc - static development files" |
| 634 | |
| 635 | FILES:libgomp = "${libdir}/libgomp*${SOLIBS}" |
| 636 | SUMMARY:libgomp = "GNU OpenMP parallel programming library" |
| 637 | FILES:libgomp-dev = "\ |
| 638 | ${libdir}/libgomp*${SOLIBSDEV} \ |
| 639 | ${libdir}/libgomp*.la \ |
| 640 | ${libdir}/libgomp.spec \ |
| 641 | ${libdir}/gcc/${TARGET_SYS}/${BINV}/include/omp.h \ |
| 642 | ${libdir}/gcc/${TARGET_SYS}/${BINV}/include/openacc.h \ |
| 643 | " |
| 644 | SUMMARY:libgomp-dev = "GNU OpenMP parallel programming library - development files" |
| 645 | FILES:libgomp-staticdev = "${libdir}/libgomp*.a" |
| 646 | SUMMARY:libgomp-staticdev = "GNU OpenMP parallel programming library - static development files" |
| 647 | |
| 648 | FILES:libatomic = "${libdir}/libatomic.so.*" |
| 649 | SUMMARY:libatomic = "GNU C++11 atomics support library" |
| 650 | FILES:libatomic-dev = "\ |
| 651 | ${libdir}/libatomic.so \ |
| 652 | ${libdir}/libatomic.la \ |
| 653 | " |
| 654 | SUMMARY:libatomic-dev = "GNU C++11 atomics support library - development files" |
| 655 | FILES:libatomic-staticdev = "${libdir}/libatomic.a" |
| 656 | SUMMARY:libatomic-staticdev = "GNU C++11 atomics support library - static development files" |
| 657 | |
| 658 | FILES:libitm = "${libdir}/libitm.so.*" |
| 659 | SUMMARY:libitm = "GNU transactional memory support library" |
| 660 | FILES:libitm-dev = "\ |
| 661 | ${libdir}/libitm.so \ |
| 662 | ${libdir}/libitm.la \ |
| 663 | ${libdir}/libitm.spec \ |
| 664 | " |
| 665 | SUMMARY:libitm-dev = "GNU transactional memory support library - development files" |
| 666 | FILES:libitm-staticdev = "${libdir}/libitm.a" |
| 667 | SUMMARY:libitm-staticdev = "GNU transactional memory support library - static development files" |
| 668 | |
| 669 | EAT_VER_MAIN ??= "" |
| 670 | |
| 671 | python () { |
| 672 | if not d.getVar("EAT_VER_MAIN", False): |
| 673 | raise bb.parse.SkipPackage("External ARM toolchain not configured (EAT_VER_MAIN not set).") |
| 674 | if d.getVar('TCLIBC', True) != "glibc": |
| 675 | raise bb.parse.SkipPackage("incompatible with %s" % d.getVar('TCLIBC', True)) |
| 676 | } |