source: patches/binutils-2.20-genscripts_multilib-1.patch@ a262a31

clfs-1.2 clfs-2.1 clfs-3.0.0-systemd clfs-3.0.0-sysvinit systemd sysvinit
Last change on this file since a262a31 was 206bb97, checked in by Joe Ciccone <jciccone@…>, 15 years ago

Updated Binutils to 2.20.

  • Property mode set to 100644
File size: 2.7 KB
RevLine 
[69cde8d]1Submitted By: Ryan Oliver (ryan dot oliver at pha dot com dot au)
2Origin: Ryan Oliver
[206bb97]3Date: 2010-01-01
[69cde8d]4Initial package version: 2.15 (problem also exists in 2.14 series)
5Description:
[7150133]6 Rediffed for 2.19.1 by Jim Gifford
[206bb97]7 Rediffed for 2.10 by Joe Ciccone
8
[69cde8d]9 Updated patch, use this for all binutils 2.15 series instead of the
10 binutils-2.15.90.0.1-genscripts-multilib.patch
11
12 If --with-libpath= was specified during configure (or LIB_PATH was
13 supplied during make) we want to have these libraries added to the
14 linker scripts search paths, and in the case of multi-lib have them
15 processed to provide both lib and lib64 search paths.
16 This patch produces this behaviour when building a cross-binutils.
17
18 Also to fix an annoyance we remove whatever was specified (if anything)
19 by --libdir= from the linker script search path. This is so when cross-
20 compiling a 64bit target-native biarch toolchain we can specify the
21 installation directory for binutils produced libraries to be */lib64
22 without having this directory added to the 32bit emulation search path.
23
24 By rights we should really check if ${libdir} matches a search path in
25 any of the supported emulations for this target (as opposed to only the
26 one genscripts.sh is currently processing) and if so ignore ${libpath}.
27
[7150133]28 This patch differs from the preceding genscripts-multilib patch as now
29 USE_LIBPATH will always be set if LIB_PATH is non empty
[69cde8d]30
[206bb97]31diff -Naur binutils-2.20.orig/ld/genscripts.sh binutils-2.20/ld/genscripts.sh
32--- binutils-2.20.orig/ld/genscripts.sh 2009-09-02 03:25:35.000000000 -0400
33+++ binutils-2.20/ld/genscripts.sh 2010-01-01 12:45:50.201595087 -0500
[7150133]34@@ -132,7 +132,8 @@
[69cde8d]35 esac
36
37 # If the emulparams file sets NATIVE, make sure USE_LIBPATH is set also.
38-if test "x$NATIVE" = "xyes" ; then
39+# Also set USE_LIBPATH if LIB_PATH has been set
40+if [ "x$NATIVE" = "xyes" -o "x${LIB_PATH}" != "x" ] ; then
41 USE_LIBPATH=yes
42 fi
43
[7150133]44@@ -147,17 +148,17 @@
[69cde8d]45 #
46 # If the emulparams file set LIBPATH_SUFFIX, prepend an extra copy of
47 # the library path with the suffix applied.
48-
49-if [ "x${LIB_PATH}" = "x" ] && [ "x${USE_LIBPATH}" = xyes ] ; then
50+if [ "x${USE_LIBPATH}" = xyes ] ; then
51 LIB_PATH2=
52+ if [ "x${LIB_PATH}" = "x" ] ; then
53+ libs="${NATIVE_LIB_DIRS}"
54+ else
55+ libs=`echo ${LIB_PATH} | sed 's/:/ /g'`
56+ LIB_PATH=
57+ fi
58
59- libs=${NATIVE_LIB_DIRS}
60 if [ "x${use_sysroot}" != "xyes" ] ; then
61 case " ${libs} " in
62- *" ${libdir} "*) ;;
63- *) libs="${libdir} ${libs}" ;;
64- esac
65- case " ${libs} " in
66 *" ${tool_lib} "*) ;;
67 *) libs="${tool_lib} ${libs}" ;;
68 esac
Note: See TracBrowser for help on using the repository browser.