configure.ac: declare AM_CFLAGS

Moved generic compiler options to AM_CFLAGS.  MPD_CFLAGS/MPD_LIBS will
hopefully fade away one day, in favor of more fine-grained variables.
This commit is contained in:
Max Kellermann 2009-02-25 16:46:07 +01:00
parent 6fdaa49668
commit bdb3129f18
3 changed files with 6 additions and 4 deletions

View File

@ -6,7 +6,7 @@ AM_LDFLAGS = $(GLIB_LIBS)
bin_PROGRAMS = src/mpd bin_PROGRAMS = src/mpd
src_mpd_CFLAGS = $(MPD_CFLAGS) src_mpd_CFLAGS = $(AM_CFLAGS) $(MPD_CFLAGS)
src_mpd_CPPFLAGS = $(AM_CPPFLAGS) \ src_mpd_CPPFLAGS = $(AM_CPPFLAGS) \
$(SQLITE_CFLAGS) \ $(SQLITE_CFLAGS) \
$(ID3TAG_CFLAGS) \ $(ID3TAG_CFLAGS) \

View File

@ -24,6 +24,8 @@ dnl
dnl declare variables dnl declare variables
dnl dnl
AC_SUBST(AM_CFLAGS,"")
AC_SUBST(MPD_LIBS) AC_SUBST(MPD_LIBS)
AC_SUBST(MPD_CFLAGS) AC_SUBST(MPD_CFLAGS)
MPD_LIBS="" MPD_LIBS=""
@ -1105,7 +1107,7 @@ AC_ARG_ENABLE(werror,
ENABLE_WERROR=no) ENABLE_WERROR=no)
if test "x$ENABLE_WERROR" = xyes; then if test "x$ENABLE_WERROR" = xyes; then
MPD_CFLAGS="$MPD_CFLAGS -Werror -pedantic-errors" AM_CFLAGS="$AM_CFLAGS -Werror -pedantic-errors"
fi fi
AC_ARG_ENABLE(debug, AC_ARG_ENABLE(debug,
@ -1116,7 +1118,7 @@ AC_ARG_ENABLE(debug,
#if test "x$ENABLE_DEBUG" = xno; then #if test "x$ENABLE_DEBUG" = xno; then
# don't set NDEBUG for now, until MPD is stable # don't set NDEBUG for now, until MPD is stable
#MPD_CFLAGS="$MPD_CFLAGS -DNDEBUG" #AM_CFLAGS="$AM_CFLAGS -DNDEBUG"
#fi #fi
AC_ARG_ENABLE(gprof, AC_ARG_ENABLE(gprof,

View File

@ -12,7 +12,7 @@ AC_DEFUN([MPD_CHECK_FLAG],[
]) ])
if eval "test x`echo '$mpd_check_cflag_'$var` = xyes" if eval "test x`echo '$mpd_check_cflag_'$var` = xyes"
then then
MPD_CFLAGS="$MPD_CFLAGS $1" AM_CFLAGS="$AM_CFLAGS $1"
fi fi
]) ])
]) ])