This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH] Build libiberty with -fPIC on Linux/MIPS hosts
- From: Aurelien Jarno <aurelien at aurel32 dot net>
- To: gcc-patches at gcc dot gnu dot org
- Date: Mon, 21 Apr 2008 09:54:24 +0200
- Subject: [PATCH] Build libiberty with -fPIC on Linux/MIPS hosts
Starting with gcc 4.3, -mshared is the default on Linux/MIPS hosts. This
means that libraries should now be built with -fPIC, which implies
-mno-shared.
The patch below, switch libiberty to -fPIC on Linux/MIPS hosts. It is
needed for binutils when build with --enable-shared.
2008-04-21 Aurelien Jarno <aurelien@aurel32.net>
* libiberty/configure.ac: use -fPIC on Linux/MIPS hosts.
* libiberty/configure: Regenerate.
Index: libiberty/configure.ac
===================================================================
--- libiberty/configure.ac (révision 134503)
+++ libiberty/configure.ac (copie de travail)
@@ -208,6 +208,7 @@
i[[34567]]86-*-* | x86_64-*-*)
PICFLAG=-fpic ;;
m68k-*-*) PICFLAG=-fpic ;;
+ mips*-*-linux) PICFLAG=-fPIC ;;
powerpc*-*-aix*) ;;
powerpc*-*-*) PICFLAG=-fPIC ;;
sparc*-*-*) case "${CFLAGS}" in
Index: libiberty/configure
===================================================================
--- libiberty/configure (révision 134503)
+++ libiberty/configure (copie de travail)
@@ -3729,6 +3729,7 @@
i[34567]86-*-* | x86_64-*-*)
PICFLAG=-fpic ;;
m68k-*-*) PICFLAG=-fpic ;;
+ mips*-*-linux) PICFLAG=-fPIC ;;
powerpc*-*-aix*) ;;
powerpc*-*-*) PICFLAG=-fPIC ;;
sparc*-*-*) case "${CFLAGS}" in
--
.''`. Aurelien Jarno | GPG: 1024D/F1BCDB73
: :' : Debian developer | Electrical Engineer
`. `' aurel32@debian.org | aurelien@aurel32.net
`- people.debian.org/~aurel32 | www.aurel32.net