summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2013-09-22 10:48:28 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-09-22 12:19:43 +0100
commit87e86d4fd3a22627bf5a7eff20d8551cb1e67452 (patch)
treeb3196af46823c42605b946e177e7a4f86fd8b729 /meta
parentc2d5fa92898942d5cd1ccf9622a522243a5ca006 (diff)
downloadpoky-87e86d4fd3a22627bf5a7eff20d8551cb1e67452.tar.gz
gcc-target: Fix libatomic dependency tracking issues
The --enable-dependency-tracking option was added to workaround build issues in libatomic. This fixes that build problem properly and removes the flag since the dependency tracking code appears to be full of races which are much deeper and harder to fix. As per the automake manual, dependency tracking is only useful and worth the build performance cost if you are doing more than one compile of the same source code which in most cases we are not so this is a good thing anyway. (From OE-Core rev: a3b665a80abed4c0659925e1cceb1568af023711) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/recipes-devtools/gcc/gcc-4.8.inc1
-rw-r--r--meta/recipes-devtools/gcc/gcc-4.8/0046-libatomic-deptracking.patch41
-rw-r--r--meta/recipes-devtools/gcc/gcc-target.inc2
3 files changed, 43 insertions, 1 deletions
diff --git a/meta/recipes-devtools/gcc/gcc-4.8.inc b/meta/recipes-devtools/gcc/gcc-4.8.inc
index 0fbbc1d9bc..4af98f8fee 100644
--- a/meta/recipes-devtools/gcc/gcc-4.8.inc
+++ b/meta/recipes-devtools/gcc/gcc-4.8.inc
@@ -75,6 +75,7 @@ SRC_URI = "${GNU_MIRROR}/gcc/gcc-${PV}/gcc-${PV}.tar.bz2 \
75 file://0043-cpp.patch \ 75 file://0043-cpp.patch \
76 file://0044-gengtypes.patch \ 76 file://0044-gengtypes.patch \
77 file://0045-gcc-4.8-PR57717-PowerPC-E500v2.patch \ 77 file://0045-gcc-4.8-PR57717-PowerPC-E500v2.patch \
78 file://0046-libatomic-deptracking.patch \
78 " 79 "
79SRC_URI[md5sum] = "3b2386c114cd74185aa3754b58a79304" 80SRC_URI[md5sum] = "3b2386c114cd74185aa3754b58a79304"
80SRC_URI[sha256sum] = "545b44be3ad9f2c4e90e6880f5c9d4f0a8f0e5f67e1ffb0d45da9fa01bb05813" 81SRC_URI[sha256sum] = "545b44be3ad9f2c4e90e6880f5c9d4f0a8f0e5f67e1ffb0d45da9fa01bb05813"
diff --git a/meta/recipes-devtools/gcc/gcc-4.8/0046-libatomic-deptracking.patch b/meta/recipes-devtools/gcc/gcc-4.8/0046-libatomic-deptracking.patch
new file mode 100644
index 0000000000..6ea4f42765
--- /dev/null
+++ b/meta/recipes-devtools/gcc/gcc-4.8/0046-libatomic-deptracking.patch
@@ -0,0 +1,41 @@
1gcc 4.8 won't build with --disable-dependency-tracking since the *.Ppo files
2don't get created unless --enable-dependency-tracking is true.
3
4This patch ensures we only use those compiler options when its enabled.
5
6Upstream-Status: Submitted
7
8(Problem was already reported upstream, attached this patch there
9http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55930)
10
11RP
122012/09/22
13
14Index: gcc-4.8.1/libatomic/Makefile.am
15===================================================================
16--- gcc-4.8.1.orig/libatomic/Makefile.am 2013-01-14 18:16:23.000000000 +0000
17+++ gcc-4.8.1/libatomic/Makefile.am 2013-09-22 10:38:18.904064750 +0000
18@@ -100,7 +100,8 @@
19 IFUNC_DEF = -DIFUNC_ALT=$(PAT_S)
20 IFUNC_OPT = $(word $(PAT_S),$(IFUNC_OPTIONS))
21
22-M_DEPS = -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
23+@AMDEP_TRUE@M_DEPS = -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
24+@AMDEP_FALSE@M_DEPS =
25 M_SIZE = -DN=$(PAT_N)
26 M_IFUNC = $(if $(PAT_S),$(IFUNC_DEF) $(IFUNC_OPT))
27 M_FILE = $(PAT_BASE)_n.c
28Index: gcc-4.8.1/libatomic/Makefile.in
29===================================================================
30--- gcc-4.8.1.orig/libatomic/Makefile.in 2013-05-31 09:09:26.000000000 +0000
31+++ gcc-4.8.1/libatomic/Makefile.in 2013-09-22 10:40:42.520059917 +0000
32@@ -298,7 +298,8 @@
33 PAT_S = $(word 3,$(PAT_SPLIT))
34 IFUNC_DEF = -DIFUNC_ALT=$(PAT_S)
35 IFUNC_OPT = $(word $(PAT_S),$(IFUNC_OPTIONS))
36-M_DEPS = -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
37+@AMDEP_TRUE@M_DEPS = -MT $@ -MD -MP -MF $(DEPDIR)/$(@F).Ppo
38+@AMDEP_FALSE@M_DEPS =
39 M_SIZE = -DN=$(PAT_N)
40 M_IFUNC = $(if $(PAT_S),$(IFUNC_DEF) $(IFUNC_OPT))
41 M_FILE = $(PAT_BASE)_n.c
diff --git a/meta/recipes-devtools/gcc/gcc-target.inc b/meta/recipes-devtools/gcc/gcc-target.inc
index c7e3e164d8..e1179ac292 100644
--- a/meta/recipes-devtools/gcc/gcc-target.inc
+++ b/meta/recipes-devtools/gcc/gcc-target.inc
@@ -5,7 +5,7 @@ EXTRA_OECONF_PATHS = " \
5 --with-sysroot=/ \ 5 --with-sysroot=/ \
6 --with-build-sysroot=${STAGING_DIR_TARGET} \ 6 --with-build-sysroot=${STAGING_DIR_TARGET} \
7 --with-native-system-header-dir=${STAGING_DIR_TARGET}${target_includedir} \ 7 --with-native-system-header-dir=${STAGING_DIR_TARGET}${target_includedir} \
8 --with-gxx-include-dir=${includedir}/c++/ --enable-dependency-tracking" 8 --with-gxx-include-dir=${includedir}/c++/"
9 9
10ARCH_FLAGS_FOR_TARGET += "-isystem${STAGING_INCDIR} -I${B}/gcc/include/ " 10ARCH_FLAGS_FOR_TARGET += "-isystem${STAGING_INCDIR} -I${B}/gcc/include/ "
11 11