aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorReid Spencer <rspencer@reidspencer.com>2004-10-13 11:53:12 +0000
committerReid Spencer <rspencer@reidspencer.com>2004-10-13 11:53:12 +0000
commit09252e970e52df126d4296dcab8489d483675425 (patch)
tree22f8cf322252ab27c00d832ad16b92bc93032423
parent36a7d906c3124a200455137ddded7358d9182956 (diff)
Set up BUILD_MODE based on the configuration so the default build mode
is established from configuration. Also, don't make the ENABLE_ options AM_CONDITIONALs. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16952 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--autoconf/configure.am15
1 files changed, 11 insertions, 4 deletions
diff --git a/autoconf/configure.am b/autoconf/configure.am
index 8a5a2a9cf2..a4f4e62d2e 100644
--- a/autoconf/configure.am
+++ b/autoconf/configure.am
@@ -72,7 +72,6 @@ AC_ARG_ENABLE(optimized,
esac],
[ENABLE_OPTIMIZED=0])
AC_SUBST(ENABLE_OPTIMIZED)
-AM_CONDITIONAL(ENABLE_OPTIMIZED,test $ENABLE_OPTIMIZED = 1)
dnl Specify whether to build profiled or not
AC_ARG_ENABLE(profiled,
@@ -86,7 +85,16 @@ AC_ARG_ENABLE(profiled,
esac],
[ENABLE_PROFILED=0])
AC_SUBST(ENABLE_PROFILED,$ENABLE_PROFILED)
-AM_CONDITIONAL(ENABLE_PROFILED,test $ENABLE_PROFILED = 1)
+
+if test $ENABLE_PROFILED = 1 ; then
+ AC_SUBST(BUILDMODE,Profile)
+else
+ if test $ENABLE_OPTIMIZED = 1 ; then
+ AC_SUBST(BUILDMODE,Release)
+ else
+ AC_SUBST(BUILDMODE,Debug)
+ fi
+fi
dnl JIT Option
AC_ARG_ENABLE(jit,
@@ -169,7 +177,7 @@ AC_PROG_INSTALL
dnl Check for compilation tools
AC_PROG_CXX
-AC_PROG_CC(gcc)
+AC_PROG_CC
AC_PROG_CPP
dnl Checks for other build tools
@@ -489,7 +497,6 @@ AC_CONFIG_HEADERS([include/llvm/ADT/iterator])
dnl Configure makefiles
AC_CONFIG_FILES([Makefile])
-AC_CONFIG_FILES([Makefile.rules])
AC_CONFIG_FILES([lib/Makefile])
AC_CONFIG_FILES([lib/Analysis/IPA/Makefile])
AC_CONFIG_FILES([lib/Analysis/Makefile])