/[svn]/linuxsampler/trunk/configure.ac
ViewVC logotype

Diff of /linuxsampler/trunk/configure.ac

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1375 by schoenebeck, Wed Oct 3 18:41:09 2007 UTC revision 1651 by persson, Sun Jan 27 15:07:11 2008 UTC
# Line 4  AC_INIT(configure.in) Line 4  AC_INIT(configure.in)
4  # LinuxSampler's / liblinuxsampler's "official" release version:  # LinuxSampler's / liblinuxsampler's "official" release version:
5    
6  LINUXSAMPLER_RELEASE_MAJOR=0  LINUXSAMPLER_RELEASE_MAJOR=0
7  LINUXSAMPLER_RELEASE_MINOR=4  LINUXSAMPLER_RELEASE_MINOR=5
8  LINUXSAMPLER_RELEASE_BUILD=0.7cvs  LINUXSAMPLER_RELEASE_BUILD=1
9    
10  #------------------------------------------------------------------------------------  #------------------------------------------------------------------------------------
11  # The following is the libtool / shared library version. This doesn't have to  # The following is the libtool / shared library version. This doesn't have to
# Line 24  LINUXSAMPLER_RELEASE_BUILD=0.7cvs Line 24  LINUXSAMPLER_RELEASE_BUILD=0.7cvs
24  #  6. If any interfaces have been removed since the last public release, then set age  #  6. If any interfaces have been removed since the last public release, then set age
25  #     to 0.  #     to 0.
26    
27  LIBLINUXSAMPLER_LT_CURRENT=0  LIBLINUXSAMPLER_LT_CURRENT=2
28  LIBLINUXSAMPLER_LT_REVISION=0  LIBLINUXSAMPLER_LT_REVISION=0
29  LIBLINUXSAMPLER_LT_AGE=0  LIBLINUXSAMPLER_LT_AGE=1
30  SHARED_VERSION_INFO="$LIBLINUXSAMPLER_LT_CURRENT:$LIBLINUXSAMPLER_LT_REVISION:$LIBLINUXSAMPLER_LT_AGE"  SHARED_VERSION_INFO="$LIBLINUXSAMPLER_LT_CURRENT:$LIBLINUXSAMPLER_LT_REVISION:$LIBLINUXSAMPLER_LT_AGE"
31    
32  #------------------------------------------------------------------------------------  #------------------------------------------------------------------------------------
33  # the LSCP specification version this LinuSampler release complies with:  # the LSCP specification version this LinuSampler release complies with:
34    
35  LSCP_RELEASE_MAJOR=1  LSCP_RELEASE_MAJOR=1
36  LSCP_RELEASE_MINOR=2  LSCP_RELEASE_MINOR=3
37    
38  AC_DEFINE_UNQUOTED(LSCP_RELEASE_MAJOR, ${LSCP_RELEASE_MAJOR}, [LSCP spec major version this release complies with.])  AC_DEFINE_UNQUOTED(LSCP_RELEASE_MAJOR, ${LSCP_RELEASE_MAJOR}, [LSCP spec major version this release complies with.])
39  AC_DEFINE_UNQUOTED(LSCP_RELEASE_MINOR, ${LSCP_RELEASE_MINOR}, [LSCP spec minor version this release complies with.])  AC_DEFINE_UNQUOTED(LSCP_RELEASE_MINOR, ${LSCP_RELEASE_MINOR}, [LSCP spec minor version this release complies with.])
# Line 52  AC_SUBST(target_cpu) Line 52  AC_SUBST(target_cpu)
52  AC_SUBST(target_os)  AC_SUBST(target_os)
53  AC_SUBST(target_vendor)  AC_SUBST(target_vendor)
54    
55    PKG_PROG_PKG_CONFIG
56    
57  ###########################################################################  ###########################################################################
58  # General Checks  # General Checks
# Line 79  if ! echo "X $CXXFLAGS " | grep -q -- " Line 80  if ! echo "X $CXXFLAGS " | grep -q -- "
80  fi  fi
81  AC_SUBST([CXX_CPU_SWITCH])  AC_SUBST([CXX_CPU_SWITCH])
82    
83    # check if we're on MS Windows
84    AC_CHECK_HEADERS(
85        mmsystem.h,
86        have_windows=1,
87        have_windows=0
88    )
89    AM_CONDITIONAL(HAVE_WINDOWS, test $have_windows = "1")
90    
91  AC_MSG_CHECKING([whether UNIX98 compatible])  AC_MSG_CHECKING([whether UNIX98 compatible])
92  AC_LANG_SAVE  AC_LANG_SAVE
93  AC_LANG_C  AC_LANG_C
# Line 101  have_unix98="no" Line 110  have_unix98="no"
110  )  )
111  AC_LANG_RESTORE  AC_LANG_RESTORE
112  AC_MSG_RESULT([$have_unix98])  AC_MSG_RESULT([$have_unix98])
113  if test "$have_unix98" = "no"; then  if test "$have_unix98" = "no" -a "have_windows" = "0"; then
114      if test "x$HAVE_UNIX98" = "x"; then      if test "x$HAVE_UNIX98" = "x"; then
115          echo "LinuxSampler only runs on UNIX98 compatible systems, which is mandatory for"          echo "LinuxSampler only runs on UNIX98 compatible systems, which is mandatory for"
116          echo "pthread_mutexattr_settype() call in Mutex.cpp. You may want to run          echo "pthread_mutexattr_settype() call in Mutex.cpp. You may want to run
# Line 114  fi Line 123  fi
123  # check for <features.h>  # check for <features.h>
124  AC_CHECK_HEADERS(features.h)  AC_CHECK_HEADERS(features.h)
125    
126    # test for POSIX thread library
127    m4_ifdef([m4_include(m4/pthread.m4)],,
128                 [sinclude([m4/pthread.m4])])
129    ACX_PTHREAD
130    LIBS="$PTHREAD_LIBS $LIBS"
131    CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
132    CXXFLAGS="$CXXFLAGS $PTHREAD_CFLAGS"
133    CC="$PTHREAD_CC"
134    
135    # check for a bug in NPTL-enabled glibc
136    # (see Gentoo bug report #194076)
137    AC_ARG_ENABLE(nptl-bug-check,
138      [  --disable-nptl-bug-check
139                              Disable check for a bug in certain NPTL-enabled
140                              glibc versions that caused crashs.],
141      [config_check_nptl_bug="$enableval"],
142      [config_check_nptl_bug="yes"]
143    )
144    if test "$config_check_nptl_bug" = "yes"; then
145        m4_ifdef([m4_include(m4/nptl_bug.m4)],,
146                 [sinclude([m4/nptl_bug.m4])])
147        ACX_NPTL_GLIBC_BUG([
148            echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
149            echo "You seem to have a buggy PTHREAD library! LinuxSampler would"
150            echo "probably crash due to this. Please report us the system you are"
151            echo "using and/or file a bug report to the bug tracking system of"
152            echo "your distribution."
153            echo "If you have a NPTL-enabled glibc AND it was compiled for TLS as"
154            echo "well, you can try to circumvent this problem for now by setting"
155            echo "the environment variable LD_ASSUME_KERNEL=\"2.4.1\" , which"
156            echo "should cause this test to pass."
157            echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
158            AC_MSG_ERROR([possibly NPTL glibc bug detected])
159        ])
160    else
161        echo "NPTL glibc bug check disabled"
162    fi
163    
164    
165    
166  ###########################################################################  ###########################################################################
167  # Checks for available audio and MIDI systems / drivers  # Checks for available audio and MIDI systems / drivers
# Line 225  fi Line 273  fi
273  AM_CONDITIONAL(HAVE_JACK, test $have_jack = "1")  AM_CONDITIONAL(HAVE_JACK, test $have_jack = "1")
274  AC_DEFINE_UNQUOTED(HAVE_JACK,$have_jack,[Define to 1 if you have JACK installed.])  AC_DEFINE_UNQUOTED(HAVE_JACK,$have_jack,[Define to 1 if you have JACK installed.])
275    
276    # JACK MIDI
277    have_jack_midi=0
278    if test $have_jack = "1"; then
279       linuxsampler_save_CFLAGS=$CFLAGS
280       linuxsampler_save_LIBS=$LIBS
281       CFLAGS="$JACK_CFLAGS $CFLAGS"
282       LIBS="$JACK_LIBS $LIBS"
283       AC_CHECK_HEADER(jack/midiport.h, have_jack_midi=1, have_jack_midi=0)
284       if test $have_jack_midi = "1"; then
285         AC_CHECK_FUNCS(jack_midi_get_event_count)
286         AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <jack/midiport.h>]], [[
287             jack_midi_clear_buffer(0, 0);
288         ]])], [AC_DEFINE(JACK_MIDI_FUNCS_NEED_NFRAMES, 1,
289                 [Define to 1 if you have the old jack midi functions that need an nframes argument.])])
290       fi
291       CFLAGS=$linuxsampler_save_CFLAGS
292       LIBS=$linuxsampler_save_LIBS
293    fi
294    AM_CONDITIONAL(HAVE_JACK_MIDI, test $have_jack_midi = "1")
295    AC_DEFINE_UNQUOTED(HAVE_JACK_MIDI, $have_jack_midi,
296                       [Define to 1 if you have JACK with MIDI support installed.])
297    
298  # ARTS  # ARTS
299  AC_ARG_ENABLE(arts-driver,  AC_ARG_ENABLE(arts-driver,
300    [  --disable-arts-driver    [  --disable-arts-driver
# Line 247  fi Line 317  fi
317  AM_CONDITIONAL(HAVE_ARTS, test "$have_arts" = "1")  AM_CONDITIONAL(HAVE_ARTS, test "$have_arts" = "1")
318  AC_DEFINE_UNQUOTED(HAVE_ARTS,$have_arts,[Define to 1 if you have aRts installed.])  AC_DEFINE_UNQUOTED(HAVE_ARTS,$have_arts,[Define to 1 if you have aRts installed.])
319    
320    # ASIO AUDIO (Win32)
321    AC_ARG_ENABLE(asiosdk-dir,
322      [  --enable-asiosdk-dir
323                              Directory where the ASIO SDK is located, this automatically
324                              enables the compilation of the ASIO audio output driver.],
325      [config_asiosdk_dir="${enableval}"],
326      [config_asiosdk_dir="."]
327    )
328    AC_SUBST(config_asiosdk_dir)
329    
330    AC_ARG_ENABLE(asio-driver,
331      [  --disable-asio-driver
332                              Disable support for the Windows ASIO driver.],
333      [config_asio_driver="$enableval"],
334      [config_asio_driver="yes"]
335    )
336    have_asio=0
337    ASIOSDK_BASEDIR=
338    if test "$config_asio_driver" = "yes"; then
339        asiosdk_headerfile=$config_asiosdk_dir/ASIOSDK2/common/asio.h
340        echo -n "checking for ASIO headerfile: $asiosdk_headerfile ...."
341        if test -e $asiosdk_headerfile ; then
342            echo yes
343            have_asio=1
344            ASIOSDK_BASEDIR="$config_asiosdk_dir"
345        else
346            echo no
347            have_asio=0
348        fi
349        if test "$have_asio" = "1"; then
350            have_audio_output_driver="true"
351        fi
352    else
353        echo "Windows ASIO support disabled by configure script parameter"
354    fi
355    AC_SUBST(ASIOSDK_BASEDIR)
356    AM_CONDITIONAL(HAVE_ASIO, test $have_asio = "1")
357    AC_DEFINE_UNQUOTED(HAVE_ASIO,$have_asio,[Define to 1 if you have ASIO installed.])
358    
359  # MidiShare (Linux, OS X, Windows)  # MidiShare (Linux, OS X, Windows)
360  AC_ARG_ENABLE(midishare-driver,  AC_ARG_ENABLE(midishare-driver,
361    [  --disable-midishare-driver    [  --disable-midishare-driver
# Line 295  fi Line 404  fi
404  AM_CONDITIONAL(HAVE_COREMIDI, test $have_coremidi = "1")  AM_CONDITIONAL(HAVE_COREMIDI, test $have_coremidi = "1")
405  AC_DEFINE_UNQUOTED(HAVE_COREMIDI,$have_coremidi,[Define to 1 if you have CoreMIDI installed.])  AC_DEFINE_UNQUOTED(HAVE_COREMIDI,$have_coremidi,[Define to 1 if you have CoreMIDI installed.])
406    
407    # MME MIDI (Win32)
408    AC_ARG_ENABLE(mmemidi-driver,
409      [  --disable-mmemidi-driver
410                              Disable support for the Windows MME MIDI system.],
411      [config_mmemidi_driver="$enableval"],
412      [config_mmemidi_driver="yes"]
413    )
414    have_mmemidi=0
415    if test "$config_mmemidi_driver" = "yes"; then
416        AC_CHECK_HEADERS(mmsystem.h,
417            have_mmemidi=1,
418            have_mmemidi=0
419        )
420        if test "$have_mmemidi" = "1"; then
421            have_midi_input_driver="true"
422        fi
423    else
424        echo "MME MIDI support disabled by configure script parameter"
425    fi
426    AM_CONDITIONAL(HAVE_MME_MIDI, test $have_mmemidi = "1")
427    AC_DEFINE_UNQUOTED(HAVE_MME_MIDI,$have_mmemidi,[Define to 1 if you have MME MIDI installed.])
428    
429  # have we found at least one MIDI input and one audio output driver ?  # have we found at least one MIDI input and one audio output driver ?
430  if test "$have_midi_input_driver" = "false"; then  if test "$have_midi_input_driver" = "false"; then
431      echo "No supported MIDI input system found!"      echo "No supported MIDI input system found!"
# Line 317  fi Line 448  fi
448  # Checks for various DLL libraries  # Checks for various DLL libraries
449    
450  # Check presence of libgig  # Check presence of libgig
451  libgig_version="3.1.1"  libgig_version="3.2.1"
452  PKG_CHECK_MODULES(GIG, gig >= $libgig_version, HAVE_GIG=true, HAVE_GIG=false)  PKG_CHECK_MODULES(GIG, gig >= $libgig_version, HAVE_GIG=true, HAVE_GIG=false)
453  if test "$HAVE_GIG" = "false"; then  if test "$HAVE_GIG" = "false"; then
454      echo "Required libgig version not found!"      echo "Required libgig version not found!"
# Line 384  if test "$config_asm" = "yes"; then Line 515  if test "$config_asm" = "yes"; then
515  fi  fi
516    
517  AC_ARG_ENABLE(dev-mode,  AC_ARG_ENABLE(dev-mode,
518    [  --disable-dev-mode    [  --enable-dev-mode
519                            Disable development mode (default=on). In that mode                            Enable development mode (default=off). In that mode
520                            we do some extra sanity checks here and there.                            we do some extra sanity checks here and there.
521                            This helps to spot possible problems, but reduces                            This helps to spot possible problems, but reduces
522                            efficiency a bit],                            efficiency a bit],
523    [config_dev_mode="$enableval"],    [config_dev_mode="$enableval"],
524    [config_dev_mode="yes"]    [config_dev_mode="no"]
525  )  )
526  if test "$config_dev_mode" = "yes"; then  if test "$config_dev_mode" = "yes"; then
527    AC_DEFINE_UNQUOTED(CONFIG_DEVMODE, 1, [Define to 1 if you want to enable development mode.])    AC_DEFINE_UNQUOTED(CONFIG_DEVMODE, 1, [Define to 1 if you want to enable development mode.])
# Line 424  if test "$config_rt_exceptions" = "yes"; Line 555  if test "$config_rt_exceptions" = "yes";
555    AC_DEFINE_UNQUOTED(CONFIG_RT_EXCEPTIONS, 1, [Define to 1 to allow exceptions in the realtime context.])    AC_DEFINE_UNQUOTED(CONFIG_RT_EXCEPTIONS, 1, [Define to 1 to allow exceptions in the realtime context.])
556  fi  fi
557    
558    AC_ARG_ENABLE(pthread-testcancel,
559      [  --enable-pthread-testcancel
560                              Enable pthread_testcancel() calls and avoid asynchronous
561                              cancel of pthreads (default=no).],
562      [config_pthread_testcancel="$enableval"],
563      [config_pthread_testcancel="no"]
564    )
565    if test "$config_pthread_testcancel" = "yes"; then
566      AC_DEFINE_UNQUOTED(CONFIG_PTHREAD_TESTCANCEL, 1, [Define to 1 to enable pthread_testcancel() calls.])
567    fi
568    
569  AC_ARG_ENABLE(preload-samples,  AC_ARG_ENABLE(preload-samples,
570    [  --enable-preload-samples    [  --enable-preload-samples
571                            Due to seeking and latency issues with hard drives                            Due to seeking and latency issues with hard drives
# Line 875  AC_DEFINE_UNQUOTED( Line 1017  AC_DEFINE_UNQUOTED(
1017      "$config_default_instruments_db_file",      "$config_default_instruments_db_file",
1018      [Only when instruments DB feature is enabled: default location of the DB file.]      [Only when instruments DB feature is enabled: default location of the DB file.]
1019  )  )
1020    AC_SUBST(config_default_instruments_db_file)
1021    
1022    
1023  ###########################################################################  ###########################################################################

Legend:
Removed from v.1375  
changed lines
  Added in v.1651

  ViewVC Help
Powered by ViewVC