From f64d0ebcce06fecf5d9fe64db267fc18efc14370 Mon Sep 17 00:00:00 2001 From: Dave Beazley Date: Tue, 11 Nov 2003 18:51:16 +0000 Subject: [PATCH] Configuration changes for OS-X. Including: - Disable use of static libraries in libtool - Setting of different file suffixes for different languages (.so, .bundle, .dylib, etc.). - Optional setting of -no-undefined option to libtool. git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5292 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- configure.in | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/configure.in b/configure.in index 0faf2c2cd..0af54e957 100644 --- a/configure.in +++ b/configure.in @@ -38,6 +38,15 @@ AM_PROG_CC_C_O # Needed for subdir-objects in AUTOMAKE_OPTIONS AC_CHECK_PROGS(AR, ar aal, ar) AC_SUBST(AR) AC_LIBTOOL_WIN32_DLL + +# On Mac OS-X, static runtime libraries don't seem to build (and are +# probably a bad idea anyways). This turns this off in libtool. + +case $host in + *-*-darwin*) AC_DISABLE_STATIC;; + *);; +esac + AC_PROG_LIBTOOL AC_COMPILE_WARNINGS # Increase warning levels @@ -225,7 +234,6 @@ then fi AC_MSG_RESULT($LINKFORSHARED) - # This variation is needed on OS-X because there is no (apparent) consistency in shared libary naming. # Sometimes .bundle works, but sometimes .so is needed. It depends on the target language @@ -253,7 +261,14 @@ case $host in *) TCL_CXXSHARED=$CXXSHARED;; esac +# On Mac OS-X, the -no-defined option to libtool doesn't seem to work. +# This fixes it +AC_SUBST(LIBTOOL_NO_UNDEFINED) +case $host in + *-*-darwin*) LIBTOOL_NO_UNDEFINED="";; + *) LIBTOOL_NO_UNDEFINED="-no-undefined";; +esac echo "" echo "Checking for installed packages."