1 dnl Process this file with autoconf to porduce a configure script
6 AUBIO_VERSION=${AUBIO_MAJOR_VERSION}.${AUBIO_MINOR_VERSION}.${AUBIO_PATCH_VERSION}${AUBIO_VERSION_STATUS}
7 VERSION=${AUBIO_VERSION}
10 AM_INIT_AUTOMAKE(${PACKAGE}, ${VERSION})
12 AC_PREFIX_DEFAULT(/usr)
14 dnl enable optimization
19 [ --enable-debug[[=value]] compile with debug [[default=no]]],
22 if test "$with_debug" = "yes"
24 AC_DEFINE(DEBUG,1,[Define to enable debug])
30 [ --enable-warnme[[=value]] compile with all -W [[default=yes]]],
33 if test "$with_warnme" = "yes"
35 ALL_CWARNINGS="-Wall -Werror -Wmissing-prototypes -Wmissing-declarations -Wno-char-subscripts -Wno-unknown-pragmas"
36 CFLAGS="$CFLAGS $ALL_CWARNINGS"
43 dnl Check for programs
45 if test "$ac_cv_prog_cc" = "no" ; then
46 AC_MSG_ERROR([*** No C compiler found !])
56 AC_CONFIG_HEADERS(src/config.h)
57 AC_CONFIG_FILES(aubio.pc)
62 AC_CHECK_HEADER(windows.h)
69 dnl Check for libraries
70 AC_CHECK_LIB(pthread, pthread_create)
72 dnl Check for header files
74 AC_CHECK_HEADERS([string.h stdlib.h stdio.h math.h errno.h stdarg.h unistd.h signal.h],,)
75 AC_CHECK_HEADERS(complex.h,,AC_MSG_ERROR([Ouch! missing complex.h header]))
76 AC_CHECK_HEADERS(fftw3.h ,,AC_MSG_ERROR([Ouch! missing fftw3.h headeri]))
78 dnl check for pkg-config
79 AC_PATH_PROG(PKG_CONFIG,pkg-config,no)
81 dnl Check for required libraries
82 PKG_CHECK_MODULES(FFTWLIB, fftw3 >= 3.0.0, FFTW3_SUPPORT=1)
83 if test "${FFTW3_SUPPORT}" = "1"; then
84 AC_DEFINE(FFTW3_SUPPORT,1,[Define to enable fftw3 support])
86 PKG_CHECK_MODULES(SNDLIB, sndfile >= 1.0.4, SNDLIB_SUPPORT=1)
87 PKG_CHECK_MODULES(SAMPLERATE, samplerate >= 0.0.15, SAMPLERATE_SUPPORT=1)
89 if test "${SNDLIB_SUPPORT}" = "1"; then
90 AC_DEFINE(SNDLIB_SUPPORT,1,[Define to enable libsndfile support])
94 dnl Check for optional libraries
96 [ --enable-fftw3f[[=value]] compile with fftw3f [[default=no]]],
99 if test "$with_fftw3f" = "yes"; then
100 PKG_CHECK_MODULES(FFTWLIB, fftw3f >= 3.0.0, FFTW3F_SUPPORT=1)
102 if test "${FFTW3F_SUPPORT}" = "1"; then
103 AC_DEFINE(FFTW3F_SUPPORT,1,[Define to enable fftw3f support])
107 [ --enable-jack[[=value]] compile with jack [[default=no]]],
110 if test "$with_jack" = "yes"
112 PKG_CHECK_MODULES(JACK, jack >= 0.15.0, JACK_SUPPORT=1)
113 if test "${JACK_SUPPORT}" = "1"; then
114 AC_DEFINE(JACK_SUPPORT,1,[Define to enable jack support])
119 [ --enable-alsa[[=value]] compile with alsa [[default=no]]],
122 if test "$with_alsa" = "yes"
124 PKG_CHECK_MODULES(ALSA, alsa >= 0.0.9, ALSA_SUPPORT=1)
125 if test "${ALSA_SUPPORT}" = "1"; then
126 AC_DEFINE(ALSA_SUPPORT,1,[Define to enable alsa support])
130 AC_ARG_ENABLE(ladcca,
131 [ --enable-ladcca[[=value]] compile with ladcca [[default=no]]],
134 if test "$with_ladcca" = "yes"
136 PKG_CHECK_MODULES(LADCCA, ladcca-1.0 >= 0.4.0, LADCCA_SUPPORT=1)
137 if test "${LADCCA_SUPPORT}" = "1"; then
138 AC_DEFINE(LADCCA_SUPPORT,1,[Define to enable ladcca support])
151 python/aubio/Makefile
153 plugins/audacity/Makefile
154 plugins/audacity/plug-ins/Makefile
155 plugins/wavesurfer/Makefile
160 echo "**************************************************************"
162 if test "${FFTW3F_SUPPORT}" = "1"; then
163 echo "Fftw3: yes (fftw3f)"
165 if test "${FFTW3_SUPPORT}" = "1"; then
171 if test "${SNDLIB_SUPPORT}" = "1"; then
172 echo "Libsndfile: yes"
174 echo "Libsndfile: no"
176 if test "${SAMPLERATE_SUPPORT}" = "1"; then
177 echo "Libsamplerate: yes"
179 echo "Libsamplerate: no"
181 if test "${JACK_SUPPORT}" = "1"; then
186 if test "${ALSA_SUPPORT}" = "1"; then
187 echo "ALSA midi: yes"
191 if test "${LADCCA_SUPPORT}" = "1"; then
196 echo "**************************************************************"
197 echo Configuration completed successfully. Type \'make\' to build ${PACKAGE}