--- linuxsampler/trunk/configure.in 2010/10/04 22:11:53 2138 +++ linuxsampler/trunk/configure.in 2012/07/08 14:44:47 2356 @@ -5,7 +5,7 @@ LINUXSAMPLER_RELEASE_MAJOR=1 LINUXSAMPLER_RELEASE_MINOR=0 -LINUXSAMPLER_RELEASE_BUILD=0.cvs9 +LINUXSAMPLER_RELEASE_BUILD=0.svn18 #------------------------------------------------------------------------------------ # The following is the libtool / shared library version. This doesn't have to @@ -78,6 +78,19 @@ fi AC_SUBST([CXX_CPU_SWITCH]) +mac=no +linux=no +case "$host" in + *-*-darwin*) + mac=yes + ;; + *-*-linux*) + linux=yes + ;; +esac +AM_CONDITIONAL(LINUX, test "$linux" = yes) +AM_CONDITIONAL(MAC, test "$mac" = yes) + # check if we're on MS Windows AC_CHECK_HEADERS( mmsystem.h, @@ -499,10 +512,9 @@ AM_CONDITIONAL(HAVE_DSSI, test $config_have_dssi = "yes") # LV2 -PKG_CHECK_MODULES(LV2, lv2core, config_have_lv2="yes", config_have_lv2="no") -if test $config_have_lv2 = "no"; then - AC_CHECK_HEADER(lv2.h, config_have_lv2="yes", config_have_lv2="no") -fi +PKG_CHECK_MODULES(LV2, lv2 >= 1.0.0, config_have_lv2="yes", config_have_lv2="no") +AC_SUBST(LV2_CFLAGS) +AC_SUBST(LV2_LIBS) AM_CONDITIONAL(HAVE_LV2, test $config_have_lv2 = "yes") # VST @@ -528,6 +540,21 @@ AM_CONDITIONAL(HAVE_AU, test $config_have_au = "yes") AM_CONDITIONAL(HAVE_AUFLAGS, test "$AUFLAGS" != "") +if test $config_have_au = "yes" ; then + if test "x$DEVELOPER_EXTRAS_DIR" = "x" ; then + if test -d /Developer/Extras ; then + DEVELOPER_EXTRAS_DIR=/Developer/Extras + else + DEVELOPER_EXTRAS_DIR=/Developer/Examples + fi + fi + AC_SUBST(DEVELOPER_EXTRAS_DIR) +fi + +if test "x$MAC_PLUGIN_INSTALL_DIR" = "x" ; then + MAC_PLUGIN_INSTALL_DIR=/Library/Audio/Plug-Ins +fi +AC_SUBST(MAC_PLUGIN_INSTALL_DIR) # have we found at least one MIDI input and one audio output driver ? if test "$have_midi_input_driver" = "false"; then @@ -600,7 +627,14 @@ # Check for Vorbis support in libsndfile linuxsampler_save_CFLAGS=$CFLAGS CFLAGS="$SNDFILE_CFLAGS $CFLAGS" -AC_CHECK_DECLS([SF_FORMAT_VORBIS], [], [] ,[[#include ]]) +AC_CHECK_DECLS([SF_FORMAT_VORBIS], [], [], [[#include ]]) + +# Check for loop functionality in libsndfile +AC_CHECK_MEMBERS([SF_INSTRUMENT.loops],, + [AC_MSG_WARN([Your version of libsndfile does not support + reading of loop information. LinuxSampler will not be able to + extract loop information from sample files.])], + [#include ]) CFLAGS=$linuxsampler_save_CFLAGS # Instruments DB feature (requires SQLite 3.3) @@ -698,13 +732,14 @@ AC_DEFINE_UNQUOTED(CONFIG_RT_EXCEPTIONS, 1, [Define to 1 to allow exceptions in the realtime context.]) fi +config_pthread_testcancel="$mac" AC_ARG_ENABLE(pthread-testcancel, [ --enable-pthread-testcancel - Enable pthread_testcancel() calls and avoid asynchronous - cancel of pthreads (default=no).], + Enable pthread_testcancel() calls and avoid + asynchronous cancel of pthreads (default=yes + for Mac targets, no otherwise).], [config_pthread_testcancel="$enableval"], - [config_pthread_testcancel="no"] -) + []) if test "$config_pthread_testcancel" = "yes"; then AC_DEFINE_UNQUOTED(CONFIG_PTHREAD_TESTCANCEL, 1, [Define to 1 to enable pthread_testcancel() calls.]) fi