comparison configure.ac @ 670:9e29bf7ce1ff

* Permit user CFLAGS, if given, to override our CXXFLAGS if no user CXXFLAGS is given
author Chris Cannam
date Tue, 08 Mar 2011 10:21:21 +0000
parents 1bb85de8c5b9
children 97fbb6b3e749
comparison
equal deleted inserted replaced
669:a41b4e30e3d9 670:9e29bf7ce1ff
8 # the user's preferences. We need to ensure CXXFLAGS is only set if 8 # the user's preferences. We need to ensure CXXFLAGS is only set if
9 # the user has expressly set it. So, save the user's (or empty) 9 # the user has expressly set it. So, save the user's (or empty)
10 # setting now and restore it after Autoconf has done its bit of 10 # setting now and restore it after Autoconf has done its bit of
11 # piddling about. 11 # piddling about.
12 USER_CXXFLAGS="$CXXFLAGS" 12 USER_CXXFLAGS="$CXXFLAGS"
13
14 # If the user supplied CFLAGS but not CXXFLAGS, use CFLAGS instead
15 if test x"$USER_CXXFLAGS" = x; then
16 if test x"$CFLAGS" != x; then
17 USER_CXXFLAGS="$CFLAGS"
18 fi
19 fi
13 20
14 AC_LANG_CPLUSPLUS 21 AC_LANG_CPLUSPLUS
15 22
16 AC_PROG_CC 23 AC_PROG_CC
17 AC_PROG_CXX 24 AC_PROG_CXX