configure.ac: added switch for test programs

The switch syntax is "--enable-test".  There are no test programs yet.
This commit is contained in:
Max Kellermann 2009-02-18 19:27:05 +01:00
parent fcf65de46b
commit 54387d1451
2 changed files with 23 additions and 0 deletions

View File

@ -7,6 +7,22 @@ EXTRA_DIST = $(doc_DATA) autogen.sh \
$(wildcard scripts/*.sh) scripts/mpd.spec \
.gitignore
AM_CFLAGS = -I$(srcdir)/src $(GLIB_CFLAGS)
AM_LDFLAGS = $(GLIB_LIBS)
#
# Test programs
#
if ENABLE_TEST
noinst_PROGRAMS =
endif
sparse-check test:
$(MAKE) -C src $@

View File

@ -1123,6 +1123,13 @@ if test "x$ENABLE_GPROF" = xyes; then
MPD_CFLAGS="$MPD_CFLAGS -pg"
fi
AC_ARG_ENABLE(test,
AS_HELP_STRING([--enable-test],
[Build the test programs (default: disabled)]),,
enable_test=no)
AM_CONDITIONAL(ENABLE_TEST, test "x$enable_test" = xyes)
dnl
dnl CFLAGS