summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--packages/gcc/gcc-cross-sdk_3.3.4.bb43
1 files changed, 40 insertions, 3 deletions
diff --git a/packages/gcc/gcc-cross-sdk_3.3.4.bb b/packages/gcc/gcc-cross-sdk_3.3.4.bb
index 562f67114a..e298b1caa1 100644
--- a/packages/gcc/gcc-cross-sdk_3.3.4.bb
+++ b/packages/gcc/gcc-cross-sdk_3.3.4.bb
@@ -3,7 +3,11 @@ HOMEPAGE = "http://www.gnu.org/software/gcc/"
SECTION = "devel"
LICENSE = "GPL"
MAINTAINER = "Phil Blundell <pb@handhelds.org>"
-PR = "r1"
+PR = "r2"
+include gcc_${PV}.bb
+
+# Files for these are defined in the main gcc.oe
+#PACKAGES = "libgcc libstdc++ libg2c"
inherit autotools sdk
@@ -75,6 +79,39 @@ do_compile () {
oe_runmake CFLAGS_FOR_TARGET="-I${STAGING_TARGET_INCDIR}"
}
-do_install () {
- autotools_do_install
+#do_install () {
+# autotools_do_install
+#}
+
+python do_package() {
+ if bb.data.getVar('DEBIAN_NAMES', d, 1):
+ bb.data.setVar('PKG_libgcc', 'libgcc1', d)
+ bb.build.exec_func('package_do_package', d)
}
+
+do_install () {
+ oe_runmake 'DESTDIR=${D}' install
+
+ # Move libgcc_s into /lib
+ mkdir -p ${D}${base_libdir}
+ if [ "${BUILD_SYS}" == "${TARGET_SYS}" ]; then
+ # native builds drop one pathname component
+ mv -f ${D}${prefix}/lib/libgcc_s.so.* ${D}${base_libdir}
+ else
+ mv -f ${D}${prefix}/*/lib/libgcc_s.so.* ${D}${base_libdir}
+ fi
+
+ # Move libstdc++ and libg2c into libdir (resetting our prefix to /usr
+ TGT_LIBDIR=`echo ${libdir} | sed -e 's,${CROSS_DIR},/usr,'`
+ mkdir -p ${D}${TGT_LIBDIR}
+ mv -f ${D}${prefix}/*/lib/libstdc++.so.* ${D}${TGT_LIBDIR}
+ mv -f ${D}${prefix}/*/lib/libg2c.so.* ${D}${TGT_LIBDIR}
+
+ # Manually run the target stripper since we won't get it run by
+ # the packaging.
+ if [ "x${OLD_INHIBIT_PACKAGE_STRIP}" != "x1" ]; then
+ ${TARGET_PREFIX}strip ${D}${TGT_LIBDIR}/libstdc++.so.*
+ ${TARGET_PREFIX}strip ${D}${TGT_LIBDIR}/libg2c.so.*
+ ${TARGET_PREFIX}strip ${D}${base_libdir}/libgcc_s.so.*
+ fi
+} \ No newline at end of file