configure.in
changeset 935 f8d5ddc7aef1
parent 886 05c551e5bc64
child 936 84f930aebaeb
     1.1 --- a/configure.in	Fri Aug 20 22:35:23 2004 +0000
     1.2 +++ b/configure.in	Sat Aug 21 02:06:30 2004 +0000
     1.3 @@ -332,6 +332,7 @@
     1.4          ],[
     1.5          have_dmedia=yes
     1.6          ])
     1.7 +        AC_MSG_RESULT($have_dmedia)
     1.8          # Set up files for the audio library
     1.9          if test x$have_dmedia = xyes; then
    1.10              CFLAGS="$CFLAGS -DDMEDIA_SUPPORT"
    1.11 @@ -489,6 +490,29 @@
    1.12      fi
    1.13  }
    1.14  
    1.15 +dnl Check whether we want to use CoreAudio
    1.16 +CheckCoreAudio()
    1.17 +{
    1.18 +    if test x$enable_audio = xyes; then
    1.19 +        AC_MSG_CHECKING(for CoreAudio audio support)
    1.20 +        have_coreaudio=no
    1.21 +        AC_TRY_COMPILE([
    1.22 +          #include <AudioUnit/AudioUnit.h>
    1.23 +        ],[
    1.24 +          AudioUnitInputCallback callback;
    1.25 +        ],[
    1.26 +        have_coreaudio=yes
    1.27 +        ])
    1.28 +        AC_MSG_RESULT($have_coreaudio)
    1.29 +        # Set up files for the audio library
    1.30 +        if test x$have_coreaudio = xyes; then
    1.31 +            CFLAGS="$CFLAGS -DCOREAUDIO_SUPPORT"
    1.32 +            AUDIO_SUBDIRS="$AUDIO_SUBDIRS macosx"
    1.33 +            AUDIO_DRIVERS="$AUDIO_DRIVERS macosx/libaudio_macosx.la"
    1.34 +        fi
    1.35 +    fi
    1.36 +}
    1.37 +
    1.38  dnl See if we can use x86 assembly blitters
    1.39  # NASM is available from: http://nasm.octium.net/
    1.40  CheckNASM()
    1.41 @@ -2507,10 +2531,15 @@
    1.42          ARCH=macosx
    1.43          CheckDummyVideo
    1.44          CheckDiskAudio
    1.45 +        CheckCoreAudio
    1.46          CheckQUARTZ
    1.47          CheckMacGL
    1.48          CheckPTHREAD
    1.49          CheckSIGACTION
    1.50 +        # If either the audio or CD driver is used, add the AudioUnit framework
    1.51 +        if test x$enable_audio = xyes -o x$enable_cdrom = xyes; then
    1.52 +            SYSTEM_LIBS="$SYSTEM_LIBS -framework AudioToolbox -framework AudioUnit"
    1.53 +        fi
    1.54          # Set up files for the audio library
    1.55          if test x$enable_audio = xyes; then
    1.56              AUDIO_SUBDIRS="$AUDIO_SUBDIRS macrom"
    1.57 @@ -2526,7 +2555,7 @@
    1.58          if test x$enable_cdrom = xyes; then
    1.59              CDROM_SUBDIRS="$CDROM_SUBDIRS macosx"
    1.60              CDROM_DRIVERS="$CDROM_DRIVERS macosx/libcdrom_macosx.la"
    1.61 -            SYSTEM_LIBS="$SYSTEM_LIBS -framework AudioToolbox -framework AudioUnit -lstdc++"
    1.62 +            SYSTEM_LIBS="$SYSTEM_LIBS -lstdc++"
    1.63          fi
    1.64          # Set up files for the thread library
    1.65          if test x$enable_threads = xyes; then
    1.66 @@ -2766,6 +2795,7 @@
    1.67  src/audio/dmedia/Makefile
    1.68  src/audio/dsp/Makefile
    1.69  src/audio/esd/Makefile
    1.70 +src/audio/macosx/Makefile
    1.71  src/audio/macrom/Makefile
    1.72  src/audio/mint/Makefile
    1.73  src/audio/mme/Makefile