Skip to content

Commit 5162de9

Browse files
author
mark.dickinson
committed
Make configure test for tanh(-0.) == -0. committed in r62447 actually
work. (The test wasn't properly linked with libm. Sigh.) git-svn-id: http://svn.python.org/projects/python/trunk@62451 6015fed2-1504-0410-9fe1-9d1591cc4771
1 parent a0aad88 commit 5162de9

2 files changed

Lines changed: 9 additions & 5 deletions

File tree

configure

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#! /bin/sh
2-
# From configure.in Revision: 62145 .
2+
# From configure.in Revision: 62447 .
33
# Guess values for system-dependent variables and create Makefiles.
44
# Generated by GNU Autoconf 2.61 for python 2.6.
55
#
@@ -20852,6 +20852,9 @@ fi
2085220852
# * Check for mathematical functions *
2085320853
# ************************************
2085420854

20855+
LIBS_SAVE=$LIBS
20856+
LIBS="$LIBS $LIBM"
20857+
2085520858
# On FreeBSD 6.2, it appears that tanh(-0.) returns 0. instead of
2085620859
# -0. on some architectures.
2085720860
{ echo "$as_me:$LINENO: checking whether tanh preserves the sign of zero" >&5
@@ -20871,6 +20874,7 @@ cat >>conftest.$ac_ext <<_ACEOF
2087120874
/* end confdefs.h. */
2087220875

2087320876
#include <math.h>
20877+
#include <stdlib.h>
2087420878
int main() {
2087520879
/* return 0 if either negative zeros don't exist
2087620880
on this platform or if negative zeros exist
@@ -20927,8 +20931,6 @@ _ACEOF
2092720931

2092820932
fi
2092920933

20930-
LIBS_SAVE=$LIBS
20931-
LIBS="$LIBS $LIBM"
2093220934

2093320935
for ac_func in hypot
2093420936
do

configure.in

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2995,12 +2995,16 @@ fi],
29952995
# * Check for mathematical functions *
29962996
# ************************************
29972997

2998+
LIBS_SAVE=$LIBS
2999+
LIBS="$LIBS $LIBM"
3000+
29983001
# On FreeBSD 6.2, it appears that tanh(-0.) returns 0. instead of
29993002
# -0. on some architectures.
30003003
AC_MSG_CHECKING(whether tanh preserves the sign of zero)
30013004
AC_CACHE_VAL(ac_cv_tanh_preserves_zero_sign, [
30023005
AC_TRY_RUN([
30033006
#include <math.h>
3007+
#include <stdlib.h>
30043008
int main() {
30053009
/* return 0 if either negative zeros don't exist
30063010
on this platform or if negative zeros exist
@@ -3020,8 +3024,6 @@ then
30203024
[Define if tanh(-0.) is -0., or if platform doesn't have signed zeros])
30213025
fi
30223026

3023-
LIBS_SAVE=$LIBS
3024-
LIBS="$LIBS $LIBM"
30253027
AC_REPLACE_FUNCS(hypot)
30263028

30273029
AC_CHECK_FUNCS(acosh asinh atanh copysign expm1 finite isinf isnan log1p)

0 commit comments

Comments
 (0)