To check out this repository please hg clone the following URL, or open the URL using EasyMercurial or your preferred Mercurial client.

Statistics Download as Zip
| Branch: | Tag: | Revision:

root / configure.ac @ 526:459cddd7e64a

History | View | Annotate | Download (1.75 KB)

1

    
2
AC_INIT(vamp-plugin-sdk, 2.8, cannam@all-day-breakfast.com)
3

    
4
AC_CONFIG_SRCDIR(vamp/vamp.h)
5
AC_PROG_CXX
6
AC_HEADER_STDC
7
AC_C_BIGENDIAN
8

    
9
# We now require C++11
10
AX_CXX_COMPILE_STDCXX_11(noext)
11

    
12
if pkg-config --modversion vamp-sdk >/dev/null 2>&1; then
13
  echo "WARNING: A version of the Vamp plugin SDK is already installed."
14
  echo "         Expect worries and sorrows if you install a new version"
15
  echo "         without removing the old one first.  (Continuing)"
16
fi
17

    
18
AC_SEARCH_LIBS([dlopen],[dl])
19

    
20
dnl See if the user wants to build programs, or just the SDK
21
AC_ARG_ENABLE(programs,	[AS_HELP_STRING([--enable-programs],
22
	[enable building of example host and RDF generator [default=yes]])],
23
	PROGS_ARGUMENT=$enableval,
24
	PROGS_ARGUMENT="yes")
25

    
26
dnl if the user wants progs, then we need to check for libsndfile
27
if test "x$PROGS_ARGUMENT" = "xyes" ; then 
28
	PKG_CHECK_MODULES([SNDFILE],[sndfile],have_sndfile="yes",have_sndfile="no")
29
	if test "x$have_sndfile" = "xyes" ; then
30
		dnl all good, build everything
31
		TARGETS="sdk plugins host rdfgen test"
32
	else
33
		dnl no libsndfile - can't build host!
34
		AC_MSG_ERROR([libsndfile not found - cannot build example Vamp host!
35
If you don't want to build the host, configure with --disable-programs.])
36
	fi
37
else
38
	dnl user didn't want programs - so we won't build them
39
	TARGETS="sdk plugins"
40
fi
41

    
42
AC_SUBST(SNDFILE_CFLAGS)
43
AC_SUBST(SNDFILE_LIBS)
44
AC_SUBST(TARGETS)
45

    
46
changequote(,)dnl
47
if test "x$GCC" = "xyes"; then
48
  case " $CXXFLAGS " in
49
    *[\ \	]-fPIC\ -Wall[\ \	]*) ;;
50
    *) CXXFLAGS="$CXXFLAGS -fPIC -Wall -Wextra" ;;
51
  esac
52
  case " $CFLAGS " in
53
    *[\ \	]-fPIC\ -Wall[\ \	]*) ;;
54
    *) CFLAGS="$CFLAGS -fPIC -Wall -Wextra" ;;
55
  esac
56
  CXXFLAGS="$CXXFLAGS -std=c++11"
57
fi
58
changequote([,])dnl
59

    
60
AC_SUBST(CXXFLAGS)
61
AC_SUBST(CFLAGS)
62
AC_OUTPUT([Makefile])
63