Do not change user variable CFLAGS in configure.ac
This commit is contained in:
parent
60cb3f67f2
commit
7036859823
13
configure.ac
13
configure.ac
|
@ -20,6 +20,10 @@ dnl NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
|||
dnl LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
||||
dnl OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
dnl WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
dnl Do not change user variables!
|
||||
dnl http://www.gnu.org/software/automake/manual/html_node/Flag-Variables-Ordering.html
|
||||
|
||||
AC_PREREQ(2.61)
|
||||
AC_INIT([nghttp2], [0.6.8-DEV], [t-tujikawa@users.sourceforge.net])
|
||||
LT_PREREQ([2.2.6])
|
||||
|
@ -522,6 +526,9 @@ case "${host}" in
|
|||
;;
|
||||
esac
|
||||
|
||||
ac_save_CFLAGS=$CFLAGS
|
||||
CFLAGS=
|
||||
|
||||
if test "x$werror" != "xno"; then
|
||||
AX_CHECK_COMPILE_FLAG([-Wall], [CFLAGS="$CFLAGS -Wall"])
|
||||
AX_CHECK_COMPILE_FLAG([-Wextra], [CFLAGS="$CFLAGS -Wextra"])
|
||||
|
@ -554,6 +561,11 @@ if test "x$werror" != "xno"; then
|
|||
AX_CHECK_COMPILE_FLAG([-Wheader-guard], [CFLAGS="$CFLAGS -Wheader-guard"])
|
||||
fi
|
||||
|
||||
WARNCFLAGS=$CFLAGS
|
||||
CFLAGS=$ac_save_CFLAGS
|
||||
|
||||
AC_SUBST([WARNCFLAGS])
|
||||
|
||||
if test "x$debug" != "xno"; then
|
||||
AC_DEFINE([DEBUGBUILD], [1], [Define to 1 to enable debug output.])
|
||||
fi
|
||||
|
@ -609,6 +621,7 @@ AC_MSG_NOTICE([summary of build options:
|
|||
Install prefix: ${prefix}
|
||||
C compiler: ${CC}
|
||||
CFLAGS: ${CFLAGS}
|
||||
WARNCFLAGS: ${WARNCFLAGS}
|
||||
LDFLAGS: ${LDFLAGS}
|
||||
LIBS: ${LIBS}
|
||||
CPPFLAGS: ${CPPFLAGS}
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
|
||||
if ENABLE_EXAMPLES
|
||||
|
||||
AM_CFLAGS = $(WARNCFLAGS)
|
||||
AM_CPPFLAGS = \
|
||||
-Wall \
|
||||
-I$(top_srcdir)/lib/includes \
|
||||
|
|
|
@ -24,7 +24,7 @@ SUBDIRS = includes
|
|||
|
||||
EXTRA_DIST = Makefile.msvc
|
||||
|
||||
AM_CFLAGS = -Wall
|
||||
AM_CFLAGS = $(WARNCFLAGS)
|
||||
AM_CPPFLAGS = -I$(srcdir)/includes -I$(builddir)/includes @DEFS@
|
||||
|
||||
pkgconfigdir = $(libdir)/pkgconfig
|
||||
|
|
|
@ -26,6 +26,7 @@ bin_PROGRAMS =
|
|||
check_PROGRAMS =
|
||||
TESTS =
|
||||
|
||||
AM_CFLAGS = $(WARNCFLAGS)
|
||||
AM_CPPFLAGS = \
|
||||
-Wall \
|
||||
-I$(top_srcdir)/lib/includes \
|
||||
|
|
|
@ -60,7 +60,10 @@ failmalloc_LDADD = $(main_LDADD)
|
|||
failmalloc_LDFLAGS = $(main_LDFLAGS)
|
||||
endif # ENABLE_FAILMALLOC
|
||||
|
||||
AM_CFLAGS = -Wall -I${top_srcdir}/lib -I${top_srcdir}/lib/includes -I${top_builddir}/lib/includes \
|
||||
AM_CFLAGS = $(WARNCFLAGS) \
|
||||
-I${top_srcdir}/lib \
|
||||
-I${top_srcdir}/lib/includes \
|
||||
-I${top_builddir}/lib/includes \
|
||||
@CUNIT_CFLAGS@ @DEFS@
|
||||
|
||||
TESTS = main
|
||||
|
|
Loading…
Reference in New Issue