aboutsummaryrefslogtreecommitdiff
path: root/libcc1/configure
diff options
context:
space:
mode:
authorIain Sandoe <iain@sandoe.co.uk>2020-11-18 10:06:03 +0000
committerIain Sandoe <iain@sandoe.co.uk>2020-12-05 08:43:20 +0000
commit1352bc88a0525743c952197fb2db6e4f8c091cde (patch)
tree06207e8cc7971e67177cda013cacc9a764abfe3c /libcc1/configure
parent3e2ae3ee285a57455d5a23bd352a68c289130186 (diff)
downloadgcc-1352bc88a0525743c952197fb2db6e4f8c091cde.zip
gcc-1352bc88a0525743c952197fb2db6e4f8c091cde.tar.gz
gcc-1352bc88a0525743c952197fb2db6e4f8c091cde.tar.bz2
Darwin : Update libtool and dependencies for Darwin20 [PR97865]
The change in major version (and the increment from Darwin19 to 20) caused libtool tests to fail which resulted in incorrect build settings for shared libraries. We take this opportunity to sort out the shared undefined symbols state rather than propagating the current unsound behaviour into a new rev. This change means that we default to the case that missing symbols are considered an error, and if one wants to allow this intentionally, the confiuration for that case should be set appropriately. Three existing cases need undefined dynamic lookup: libitm, where there is already a configuration mechanism to add the flags. libcc1, where we add simple configuration to add the flags for Darwin. libsanitizer, where we can add to the existing extra flags. libcc1/ChangeLog: PR target/97865 * Makefile.am: Add dynamic_lookup to LD flags for Darwin. * configure.ac: Test for Darwin host and set a flag. * Makefile.in: Regenerate. * configure: Regenerate. libitm/ChangeLog: PR target/97865 * configure.tgt: Add dynamic_lookup to XLDFLAGS for Darwin. * configure: Regenerate. libsanitizer/ChangeLog: PR target/97865 * configure.tgt: Add dynamic_lookup to EXTRA_CXXFLAGS for Darwin. * configure: Regenerate. ChangeLog: PR target/97865 * libtool.m4: Update handling of Darwin platform link flags for Darwin20. gcc/ChangeLog: PR target/97865 * configure: Regenerate. libatomic/ChangeLog: PR target/97865 * configure: Regenerate. libbacktrace/ChangeLog: PR target/97865 * configure: Regenerate. libffi/ChangeLog: PR target/97865 * configure: Regenerate. libgfortran/ChangeLog: PR target/97865 * configure: Regenerate. libgomp/ChangeLog: PR target/97865 * configure: Regenerate. libhsail-rt/ChangeLog: PR target/97865 * configure: Regenerate. libobjc/ChangeLog: PR target/97865 * configure: Regenerate. libphobos/ChangeLog: PR target/97865 * configure: Regenerate. libquadmath/ChangeLog: PR target/97865 * configure: Regenerate. libssp/ChangeLog: PR target/97865 * configure: Regenerate. libstdc++-v3/ChangeLog: PR target/97865 * configure: Regenerate. libvtv/ChangeLog: PR target/97865 * configure: Regenerate. zlib/ChangeLog: PR target/97865 * configure: Regenerate.
Diffstat (limited to 'libcc1/configure')
-rwxr-xr-xlibcc1/configure53
1 files changed, 37 insertions, 16 deletions
diff --git a/libcc1/configure b/libcc1/configure
index 4e2ca41..d3eedfe 100755
--- a/libcc1/configure
+++ b/libcc1/configure
@@ -635,6 +635,8 @@ LTLIBOBJS
LIBOBJS
ENABLE_PLUGIN_FALSE
ENABLE_PLUGIN_TRUE
+DARWIN_DYNAMIC_LOOKUP_FALSE
+DARWIN_DYNAMIC_LOOKUP_TRUE
libsuffix
GMPINC
WERROR
@@ -7253,23 +7255,25 @@ _LT_EOF
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
$as_echo "$lt_cv_ld_force_load" >&6; }
- case $host_os in
- rhapsody* | darwin1.[012])
+ # Allow for Darwin 4-7 (macOS 10.0-10.3) although these are not expect to
+ # build without first building modern cctools / linker.
+ case $host_cpu-$host_os in
+ *-rhapsody* | *-darwin1.[012])
_lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
- darwin1.*)
+ *-darwin1.*)
_lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
- darwin*) # darwin 5.x on
- # if running on 10.5 or later, the deployment target defaults
- # to the OS version, if on x86, and 10.4, the deployment
- # target defaults to 10.4. Don't you love it?
- case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
- 10.0,*86*-darwin8*|10.0,*-darwin[91]*)
- _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
+ *-darwin*)
+ # darwin 5.x (macOS 10.1) onwards we only need to adjust when the
+ # deployment target is forced to an earlier version.
+ case ${MACOSX_DEPLOYMENT_TARGET-UNSET},$host in
+ UNSET,*-darwin[89]*|UNSET,*-darwin[12][0123456789]*)
+ ;;
10.[012][,.]*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
- 10.*)
- _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
- esac
+ _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
+ ;;
+ *)
+ ;;
+ esac
;;
esac
if test "$lt_cv_apple_cc_single_mod" = "yes"; then
@@ -10783,7 +10787,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 10786 "configure"
+#line 10790 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -10889,7 +10893,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 10892 "configure"
+#line 10896 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -14970,6 +14974,19 @@ fi
$as_echo "$libcc1_cv_lib_sockets" >&6; }
LIBS="$LIBS $libcc1_cv_lib_sockets"
+case "$host" in
+ *-*-darwin*) darwin_dynamic_lookup=yes ;;
+ *) darwin_dynamic_lookup= ;;
+esac
+ if test $darwin_dynamic_lookup = yes; then
+ DARWIN_DYNAMIC_LOOKUP_TRUE=
+ DARWIN_DYNAMIC_LOOKUP_FALSE='#'
+else
+ DARWIN_DYNAMIC_LOOKUP_TRUE='#'
+ DARWIN_DYNAMIC_LOOKUP_FALSE=
+fi
+
+
# If any of these functions are missing, simply don't bother building
# this plugin.
# Check for plugin support
@@ -15338,6 +15355,10 @@ if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then
as_fn_error $? "conditional \"am__fastdepCXX\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
+if test -z "${DARWIN_DYNAMIC_LOOKUP_TRUE}" && test -z "${DARWIN_DYNAMIC_LOOKUP_FALSE}"; then
+ as_fn_error $? "conditional \"DARWIN_DYNAMIC_LOOKUP\" was never defined.
+Usually this means the macro was only invoked conditionally." "$LINENO" 5
+fi
if test -z "${ENABLE_PLUGIN_TRUE}" && test -z "${ENABLE_PLUGIN_FALSE}"; then
as_fn_error $? "conditional \"ENABLE_PLUGIN\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5