diff options
author | Patrick Williams <patrick@stwcx.xyz> | 2015-09-15 22:41:29 +0300 |
---|---|---|
committer | Patrick Williams <patrick@stwcx.xyz> | 2015-09-15 22:41:29 +0300 |
commit | 21f9b84b4b729fbd7acbd465e7a3f726e4d20f91 (patch) | |
tree | eb2d091d427ca0813b445509d59cc8e27e8ad25f /yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0061-target-gcc-includedir.patch | |
parent | 101cef31e2bf54c678501155cd2106251acbd076 (diff) | |
parent | c124f4f2e04dca16a428a76c89677328bc7bf908 (diff) | |
download | openbmc-21f9b84b4b729fbd7acbd465e7a3f726e4d20f91.tar.xz |
Merge commit 'c124f4f2e04dca16a428a76c89677328bc7bf908' as 'yocto-poky'
Diffstat (limited to 'yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0061-target-gcc-includedir.patch')
-rw-r--r-- | yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0061-target-gcc-includedir.patch | 81 |
1 files changed, 81 insertions, 0 deletions
diff --git a/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0061-target-gcc-includedir.patch b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0061-target-gcc-includedir.patch new file mode 100644 index 000000000..f48c66dca --- /dev/null +++ b/yocto-poky/meta/recipes-devtools/gcc/gcc-4.9/0061-target-gcc-includedir.patch @@ -0,0 +1,81 @@ +Ensure target gcc headers can be included + +There are a few headers installed as part of the OpenEmbedded +gcc-runtime target (omp.h, ssp/*.h). Being installed from a recipe +built for the target architecture, these are within the target +sysroot and not cross/nativesdk; thus they weren't able to be +found by gcc with the existing search paths. Add support for +picking up these headers under the sysroot supplied on the gcc +command line in order to resolve this. + +Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> + +Upstream-Status: Pending + +--- a/gcc/Makefile.in 2014-12-23 11:57:33.327873331 +0000 ++++ b/gcc/Makefile.in 2015-01-21 11:32:35.447305394 +0000 +@@ -587,6 +587,7 @@ + + # Directory in which the compiler finds libraries etc. + libsubdir = $(libdir)/gcc/$(target_noncanonical)/$(version) ++libsubdir_target = gcc/$(target_noncanonical)/$(version) + # Directory in which the compiler finds executables + libexecsubdir = $(libexecdir)/gcc/$(target_noncanonical)/$(version) + # Directory in which all plugin resources are installed +@@ -2534,6 +2535,7 @@ + + PREPROCESSOR_DEFINES = \ + -DGCC_INCLUDE_DIR=\"$(libsubdir)/include\" \ ++ -DGCC_INCLUDE_SUBDIR_TARGET=\"$(libsubdir_target)/include\" \ + -DFIXED_INCLUDE_DIR=\"$(libsubdir)/include-fixed\" \ + -DGPLUSPLUS_INCLUDE_DIR=\"$(gcc_gxx_include_dir)\" \ + -DGPLUSPLUS_INCLUDE_DIR_ADD_SYSROOT=$(gcc_gxx_include_dir_add_sysroot) \ +--- a/gcc/cppdefault.c 2015-01-13 17:40:26.131012725 +0000 ++++ b/gcc/cppdefault.c 2015-01-21 11:30:08.928426492 +0000 +@@ -59,6 +59,10 @@ + /* This is the dir for gcc's private headers. */ + { GCC_INCLUDE_DIR, "GCC", 0, 0, 0, 0 }, + #endif ++#ifdef GCC_INCLUDE_SUBDIR_TARGET ++ /* This is the dir for gcc's private headers under the specified sysroot. */ ++ { STANDARD_STARTFILE_PREFIX_2 GCC_INCLUDE_SUBDIR_TARGET, "GCC", 0, 0, 1, 0 }, ++#endif + #ifdef LOCAL_INCLUDE_DIR + /* /usr/local/include comes before the fixincluded header files. */ + { LOCAL_INCLUDE_DIR, 0, 0, 1, 1, 2 }, +diff --git a/gcc/defaults.h b/gcc/defaults.h +index f94ae17..d98b40b 100644 +--- a/gcc/defaults.h ++++ b/gcc/defaults.h +@@ -1390,4 +1390,13 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see + + #endif /* GCC_INSN_FLAGS_H */ + ++/* Default prefixes to attach to command names. */ ++ ++#ifndef STANDARD_STARTFILE_PREFIX_1 ++#define STANDARD_STARTFILE_PREFIX_1 "/lib/" ++#endif ++#ifndef STANDARD_STARTFILE_PREFIX_2 ++#define STANDARD_STARTFILE_PREFIX_2 "/usr/lib/" ++#endif ++ + #endif /* ! GCC_DEFAULTS_H */ +diff --git a/gcc/gcc.c b/gcc/gcc.c +index 9f0b781..174fca8 100644 +--- a/gcc/gcc.c ++++ b/gcc/gcc.c +@@ -1189,13 +1189,6 @@ static const char *gcc_libexec_prefix; + + /* Default prefixes to attach to command names. */ + +-#ifndef STANDARD_STARTFILE_PREFIX_1 +-#define STANDARD_STARTFILE_PREFIX_1 "/lib/" +-#endif +-#ifndef STANDARD_STARTFILE_PREFIX_2 +-#define STANDARD_STARTFILE_PREFIX_2 "/usr/lib/" +-#endif +- + #ifdef CROSS_DIRECTORY_STRUCTURE /* Don't use these prefixes for a cross compiler. */ + #undef MD_EXEC_PREFIX + #undef MD_STARTFILE_PREFIX |