summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobert Yang <liezhi.yang@windriver.com>2011-06-28 14:31:53 -0600
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-06-30 20:56:34 +0100
commit64be70130548e26f793d24234cdc379fd8b1f0e9 (patch)
treeb44a0de7aa93ce45a4ac7b6e59b36b16461e4968
parente4f43aa5df696b3773e4ebc54dbb1ef7925e82ee (diff)
downloadpoky-64be70130548e26f793d24234cdc379fd8b1f0e9.tar.gz
gcc-4.6: share work directories
* Fix configure and Makefile to read the defaults.h and t-oe from ${B}, so that the ${S} can be shared. * Change ${S} to the shared source directory. (From OE-Core rev: c1ec5100da76d35afb91de7353599564e5b653dc) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-devtools/gcc/gcc-4.6.inc5
-rw-r--r--meta/recipes-devtools/gcc/gcc-4.6/use-defaults.h-and-t-oe-in-B.patch80
2 files changed, 84 insertions, 1 deletions
diff --git a/meta/recipes-devtools/gcc/gcc-4.6.inc b/meta/recipes-devtools/gcc/gcc-4.6.inc
index 577e7f7e47..a0120492ae 100644
--- a/meta/recipes-devtools/gcc/gcc-4.6.inc
+++ b/meta/recipes-devtools/gcc/gcc-4.6.inc
@@ -66,11 +66,14 @@ SRC_URI = "svn://gcc.gnu.org/svn/gcc/branches;module=${BRANCH};proto=http \
66 file://GPLUSPLUS_INCLUDE_DIR_with_sysroot.patch \ 66 file://GPLUSPLUS_INCLUDE_DIR_with_sysroot.patch \
67 file://COLLECT_GCC_OPTIONS.patch \ 67 file://COLLECT_GCC_OPTIONS.patch \
68 file://volatile_access_backport.patch \ 68 file://volatile_access_backport.patch \
69 file://use-defaults.h-and-t-oe-in-B.patch \
69 " 70 "
70 71
71SRC_URI_append_sh3 = " file://sh3-installfix-fixheaders.patch;patch=1 " 72SRC_URI_append_sh3 = " file://sh3-installfix-fixheaders.patch;patch=1 "
72 73
73S = "${WORKDIR}/${BRANCH}" 74#S = "${WORKDIR}/${BRANCH}"
75S = "${TMPDIR}/work-shared/gcc-${PV}/${BRANCH}"
76B = "${WORKDIR}/${BRANCH}/build.${HOST_SYS}.${TARGET_SYS}"
74 77
75# Language Overrides 78# Language Overrides
76FORTRAN = "" 79FORTRAN = ""
diff --git a/meta/recipes-devtools/gcc/gcc-4.6/use-defaults.h-and-t-oe-in-B.patch b/meta/recipes-devtools/gcc/gcc-4.6/use-defaults.h-and-t-oe-in-B.patch
new file mode 100644
index 0000000000..b4351ee7ef
--- /dev/null
+++ b/meta/recipes-devtools/gcc/gcc-4.6/use-defaults.h-and-t-oe-in-B.patch
@@ -0,0 +1,80 @@
1Upstream-Status: Pending
2
3Use the defaults.h in ${B} instead of ${S}, and t-oe in ${B}, so that
4the source can be shared between gcc-cross-initial,
5gcc-cross-intermediate, gcc-cross, gcc-runtime, and also the sdk build.
6---
7 gcc/Makefile.in | 2 +-
8 gcc/configure | 4 ++--
9 gcc/configure.ac | 4 ++--
10 gcc/mkconfig.sh | 4 ++--
11 4 files changed, 7 insertions(+), 7 deletions(-)
12
13diff --git a/gcc/Makefile.in b/gcc/Makefile.in
14index 7790915..3a0c34a 100644
15--- a/gcc/Makefile.in
16+++ b/gcc/Makefile.in
17@@ -463,7 +463,7 @@ LIMITS_H_TEST = [ -f $(SYSTEM_HEADER_DIR)/limits.h ]
18 TARGET_SYSTEM_ROOT = @TARGET_SYSTEM_ROOT@
19
20 xmake_file=@xmake_file@
21-tmake_file=@tmake_file@
22+tmake_file=@tmake_file@ ./t-oe
23 TM_ENDIAN_CONFIG=@TM_ENDIAN_CONFIG@
24 TM_MULTILIB_CONFIG=@TM_MULTILIB_CONFIG@
25 TM_MULTILIB_EXCEPTIONS_CONFIG=@TM_MULTILIB_EXCEPTIONS_CONFIG@
26diff --git a/gcc/configure b/gcc/configure
27index 82fa3e4..d4711b5 100755
28--- a/gcc/configure
29+++ b/gcc/configure
30@@ -11227,8 +11227,8 @@ for f in $tm_file; do
31 tm_include_list="${tm_include_list} $f"
32 ;;
33 defaults.h )
34- tm_file_list="${tm_file_list} \$(srcdir)/$f"
35- tm_include_list="${tm_include_list} $f"
36+ tm_file_list="${tm_file_list} ./$f"
37+ tm_include_list="${tm_include_list} ./$f"
38 ;;
39 * )
40 tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
41diff --git a/gcc/configure.ac b/gcc/configure.ac
42index 844d8da..a960343 100644
43--- a/gcc/configure.ac
44+++ b/gcc/configure.ac
45@@ -1628,8 +1628,8 @@ for f in $tm_file; do
46 tm_include_list="${tm_include_list} $f"
47 ;;
48 defaults.h )
49- tm_file_list="${tm_file_list} \$(srcdir)/$f"
50- tm_include_list="${tm_include_list} $f"
51+ tm_file_list="${tm_file_list} ./$f"
52+ tm_include_list="${tm_include_list} ./$f"
53 ;;
54 * )
55 tm_file_list="${tm_file_list} \$(srcdir)/config/$f"
56diff --git a/gcc/mkconfig.sh b/gcc/mkconfig.sh
57index d56df8c..875d0f1 100644
58--- a/gcc/mkconfig.sh
59+++ b/gcc/mkconfig.sh
60@@ -77,7 +77,7 @@ if [ -n "$HEADERS" ]; then
61 if [ $# -ge 1 ]; then
62 echo '#ifdef IN_GCC' >> ${output}T
63 for file in "$@"; do
64- if test x"$file" = x"defaults.h"; then
65+ if test x"$file" = x"./defaults.h"; then
66 postpone_defaults_h="yes"
67 else
68 echo "# include \"$file\"" >> ${output}T
69@@ -103,7 +103,7 @@ esac
70
71 # If we postponed including defaults.h, add the #include now.
72 if test x"$postpone_defaults_h" = x"yes"; then
73- echo "# include \"defaults.h\"" >> ${output}T
74+ echo "# include \"./defaults.h\"" >> ${output}T
75 fi
76
77 # Add multiple inclusion protection guard, part two.
78--
791.7.1
80