diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-07-31 11:24:37 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-08-01 07:34:06 +0100 |
commit | f494fc25ea884dd262d83739e05f0e5d440cdcad (patch) | |
tree | 0abca691945818f16a6e98c93b92d7475e2561c4 /meta/recipes-devtools/gcc/gcc-multilib-config.inc | |
parent | c125ef12ae6c2ffdd11ce271e11d2a9a8cfcace4 (diff) | |
download | poky-f494fc25ea884dd262d83739e05f0e5d440cdcad.tar.gz |
gcc-multilib-config: Adapt mips for mips64 and different gcc versions
The location of some files for mips varies between gcc 4.9 and 5.2. Ensure
that we cover both cases (and allow specified files to be optional).
(From OE-Core rev: 5c33b0a752e6168200776da61dee7d4d807ddbb0)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/gcc/gcc-multilib-config.inc')
-rw-r--r-- | meta/recipes-devtools/gcc/gcc-multilib-config.inc | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/meta/recipes-devtools/gcc/gcc-multilib-config.inc b/meta/recipes-devtools/gcc/gcc-multilib-config.inc index cfad50fe1f..f7f9f557db 100644 --- a/meta/recipes-devtools/gcc/gcc-multilib-config.inc +++ b/meta/recipes-devtools/gcc/gcc-multilib-config.inc | |||
@@ -29,6 +29,7 @@ python gcc_multilib_setup() { | |||
29 | bb.utils.remove(build_conf_dir, True) | 29 | bb.utils.remove(build_conf_dir, True) |
30 | ml_globs = ('%s/*/t-linux64' % src_conf_dir, | 30 | ml_globs = ('%s/*/t-linux64' % src_conf_dir, |
31 | '%s/*/linux64.h' % src_conf_dir, | 31 | '%s/*/linux64.h' % src_conf_dir, |
32 | '%s/*/linux.h' % src_conf_dir, | ||
32 | '%s/linux.h' % src_conf_dir) | 33 | '%s/linux.h' % src_conf_dir) |
33 | 34 | ||
34 | # copy the target multilib config files to ${B} | 35 | # copy the target multilib config files to ${B} |
@@ -80,7 +81,10 @@ python gcc_multilib_setup() { | |||
80 | return '"/%s/"' % libdir | 81 | return '"/%s/"' % libdir |
81 | 82 | ||
82 | for ml_conf_file in files: | 83 | for ml_conf_file in files: |
83 | with open(root + '/' + ml_conf_file, 'r') as f: | 84 | fn = root + '/' + ml_conf_file |
85 | if not os.path.exists(fn): | ||
86 | continue | ||
87 | with open(fn, 'r') as f: | ||
84 | filelines = f.readlines() | 88 | filelines = f.readlines() |
85 | 89 | ||
86 | # replace lines like | 90 | # replace lines like |
@@ -132,8 +136,8 @@ python gcc_multilib_setup() { | |||
132 | 'x86_64' : ['gcc/config/i386/linux64.h'], | 136 | 'x86_64' : ['gcc/config/i386/linux64.h'], |
133 | 'i586' : ['gcc/config/i386/linux64.h'], | 137 | 'i586' : ['gcc/config/i386/linux64.h'], |
134 | 'i686' : ['gcc/config/i386/linux64.h'], | 138 | 'i686' : ['gcc/config/i386/linux64.h'], |
135 | 'mips' : ['gcc/config/mips/linux64.h'], | 139 | 'mips' : ['gcc/config/mips/linux.h', 'gcc/config/mips/linux64.h'], |
136 | 'mips64' : ['gcc/config/mips/linux64.h'], | 140 | 'mips64' : ['gcc/config/mips/linux.h', 'gcc/config/mips/linux64.h'], |
137 | 'powerpc' : ['gcc/config/rs6000/linux64.h'], | 141 | 'powerpc' : ['gcc/config/rs6000/linux64.h'], |
138 | 'powerpc64' : ['gcc/config/rs6000/linux64.h'], | 142 | 'powerpc64' : ['gcc/config/rs6000/linux64.h'], |
139 | } | 143 | } |