diff options
Diffstat (limited to 'meta/packages/gcc/gcc-package-sdk.inc')
-rw-r--r-- | meta/packages/gcc/gcc-package-sdk.inc | 64 |
1 files changed, 44 insertions, 20 deletions
diff --git a/meta/packages/gcc/gcc-package-sdk.inc b/meta/packages/gcc/gcc-package-sdk.inc index e106abbd40..635ab6d1f4 100644 --- a/meta/packages/gcc/gcc-package-sdk.inc +++ b/meta/packages/gcc/gcc-package-sdk.inc | |||
@@ -1,20 +1,58 @@ | |||
1 | # Packages emitted by our gcc-cross builds. | ||
2 | # | 1 | # |
2 | # Note gcc-package.inc was already included before us. | ||
3 | # | ||
4 | # We override PACKAGES and FILES to change the packaging | ||
5 | # | ||
6 | |||
3 | INHIBIT_PACKAGE_STRIP ?= "" | 7 | INHIBIT_PACKAGE_STRIP ?= "" |
4 | HAS_G2C ?= "yes" | 8 | HAS_G2C ?= "yes" |
5 | HAS_GFORTRAN ?= "no" | 9 | HAS_GFORTRAN ?= "no" |
6 | OLD_INHIBIT_PACKAGE_STRIP := "${INHIBIT_PACKAGE_STRIP}" | 10 | OLD_INHIBIT_PACKAGE_STRIP := "${INHIBIT_PACKAGE_STRIP}" |
7 | INHIBIT_PACKAGE_STRIP = "1" | 11 | INHIBIT_PACKAGE_STRIP = "1" |
8 | 12 | ||
9 | python do_package() { | 13 | # Having anything auto depending on gcc-cross-sdk is a really bad idea... |
10 | if bb.data.getVar('DEBIAN_NAMES', d, 1): | 14 | EXCLUDE_FROM_SHLIBS = "1" |
11 | bb.data.setVar('PKG_libgcc', 'libgcc1', d) | ||
12 | bb.build.exec_func('package_do_package', d) | ||
13 | } | ||
14 | 15 | ||
16 | PACKAGES = "${PN} ${PN}-doc" | ||
17 | |||
18 | FILES_${PN} = "\ | ||
19 | ${bindir}/* \ | ||
20 | ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/cc1 \ | ||
21 | ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/collect2 \ | ||
22 | ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/f771 \ | ||
23 | ${libexecdir}/gcc/${TARGET_SYS}/${BINV}/cc1plus \ | ||
24 | ${gcclibdir}/${TARGET_SYS}/${BINV}/*.o \ | ||
25 | ${gcclibdir}/${TARGET_SYS}/${BINV}/specs \ | ||
26 | ${gcclibdir}/${TARGET_SYS}/${BINV}/lib* \ | ||
27 | ${gcclibdir}/${TARGET_SYS}/${BINV}/include \ | ||
28 | ${includedir}/c++/${BINV} \ | ||
29 | ${prefix}/${TARGET_SYS}/bin/* \ | ||
30 | ${prefix}/${TARGET_SYS}/lib/* \ | ||
31 | " | ||
15 | do_install () { | 32 | do_install () { |
16 | oe_runmake 'DESTDIR=${D}' install | 33 | oe_runmake 'DESTDIR=${D}' install |
17 | 34 | ||
35 | # Cleanup some of the ${libdir}{,exec}/gcc stuff ... | ||
36 | rm -r ${D}${libdir}/gcc/${TARGET_SYS}/${BINV}/install-tools | ||
37 | rm -r ${D}${libexecdir}/gcc/${TARGET_SYS}/${BINV}/install-tools | ||
38 | |||
39 | # We care about g++ not c++ | ||
40 | rm -f ${D}${bindir}/*c++ | ||
41 | |||
42 | # We don't care about the gcc-<version> copies | ||
43 | rm -f ${D}${bindir}/*gcc-?.?* | ||
44 | |||
45 | # We use libiberty from binutils | ||
46 | rm -f ${D}${prefix}/${TARGET_SYS}/lib/libiberty.a | ||
47 | rm -f ${D}${libdir}/libiberty.a | ||
48 | |||
49 | # Create the ${prefix}/${TARGET_SYS}/bin/* symlinks | ||
50 | install -d ${D}${prefix}/${TARGET_SYS}/bin/ | ||
51 | for l in ${D}${bindir}/*; do | ||
52 | ln -sf "${bindir}/`basename $l`" "${D}${prefix}/${TARGET_SYS}/bin/`basename $l | sed -e 's,${TARGET_PREFIX},,'`" | ||
53 | done | ||
54 | ln -sf "${bindir}/${TARGET_PREFIX}gcc" "${D}${prefix}/${TARGET_SYS}/bin/cc" | ||
55 | |||
18 | # Manually run the target stripper since we won't get it run by | 56 | # Manually run the target stripper since we won't get it run by |
19 | # the packaging. | 57 | # the packaging. |
20 | if [ "x${OLD_INHIBIT_PACKAGE_STRIP}" != "x1" ]; then | 58 | if [ "x${OLD_INHIBIT_PACKAGE_STRIP}" != "x1" ]; then |
@@ -24,17 +62,3 @@ do_install () { | |||
24 | fi | 62 | fi |
25 | } | 63 | } |
26 | 64 | ||
27 | FILES_libgcc = "${prefix}/${TARGET_SYS}/lib/libgcc*.so.*" | ||
28 | FILES_libgcc-dev = "${prefix}/${TARGET_SYS}/lib/libgcc*.so" | ||
29 | |||
30 | FILES_libstdc++ = "${prefix}/${TARGET_SYS}/lib/libstdc++.so.*" | ||
31 | FILES_libstdc++-dev = "${includedir}/c++/${BINV} \ | ||
32 | ${prefix}/${TARGET_SYS}/lib/libstdc++.so \ | ||
33 | ${prefix}/${TARGET_SYS}/lib/libstdc++.a \ | ||
34 | ${prefix}/${TARGET_SYS}/lib/libsupc++.a" | ||
35 | |||
36 | FILES_libmudflap = "${prefix}/${TARGET_SYS}/lib/libmudflap*.so.*" | ||
37 | FILES_libmudflap-dev = "${prefix}/${TARGET_SYS}/lib/libmudflap*.so \ | ||
38 | ${prefix}/${TARGET_SYS}/lib/libmudflap*.a" | ||
39 | |||
40 | RRECOMMENDS_${PN} += "libgcc libgcc-dev cpp g++ libstdc++ libstdc++-dev" | ||