summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@haypocalc.com>2011-11-24 12:53:38 (GMT)
committerVictor Stinner <victor.stinner@haypocalc.com>2011-11-24 12:53:38 (GMT)
commit984890fcbbb2bb9d7168fd78a1383804593c3fd3 (patch)
tree6bfdaf51f6d170bca2fad95b42b2d1aabb0dfe25 /configure
parent1518e8713d1e372284c653f254fb29cecc66d764 (diff)
downloadcpython-984890fcbbb2bb9d7168fd78a1383804593c3fd3.zip
cpython-984890fcbbb2bb9d7168fd78a1383804593c3fd3.tar.gz
cpython-984890fcbbb2bb9d7168fd78a1383804593c3fd3.tar.bz2
Close #13415: Test in configure if unsetenv() has a return value or not.
Patch written by Charles-François Natali.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure28
1 files changed, 28 insertions, 0 deletions
diff --git a/configure b/configure
index 596336e..112c20a 100755
--- a/configure
+++ b/configure
@@ -9812,6 +9812,34 @@ $as_echo "no" >&6; }
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken unsetenv" >&5
+$as_echo_n "checking for broken unsetenv... " >&6; }
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+#include <stdlib.h>
+
+int
+main ()
+{
+int res = unsetenv("DUMMY")
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+else
+
+$as_echo "#define HAVE_BROKEN_UNSETENV 1" >>confdefs.h
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+
for ac_prog in true
do
# Extract the first word of "$ac_prog", so it can be a program name with args.