summaryrefslogtreecommitdiffstats
path: root/libcpu
diff options
context:
space:
mode:
authorJose E. Marchesi <jose.marchesi@oracle.com>2015-10-05 17:36:30 +0200
committerMark Wielaard <mjw@redhat.com>2015-10-06 23:40:19 +0200
commit133509fa406e0e8d4d0f0632e2ee8c5e32dcb010 (patch)
treefd35007eb121d163d77052cb1bf69c79a0ef50c4 /libcpu
parent22843755fa0b6870162660105c6fbbd1ba078390 (diff)
Use -fPIC instead of -fpic when generating PIC code.
This avoids relocation overflows in sparc/sparc64 targets while linking, where the reachable data using -fpic is only 4kb. Signed-off-by: Jose E. Marchesi <jose.marchesi@oracle.com>
Diffstat (limited to 'libcpu')
-rw-r--r--libcpu/ChangeLog5
-rw-r--r--libcpu/Makefile.am2
2 files changed, 6 insertions, 1 deletions
diff --git a/libcpu/ChangeLog b/libcpu/ChangeLog
index a20f4407..88ce6616 100644
--- a/libcpu/ChangeLog
+++ b/libcpu/ChangeLog
@@ -1,3 +1,8 @@
+2014-10-29 Jose E. Marchesi <jose.marchesi@oracle.com>
+
+ * Makefile.am (AM_CFLAGS): Use -fPIC instead of -fpic to avoid
+ relocation overflows in some platforms.
+
2014-04-13 Mark Wielaard <mjw@redhat.com>
* Makefile.am (i386_gendis_LDADD): Remove libmudflap.
diff --git a/libcpu/Makefile.am b/libcpu/Makefile.am
index 3beccf34..0aff4742 100644
--- a/libcpu/Makefile.am
+++ b/libcpu/Makefile.am
@@ -30,7 +30,7 @@
include $(top_srcdir)/config/eu.am
AM_CPPFLAGS += -I$(srcdir)/../libelf -I$(srcdir)/../libebl \
-I$(srcdir)/../libdw -I$(srcdir)/../libasm
-AM_CFLAGS += -fpic -fdollars-in-identifiers
+AM_CFLAGS += -fPIC -fdollars-in-identifiers
LEXCOMPILE = $(LEX) $(LFLAGS) $(AM_LFLAGS) -P$(<F:lex.l=)
LEX_OUTPUT_ROOT = lex.$(<F:lex.l=)
AM_YFLAGS = -p$(<F:parse.y=)