]> code.ossystems Code Review - openembedded-core.git/commitdiff
mklibs-native 0.1.33: include unistd.h to fix build for gcc 4.7
authorRobert Yang <liezhi.yang@windriver.com>
Thu, 12 Apr 2012 14:49:02 +0000 (07:49 -0700)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 13 Apr 2012 11:05:46 +0000 (12:05 +0100)
Many of the standard C++ library include files have been edited to no
longer include <unistd.h> to remove namespace pollution in gcc 4.7, so
we need include <unistd.h> manually sometimes.

More information:
http://gcc.gnu.org/gcc-4.7/porting_to.html

[YOCTO #2278]

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
[Updated patch header - sgw]

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-devtools/mklibs/files/include-unistd.h-for-gcc47.patch [new file with mode: 0644]
meta/recipes-devtools/mklibs/mklibs-native_0.1.33.bb

diff --git a/meta/recipes-devtools/mklibs/files/include-unistd.h-for-gcc47.patch b/meta/recipes-devtools/mklibs/files/include-unistd.h-for-gcc47.patch
new file mode 100644 (file)
index 0000000..baa12bd
--- /dev/null
@@ -0,0 +1,43 @@
+include <unistd.h> to fix build on gcc 4.7
+
+Many of the standard C++ library include files have been edited to no
+longer include <unistd.h> to remove namespace pollution in gcc 4.7, so
+we need include <unistd.h> manually sometimes.
+
+mklibs (0.1.33+nmu1) UNRELEASED; urgency=low
+ * Non-maintainer upload
+ * Fix FTBFS with gcc 4.7 due to missing <unistd.h> include (Closes: #667282).
+
+-- Cyril Brulebois <kibi@debian.org>  Thu, 05 Apr 2012 00:15:27 +0000
+
+mklibs (0.1.33) unstable; urgency=low
+  * Adjust the libc_pic directory for multiarch as well.
+
+Upstream-Status: Backport 
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+
+[Added upstream information about patch]
+
+Signed-off-by: Saul Wold <sgw@linux.intel.com>
+
+---
+ src/mklibs-readelf/elf.cpp |    1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/mklibs-readelf/elf.cpp b/src/mklibs-readelf/elf.cpp
+index 444f330..654c46f 100644
+--- a/src/mklibs-readelf/elf.cpp
++++ b/src/mklibs-readelf/elf.cpp
+@@ -25,6 +25,7 @@
+ #include <fcntl.h>
+ #include <sys/mman.h>
+ #include <sys/stat.h>
++#include <unistd.h>
+ using namespace Elf;
+-- 
+1.7.10
+
index d288c77afbbdc3030afd4ab00fcf2d2145427097..a8d12ec17d5841a40151f948b3ec37a3958ce842 100644 (file)
@@ -5,11 +5,12 @@ LICENSE = "GPLv2+"
 LIC_FILES_CHKSUM = "file://debian/copyright;md5=98d31037b13d896e33890738ef01af64"
 DEPENDS = "python-native"
 
-PR = "r0"
+PR = "r1"
 
 SRC_URI = "http://ftp.de.debian.org/debian/pool/main/m/mklibs/${BPN}_${PV}.tar.gz \
        file://ac_init_fix.patch\
        file://fix_STT_GNU_IFUNC.patch\
+       file://include-unistd.h-for-gcc47.patch \
 "
 
 SRC_URI[md5sum] = "a462d9b802164993d247c1193116d78b"