summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorIan Lynagh <igloo@earth.li>2010-12-07 01:00:33 +0000
committerIan Lynagh <igloo@earth.li>2010-12-07 01:00:33 +0000
commit75cd9c50ea68a5e426e3105735713b8015d63413 (patch)
treed42739ff3a6766b255264844527861e9efb05ffe /configure.ac
parentc0eb9d997653da4357873829990cc338475bca39 (diff)
downloadhaskell-75cd9c50ea68a5e426e3105735713b8015d63413.tar.gz
Make CPPFLAGS variables, as well as CFLAGS and LDFLAGS
This fixes the "does unsetenv return void" test in the unix package on OS X, if I tell it to make 10.4-compatible binaries. The test uses CPPFLAGS but not CFLAGS, so it thought it returned int (as it was in 10.5-mode), but the C compiler (using CFLAGS, so in 10.4 mode) thought it returned void. I also added CONF_LD_OPTS_STAGE$3 to the list of things in LDFLAGS, which looks like an accidental ommission.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac11
1 files changed, 7 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac
index 28a5875832..e89a2fe4ca 100644
--- a/configure.ac
+++ b/configure.ac
@@ -530,11 +530,11 @@ dnl If gcc, make sure it's at least 2.1
dnl
FP_HAVE_GCC
-FPTOOLS_SET_C_LD_FLAGS([target],[CFLAGS],[LDFLAGS])
-FPTOOLS_SET_C_LD_FLAGS([build],[CONF_CC_OPTS_STAGE0],[CONF_LD_OPTS_STAGE0])
-FPTOOLS_SET_C_LD_FLAGS([target],[CONF_CC_OPTS_STAGE1],[CONF_LD_OPTS_STAGE1])
+FPTOOLS_SET_C_LD_FLAGS([target],[CFLAGS],[LDFLAGS],[CPPFLAGS])
+FPTOOLS_SET_C_LD_FLAGS([build],[CONF_CC_OPTS_STAGE0],[CONF_LD_OPTS_STAGE0],[CONF_CPP_OPTS_STAGE0])
+FPTOOLS_SET_C_LD_FLAGS([target],[CONF_CC_OPTS_STAGE1],[CONF_LD_OPTS_STAGE1],[CONF_CPP_OPTS_STAGE1])
# Stage 3 won't be supported by cross-compilation
-FPTOOLS_SET_C_LD_FLAGS([target],[CONF_CC_OPTS_STAGE2],[CONF_LD_OPTS_STAGE2])
+FPTOOLS_SET_C_LD_FLAGS([target],[CONF_CC_OPTS_STAGE2],[CONF_LD_OPTS_STAGE2],[CONF_CPP_OPTS_STAGE2])
FP_GCC_EXTRA_FLAGS
@@ -547,6 +547,9 @@ AC_SUBST(CONF_CC_OPTS_STAGE2)
AC_SUBST(CONF_LD_OPTS_STAGE0)
AC_SUBST(CONF_LD_OPTS_STAGE1)
AC_SUBST(CONF_LD_OPTS_STAGE2)
+AC_SUBST(CONF_CPP_OPTS_STAGE0)
+AC_SUBST(CONF_CPP_OPTS_STAGE1)
+AC_SUBST(CONF_CPP_OPTS_STAGE2)
dnl ** figure out how to do context diffs
FP_PROG_CONTEXT_DIFF