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

Diff of /linuxsampler/trunk/configure.in

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

revision 563 by schoenebeck, Sun May 22 20:43:32 2005 UTC revision 1777 by persson, Mon Sep 15 16:58:10 2008 UTC
# Line 1  Line 1 
1  AC_INIT(configure.in)  AC_INIT(configure.in)
2    
3    #------------------------------------------------------------------------------------
4    # LinuxSampler's / liblinuxsampler's "official" release version:
5    
6    LINUXSAMPLER_RELEASE_MAJOR=0
7    LINUXSAMPLER_RELEASE_MINOR=5
8    LINUXSAMPLER_RELEASE_BUILD=1.7cvs
9    
10    #------------------------------------------------------------------------------------
11    # The following is the libtool / shared library version. This doesn't have to
12    # do anything with the release version. It MUST conform to the following rules:
13    #
14    #  1. Start with version information of `0:0:0' for each libtool library.
15    #  2. Update the version information only immediately before a public release of
16    #     your software. More frequent updates are unnecessary, and only guarantee
17    #     that the current interface number gets larger faster.
18    #  3. If the library source code has changed at all since the last update, then
19    #     increment revision (`c:r:a' becomes `c:r+1:a').
20    #  4. If any interfaces have been added, removed, or changed since the last update,
21    #     increment current, and set revision to 0.
22    #  5. If any interfaces have been added since the last public release, then increment
23    #     age.
24    #  6. If any interfaces have been removed since the last public release, then set age
25    #     to 0.
26    
27    LIBLINUXSAMPLER_LT_CURRENT=2
28    LIBLINUXSAMPLER_LT_REVISION=0
29    LIBLINUXSAMPLER_LT_AGE=1
30    SHARED_VERSION_INFO="$LIBLINUXSAMPLER_LT_CURRENT:$LIBLINUXSAMPLER_LT_REVISION:$LIBLINUXSAMPLER_LT_AGE"
31    
32    #------------------------------------------------------------------------------------
33    # the LSCP specification version this LinuSampler release complies with:
34    
35    LSCP_RELEASE_MAJOR=1
36    LSCP_RELEASE_MINOR=4
37    
38    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.])
40    
41    AC_PROG_CXX
42    AC_LIBTOOL_WIN32_DLL
43    AM_PROG_LIBTOOL
44    
45    AC_SUBST(SHLIB_VERSION_ARG)
46    AC_SUBST(SHARED_VERSION_INFO)
47    
48  AC_C_BIGENDIAN  AC_C_BIGENDIAN
49  AC_CANONICAL_SYSTEM  AC_CANONICAL_SYSTEM
50    
# Line 8  AC_SUBST(target_cpu) Line 54  AC_SUBST(target_cpu)
54  AC_SUBST(target_os)  AC_SUBST(target_os)
55  AC_SUBST(target_vendor)  AC_SUBST(target_vendor)
56    
57    PKG_PROG_PKG_CONFIG
58    
59  ###########################################################################  ###########################################################################
60  # General Checks  # General Checks
# Line 24  esac Line 71  esac
71  AC_DEFINE_UNQUOTED(ARCH_X86,$def_arch_x86,[Define to 1 if you build for x86 architecture.])  AC_DEFINE_UNQUOTED(ARCH_X86,$def_arch_x86,[Define to 1 if you build for x86 architecture.])
72    
73  # determine the right gcc switch for CPU specific optimizations  # determine the right gcc switch for CPU specific optimizations
74    # (only if the user did not provide one)
75  CXX_CPU_SWITCH=  CXX_CPU_SWITCH=
76  if test "$def_arch_x86" = 1; then  if ! echo "X $CXXFLAGS " | grep -q -- " \(-march=\|-mcpu=\|-mtune=\|-arch=\)" ; then
77    CXX_CPU_SWITCH="-march=$target_cpu"    if test "$def_arch_x86" = 1; then
78  elif test "$target_cpu" = "powerpc"; then      CXX_CPU_SWITCH="-march=$target_cpu"
79    CXX_CPU_SWITCH="-arch=$target_cpu"    elif test "$target_cpu" = "ppc"; then
80        CXX_CPU_SWITCH="-arch=$target_cpu"
81      fi
82  fi  fi
83  AC_SUBST([CXX_CPU_SWITCH])  AC_SUBST([CXX_CPU_SWITCH])
84    
85    # check if we're on MS Windows
86    AC_CHECK_HEADERS(
87        mmsystem.h,
88        have_windows=1,
89        have_windows=0
90    )
91    AM_CONDITIONAL(HAVE_WINDOWS, test $have_windows = "1")
92    
93  AC_MSG_CHECKING([whether UNIX98 compatible])  AC_MSG_CHECKING([whether UNIX98 compatible])
94  AC_LANG_SAVE  AC_LANG_SAVE
95  AC_LANG_C  AC_LANG_C
# Line 54  have_unix98="no" Line 112  have_unix98="no"
112  )  )
113  AC_LANG_RESTORE  AC_LANG_RESTORE
114  AC_MSG_RESULT([$have_unix98])  AC_MSG_RESULT([$have_unix98])
115  if test "$have_unix98" = "no"; then  if test "$have_unix98" = "no" -a "have_windows" = "0"; then
116      if test "x$HAVE_UNIX98" = "x"; then      if test "x$HAVE_UNIX98" = "x"; then
117          echo "LinuxSampler only runs on UNIX98 compatible systems, which is mandatory for"          echo "LinuxSampler only runs on UNIX98 compatible systems, which is mandatory for"
118          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 64  if test "$have_unix98" = "no"; then Line 122  if test "$have_unix98" = "no"; then
122      fi      fi
123  fi  fi
124    
125    # check for <features.h>
126    AC_CHECK_HEADERS(features.h)
127    
128    # test for POSIX thread library
129    m4_ifdef([m4_include(m4/pthread.m4)],,
130                 [sinclude([m4/pthread.m4])])
131    ACX_PTHREAD
132    LIBS="$PTHREAD_LIBS $LIBS"
133    CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
134    CXXFLAGS="$CXXFLAGS $PTHREAD_CFLAGS"
135    CC="$PTHREAD_CC"
136    
137    # check for a bug in NPTL-enabled glibc
138    # (see Gentoo bug report #194076)
139    AC_ARG_ENABLE(nptl-bug-check,
140      [  --disable-nptl-bug-check
141                              Disable check for a bug in certain NPTL-enabled
142                              glibc versions that caused crashs.],
143      [config_check_nptl_bug="$enableval"],
144      [config_check_nptl_bug="yes"]
145    )
146    if test "$config_check_nptl_bug" = "yes"; then
147        m4_ifdef([m4_include(m4/nptl_bug.m4)],,
148                 [sinclude([m4/nptl_bug.m4])])
149        ACX_NPTL_GLIBC_BUG([
150            echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
151            echo "You seem to have a buggy PTHREAD library! LinuxSampler would"
152            echo "probably crash due to this. Please report us the system you are"
153            echo "using and/or file a bug report to the bug tracking system of"
154            echo "your distribution."
155            echo "If you have a NPTL-enabled glibc AND it was compiled for TLS as"
156            echo "well, you can try to circumvent this problem for now by setting"
157            echo "the environment variable LD_ASSUME_KERNEL=\"2.4.1\" , which"
158            echo "should cause this test to pass."
159            echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
160            AC_MSG_ERROR([possibly NPTL glibc bug detected])
161        ])
162    else
163        echo "NPTL glibc bug check disabled"
164    fi
165    
166    # FIXME: this is actually a dependency of libgig, not of LS directly, why
167    # isn't it hidden by libgig?
168    AC_CHECK_HEADERS(uuid/uuid.h)
169    AC_SEARCH_LIBS(uuid_generate, uuid)
170    
171    
172    
173    ###########################################################################
174  # Checks for available audio and MIDI systems / drivers  # Checks for available audio and MIDI systems / drivers
175  # (we throw an error if there's not at least one system for audio output and MIDI input available)  # (we throw an error if there's not at least one system for audio output and MIDI input available)
176    
177  have_midi_input_driver="false"  have_midi_input_driver="false"
178  have_audio_output_driver="false"  have_audio_output_driver="false"
179    
180  AC_CHECK_HEADER(alsa/asoundlib.h,  # ALSA
181      AC_CHECK_LIB(asound, main,  AC_ARG_ENABLE(alsa-driver,
182                               have_alsa=1    [  --disable-alsa-driver
183                               ,                            Disable support for the Advanced Linux Sound
184                               have_alsa=0                            Architecture (ALSA).],
185                  )    [config_alsa_driver="$enableval"],
186                  ,    [config_alsa_driver="yes"]
187                  have_alsa=0  )
188  )  have_alsa=0
189  if test "$have_alsa" = "1"; then  if test "$config_alsa_driver" = "yes"; then
190      have_midi_input_driver="true"      AC_CHECK_HEADER(alsa/asoundlib.h,
191      have_audio_output_driver="true";          AC_CHECK_LIB(asound, main,
192                                     have_alsa=1
193                                     ,
194                                     have_alsa=0
195                        )
196                        ,
197                        have_alsa=0
198        )
199        if test "$have_alsa" = "1"; then
200            have_midi_input_driver="true"
201            have_audio_output_driver="true";
202        fi
203    
204        echo -n "checking Alsa version... "
205        AC_LANG_SAVE
206        AC_LANG_C
207        AC_TRY_RUN([
208            #include <alsa/asoundlib.h>
209            void main(void) {
210                /* ensure backward compatibility */
211                #if !defined(SND_LIB_MAJOR) && defined(SOUNDLIB_VERSION_MAJOR)
212                #define SND_LIB_MAJOR SOUNDLIB_VERSION_MAJOR
213                #endif
214                exit(SND_LIB_MAJOR);
215            }
216        ],
217        alsa_major=0,
218        alsa_major=$?,
219        alsa_major=0
220        )
221        AC_TRY_RUN([
222            #include <alsa/asoundlib.h>
223            void main(void) {
224                /* ensure backward compatibility */
225                #if !defined(SND_LIB_MINOR) && defined(SOUNDLIB_VERSION_MINOR)
226                #define SND_LIB_MINOR SOUNDLIB_VERSION_MINOR
227                #endif
228                exit(SND_LIB_MINOR);
229            }
230        ],
231        alsa_minor=0,
232        alsa_minor=$?,
233        alsa_minor=0
234        )
235        AC_TRY_RUN([
236            #include <alsa/asoundlib.h>
237            void main(void) {
238                /* ensure backward compatibility */
239                #if !defined(SND_LIB_SUBMINOR) && defined(SOUNDLIB_VERSION_SUBMINOR)
240                #define SND_LIB_SUBMINOR SOUNDLIB_VERSION_SUBMINOR
241                #endif
242                exit(SND_LIB_SUBMINOR);
243            }
244        ],
245        alsa_subminor=0,
246        alsa_subminor=$?,
247        alsa_subminor=0
248        )
249        AC_LANG_RESTORE
250        echo "$alsa_major.$alsa_minor.$alsa_subminor";
251        AC_DEFINE_UNQUOTED(ALSA_MAJOR,$alsa_major,[Define to the major version number of your Alsa installation.])
252        AC_DEFINE_UNQUOTED(ALSA_MINOR,$alsa_minor,[Define to the minor version number of your Alsa installation.])
253        AC_DEFINE_UNQUOTED(ALSA_SUBMINOR,$alsa_subminor,[Define to the subminor version number of your Alsa installation.])
254    else
255        echo "ALSA support disabled by configure script parameter"
256  fi  fi
257  AM_CONDITIONAL(HAVE_ALSA, test $have_alsa = "1")  AM_CONDITIONAL(HAVE_ALSA, test $have_alsa = "1")
258  AC_DEFINE_UNQUOTED(HAVE_ALSA,$have_alsa,[Define to 1 if you have ALSA installed.])  AC_DEFINE_UNQUOTED(HAVE_ALSA,$have_alsa,[Define to 1 if you have ALSA installed.])
259    
260  echo -n "checking Alsa version... "  # JACK
261  AC_LANG_SAVE  AC_ARG_ENABLE(jack-driver,
262  AC_LANG_C    [  --disable-jack-driver
263  AC_TRY_RUN([                            Disable support for the Jack Audio Connection Kit
264  #include <alsa/asoundlib.h>                            (JACK).],
265  void main(void) {    [config_jack_driver="$enableval"],
266  /* ensure backward compatibility */    [config_jack_driver="yes"]
267  #if !defined(SND_LIB_MAJOR) && defined(SOUNDLIB_VERSION_MAJOR)  )
268  #define SND_LIB_MAJOR SOUNDLIB_VERSION_MAJOR  have_jack=0
269  #endif  if test "$config_jack_driver" = "yes"; then
270  exit(SND_LIB_MAJOR);      PKG_CHECK_MODULES(JACK, jack, have_jack=1, have_jack=0)
271  }      if test $have_jack = "1"; then
272  ],          AC_SUBST(JACK_LIBS)
273  alsa_major=0,          AC_SUBST(JACK_CFLAGS)
274  alsa_major=$?,          linuxsampler_save_LIBS=$LIBS
275  alsa_major=0          LIBS="$JACK_LIBS $LIBS"
276  )          AC_CHECK_FUNCS(jack_client_name_size jack_client_open)
277  AC_TRY_RUN([          LIBS=$linuxsampler_save_LIBS
278  #include <alsa/asoundlib.h>          have_audio_output_driver="true";
279  void main(void) {      fi
280  /* ensure backward compatibility */  else
281  #if !defined(SND_LIB_MINOR) && defined(SOUNDLIB_VERSION_MINOR)      echo "JACK support disabled by configure script parameter"
282  #define SND_LIB_MINOR SOUNDLIB_VERSION_MINOR  fi
283  #endif  AM_CONDITIONAL(HAVE_JACK, test $have_jack = "1")
284  exit(SND_LIB_MINOR);  AC_DEFINE_UNQUOTED(HAVE_JACK,$have_jack,[Define to 1 if you have JACK installed.])
285  }  
286  ],  # JACK MIDI
287  alsa_minor=0,  have_jack_midi=0
288  alsa_minor=$?,  if test $have_jack = "1"; then
289  alsa_minor=0      linuxsampler_save_CFLAGS=$CFLAGS
290  )      linuxsampler_save_LIBS=$LIBS
291  AC_TRY_RUN([      CFLAGS="$JACK_CFLAGS $CFLAGS"
292  #include <alsa/asoundlib.h>      LIBS="$JACK_LIBS $LIBS"
293  void main(void) {      AC_CHECK_HEADER(jack/midiport.h, have_jack_midi=1, have_jack_midi=0)
294  /* ensure backward compatibility */      if test $have_jack_midi = "1"; then
295  #if !defined(SND_LIB_SUBMINOR) && defined(SOUNDLIB_VERSION_SUBMINOR)          AC_CHECK_FUNCS(jack_midi_get_event_count)
296  #define SND_LIB_SUBMINOR SOUNDLIB_VERSION_SUBMINOR          AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <jack/midiport.h>]], [[
297  #endif              jack_midi_clear_buffer(0, 0);
298  exit(SND_LIB_SUBMINOR);          ]])], [AC_DEFINE(JACK_MIDI_FUNCS_NEED_NFRAMES, 1,
299  }                    [Define to 1 if you have the old jack midi functions that need an nframes argument.])])
300  ],          have_midi_input_driver="true"
301  alsa_subminor=0,      fi
302  alsa_subminor=$?,      CFLAGS=$linuxsampler_save_CFLAGS
303  alsa_subminor=0      LIBS=$linuxsampler_save_LIBS
304    fi
305    AM_CONDITIONAL(HAVE_JACK_MIDI, test $have_jack_midi = "1")
306    AC_DEFINE_UNQUOTED(HAVE_JACK_MIDI, $have_jack_midi,
307                       [Define to 1 if you have JACK with MIDI support installed.])
308    
309    # ARTS
310    AC_ARG_ENABLE(arts-driver,
311      [  --disable-arts-driver
312                              Disable support for the Analogue Realtime System
313                              (aRts).],
314      [config_arts_driver="$enableval"],
315      [config_arts_driver="yes"]
316    )
317    have_arts=0
318    if test "$config_arts_driver" = "yes"; then
319        m4_ifdef([m4_include(m4/arts.m4)],,
320                 [sinclude([m4/arts.m4])])
321        AM_PATH_ARTS(0.9.5, have_arts=1, have_arts=0)
322        if test "$have_arts" = "1"; then
323            have_audio_output_driver="true"
324        fi
325    else
326        echo "ARTS support disabled by configure script parameter"
327    fi
328    AM_CONDITIONAL(HAVE_ARTS, test "$have_arts" = "1")
329    AC_DEFINE_UNQUOTED(HAVE_ARTS,$have_arts,[Define to 1 if you have aRts installed.])
330    
331    # ASIO AUDIO (Win32)
332    AC_ARG_ENABLE(asiosdk-dir,
333      [  --enable-asiosdk-dir
334                              Directory where the ASIO SDK is located, this automatically
335                              enables the compilation of the ASIO audio output driver.],
336      [config_asiosdk_dir="${enableval}"],
337      [config_asiosdk_dir="."]
338    )
339    AC_SUBST(config_asiosdk_dir)
340    
341    AC_ARG_ENABLE(asio-driver,
342      [  --disable-asio-driver
343                              Disable support for the Windows ASIO driver.],
344      [config_asio_driver="$enableval"],
345      [config_asio_driver="yes"]
346    )
347    have_asio=0
348    ASIOSDK_BASEDIR=
349    if test "$config_asio_driver" = "yes"; then
350        asiosdk_headerfile=$config_asiosdk_dir/ASIOSDK2/common/asio.h
351        echo -n "checking for ASIO headerfile: $asiosdk_headerfile ...."
352        if test -e $asiosdk_headerfile ; then
353            echo yes
354            have_asio=1
355            ASIOSDK_BASEDIR="$config_asiosdk_dir"
356        else
357            echo no
358            have_asio=0
359        fi
360        if test "$have_asio" = "1"; then
361            have_audio_output_driver="true"
362        fi
363    else
364        echo "Windows ASIO support disabled by configure script parameter"
365    fi
366    AC_SUBST(ASIOSDK_BASEDIR)
367    AM_CONDITIONAL(HAVE_ASIO, test $have_asio = "1")
368    AC_DEFINE_UNQUOTED(HAVE_ASIO,$have_asio,[Define to 1 if you have ASIO installed.])
369    
370    # MidiShare (Linux, OS X, Windows)
371    AC_ARG_ENABLE(midishare-driver,
372      [  --disable-midishare-driver
373                              Disable support for the MidiShare system.],
374      [config_midishare_driver="$enableval"],
375      [config_midishare_driver="yes"]
376    )
377    have_midishare=0
378    if test "$config_midishare_driver" = "yes"; then
379        AC_CHECK_HEADER(MidiShare.h,
380            AC_CHECK_LIB(MidiShare, MidiCountEvs,
381                                    have_midishare=1,
382                                    have_midishare=0
383                        )
384                        ,
385                        have_midishare=0
386        )
387        if test "$have_midishare" = "1"; then
388            have_midi_input_driver="true"
389        fi
390    else
391        echo "MidiShare support disabled by configure script parameter"
392    fi
393    AM_CONDITIONAL(HAVE_MIDISHARE, test $have_midishare = "1")
394    AC_DEFINE_UNQUOTED(HAVE_MIDISHARE,$have_midishare,[Define to 1 if you have MidiShare installed.])
395    
396    # CoreMIDI (OS X)
397    AC_ARG_ENABLE(coremidi-driver,
398      [  --disable-coremidi-driver
399                              Disable support for the Apple CoreMIDI system.],
400      [config_coremidi_driver="$enableval"],
401      [config_coremidi_driver="yes"]
402    )
403    have_coremidi=0
404    if test "$config_coremidi_driver" = "yes"; then
405        AC_CHECK_HEADER(CoreMIDI/CoreMIDI.h,
406            have_coremidi=1,
407            have_coremidi=0
408        )
409        if test "$have_coremidi" = "1"; then
410            have_midi_input_driver="true"
411        fi
412    else
413        echo "CoreMIDI support disabled by configure script parameter"
414    fi
415    AM_CONDITIONAL(HAVE_COREMIDI, test $have_coremidi = "1")
416    AC_DEFINE_UNQUOTED(HAVE_COREMIDI,$have_coremidi,[Define to 1 if you have CoreMIDI installed.])
417    
418    # MME MIDI (Win32)
419    AC_ARG_ENABLE(mmemidi-driver,
420      [  --disable-mmemidi-driver
421                              Disable support for the Windows MME MIDI system.],
422      [config_mmemidi_driver="$enableval"],
423      [config_mmemidi_driver="yes"]
424    )
425    have_mmemidi=0
426    if test "$config_mmemidi_driver" = "yes"; then
427        AC_CHECK_HEADERS(mmsystem.h,
428            have_mmemidi=1,
429            have_mmemidi=0
430        )
431        if test "$have_mmemidi" = "1"; then
432            have_midi_input_driver="true"
433        fi
434    else
435        echo "MME MIDI support disabled by configure script parameter"
436    fi
437    AM_CONDITIONAL(HAVE_MME_MIDI, test $have_mmemidi = "1")
438    AC_DEFINE_UNQUOTED(HAVE_MME_MIDI,$have_mmemidi,[Define to 1 if you have MME MIDI installed.])
439    
440    
441    # DSSI
442    AC_CHECK_HEADERS(dssi.h,
443            have_dssi=1,
444            have_dssi=0)
445    AM_CONDITIONAL(HAVE_DSSI, test $have_dssi = "1")
446    
447    # LV2
448    PKG_CHECK_MODULES(LV2, lv2core, have_lv2=1, have_lv2=0)
449    if test $have_lv2 = "0"; then
450        AC_CHECK_HEADER(lv2.h, have_lv2=1, have_lv2=0)
451    fi
452    AM_CONDITIONAL(HAVE_LV2, test $have_lv2 = "1")
453    
454    # VST
455    AC_ARG_ENABLE(vstsdk-dir,
456      [  --enable-vstsdk-dir
457                              Directory where the VST SDK is located.
458                              This automatically enables the compilation
459                              of the VST plugin.],
460      [VSTSDK_DIR="${enableval}"],
461      [VSTSDK_DIR=]
462  )  )
463  AC_LANG_RESTORE  AC_SUBST(VSTSDK_DIR)
464  echo "$alsa_major.$alsa_minor.$alsa_subminor";  AM_CONDITIONAL(HAVE_VST, test "x$VSTSDK_DIR" != "x")
 AC_DEFINE_UNQUOTED(ALSA_MAJOR,$alsa_major,[Define to the major version number of your Alsa installation.])  
 AC_DEFINE_UNQUOTED(ALSA_MINOR,$alsa_minor,[Define to the minor version number of your Alsa installation.])  
 AC_DEFINE_UNQUOTED(ALSA_SUBMINOR,$alsa_subminor,[Define to the subminor version number of your Alsa installation.])  
