aboutsummaryrefslogtreecommitdiff
path: root/libiberty
diff options
context:
space:
mode:
authorDavid Malcolm <dmalcolm@redhat.com>2013-10-15 20:33:55 +0000
committerDavid Malcolm <dmalcolm@redhat.com>2013-10-15 20:33:55 +0000
commit0e9dd5f5d8f0ef4c55233851ed6678c563a62734 (patch)
treeb101be713129409fe69e45a4e5436995f481906a /libiberty
parentbb6d7590f4e7efa24f9694b7526b73b551e9eb84 (diff)
Add --enable-host-shared configuration option
/ * configure.ac: Add --enable-host-shared * configure: Regenerate. gcc/ * Makefile.in (PICFLAG): New. (enable_host_shared): New. (INTERNAL_CFLAGS): Use PICFLAG. (LIBIBERTY): Use pic build of libiberty.a if configured with --enable-host-shared. * configure.ac: Add --enable-host-shared, setting up new PICFLAG variable. * configure: Regenerate. * doc/install.texi (--enable-shared): Add note contrasting it with... (--enable-host-shared): New option. libbacktrace/ * configure.ac: Add --enable-host-shared, setting up pre-existing PIC_FLAG variable within Makefile.am et al. * configure: Regenerate. libcpp/ * Makefile.in (PICFLAG): New. (ALL_CFLAGS): Add PICFLAG. (ALL_CXXFLAGS): Likewise. * configure.ac: Add --enable-host-shared, setting up new PICFLAG variable. * configure: Regenerate. libdecnumber/ * Makefile.in (PICFLAG): New. (ALL_CFLAGS): Add PICFLAG. * configure.ac: Add --enable-host-shared, setting up new PICFLAG variable. * configure: Regenerate. libiberty/ * configure.ac: If --enable-host-shared, use -fPIC. * configure: Regenerate. zlib/ * configure.ac: Add --enable-host-shared, setting up new PICFLAG variable. * Makefile.am: Add PICFLAG to libz_a_CFLAGS. * Makefile.in: Regenerate. * configure: Regenerate. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@203632 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libiberty')
-rw-r--r--libiberty/ChangeLog5
-rwxr-xr-xlibiberty/configure6
-rw-r--r--libiberty/configure.ac6
3 files changed, 17 insertions, 0 deletions
diff --git a/libiberty/ChangeLog b/libiberty/ChangeLog
index c37939ca8ea..7250dc1f490 100644
--- a/libiberty/ChangeLog
+++ b/libiberty/ChangeLog
@@ -1,3 +1,8 @@
+2013-10-15 David Malcolm <dmalcolm@redhat.com>
+
+ * configure.ac: If --enable-host-shared, use -fPIC.
+ * configure: Regenerate.
+
2013-10-11 Paul Pluzhnikov <ppluzhnikov@google.com>
* cp-demangle.c (d_name): Demangle local-source-names.
diff --git a/libiberty/configure b/libiberty/configure
index e601ccd99f4..b71141a98b0 100755
--- a/libiberty/configure
+++ b/libiberty/configure
@@ -4963,6 +4963,12 @@ case "${enable_shared}" in
"") shared=no ;;
*) shared=yes ;;
esac
+
+# ...unless --enable-host-shared was passed from top-level config:
+if [ "${enable_host_shared}" = "yes" ]; then
+ shared=yes
+fi
+
if [ "${shared}" != "yes" ]; then
PICFLAG=
fi
diff --git a/libiberty/configure.ac b/libiberty/configure.ac
index fcea46f6c7b..4ad88a984d7 100644
--- a/libiberty/configure.ac
+++ b/libiberty/configure.ac
@@ -225,6 +225,12 @@ case "${enable_shared}" in
"") shared=no ;;
*) shared=yes ;;
esac
+
+# ...unless --enable-host-shared was passed from top-level config:
+if [[ "${enable_host_shared}" = "yes" ]]; then
+ shared=yes
+fi
+
if [[ "${shared}" != "yes" ]]; then
PICFLAG=
fi