diff options
author | Joakim Tjernlund <Joakim.Tjernlund@transmode.se> | 2010-12-06 14:36:46 +0100 |
---|---|---|
committer | Wolfgang Denk <wd@denx.de> | 2011-04-11 21:36:41 +0200 |
commit | 33ee4c92339ee386662c0ee2d221098c5cc8b07e (patch) | |
tree | adcaaa9e8759a48d7a40c1476191ed840abd9888 /arch/powerpc/cpu/ppc4xx/config.mk | |
parent | 7d2fade7b1cd08432d16f7af5b10a8d1c0213813 (diff) | |
download | u-boot-imx-33ee4c92339ee386662c0ee2d221098c5cc8b07e.zip u-boot-imx-33ee4c92339ee386662c0ee2d221098c5cc8b07e.tar.gz u-boot-imx-33ee4c92339ee386662c0ee2d221098c5cc8b07e.tar.bz2 |
PowerPC: Move -fPIC flag to common place
The -fPIC flag belongs with -mrelocatable, move it there.
Also change -fPIC to -fpic as this produces smaller
binaries.
However, currently -mrelocatable promotes -fpic to -fPIC, a
fix for this is in upcoming gcc 4.6 or you can apply this small
patch to gcc:
diff --git a/gcc/config/rs6000/sysv4.h b/gcc/config/rs6000/sysv4.h
index 8da8410..e4b8280 100644
--- a/gcc/config/rs6000/sysv4.h
+++ b/gcc/config/rs6000/sysv4.h
@@ -227,7 +227,8 @@ do { \
} \
\
else if (TARGET_RELOCATABLE) \
- flag_pic = 2; \
+ if (!flag_pic) \
+ flag_pic = 2; \
} while (0)
#ifndef RS6000_BI_ARCH
--
Signed-off-by: Joakim Tjernlund <Joakim.Tjernlund@transmode.se>
Diffstat (limited to 'arch/powerpc/cpu/ppc4xx/config.mk')
-rw-r--r-- | arch/powerpc/cpu/ppc4xx/config.mk | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/powerpc/cpu/ppc4xx/config.mk b/arch/powerpc/cpu/ppc4xx/config.mk index d862bb4..f5cbbbd 100644 --- a/arch/powerpc/cpu/ppc4xx/config.mk +++ b/arch/powerpc/cpu/ppc4xx/config.mk @@ -21,7 +21,7 @@ # MA 02111-1307 USA # -PLATFORM_RELFLAGS += -fPIC -meabi +PLATFORM_RELFLAGS += -meabi PLATFORM_CPPFLAGS += -DCONFIG_4xx -ffixed-r2 -mstring -msoft-float cfg=$(shell grep configs $(OBJTREE)/include/config.h | sed 's/.*<\(configs.*\)>/\1/') |