465    
466  # JACK  
467  PKG_CHECK_MODULES(JACK, jack, HAVE_JACK=true, HAVE_JACK=false)  # have we found at least one MIDI input and one audio output driver ?
468  AC_SUBST(JACK_LIBS)  if test "$have_midi_input_driver" = "false"; then
469  AC_SUBST(JACK_CFLAGS)      echo "No supported MIDI input system found!"
470  if test $HAVE_JACK = false; then      echo "Sorry, LinuxSampler only supports the following MIDI drivers at the moment:"
471      HAVE_JACK=0;      echo "ALSA, JACK, MIDIShare, CoreMIDI, MME."
472  else      echo "If you think you have one of those available on your system, make sure you"
473      HAVE_JACK=1      echo "also have the respective development (header) files installed."
474      have_audio_output_driver="true";      exit -1;
     AC_CHECK_LIB(jack, jack_client_name_size, [AC_DEFINE(HAVE_JACK_CLIENT_NAME_SIZE, 1, [Define to 1 if you have the `jack_client_name_size' function.])], , $JACK_LIBS)  
475  fi  fi
476  AM_CONDITIONAL(HAVE_JACK, test $HAVE_JACK = 1)  if test "$have_audio_output_driver" = "false"; then
477  AC_DEFINE_UNQUOTED(HAVE_JACK,$HAVE_JACK,[Define to 1 if you have JACK installed.])      echo "No supported audio output system found!"
478        echo "Sorry, LinuxSampler only supports ALSA, JACK, ARTS and ASIO as audio output"
479        echo "driver at the moment!"
480        exit -1;
481    fi
482    
483    
484    
485    ###########################################################################
486    # Checks for various DLL libraries
487    
488  # Check presence of libgig  # Check presence of libgig
489  libgig_version="2.0.0"  libgig_version="3.2.1"
490  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)
491  if test "$HAVE_GIG" = "false"; then  if test "$HAVE_GIG" = "false"; then
492      echo "Required libgig version not found!"      echo "Required libgig version not found!"
493      echo "You need to have libgig version ${libgig_version} installed!"      echo "You need to have libgig version ${libgig_version} installed!"
494      exit -1;      exit -1;
495    else
496        echo "yes, found libgig $libgig_version"
497  fi  fi
498  AC_SUBST(GIG_CFLAGS)  AC_SUBST(GIG_CFLAGS)
499  AC_SUBST(GIG_LIBS)  AC_SUBST(GIG_LIBS)
500    
501  # SQLITE3  # Instruments DB feature (requires SQLite 3.3)
502  PKG_CHECK_MODULES(SQLITE3, sqlite3, HAVE_SQLITE3=true, HAVE_SQLITE3=false)  AC_ARG_ENABLE(instruments-db,
503  AC_SUBST(SQLITE3_LIBS)    [  --disable-instruments-db
504  AC_SUBST(SQLITE3_CFLAGS)                            Disable compilation of the sampler's instruments
505  if test $HAVE_SQLITE3 = false; then                            database feature. You need to have SQLite 3.3
506      HAVE_SQLITE3=0;                            or younger installed for this feature.],
507      [config_instruments_db="$enableval"],
508      [config_instruments_db="yes"]
509    )
510    HAVE_SQLITE3=0;
511    if test "$config_instruments_db" = "yes"; then
512        # Check presence of sqlite3
513        sqlite_version="3.3"
514        PKG_CHECK_MODULES(SQLITE3, sqlite3 >= $sqlite_version, HAVE_SQLITE3=true, HAVE_SQLITE3=false)
515        AC_SUBST(SQLITE3_LIBS)
516        AC_SUBST(SQLITE3_CFLAGS)
517        if test $HAVE_SQLITE3 = false; then
518            HAVE_SQLITE3=0
519            config_instruments_db="no"
520            echo "*** Required sqlite version not found!"
521            echo "*** You need to have sqlite version ${sqlite_version} or higher"
522            echo "*** for instruments database support to be enabled."
523            echo "*** Support for instruments DB will be disabled!"
524        else
525            HAVE_SQLITE3=1
526        fi
527  else  else
528      HAVE_SQLITE3=1      echo "Instruments DB feature disabled by configure script parameter"
529  fi  fi
530  AM_CONDITIONAL(HAVE_SQLITE3, test $HAVE_SQLITE3 = 1)  AM_CONDITIONAL(HAVE_SQLITE3, test $HAVE_SQLITE3 = 1)
531  AC_DEFINE_UNQUOTED(HAVE_SQLITE3,$HAVE_SQLITE3,[Define to 1 if you have SQLITE3 installed.])  AC_DEFINE_UNQUOTED(HAVE_SQLITE3,$HAVE_SQLITE3,[Define to 1 if you want the instruments DB feature and have SQLITE3 installed.])
532    
 if test "$have_midi_input_driver" = "false"; then  
     echo "No supported MIDI input system found!"  
     echo "Sorry, LinuxSampler only supports ALSA as MIDI input driver at the moment!"  
     exit -1;  
 fi  
 if test "$have_audio_output_driver" = "false"; then  
     echo "No supported audio output system found!"  
     echo "Sorry, LinuxSampler only supports ALSA and JACK as audio output driver at the moment!"  
     exit -1;  
 fi  
533    
534    
535  ###########################################################################  ###########################################################################
# Line 190  fi Line 537  fi
537    
538  # TODO: should we use AC_ARG_VAR(variable, description) instead?  # TODO: should we use AC_ARG_VAR(variable, description) instead?
539    
540    AC_ARG_ENABLE(asm,
541      [  --disable-asm
542                              Enable hand-crafted assembly optimizations
543                              (default=on). LinuxSampler provides CPU specific
544                              assembly optimizations. This is currently limited
545                              to just enter a fast (denormal) FPU mode on x86
546                              platforms. There are currently no synthesis core
547                              assembly optimizations anymore since LS 0.4.0],
548      [config_asm="$enableval"],
549      [config_asm="yes"]
550    )
551    if test "$config_asm" = "yes"; then
552      AC_DEFINE_UNQUOTED(CONFIG_ASM, 1, [Define to 1 if you want to enable asm optimizations.])
553    fi
554    
555  AC_ARG_ENABLE(dev-mode,  AC_ARG_ENABLE(dev-mode,
556    [  --enable-dev-mode    [  --enable-dev-mode
557                            Enable development mode (default=no). In that mode                            Enable development mode (default=off). In that mode
558                            we do some extra sanity checks here and there.                            we do some extra sanity checks here and there.
559                            This helps to spot possible problems, but reduces                            This helps to spot possible problems, but reduces
560                            efficiency a bit],                            efficiency a bit],
561    [config_dev_mode="yes"],    [config_dev_mode="$enableval"],
562    [config_dev_mode="no"]    [config_dev_mode="no"]
563  )  )
564  if test "$config_dev_mode" = "yes"; then  if test "$config_dev_mode" = "yes"; then
# Line 224  AC_ARG_ENABLE(rt-exceptions, Line 586  AC_ARG_ENABLE(rt-exceptions,
586                            context as well. Otherwise if disabled                            context as well. Otherwise if disabled
587                            segmentation faults will be forced by the                            segmentation faults will be forced by the
588                            application on critical errors.],                            application on critical errors.],
589    [config_rt_exceptions="yes"],    [config_rt_exceptions="$enableval"],
590    [config_rt_exceptions="no"]    [config_rt_exceptions="no"]
591  )  )
592  if test "$config_rt_exceptions" = "yes"; then  if test "$config_rt_exceptions" = "yes"; then
593    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.])
594  fi  fi
595    
596    AC_ARG_ENABLE(pthread-testcancel,
597      [  --enable-pthread-testcancel
598                              Enable pthread_testcancel() calls and avoid asynchronous
599                              cancel of pthreads (default=no).],
600      [config_pthread_testcancel="$enableval"],
601      [config_pthread_testcancel="no"]
602    )
603    if test "$config_pthread_testcancel" = "yes"; then
604      AC_DEFINE_UNQUOTED(CONFIG_PTHREAD_TESTCANCEL, 1, [Define to 1 to enable pthread_testcancel() calls.])
605    fi
606    
607  AC_ARG_ENABLE(preload-samples,  AC_ARG_ENABLE(preload-samples,
608    [  --enable-preload-samples    [  --enable-preload-samples
609                            Due to seeking and latency issues with hard drives                            Due to seeking and latency issues with hard drives
# Line 354  AC_ARG_ENABLE(max-voices, Line 727  AC_ARG_ENABLE(max-voices,
727  )  )
728  AC_DEFINE_UNQUOTED(CONFIG_MAX_VOICES, $config_max_voices, [Define max. voices.])  AC_DEFINE_UNQUOTED(CONFIG_MAX_VOICES, $config_max_voices, [Define max. voices.])
729    
730    AC_ARG_ENABLE(subfragment-size,
731      [  --enable-subfragment-size
732                              Every audio fragment will be splitted into
733                              subfragments. Where each subfragment renders
734                              audio with constant synthesis parameters. This is
735                              done for efficiency reasons. This parameter
736                              defines the default size of a subfragment in
737                              sample points. A large value means less CPU time
738                              whereas a low value means better audio quality
739                              (default=32).],
740      [config_subfragment_size="${enableval}"],
741      [config_subfragment_size="32"]
742    )
743    AC_DEFINE_UNQUOTED(CONFIG_DEFAULT_SUBFRAGMENT_SIZE, $config_subfragment_size, [Define default subfragment size (in sample points).])
744    
745    AC_ARG_ENABLE(global-attenuation-default,
746      [  --enable-global-attenuation-default
747                              To prevent clipping all samples will be lowered
748                              in amplitude by this given default factor (can
749                              be overridden at runtime).
750                              (default=0.35)],
751      [config_global_attenuation_default="${enableval}"],
752      [config_global_attenuation_default="0.35"]
753    )
754    AC_DEFINE_UNQUOTED(CONFIG_GLOBAL_ATTENUATION_DEFAULT, $config_global_attenuation_default, [Define default global volume attenuation (as floating point factor).])
755    
756  AC_ARG_ENABLE(voice-steal-algo,  AC_ARG_ENABLE(voice-steal-algo,
757    [  --enable-voice-steal-algo    [  --enable-voice-steal-algo
758                            Voice stealing algorithm to be used. Currently                            Voice stealing algorithm to be used. Currently
# Line 372  AC_ARG_ENABLE(voice-steal-algo, Line 771  AC_ARG_ENABLE(voice-steal-algo,
771        AC_MSG_ERROR([Unknown voice stealing algorithm for parameter --enable-voice-steal-algo])        AC_MSG_ERROR([Unknown voice stealing algorithm for parameter --enable-voice-steal-algo])
772      else      else
773        config_voice_steal_algo="${enableval}"        config_voice_steal_algo="${enableval}"
774      fi        fi
775    ],    ],
776    [config_voice_steal_algo="oldestvoiceonkey"]    [config_voice_steal_algo="oldestvoiceonkey"]
777  )  )
# Line 387  AC_ARG_ENABLE(sysex-buffer-size, Line 786  AC_ARG_ENABLE(sysex-buffer-size,
786  )  )
787  AC_DEFINE_UNQUOTED(CONFIG_SYSEX_BUFFER_SIZE, $config_sysex_buffer_size, [Define SysEx buffer size.])  AC_DEFINE_UNQUOTED(CONFIG_SYSEX_BUFFER_SIZE, $config_sysex_buffer_size, [Define SysEx buffer size.])
788    
 AC_ARG_ENABLE(filter-update-steps,  
   [  --enable-filter-update-steps  
                           Amount of sample points after which filter  
                           parameters (cutoff, resonance) are going to be  
                           updated (default=64). Higher value means less CPU  
                           load, but also worse parameter resolution, this  
                           value will be aligned to a power of two.],  
   [config_filter_update_steps="${enableval}"],  
   [config_filter_update_steps="64"]  
 )  
 AC_DEFINE_UNQUOTED(CONFIG_FILTER_UPDATE_STEPS, $config_filter_update_steps, [Define amount of steps to refresh filter coefficients.])  
   
789  AC_ARG_ENABLE(force-filter,  AC_ARG_ENABLE(force-filter,
790    [  --enable-force-filter    [  --enable-force-filter
791                            If enabled will force filter to be used even if                            If enabled will force filter to be used even if
792                            no usage was define in instrument patch files.                            no usage was define in instrument patch files.
793                            (default=no).],                            (default=no).],
794    [config_force_filter="yes"],    [config_force_filter="$enableval"],
795    [config_force_filter="no"]    [config_force_filter="no"]
796  )  )
797  if test "$config_force_filter" = "yes"; then  if test "$config_force_filter" = "yes"; then
# Line 479  AC_ARG_ENABLE(override-filter-type, Line 866  AC_ARG_ENABLE(override-filter-type,
866         config_override_filter_type="::gig::vcf_type_lowpassturbo"         config_override_filter_type="::gig::vcf_type_lowpassturbo"
867      elif test ! "${enableval}" = "no"; then      elif test ! "${enableval}" = "no"; then
868         AC_MSG_ERROR([Unknown filter type for parameter --enable-override-filter-type])         AC_MSG_ERROR([Unknown filter type for parameter --enable-override-filter-type])
869      fi        fi
870    ],    ],
871    [config_override_filter_type="no"]    [config_override_filter_type="no"]
872  )  )
# Line 494  AC_ARG_ENABLE(gs-checksum, Line 881  AC_ARG_ENABLE(gs-checksum,
881                            messages which do not provide a correct checksum                            messages which do not provide a correct checksum
882                            will be ignored. This is disabled by default as                            will be ignored. This is disabled by default as
883                            not all devices honor GS checksums.],                            not all devices honor GS checksums.],
884    [config_assert_gs_sysex_checksum="yes"],    [config_assert_gs_sysex_checksum="$enableval"],
885    [config_assert_gs_sysex_checksum="no"]    [config_assert_gs_sysex_checksum="no"]
886  )  )
887  if test "config_assert_gs_sysex_checksum" = "yes"; then  if test "config_assert_gs_sysex_checksum" = "yes"; then
888    AC_DEFINE_UNQUOTED(CONFIG_ASSERT_GS_SYSEX_CHECKSUM, 1, [Define to 1 if you want to enable GS SysEx check.])    AC_DEFINE_UNQUOTED(CONFIG_ASSERT_GS_SYSEX_CHECKSUM, 1, [Define to 1 if you want to enable GS SysEx check.])
889  fi  fi
890    
891    AC_ARG_ENABLE(portamento-time-min,
892      [  --enable-portamento-time-min
893                              Minimum Portamento time in seconds
894                              (default=0.1).],
895      [config_portamento_time_min="${enableval}"],
896      [config_portamento_time_min="0.1"]
897    )
898    AC_DEFINE_UNQUOTED(CONFIG_PORTAMENTO_TIME_MIN, $config_portamento_time_min, [Define min. portamento time.])
899    
900    AC_ARG_ENABLE(portamento-time-max,
901      [  --enable-portamento-time-max
902                              Maximum Portamento time in seconds
903                              (default=32).],
904      [config_portamento_time_max="${enableval}"],
905      [config_portamento_time_max="32"]
906    )
907    AC_DEFINE_UNQUOTED(CONFIG_PORTAMENTO_TIME_MAX, $config_portamento_time_max, [Define max. portamento time.])
908    
909    AC_ARG_ENABLE(portamento-time-default,
910      [  --enable-portamento-time-default
911                              Default Portamento time in seconds
912                              (default=1).],
913      [config_portamento_time_default="${enableval}"],
914      [config_portamento_time_default="1"]
915    )
916    AC_DEFINE_UNQUOTED(CONFIG_PORTAMENTO_TIME_DEFAULT, $config_portamento_time_default, [Define default portamento time.])
917    
918    AC_ARG_ENABLE(signed-triang-algo,
919      [  --enable-signed-triang-algo
920                              Signed triangular wave algorithm to be used (e.g. for LFOs).
921                              Currently available options:
922                                intmath:
923                                  Uses integer math without any branch will then be
924                                  converted to floating point value for each sample point.
925                                  This int->float conversion might hurt on some systems.
926                                intmathabs:
927                                  Similar to intmath but uses abs() function.
928                                  Depending on compiler and platrofm this could
929                                  perform better than integer math as it avoids
930                                  an extra integer multiply instruction.
931                                diharmonic:
932                                  The triangular wave will be approximated by adding two
933                                  sinusoidials. This solution might especially hurt on
934                                  systems with weak floating point unit.
935                                benchmark (default):
936                                  This is not an algorithm. Use this option if the
937                                  appropriate algorithm should be automatically
938                                  chosen by the configure script by performing a
939                                  benchmark between the algorithms mentioned above.
940                                  This will NOT work for cross compilation!],
941      [ if test ! "(" "${enableval}" = "intmath" \
942                  -o "${enableval}" = "intmathabs" \
943                  -o "${enableval}" = "diharmonic" ")" ; then
944          AC_MSG_ERROR([Unknown triangular wave algorithm for parameter --enable-signed-triang-algo])
945        else
946          config_signed_triang_algo="${enableval}"
947        fi
948      ],
949      [config_signed_triang_algo="benchmark"]
950    )
951    
952    AC_ARG_ENABLE(unsigned-triang-algo,
953      [  --enable-unsigned-triang-algo
954                              Unsigned triangular wave algorithm to be used (e.g. for LFOs).
955                              Currently available options:
956                                intmath:
957                                  Uses integer math without any branch will then be
958                                  converted to floating point value for each sample point.
959                                  This int->float conversion might hurt on some systems.
960                                intmathabs:
961                                  Similar to intmath but uses abs() function.
962                                  Depending on compiler and platrofm this could
963                                  perform better than integer math as it avoids
964                                  an extra integer multiply instruction.
965                                diharmonic:
966                                  The triangular wave will be approximated by adding two
967                                  sinusoidials. This solution might especially hurt on
968                                  systems with weak floating point unit.
969                                benchmark (default):
970                                  This is not an algorithm. Use this option if the
971                                  appropriate algorithm should be automatically
972                                  chosen by the configure script by performing a
973                                  benchmark between the algorithms mentioned above.
974                                  This will NOT work for cross compilation!],
975      [ if test ! "(" "${enableval}" = "intmath" \
976                  -o "${enableval}" = "intmathabs" \
977                  -o "${enableval}" = "diharmonic" ")" ; then
978          AC_MSG_ERROR([Unknown triangular wave algorithm for parameter --enable-unsigned-triang-algo])
979        else
980          config_unsigned_triang_algo="${enableval}"
981        fi
982      ],
983      [config_unsigned_triang_algo="benchmark"]
984    )
985    
986    AC_ARG_ENABLE(process-muted-channels,
987      [  --enable-process-muted-channels
988                              Enable processing of muted channels (default=no).
989                              In that mode all MIDI events in the muted channels
990                              will be processed. This will provide information
991                              about the active voices in the muted channels and
992                              will not discard notes, triggered in mute mode,
993                              when the channel is unmuted. But also will reduce
994                              the efficiency.],
995      [config_process_muted_channels="$enableval"],
996      [config_process_muted_channels="no"]
997    )
998    if test "$config_process_muted_channels" = "yes"; then
999      AC_DEFINE_UNQUOTED(CONFIG_PROCESS_MUTED_CHANNELS, 1, [Define to 1 if you want to enable processing of muted channels.])
1000    fi
1001    
1002    AC_ARG_ENABLE(process-all-notes-off,
1003      [  --disable-process-all-notes-off
1004                              Disable interpretation of All-Notes-Off MIDI
1005                              messages (default=on). By default LS will release
1006                              all voices whenever it receives an All-Notes-Off
1007                              MIDI message. You can disable this behavior, so
1008                              that LS simply ignores such messages.],
1009      [config_process_all_notes_off="$enableval"],
1010      [config_process_all_notes_off="yes"]
1011    )
1012    if test "$config_process_all_notes_off" = "yes"; then
1013      AC_DEFINE_UNQUOTED(CONFIG_PROCESS_ALL_NOTES_OFF, 1, [Define to 1 if you want to enable processing of All-Notes-Off MIDI messages.])
1014    fi
1015    
1016    AC_ARG_ENABLE(interpolate-volume,
1017      [  --disable-interpolate-volume
1018                              Disable interpolation of volume modulation
1019                              (default=on). With this enabled, the volume changes
1020                              generated by for example the envelope generator
1021                              will be smoother, minimizing the risk for audio
1022                              clicks. Disable it to reduce CPU usage.],
1023      [config_interpolate_volume="$enableval"],
1024      [config_interpolate_volume="yes"]
1025    )
1026    if test "$config_interpolate_volume" = "yes"; then
1027      AC_DEFINE_UNQUOTED(CONFIG_INTERPOLATE_VOLUME, 1, [Define to 1 if you want to enable interpolation of volume modulation.])
1028    fi
1029    
1030    AC_ARG_ENABLE(master-volume-sysex-by-port,
1031      [  --enable-master-volume-sysex-by-port
1032                              Whether global volume sysex message should be
1033                              applied globally to the whole sampler or only to
1034                              the sampler channels connected to the same MIDI
1035                              input port on which the sysex message arrived on.
1036                              By default global volume sysex messages apply
1037                              globally to the whole sampler, since many MIDI
1038                              devices behave that way.],
1039      [config_master_volume_sysex_by_port="$enableval"],
1040      [config_master_volume_sysex_by_port="no"]
1041    )
1042    if test "$config_master_volume_sysex_by_port" = "yes"; then
1043      AC_DEFINE_UNQUOTED(CONFIG_MASTER_VOLUME_SYSEX_BY_PORT, 1, [Define to 1 if you want global volume sysex message only be applied to the respective MIDI port.])
1044    fi
1045    
1046    AC_ARG_ENABLE(plugin-dir,
1047      [  --enable-plugin-dir
1048                              Directory where the sampler shall look for potential plugins,
1049                              that is 3rd party shared libraries that should be loaded by
1050                              the sampler on startup. By default the sampler will search
1051                              for plugins in the subdirectory "plugins" below its own
1052                              library directory.
1053                              (i.e. /usr/local/lib/linuxsampler/plugins)],
1054      [config_plugin_dir="${enableval}"],
1055      [config_plugin_dir="${libdir}/linuxsampler/plugins"]
1056    )
1057    AC_SUBST(config_plugin_dir)
1058    
1059    AC_ARG_ENABLE(default-instruments-db-location,
1060      [  --enable-default-instruments-db-location
1061                              Only when instruments DB feature is enabled: file name
1062                              which shall be taken as default location of the
1063                              instruments DB file. This location can still be
1064                              overridden at runtime with a command line switch.
1065                              (default: /var/lib/linuxsampler/instruments.db)],
1066      [config_default_instruments_db_file="${enableval}"],
1067      [config_default_instruments_db_file="/var/lib/linuxsampler/instruments.db"]
1068    )
1069    AC_DEFINE_UNQUOTED(
1070        CONFIG_DEFAULT_INSTRUMENTS_DB_LOCATION,
1071        "$config_default_instruments_db_file",
1072        [Only when instruments DB feature is enabled: default location of the DB file.]
1073    )
1074    AC_SUBST(config_default_instruments_db_file)
1075    
1076    
1077    ###########################################################################
1078    # Automatic Benchmarks (to detect the best algorithms for the system)
1079    
1080    AC_LANG_SAVE
1081    
1082    if test "$config_signed_triang_algo" = "benchmark"; then
1083        echo -n "benchmarking for the best (signed) triangular oscillator algorithm... "
1084        AC_LANG_CPLUSPLUS
1085        AC_TRY_RUN([
1086                #define SIGNED 1
1087                #define SILENT 1
1088                #include "${srcdir}/benchmarks/triang.cpp"
1089            ],
1090            triang_signed=0,
1091            triang_signed=$?,
1092            triang_signed=0
1093        )
1094        if test "$triang_signed" = "2"; then
1095            config_signed_triang_algo="intmath"
1096            echo "integer math"
1097        elif test "$triang_signed" = "3"; then
1098            config_signed_triang_algo="diharmonic"
1099            echo "di harmonics"
1100        elif test "$triang_signed" = "5"; then
1101            config_signed_triang_algo="intmathabs"
1102            echo "integer math using abs()"
1103        else
1104            echo "Benchmark of signed triangular wave algorithms failed!"
1105            echo "Maybe you are doing cross compilation? In that case you have to select"
1106            echo "an algorithm manually with './configure --enable-signed-triang-algo=...'"
1107            echo "Call './configure --help' for further information or read configure.in."
1108            exit -1;
1109        fi
1110    else
1111        case "$config_signed_triang_algo" in
1112            intmath)
1113                triang_signed=2 ;;
1114            diharmonic)
1115                triang_signed=3 ;;
1116            intmathabs)
1117                triang_signed=5 ;;
1118        esac
1119    fi
1120    AC_DEFINE_UNQUOTED(CONFIG_SIGNED_TRIANG_ALGO, ${triang_signed}, [Define signed triangular wave algorithm to be used.])
1121    
1122    if test "$config_unsigned_triang_algo" = "benchmark"; then
1123        echo -n "benchmarking for the best (unsigned) triangular oscillator algorithm... "
1124        AC_LANG_CPLUSPLUS
1125        AC_TRY_RUN([
1126                #define SIGNED 0
1127                #define SILENT 1
1128                #include "${srcdir}/benchmarks/triang.cpp"
1129            ],
1130            triang_unsigned=0,
1131            triang_unsigned=$?,
1132            triang_unsigned=0
1133        )
1134        if test "$triang_unsigned" = "2"; then
1135            config_unsigned_triang_algo="intmath"
1136            echo "integer math"
1137        elif test "$triang_unsigned" = "3"; then
1138            config_unsigned_triang_algo="diharmonic"
1139            echo "di harmonics"
1140        elif test "$triang_unsigned" = "5"; then
1141            config_unsigned_triang_algo="intmathabs"
1142            echo "integer math using abs()"
1143        else
1144            echo "Benchmark of unsigned triangular wave algorithms failed!"
1145            echo "Maybe you are doing cross compilation? In that case you have to select"
1146            echo "an algorithm manually with './configure --enable-unsigned-triang-algo=...'"
1147            echo "Call './configure --help' for further information or read configure.in."
1148            exit -1;
1149        fi
1150    else
1151        case "$config_unsigned_triang_algo" in
1152            intmath)
1153                triang_unsigned=2 ;;
1154            diharmonic)
1155                triang_unsigned=3 ;;
1156            intmathabs)
1157                triang_unsigned=5 ;;
1158        esac
1159    fi
1160    AC_DEFINE_UNQUOTED(CONFIG_UNSIGNED_TRIANG_ALGO, ${triang_unsigned}, [Define unsigned triangular wave algorithm to be used.])
1161    
1162    AC_LANG_RESTORE
1163    
1164    
1165  ###########################################################################  ###########################################################################
1166  # Create Build Files  # Create Build Files
1167    
1168  AM_CONFIG_HEADER(config.h)  AM_CONFIG_HEADER(config.h)
1169  AM_INIT_AUTOMAKE(linuxsampler, 0.3.1)  AM_INIT_AUTOMAKE(linuxsampler, "$LINUXSAMPLER_RELEASE_MAJOR.$LINUXSAMPLER_RELEASE_MINOR.$LINUXSAMPLER_RELEASE_BUILD")
1170    
1171  AC_LANG_CPLUSPLUS  AC_LANG_CPLUSPLUS
1172  AC_PROG_CXX  
1173    # some gcc 4.0 versions need -msse for SSE register allocations
1174    if test "$config_asm" = "yes"; then
1175      if test "$def_arch_x86" = 1; then
1176        CXXFLAGS="$CXXFLAGS -msse"
1177      fi
1178    fi
1179    
1180  # autoconf 2.59/libtool 1.5.12 bug? work-around. Without a check like  # autoconf 2.59/libtool 1.5.12 bug? work-around. Without a check like
1181  # this, the dlfcn.h check in am_prog_libtool may fail.  # this, the dlfcn.h check in am_prog_libtool may fail.
1182  AC_CHECK_HEADER(stdlib.h)  AC_CHECK_HEADER(stdlib.h)
1183    
1184  AM_PROG_LIBTOOL  AC_OUTPUT( \
1185        Makefile \
1186  AC_OUTPUT(Makefile src/Makefile src/network/Makefile src/engines/Makefile src/engines/gig/Makefile src/engines/common/Makefile src/common/Makefile src/lib/Makefile src/lib/fileloader/Makefile src/lib/fileloader/libgig/Makefile src/testcases/Makefile src/drivers/Makefile src/drivers/audio/Makefile src/drivers/midi/Makefile)      man/Makefile \
1187        man/linuxsampler.1 \
1188        src/Makefile \
1189        src/db/Makefile \
1190        src/network/Makefile \
1191        src/engines/Makefile \
1192        src/engines/gig/Makefile \
1193        src/engines/common/Makefile \
1194        src/effects/Makefile \
1195        src/common/Makefile \
1196        src/testcases/Makefile \
1197        src/drivers/Makefile \
1198        src/drivers/audio/Makefile \
1199        src/drivers/midi/Makefile \
1200        src/plugins/Makefile \
1201        src/hostplugins/Makefile \
1202        src/hostplugins/dssi/Makefile \
1203        src/hostplugins/lv2/Makefile \
1204        src/hostplugins/vst/Makefile \
1205        linuxsampler.spec \
1206        debian/Makefile \
1207        Artwork/Makefile \
1208        scripts/Makefile \
1209        osx/Makefile \
1210        osx/linuxsampler.xcodeproj/Makefile \
1211        Documentation/Makefile \
1212        Documentation/Engines/Makefile \
1213        Documentation/Engines/gig/Makefile \
1214        linuxsampler.pc \
1215        Doxyfile \
1216    )
1217    
1218    # resolve all nested variables in '${config_plugin_dir}'
1219    # (merely for providing a human readable summary below)
1220    while test $config_plugin_dir != `eval echo ${config_plugin_dir}` ; do
1221            config_plugin_dir=`eval echo ${config_plugin_dir}`
1222    done
1223    
1224    
1225  ###########################################################################  ###########################################################################
# Line 527  echo "" Line 1229  echo ""
1229  echo "#####################################################################"  echo "#####################################################################"
1230  echo "# LinuxSampler Configuration                                        #"  echo "# LinuxSampler Configuration                                        #"
1231  echo "#-------------------------------------------------------------------#"  echo "#-------------------------------------------------------------------#"
1232    echo "# Assembly Optimizations: ${config_asm}"
1233  echo "# Development Mode: ${config_dev_mode}"  echo "# Development Mode: ${config_dev_mode}"
1234  echo "# Debug Level: ${config_debug_level}"  echo "# Debug Level: ${config_debug_level}"
1235  echo "# Use Exceptions in RT Context: ${config_rt_exceptions}"  echo "# Use Exceptions in RT Context: ${config_rt_exceptions}"
# Line 541  echo "# Maximum Stream Refill Size: ${co Line 1244  echo "# Maximum Stream Refill Size: ${co
1244  echo "# Stream Size: ${config_stream_size}"  echo "# Stream Size: ${config_stream_size}"
1245  echo "# Maximum Disk Streams: ${config_max_streams}"  echo "# Maximum Disk Streams: ${config_max_streams}"
1246  echo "# Maximum Voices: ${config_max_voices}"  echo "# Maximum Voices: ${config_max_voices}"
1247    echo "# Default Subfragment Size: ${config_subfragment_size}"
1248    echo "# Default Global Volume Attenuation: ${config_global_attenuation_default}"
1249  echo "# Voice Stealing Algorithm: ${config_voice_steal_algo}"  echo "# Voice Stealing Algorithm: ${config_voice_steal_algo}"
1250    echo "# Signed Triangular Oscillator Algorithm: ${config_signed_triang_algo}"
1251    echo "# Unsigned Triangular Oscillator Algorithm: ${config_unsigned_triang_algo}"
1252  echo "# SysEx Buffer Size: ${config_sysex_buffer_size} Byte"  echo "# SysEx Buffer Size: ${config_sysex_buffer_size} Byte"
1253  echo "# Filter Update Steps: ${config_filter_update_steps}"  echo "# Min. Portamento Time: ${config_portamento_time_min} s"
1254    echo "# Max. Portamento Time: ${config_portamento_time_max} s"
1255    echo "# Default Portamento Time: ${config_portamento_time_default} s"
1256  echo "# Force Filter Usage: ${config_force_filter}"  echo "# Force Filter Usage: ${config_force_filter}"
1257  echo "# Filter Cutoff Minimum: ${config_filter_cutoff_min} Hz"  echo "# Filter Cutoff Minimum: ${config_filter_cutoff_min} Hz"
1258  echo "# Filter Cutoff Maximum: ${config_filter_cutoff_max} Hz"  echo "# Filter Cutoff Maximum: ${config_filter_cutoff_max} Hz"
# Line 551  echo "# Override Filter Cutoff Controlle Line 1260  echo "# Override Filter Cutoff Controlle
1260  echo "# Override Filter Resonance Controller: ${config_override_resonance_ctrl}"  echo "# Override Filter Resonance Controller: ${config_override_resonance_ctrl}"
1261  echo "# Override Filter Type: ${config_override_filter_type}"  echo "# Override Filter Type: ${config_override_filter_type}"
1262  echo "# Assert GS SysEx Checksum: ${config_assert_gs_sysex_checksum}"  echo "# Assert GS SysEx Checksum: ${config_assert_gs_sysex_checksum}"
1263    echo "# Process Muted Channels: ${config_process_muted_channels}"
1264    echo "# Process All-Notes-Off MIDI message: ${config_process_all_notes_off}"
1265    echo "# Apply global volume SysEx by MIDI port: ${config_master_volume_sysex_by_port}"
1266    echo "# Interpolate Volume: ${config_interpolate_volume}"
1267    echo "# Instruments database support: ${config_instruments_db}"
1268    if test "$config_instruments_db" = "yes"; then
1269    echo "# Instruments DB default location: ${config_default_instruments_db_file}"
1270    fi
1271    echo "# Plugin Path: ${config_plugin_dir}"
1272  echo "#-------------------------------------------------------------------#"  echo "#-------------------------------------------------------------------#"
1273  echo "# Read './configure --help' or file 'configure.in' for details.     #"  echo "# Read './configure --help' or file 'configure.in' for details.     #"
1274  echo "#####################################################################"  echo "#####################################################################"

Legend:
Removed from v.563  
changed lines
  Added in v.1777

  ViewVC Help
Powered by ViewVC