From 45987c5135d22757ed2eb06b37e192d73309f59f Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Fri, 16 Dec 2011 14:33:38 -0800 Subject: eglibc: Fixes for running regression tests Override cxx-sysincludes along with CC and CXX since it contains path pointing to tcbootstrap sysroot which does not have c++ headers and libraries Drop shorten-build-commands patch since it did not override the include flags for c++ headers when tests written in c++ are executed the @includes file does not get updated to add c++ header paths This patch only reduced the build output anyway Add a patch to point eglibc to look into c++ headers the way OE installs them its not standard install e.g. usr/include/c++/GCC_VER but instead usr/include/c++. This lets g++ find the headers in right place when compiling c++ testcases (From OE-Core rev: dc1fbfb2cd3c0d35f212523189ea7b1621906201) Signed-off-by: Khem Raj Signed-off-by: Richard Purdie --- .../eglibc-2.13/shorten-build-commands.patch | 82 ---------------------- .../eglibc-2.13/use-sysroot-cxx-headers.patch | 36 ++++++++++ 2 files changed, 36 insertions(+), 82 deletions(-) delete mode 100644 meta/recipes-core/eglibc/eglibc-2.13/shorten-build-commands.patch create mode 100644 meta/recipes-core/eglibc/eglibc-2.13/use-sysroot-cxx-headers.patch (limited to 'meta/recipes-core/eglibc/eglibc-2.13') diff --git a/meta/recipes-core/eglibc/eglibc-2.13/shorten-build-commands.patch b/meta/recipes-core/eglibc/eglibc-2.13/shorten-build-commands.patch deleted file mode 100644 index 080568d9c2..0000000000 --- a/meta/recipes-core/eglibc/eglibc-2.13/shorten-build-commands.patch +++ /dev/null @@ -1,82 +0,0 @@ - -Source: http://sourceware.org/ml/libc-alpha/2010-03/msg00064.html - -This patch scratches an itch. Each individual gcc command in the -glibc build is over 1K, which means it takes up a good chunk of my -terminal. Most of that is include paths. Any version of GCC new -enough to build glibc supports response files, which were added in -2005. So use a response file for the static list of include paths. -Now the build commands are a lot shorter, and easier to use when -developing glibc. - -Tested on x86_64-linux-gnu. Please apply if acceptable. - --- -Daniel Jacobowitz -CodeSourcery - -2010-03-30 Daniel Jacobowitz - - * Makeconfig (+common-includes): Define. - (+includes): Use @$(common-objpfx)includes. - * Makefile (postclean): Remove includes and includes.mk. - * Makerules ($(common-objpfx)includes.mk): Include and create - includes.mk. Create includes. - -Upstream-Status: Pending - -Index: libc/Makeconfig -=================================================================== ---- libc.orig/Makeconfig 2009-10-13 22:55:12.000000000 -0700 -+++ libc/Makeconfig 2010-03-31 16:02:37.120489733 -0700 -@@ -678,9 +678,10 @@ endif # $(+cflags) == "" - # library source directory, in the include directory, and in the - # current directory. - +sysdep-includes = $(addprefix -I,$(+sysdep_dirs)) -++common-includes = $(+sysdep-includes) $(includes) $(sysincludes) - +includes = -I$(..)include $(if $(subdir),$(objpfx:%/=-I%)) \ -- $(+sysdep-includes) $(includes) \ -- $(patsubst %/,-I%,$(..)) $(libio-include) -I. $(sysincludes) -+ @$(common-objpfx)includes \ -+ $(patsubst %/,-I%,$(..)) $(libio-include) -I. - - # Since libio has several internal header files, we use a -I instead - # of many little headers in the include directory. -Index: libc/Makefile -=================================================================== ---- libc.orig/Makefile 2009-12-09 12:06:28.000000000 -0800 -+++ libc/Makefile 2010-03-31 16:02:37.132481508 -0700 -@@ -247,7 +247,7 @@ parent-mostlyclean: common-mostlyclean # - parent-clean: parent-mostlyclean common-clean - - postclean = $(addprefix $(common-objpfx),$(postclean-generated)) \ -- $(addprefix $(objpfx),sysd-dirs sysd-rules) \ -+ $(addprefix $(objpfx),sysd-dirs sysd-rules includes includes.mk) \ - $(addprefix $(objpfx),sysd-sorted soversions.mk soversions.i) - - clean: parent-clean -Index: libc/Makerules -=================================================================== ---- libc.orig/Makerules 2009-12-09 12:06:28.000000000 -0800 -+++ libc/Makerules 2010-03-31 16:02:37.140481645 -0700 -@@ -254,6 +254,20 @@ ifndef sysd-rules-done - no_deps=t - endif - -+-include $(common-objpfx)includes.mk -+ifneq ($(+common-includes),$(saved-includes)) -+# Recreate includes.mk (and includes). -+includes-force = FORCE -+FORCE: -+endif -+$(common-objpfx)includes.mk: $(includes-force) -+ -@rm -f $@T $(common-objpfx)includesT -+ for inc in $(+common-includes); do echo "$$inc"; done \ -+ > $(common-objpfx)includesT -+ mv -f $(common-objpfx)includesT $(common-objpfx)includes -+ echo 'saved-includes := $(+common-includes)' > $@T -+ mv -f $@T $@ -+ - define o-iterator-doit - $(objpfx)%$o: %.S $(before-compile); $$(compile-command.S) - endef diff --git a/meta/recipes-core/eglibc/eglibc-2.13/use-sysroot-cxx-headers.patch b/meta/recipes-core/eglibc/eglibc-2.13/use-sysroot-cxx-headers.patch new file mode 100644 index 0000000000..c06eebfac4 --- /dev/null +++ b/meta/recipes-core/eglibc/eglibc-2.13/use-sysroot-cxx-headers.patch @@ -0,0 +1,36 @@ +build system of glibc currently adds the cxx headers path by detecting +it using provided CXX and expects that they are installed w.r.t to standard +installation location but in OE we install and use cxx headers from target +sysroot therefore that code needs to be adapted for OE + +Upstream-Status: Inappropriate [OE-specific] + +-Khem + + +--- a/configure.in ++++ b/configure.in +@@ -1118,9 +1118,8 @@ if test -n "$sysheaders"; then + SYSINCLUDES="$SYSINCLUDES \ + -isystem `echo $sysheaders | sed 's/:/ -isystem /g'`" + if test -n "$CXX"; then +- cxxversion=`$CXX -dumpversion 2>&AS_MESSAGE_LOG_FD` && + cxxmachine=`$CXX -dumpmachine 2>&AS_MESSAGE_LOG_FD` && +- cxxheaders=`$CXX -print-file-name=../../../../include/c++/`"$cxxversion" && ++ cxxheaders=`$CXX -print-sysroot`"$prefix/include/c++" && + CXX_SYSINCLUDES="-isystem $cxxheaders \ + -isystem $cxxheaders/$cxxmachine -isystem $cxxheaders/backward" + fi +--- a/configure ++++ b/configure +@@ -5544,9 +5544,8 @@ if test -n "$sysheaders"; then + SYSINCLUDES="$SYSINCLUDES \ + -isystem `echo $sysheaders | sed 's/:/ -isystem /g'`" + if test -n "$CXX"; then +- cxxversion=`$CXX -dumpversion 2>&5` && + cxxmachine=`$CXX -dumpmachine 2>&5` && +- cxxheaders=`$CXX -print-file-name=../../../../include/c++/`"$cxxversion" && ++ cxxheaders=`$CXX -print-sysroot`"$prefix/include/c++" && + CXX_SYSINCLUDES="-isystem $cxxheaders \ + -isystem $cxxheaders/$cxxmachine -isystem $cxxheaders/backward" + fi -- cgit v1.2.3-54-g00ecf