summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configure.ac12
-rw-r--r--m4/mpc.m42
2 files changed, 7 insertions, 7 deletions
diff --git a/configure.ac b/configure.ac
index 4f8829a..02ad6c7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -93,6 +93,11 @@ AC_ARG_ENABLE([valgrind-tests],
]
)
+# Check for user specification of CC or CFLAGS
+if test -n "$CFLAGS" || test -n "$CC" ; then
+ user_redefine_cc_or_cflags=yes
+fi
+
# Setup CC and CFLAGS
AC_PROG_CC
AC_LANG(C)
@@ -100,11 +105,6 @@ AC_LANG(C)
# Set up LibTool
AC_PROG_LIBTOOL
-# Check for user specification of CC or CFLAGS
-if test -n "$CFLAGS" || test -n "$CC" ; then
- user_redefine_cc=yes
-fi
-
# Check GMP Header
AC_MSG_CHECKING(for gmp.h)
AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
@@ -115,7 +115,7 @@ AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
])
# Check for GMP CFLAGS in gmp.h
-if test -z "$user_redefine_cc" ; then
+if test -z "$user_redefine_cc_or_cflags" ; then
MPC_GMP_CC_CFLAGS
fi
diff --git a/m4/mpc.m4 b/m4/mpc.m4
index 3738bf3..8d233a4 100644
--- a/m4/mpc.m4
+++ b/m4/mpc.m4
@@ -142,10 +142,10 @@ AC_DEFUN([MPC_C_CHECK_WARNINGCFLAGS], [
# Checks if CC and CFLAGS can be extracted from gmp.h
#
AC_DEFUN([MPC_GMP_CC_CFLAGS], [
- AC_MSG_CHECKING(for CC and CFLAGS in gmp.h)
AC_PROG_CPP
AC_PROG_EGREP
AC_PROG_SED
+ AC_MSG_CHECKING(for CC and CFLAGS in gmp.h)
# Get CC
echo "#include \"gmp.h\"" > conftest.c
echo "MPC_OPTION __GMP_CC" >> conftest.c