gcc-configure-sdk: Handle hardcoded /usr/include
authorKhem Raj <raj.khem@gmail.com>
Thu, 25 Nov 2010 22:47:58 +0000 (14:47 -0800)
committerKhem Raj <raj.khem@gmail.com>
Thu, 25 Nov 2010 22:47:58 +0000 (14:47 -0800)
This does not work for distros like micro who use
a flattened tree structure for root file system

Signed-off-by: Khem Raj <raj.khem@gmail.com>
15 files changed:
recipes/gcc/gcc-configure-sdk.inc
recipes/gcc/gcc-cross-sdk_4.1.0.bb
recipes/gcc/gcc-cross-sdk_4.1.1.bb
recipes/gcc/gcc-cross-sdk_4.1.2.bb
recipes/gcc/gcc-cross-sdk_4.2.2.bb
recipes/gcc/gcc-cross-sdk_4.2.3.bb
recipes/gcc/gcc-cross-sdk_4.2.4.bb
recipes/gcc/gcc-cross-sdk_4.3.1.bb
recipes/gcc/gcc-cross-sdk_4.3.2.bb
recipes/gcc/gcc-cross-sdk_4.3.3.bb
recipes/gcc/gcc-cross-sdk_4.3.4.bb
recipes/gcc/gcc-cross-sdk_4.4.1.bb
recipes/gcc/gcc-cross-sdk_4.4.2.bb
recipes/gcc/gcc-cross-sdk_4.4.4.bb
recipes/gcc/gcc-cross-sdk_4.5.bb

index c8fae11..7210d2b 100644 (file)
@@ -44,6 +44,14 @@ do_configure () {
         sed -i 's/^\(HOST_LIBELFLIBS =\) \(.*\)$/\1 -Wl,-Bstatic \2 -Wl,-Bdynamic/' ${S}/Makefile.in
 
        (cd ${S} && gnu-configize) || die "failure running gnu-configize"
+       # gcc assumes ${sysroot}/usr to be prefix on linux targets
+       # but we have distro option to flatten out the tree and micro
+       # uses root file system without leading /usr so we need to
+       # teach gcc configure to look in correct include paths
+       # unfortunately there is no configure knob to indicate this
+       # to configury hence the sed :(
+       sed -i 's:/usr/include:${target_includedir}:g' ${S}/gcc/configure.ac
+       sed -i 's:/usr/include:${target_includedir}:g' ${S}/gcc/configure
        oe_runconf
 }
 
index 9aa6a56..24c76b5 100644 (file)
@@ -1,5 +1,5 @@
 
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
 
 require gcc-${PV}.inc
 require gcc-cross-sdk.inc
index 26eb80b..7ea943e 100644 (file)
@@ -1,4 +1,4 @@
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
 
 require gcc-${PV}.inc
 require gcc-cross-sdk.inc
index 2475f3e..b1525b3 100644 (file)
@@ -1,4 +1,4 @@
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
 
 require gcc-${PV}.inc
 require gcc-cross-sdk.inc
index eb30315..4ec237b 100644 (file)
@@ -1,4 +1,4 @@
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
 
 inherit sdk
 
index fbbfbce..62de382 100644 (file)
@@ -1,4 +1,4 @@
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
 
 inherit sdk
 
index 28cdbb7..86ffc25 100644 (file)
@@ -1,4 +1,4 @@
-PR = "${INC_PR}.2"
+PR = "${INC_PR}.3"
 
 inherit sdk
 
index fbbfbce..62de382 100644 (file)
@@ -1,4 +1,4 @@
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
 
 inherit sdk
 
index fbbfbce..62de382 100644 (file)
@@ -1,4 +1,4 @@
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
 
 inherit sdk
 
index 62de382..82bd95e 100644 (file)
@@ -1,4 +1,4 @@
-PR = "${INC_PR}.2"
+PR = "${INC_PR}.3"
 
 inherit sdk
 
index 1a2ed67..fbbfbce 100644 (file)
@@ -1,4 +1,4 @@
-PR = "${INC_PR}.0"
+PR = "${INC_PR}.1"
 
 inherit sdk
 
index 77ccf72..9f8c75d 100644 (file)
@@ -2,7 +2,7 @@ inherit sdk
 
 require gcc-${PV}.inc
 require gcc-cross-sdk.inc
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
 
 EXTRA_OECONF += "--disable-libunwind-exceptions --disable-libssp \
                --disable-libgomp --disable-libmudflap \
index 77ccf72..9f8c75d 100644 (file)
@@ -2,7 +2,7 @@ inherit sdk
 
 require gcc-${PV}.inc
 require gcc-cross-sdk.inc
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
 
 EXTRA_OECONF += "--disable-libunwind-exceptions --disable-libssp \
                --disable-libgomp --disable-libmudflap \
index 44abbcf..439ae36 100644 (file)
@@ -2,7 +2,7 @@ inherit sdk
 
 require gcc-${PV}.inc
 require gcc-cross-sdk.inc
-PR = "${INC_PR}.1"
+PR = "${INC_PR}.2"
 
 EXTRA_OECONF += "--disable-libunwind-exceptions --disable-libssp \
                --disable-libgomp --disable-libmudflap \
index f96607e..d1e13d4 100644 (file)
@@ -2,7 +2,7 @@ inherit sdk
 
 require gcc-${PV}.inc
 require gcc-cross-sdk.inc
-PR = "${INC_PR}.0"
+PR = "${INC_PR}.1"
 
 EXTRA_OECONF += " --disable-libunwind-exceptions --with-mpfr=${STAGING_DIR_NATIVE}${prefix_native} --with-system-zlib"