Chris@12: Chris@12: AC_INIT(vamp-plugin-sdk, 2.4, cannam@all-day-breakfast.com) Chris@12: Chris@12: AC_CONFIG_SRCDIR(vamp/vamp.h) Chris@12: AC_PROG_CXX Chris@12: AC_HEADER_STDC Chris@12: AC_C_BIGENDIAN Chris@12: Chris@12: if pkg-config --modversion vamp-sdk >/dev/null 2>&1; then Chris@12: echo "WARNING: A version of the Vamp plugin SDK is already installed." Chris@12: echo " Expect worries and sorrows if you install a new version" Chris@12: echo " without removing the old one first. (Continuing)" Chris@12: fi Chris@12: Chris@12: AC_SEARCH_LIBS([dlopen],[dl]) Chris@12: Chris@12: dnl See if the user wants to build programs, or just the SDK Chris@12: AC_ARG_ENABLE(programs, [AS_HELP_STRING([--enable-programs], Chris@12: [enable building of example host and RDF generator [default=yes]])], Chris@12: PROGS_ARGUMENT=$enableval, Chris@12: PROGS_ARGUMENT="yes") Chris@12: Chris@12: dnl if the user wants progs, then we need to check for libsndfile Chris@12: if test "x$PROGS_ARGUMENT" = "xyes" ; then Chris@12: PKG_CHECK_MODULES([SNDFILE],[sndfile],have_sndfile="yes",have_sndfile="no") Chris@12: if test "x$have_sndfile" = "xyes" ; then Chris@12: dnl all good, build everything Chris@12: TARGETS="sdk plugins host rdfgen test" Chris@12: else Chris@12: dnl no libsndfile - can't build host! Chris@12: AC_MSG_ERROR([libsndfile not found - cannot build example Vamp host! Chris@12: If you don't want to build the host, configure with --disable-programs.]) Chris@12: fi Chris@12: else Chris@12: dnl user didn't want programs - so we won't build them Chris@12: TARGETS="sdk plugins" Chris@12: fi Chris@12: Chris@12: AC_SUBST(SNDFILE_CFLAGS) Chris@12: AC_SUBST(SNDFILE_LIBS) Chris@12: AC_SUBST(TARGETS) Chris@12: Chris@12: changequote(,)dnl Chris@12: if test "x$GCC" = "xyes"; then Chris@12: case " $CXXFLAGS " in Chris@12: *[\ \ ]-fPIC\ -Wall[\ \ ]*) ;; Chris@12: *) CXXFLAGS="$CXXFLAGS -fPIC -Wall" ;; Chris@12: esac Chris@12: fi Chris@12: changequote([,])dnl Chris@12: Chris@12: AC_SUBST(CXXFLAGS) Chris@12: AC_OUTPUT([Makefile]) Chris@12: