wscript: check for pd header, define VERSION
[pd-aubio.git] / configure.ac
1 dnl Process this file with autoconf to produce a configure script
2
3 dnl Init autoconf
4 AC_INIT([pd-aubio], [0.0.1])
5 AC_CONFIG_SRCDIR([aubio_setup.c])
6
7 dnl Init automake
8 AM_INIT_AUTOMAKE([dist-bzip2 no-define])
9
10 dnl Check for Puredata
11 AC_CHECK_HEADER([m_pd.h],PUREDATA=y,AC_MSG_WARN([Puredata header not found.]))
12 AM_CONDITIONAL(PUREDATAFOUND, test "${PUREDATA}" = "y")
13
14 dnl Check for pkg-config
15 AC_PATH_PROG(PKG_CONFIG,pkg-config,no)
16
17 dnl Check for aubio
18 PKG_CHECK_MODULES(AUBIO, aubio >= 0.4.0, HAVE_AUBIO=1)
19
20 AM_CONDITIONAL(MINGW, false)
21 AM_CONDITIONAL(DARWIN, false)
22 case "${host}" in
23 *mingw* | *cygwin*)
24   mingw32_support="yes"
25   AC_CHECK_HEADER(windows.h)
26   AM_CONDITIONAL(MINGW, true)
27   LDFLAGS="$LDFLAGS -no-undefined"
28   ;;
29 *darwin* | *rhapsody* | *macosx*)
30   AC_ISC_POSIX
31   AM_CONDITIONAL(DARWIN, true)
32   ;;
33 *)
34   AC_ISC_POSIX
35   ;;
36 esac
37
38 dnl Create Makefiles
39 AC_OUTPUT([
40     Makefile
41 ])