blob: 6d48ec980925dbe4d13d58b5e071a7fee7fe787a [file] [log] [blame]
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001require libgcc-common.inc
2
Brad Bishop19323692019-04-05 15:28:33 -04003DEPENDS = "virtual/${TARGET_PREFIX}gcc virtual/${TARGET_PREFIX}g++ virtual/${MLPREFIX}libc"
Patrick Williamsc124f4f2015-09-15 14:41:29 -05004
Patrick Williamsc0f7c042017-02-23 20:41:17 -06005do_install_append_class-target () {
6 if [ "${TCLIBC}" != "glibc" ]; then
7 case "${TARGET_OS}" in
Brad Bishopd7bf8c12018-02-25 22:55:05 -05008 "linux-musl" | "linux-*spe") extra_target_os="linux";;
9 "linux-musleabi") extra_target_os="linux-gnueabi";;
Patrick Williamsc0f7c042017-02-23 20:41:17 -060010 *) extra_target_os="linux";;
11 esac
Andrew Geissler82c905d2020-04-13 13:39:40 -050012 if [ ! -e ${D}${libdir}/${TARGET_ARCH}${TARGET_VENDOR}-$extra_target_os ]; then
13 ln -s ${TARGET_SYS} ${D}${libdir}/${TARGET_ARCH}${TARGET_VENDOR}-$extra_target_os
14 fi
Patrick Williamsc0f7c042017-02-23 20:41:17 -060015 fi
Brad Bishopd89cb5f2019-04-10 09:02:41 -040016 if [ -n "${@ bb.utils.contains('TUNE_CCARGS_MFLOAT', 'hard', 'hf', '', d)}" ]; then
17 case "${TARGET_OS}" in
18 "linux-musleabi") extra_target_os="linux-musleabihf";;
19 "linux-gnueabi") extra_target_os="linux-gnueabihf";;
20 esac
Andrew Geissler82c905d2020-04-13 13:39:40 -050021 if [ ! -e ${D}${libdir}/${TARGET_ARCH}${TARGET_VENDOR}-$extra_target_os ]; then
22 ln -s ${TARGET_SYS} ${D}${libdir}/${TARGET_ARCH}${TARGET_VENDOR}-$extra_target_os
23 fi
Brad Bishopd89cb5f2019-04-10 09:02:41 -040024 fi
Patrick Williamsc0f7c042017-02-23 20:41:17 -060025}
26
Patrick Williamsc124f4f2015-09-15 14:41:29 -050027PACKAGES = "\
28 ${PN} \
29 ${PN}-dev \
30 ${PN}-dbg \
31"
32
33# All libgcc source is marked with the exception.
34#
35LICENSE_${PN} = "GPL-3.0-with-GCC-exception"
36LICENSE_${PN}-dev = "GPL-3.0-with-GCC-exception"
37LICENSE_${PN}-dbg = "GPL-3.0-with-GCC-exception"
38
39
Patrick Williamsc124f4f2015-09-15 14:41:29 -050040FILES_${PN}-dev = "\
41 ${base_libdir}/libgcc*.so \
Brad Bishop316dfdd2018-06-25 12:45:53 -040042 ${@oe.utils.conditional('BASETARGET_SYS', '${TARGET_SYS}', '', '${libdir}/${BASETARGET_SYS}', d)} \
Patrick Williamsf1e5d692016-03-30 15:21:19 -050043 ${libdir}/${TARGET_SYS}/${BINV}* \
Patrick Williamsc0f7c042017-02-23 20:41:17 -060044 ${libdir}/${TARGET_ARCH}${TARGET_VENDOR}* \
Patrick Williamsc124f4f2015-09-15 14:41:29 -050045"
46
Patrick Williamsc124f4f2015-09-15 14:41:29 -050047do_package[depends] += "virtual/${MLPREFIX}libc:do_packagedata"
48do_package_write_ipk[depends] += "virtual/${MLPREFIX}libc:do_packagedata"
49do_package_write_deb[depends] += "virtual/${MLPREFIX}libc:do_packagedata"
50do_package_write_rpm[depends] += "virtual/${MLPREFIX}libc:do_packagedata"
51
52INSANE_SKIP_${PN}-dev = "staticdev"
53