summaryrefslogtreecommitdiffstats
path: root/common/recipes-devtools/gcc
diff options
context:
space:
mode:
authorNobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>2015-03-25 10:47:45 +0900
committerNobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>2015-03-25 10:47:45 +0900
commit1c35920d85e424b3f65aa6df1dbde689dd6ec007 (patch)
tree58b2cacb3674111aad5a4ded694db0cef5cf55f3 /common/recipes-devtools/gcc
commit BSP v1.8.0
Signed-off-by: Nobuhiro Iwamatsu <nobuhiro.iwamatsu.yj@renesas.com>
Diffstat (limited to 'common/recipes-devtools/gcc')
-rw-r--r--common/recipes-devtools/gcc/gcc-cross-canadian_linaro-4.8.bbappend1
-rw-r--r--common/recipes-devtools/gcc/libgcc_4.8.bbappend38
2 files changed, 39 insertions, 0 deletions
diff --git a/common/recipes-devtools/gcc/gcc-cross-canadian_linaro-4.8.bbappend b/common/recipes-devtools/gcc/gcc-cross-canadian_linaro-4.8.bbappend
new file mode 100644
index 0000000..8dec207
--- /dev/null
+++ b/common/recipes-devtools/gcc/gcc-cross-canadian_linaro-4.8.bbappend
@@ -0,0 +1 @@
+INSANE_SKIP_${PN} += "libdir"
diff --git a/common/recipes-devtools/gcc/libgcc_4.8.bbappend b/common/recipes-devtools/gcc/libgcc_4.8.bbappend
new file mode 100644
index 0000000..1f9888d
--- /dev/null
+++ b/common/recipes-devtools/gcc/libgcc_4.8.bbappend
@@ -0,0 +1,38 @@
+do_install_append () {
+ BINVER=`${TARGET_PREFIX}gcc -dumpversion`
+ if [ ${BINVER} != ${BINV} ] ; then
+ rm -rf ${D}${libdir}/${TARGET_SYS}/${BINVER}/include
+ SRC=${D}${libdir}/${TARGET_SYS}/${BINV}
+ DEST=${D}${libdir}/${TARGET_SYS}/${BINVER}
+ install -d ${SRC} ${DEST}
+ for f in ${SRC}/*
+ do
+ cp ${f} ${DEST}
+ done
+ fi
+}
+
+python do_package_prepend () {
+ import subprocess
+ subfolder = "*crt* 64 32 x32 n32 libgcc*"
+ cc = d.getVar('TARGET_PREFIX', True) + 'gcc'
+ cmd = subprocess.Popen([cc, "-dumpversion"], stdout=subprocess.PIPE)
+ out, err = cmd.communicate()
+ version = out.split()[-1]
+ binv = d.getVar('BINV', True)
+ if (version != binv):
+ pn = d.getVar('PN', True)
+ libdir = d.getVar('libdir', True)
+ targetsys = d.getVar('TARGET_SYS', True)
+ appendprefix = ' ' + libdir + '/' + targetsys + '/' + version + '/'
+ appends = ''
+ for i in subfolder.split():
+ appends = appends + appendprefix + i
+ d.appendVar("FILES_" + pn + "-dev", appends)
+ if bb.data.inherits_class('nativesdk', d):
+ packages_libgcov = 'FILES_nativesdk-libgcov-dev'
+ else:
+ packages_libgcov = 'FILES_libgcov-dev'
+ d.appendVar(packages_libgcov, appendprefix + "libgcov.a")
+}
+