-
-# Handle --compile-c-with-cxx here, once CXX and CXXFLAGS are known.
-if "$at_arg_compile_c_with_cxx"; then
- CC=$CXX
- CFLAGS=$CXXFLAGS
+# Don't just check if $POSIXLY_CORRECT is set, as Bash, when launched
+# as /bin/sh, sets the shell variable POSIXLY_CORRECT to y, but not
+# the environment variable.
+: ${C_COMPILER_POSIXLY_CORRECT='@C_COMPILER_POSIXLY_CORRECT@'}
+if env | grep '^POSIXLY_CORRECT=' >/dev/null; then
+ POSIXLY_CORRECT_IS_EXPORTED=true
+else
+ POSIXLY_CORRECT_IS_EXPORTED=false