patches/eglibc/2_9/110-binutils-elf-begin.patch
author "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Fri Oct 08 23:37:12 2010 +0200 (2010-10-08)
branch1.8
changeset 2150 f97a8ad2b172
parent 1327 5fd1f22a6062
permissions -rw-r--r--
cc/gcc: fix C++ headers location

In case we build the C++ compiler, we have to tell gcc where to put the C++
headers, or else it will try to # put it in prefix/tuple/include, which we
make a symlink to sysroot/usr/include during the build, and that we delete
(the symlink!) after the build, but gcc will not look in sysroot/usr/inlcude
for C++ headers by default.

Implements a fix suggested by: Bryan Hundven <bryanhundven@gmail.com>

Reported-by: Anthony Foiani <anthony.foiani@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
(transplanted from a0924619112015bdaa81a0a2313d21ef38607bc2)
     1 diff -ru eglibc-2_9_orig/elf/Makefile eglibc-2_9/elf/Makefile
     2 --- eglibc-2_9_orig/elf/Makefile	2009-01-26 07:31:40.000000000 -0800
     3 +++ eglibc-2_9/elf/Makefile	2009-05-06 16:52:28.000000000 -0700
     4 @@ -305,7 +305,7 @@
     5  		  $(LDFLAGS-rtld) -Wl,-z,defs -Wl,--verbose 2>&1 |	\
     6  		  LC_ALL=C \
     7  		  sed -e '/^=========/,/^=========/!d;/^=========/d'	\
     8 -		      -e 's/\. = 0 + SIZEOF_HEADERS;/& _begin = . - SIZEOF_HEADERS;/' \
     9 +		      -e 's/\. = .* + SIZEOF_HEADERS;/& _begin = . - SIZEOF_HEADERS;/' \
    10  		      -e 's/\. = SEGMENT_START("text-segment", 0) + SIZEOF_HEADERS;/& _begin = . - SIZEOF_HEADERS;/' \
    11  		  > $@.lds
    12  	$(LINK.o) -nostdlib -nostartfiles -shared -o $@			\