summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authordoko@ubuntu.com <doko@ubuntu.com>2013-03-21 13:31:41 -0700
committerdoko@ubuntu.com <doko@ubuntu.com>2013-03-21 13:31:41 -0700
commit1621d77fc8fb2385d26c7de39f55df60426ec6ec (patch)
tree0a31742c8b8aed6453b95f92a77f50f66d5085cd /configure
parentbd2d30cf31c61843645a96a377aa0573052c4972 (diff)
parentd5537d071cc2acada7220431a0eea5931c2e8a2d (diff)
downloadcpython-git-1621d77fc8fb2385d26c7de39f55df60426ec6ec.tar.gz
- Issue #16754: Fix the incorrect shared library extension on linux. Introduce
two makefile macros SHLIB_SUFFIX and EXT_SUFFIX. SO now has the value of SHLIB_SUFFIX again (as in 2.x and 3.1). The SO macro is removed in 3.4.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure69
1 files changed, 29 insertions, 40 deletions
diff --git a/configure b/configure
index b881602e46..fa8d518783 100755
--- a/configure
+++ b/configure
@@ -625,6 +625,7 @@ ac_includes_default="\
ac_subst_vars='LTLIBOBJS
SRCDIRS
THREADHEADERS
+EXT_SUFFIX
SOABI
LIBC
LIBM
@@ -652,7 +653,7 @@ CCSHARED
BLDSHARED
LDCXXSHARED
LDSHARED
-SO
+SHLIB_SUFFIX
LIBTOOL_CRUFT
OTHER_LIBTOOL_OPT
UNIVERSAL_ARCH_FLAGS
@@ -8392,6 +8393,25 @@ esac
+# SHLIB_SUFFIX is the extension of shared libraries `(including the dot!)
+# -- usually .so, .sl on HP-UX, .dll on Cygwin
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the extension of shared libraries" >&5
+$as_echo_n "checking the extension of shared libraries... " >&6; }
+if test -z "$SHLIB_SUFFIX"; then
+ case $ac_sys_system in
+ hp*|HP*)
+ case `uname -m` in
+ ia64) SHLIB_SUFFIX=.so;;
+ *) SHLIB_SUFFIX=.sl;;
+ esac
+ ;;
+ CYGWIN*) SHLIB_SUFFIX=.dll;;
+ *) SHLIB_SUFFIX=.so;;
+ esac
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHLIB_SUFFIX" >&5
+$as_echo "$SHLIB_SUFFIX" >&6; }
+
# LDSHARED is the ld *command* used to create shared library
# -- "cc -G" on SunOS 5.x, "ld -shared" on IRIX 5
# (Shared libraries in this instance are shared modules to be loaded into
@@ -13685,51 +13705,20 @@ SOABI='cpython-'`echo $VERSION | tr -d .`${ABIFLAGS}
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $SOABI" >&5
$as_echo "$SOABI" >&6; }
+
+case $ac_sys_system in
+ Linux*|GNU*)
+ EXT_SUFFIX=.${SOABI}${SHLIB_SUFFIX};;
+ *)
+ EXT_SUFFIX=${SHLIB_SUFFIX};;
+esac
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking LDVERSION" >&5
$as_echo_n "checking LDVERSION... " >&6; }
LDVERSION='$(VERSION)$(ABIFLAGS)'
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDVERSION" >&5
$as_echo "$LDVERSION" >&6; }
-# SO is the extension of shared libraries `(including the dot!)
-# -- usually .so, .sl on HP-UX, .dll on Cygwin
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking SO" >&5
-$as_echo_n "checking SO... " >&6; }
-if test -z "$SO"
-then
- case $ac_sys_system in
- hp*|HP*)
- case `uname -m` in
- ia64) SO=.so;;
- *) SO=.sl;;
- esac
- ;;
- CYGWIN*) SO=.dll;;
- Linux*|GNU*)
- SO=.${SOABI}.so;;
- *) SO=.so;;
- esac
-else
- # this might also be a termcap variable, see #610332
- echo
- echo '====================================================================='
- echo '+ +'
- echo '+ WARNING: You have set SO in your environment. +'
- echo '+ Do you really mean to change the extension for shared libraries? +'
- echo '+ Continuing in 10 seconds to let you to ponder. +'
- echo '+ +'
- echo '====================================================================='
- sleep 10
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $SO" >&5
-$as_echo "$SO" >&6; }
-
-
-cat >>confdefs.h <<_ACEOF
-#define SHLIB_EXT "$SO"
-_ACEOF
-
-
# Check whether right shifting a negative integer extends the sign bit
# or fills with zeros (like the Cray J90, according to Tim Peters).
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether right shift extends the sign bit" >&5