From c2cdd8f8d35d933c5857fda761f8778e6961f861 Mon Sep 17 00:00:00 2001 From: Brad King Date: Tue, 10 Sep 2002 10:02:58 -0400 Subject: [PATCH] ERR: AC_SUBST replaced with AC_DEFINE. Needed to get configure script to correctly setup cmConfigure.h. --- configure | 48 ++++++++++++++++++++++++++---------------------- configure.in | 12 ++++-------- 2 files changed, 30 insertions(+), 30 deletions(-) diff --git a/configure b/configure index b155228db..fd697910f 100755 --- a/configure +++ b/configure @@ -1118,7 +1118,10 @@ else cat conftest.$ac_ext >&5 rm -rf conftest* - CMAKE_NO_ANSI_STREAM_HEADERS=1 + cat >> confdefs.h <<\EOF +#define CMAKE_NO_ANSI_STREAM_HEADERS 1 +EOF + echo "$ac_t""no" 1>&6 fi @@ -1133,12 +1136,11 @@ cross_compiling=$ac_cv_prog_cc_cross CXXFLAGS="$CXXFLAGS_ORIG" fi - # check non-g++ compilers to see if they have std::stringstream CXXFLAGS_ORIG="$CXXFLAGS" CXXFLAGS="$CMAKE_ANSI_CXXFLAGS $CXXFLAGS" echo $ac_n "checking for ansi standard C++ stringstream""... $ac_c" 1>&6 -echo "configure:1142: checking for ansi standard C++ stringstream" >&5 +echo "configure:1144: checking for ansi standard C++ stringstream" >&5 ac_ext=C # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. @@ -1148,7 +1150,7 @@ ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftes cross_compiling=$ac_cv_prog_cxx_cross cat > conftest.$ac_ext < @@ -1157,7 +1159,7 @@ int main() { ; return 0; } EOF -if { (eval echo configure:1161: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1163: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""yes" 1>&6 @@ -1167,7 +1169,10 @@ else cat conftest.$ac_ext >&5 rm -rf conftest* -CMAKE_NO_ANSI_STRING_STREAM=1 +cat >> confdefs.h <<\EOF +#define CMAKE_NO_ANSI_STRING_STREAM 1 +EOF + echo "$ac_t""no" 1>&6 fi @@ -1181,13 +1186,12 @@ cross_compiling=$ac_cv_prog_cc_cross CXXFLAGS="$CXXFLAGS_ORIG" - # check to see if stl is in the std namespace if test $ac_cv_prog_gxx = no; then CXXFLAGS_ORIG="$CXXFLAGS" CXXFLAGS="$CMAKE_ANSI_CXXFLAGS $CXXFLAGS" echo $ac_n "checking whether the std namespace is supported""... $ac_c" 1>&6 -echo "configure:1191: checking whether the std namespace is supported" >&5 +echo "configure:1195: checking whether the std namespace is supported" >&5 ac_ext=C # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. @@ -1197,7 +1201,7 @@ ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftes cross_compiling=$ac_cv_prog_cxx_cross cat > conftest.$ac_ext < @@ -1207,7 +1211,7 @@ int main() { ; return 0; } EOF -if { (eval echo configure:1211: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1215: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""yes" 1>&6 @@ -1217,7 +1221,10 @@ else cat conftest.$ac_ext >&5 rm -rf conftest* - CMAKE_NO_STD_NAMESPACE=1 + cat >> confdefs.h <<\EOF +#define CMAKE_NO_STD_NAMESPACE 1 +EOF + echo "$ac_t""no" 1>&6 fi @@ -1232,13 +1239,12 @@ cross_compiling=$ac_cv_prog_cc_cross CXXFLAGS="$CXXFLAGS_ORIG" fi - # check to see if for scoping is supported if test $ac_cv_prog_gxx = no; then CXXFLAGS_ORIG="$CXXFLAGS" CXXFLAGS="$CMAKE_ANSI_CXXFLAGS $CXXFLAGS" echo $ac_n "checking ansi for scope support""... $ac_c" 1>&6 -echo "configure:1242: checking ansi for scope support" >&5 +echo "configure:1248: checking ansi for scope support" >&5 ac_ext=C # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. @@ -1248,7 +1254,7 @@ ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftes cross_compiling=$ac_cv_prog_cxx_cross cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1267: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* echo "$ac_t""yes" 1>&6 @@ -1267,7 +1273,10 @@ else cat conftest.$ac_ext >&5 rm -rf conftest* - CMAKE_NO_ANSI_FOR_SCOPE=1 + cat >> confdefs.h <<\EOF +#define CMAKE_NO_ANSI_FOR_SCOPE 1 +EOF + echo "$ac_t""no" 1>&6 fi @@ -1282,14 +1291,13 @@ cross_compiling=$ac_cv_prog_cc_cross CXXFLAGS="$CXXFLAGS_ORIG" fi - # find make to use to build cmake, prefer gmake for ac_prog in gmake make do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:1293: checking for $ac_word" >&5 +echo "configure:1301: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_path_RUNMAKE'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1463,10 +1471,6 @@ s%@CMAKE_ROOT_DIR@%$CMAKE_ROOT_DIR%g s%@CMAKE_CONFIG_DIR@%$CMAKE_CONFIG_DIR%g s%@CMAKE_ANSI_CFLAGS@%$CMAKE_ANSI_CFLAGS%g s%@CMAKE_ANSI_CXXFLAGS@%$CMAKE_ANSI_CXXFLAGS%g -s%@CMAKE_NO_ANSI_STREAM_HEADERS@%$CMAKE_NO_ANSI_STREAM_HEADERS%g -s%@CMAKE_NO_ANSI_STRING_STREAM@%$CMAKE_NO_ANSI_STRING_STREAM%g -s%@CMAKE_NO_STD_NAMESPACE@%$CMAKE_NO_STD_NAMESPACE%g -s%@CMAKE_NO_ANSI_FOR_SCOPE@%$CMAKE_NO_ANSI_FOR_SCOPE%g s%@RUNMAKE@%$RUNMAKE%g CEOF diff --git a/configure.in b/configure.in index 6f1a039f6..57db2a4f6 100644 --- a/configure.in +++ b/configure.in @@ -133,13 +133,12 @@ if test $ac_cv_prog_gxx = no; then ],,[ AC_MSG_RESULT(yes) ],[ - CMAKE_NO_ANSI_STREAM_HEADERS=1 + AC_DEFINE(CMAKE_NO_ANSI_STREAM_HEADERS) AC_MSG_RESULT(no) ]) AC_LANG_RESTORE CXXFLAGS="$CXXFLAGS_ORIG" fi -AC_SUBST(CMAKE_NO_ANSI_STREAM_HEADERS) # check non-g++ compilers to see if they have std::stringstream CXXFLAGS_ORIG="$CXXFLAGS" @@ -152,12 +151,11 @@ AC_TRY_COMPILE([ ],,[ AC_MSG_RESULT(yes) ],[ -CMAKE_NO_ANSI_STRING_STREAM=1 +AC_DEFINE(CMAKE_NO_ANSI_STRING_STREAM) AC_MSG_RESULT(no) ]) AC_LANG_RESTORE CXXFLAGS="$CXXFLAGS_ORIG" -AC_SUBST(CMAKE_NO_ANSI_STRING_STREAM) # check to see if stl is in the std namespace if test $ac_cv_prog_gxx = no; then @@ -172,13 +170,12 @@ if test $ac_cv_prog_gxx = no; then ],,[ AC_MSG_RESULT(yes) ],[ - CMAKE_NO_STD_NAMESPACE=1 + AC_DEFINE(CMAKE_NO_STD_NAMESPACE) AC_MSG_RESULT(no) ]) AC_LANG_RESTORE CXXFLAGS="$CXXFLAGS_ORIG" fi -AC_SUBST(CMAKE_NO_STD_NAMESPACE) # check to see if for scoping is supported if test $ac_cv_prog_gxx = no; then @@ -192,13 +189,12 @@ if test $ac_cv_prog_gxx = no; then ],,[ AC_MSG_RESULT(yes) ],[ - CMAKE_NO_ANSI_FOR_SCOPE=1 + AC_DEFINE(CMAKE_NO_ANSI_FOR_SCOPE) AC_MSG_RESULT(no) ]) AC_LANG_RESTORE CXXFLAGS="$CXXFLAGS_ORIG" fi -AC_SUBST(CMAKE_NO_ANSI_FOR_SCOPE) # find make to use to build cmake, prefer gmake AC_PATH_PROGS(RUNMAKE, gmake make)