/[pcsx2_0.9.7]/trunk/3rdparty/portaudio/configure.in
ViewVC logotype

Diff of /trunk/3rdparty/portaudio/configure.in

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

revision 31 by william, Tue Sep 7 03:24:11 2010 UTC revision 273 by william, Fri Nov 12 01:10:22 2010 UTC
# Line 1  Line 1 
1  dnl  dnl
2  dnl portaudio V19 configure.in script  dnl portaudio V19 configure.in script
3  dnl  dnl
4  dnl Dominic Mazzoni, Arve Knudsen, Stelios Bounanos  dnl Dominic Mazzoni, Arve Knudsen, Stelios Bounanos
5  dnl  dnl
6    
7  dnl Require autoconf >= 2.13  dnl Require autoconf >= 2.13
8  AC_PREREQ(2.13)  AC_PREREQ(2.13)
9    
10  dnl Init autoconf and make sure configure is being called  dnl Init autoconf and make sure configure is being called
11  dnl from the right directory  dnl from the right directory
12  AC_INIT([include/portaudio.h])  AC_INIT([include/portaudio.h])
13    
14  dnl Define build, build_cpu, build_vendor, build_os  dnl Define build, build_cpu, build_vendor, build_os
15  AC_CANONICAL_BUILD  AC_CANONICAL_BUILD
16  dnl Define host, host_cpu, host_vendor, host_os  dnl Define host, host_cpu, host_vendor, host_os
17  AC_CANONICAL_HOST  AC_CANONICAL_HOST
18  dnl Define target, target_cpu, target_vendor, target_os  dnl Define target, target_cpu, target_vendor, target_os
19  AC_CANONICAL_TARGET  AC_CANONICAL_TARGET
20    
21  dnl Specify options  dnl Specify options
22    
23  AC_ARG_WITH(alsa,  AC_ARG_WITH(alsa,
24              AS_HELP_STRING([--with-alsa], [Enable support for ALSA @<:@autodetect@:>@]),              AS_HELP_STRING([--with-alsa], [Enable support for ALSA @<:@autodetect@:>@]),
25              [with_alsa=$withval])              [with_alsa=$withval])
26    
27  AC_ARG_WITH(jack,  AC_ARG_WITH(jack,
28              AS_HELP_STRING([--with-jack], [Enable support for JACK @<:@autodetect@:>@]),              AS_HELP_STRING([--with-jack], [Enable support for JACK @<:@autodetect@:>@]),
29              [with_jack=$withval])              [with_jack=$withval])
30    
31  AC_ARG_WITH(oss,  AC_ARG_WITH(oss,
32              AS_HELP_STRING([--with-oss], [Enable support for OSS @<:@autodetect@:>@]),              AS_HELP_STRING([--with-oss], [Enable support for OSS @<:@autodetect@:>@]),
33              [with_oss=$withval])              [with_oss=$withval])
34    
35  AC_ARG_WITH(asihpi,  AC_ARG_WITH(asihpi,
36              AS_HELP_STRING([--with-asihpi], [Enable support for ASIHPI @<:@autodetect@:>@]),              AS_HELP_STRING([--with-asihpi], [Enable support for ASIHPI @<:@autodetect@:>@]),
37              [with_asihpi=$withval])              [with_asihpi=$withval])
38    
39  AC_ARG_WITH(winapi,  AC_ARG_WITH(winapi,
40              AS_HELP_STRING([--with-winapi],              AS_HELP_STRING([--with-winapi],
41                             [Select Windows API support (@<:@wmme|directx|asio|wasapi|wdmks@:>@@<:@,...@:>@) @<:@wmme@:>@]),                             [Select Windows API support (@<:@wmme|directx|asio|wasapi|wdmks@:>@@<:@,...@:>@) @<:@wmme@:>@]),
42              [with_winapi=$withval], [with_winapi="wmme"])              [with_winapi=$withval], [with_winapi="wmme"])
43  case "$target_os" in *mingw* | *cygwin*)  case "$target_os" in *mingw* | *cygwin*)
44       with_wmme=no       with_wmme=no
45       with_directx=no       with_directx=no
46       with_asio=no       with_asio=no
47       with_wasapi=no       with_wasapi=no
48       with_wdmks=no       with_wdmks=no
49       for api in $(echo $with_winapi | sed 's/,/ /g'); do       for api in $(echo $with_winapi | sed 's/,/ /g'); do
50           case "$api" in           case "$api" in
51               wmme|directx|asio|wasapi|wdmks)               wmme|directx|asio|wasapi|wdmks)
52                   eval with_$api=yes                   eval with_$api=yes
53                   ;;                   ;;
54               *)               *)
55                   AC_MSG_ERROR([unknown Windows API \"$api\" (do you need --help?)])                   AC_MSG_ERROR([unknown Windows API \"$api\" (do you need --help?)])
56                   ;;                   ;;
57           esac           esac
58       done       done
59       ;;       ;;
60  esac  esac
61    
62  AC_ARG_WITH(asiodir,  AC_ARG_WITH(asiodir,
63              AS_HELP_STRING([--with-asiodir], [ASIO directory @<:@/usr/local/asiosdk2@:>@]),              AS_HELP_STRING([--with-asiodir], [ASIO directory @<:@/usr/local/asiosdk2@:>@]),
64              with_asiodir=$withval, with_asiodir="/usr/local/asiosdk2")              with_asiodir=$withval, with_asiodir="/usr/local/asiosdk2")
65    
66  AC_ARG_WITH(dxdir,  AC_ARG_WITH(dxdir,
67              AS_HELP_STRING([--with-dxdir], [DirectX directory @<:@/usr/local/dx7sdk@:>@]),              AS_HELP_STRING([--with-dxdir], [DirectX directory @<:@/usr/local/dx7sdk@:>@]),
68              with_dxdir=$withval, with_dxdir="/usr/local/dx7sdk")              with_dxdir=$withval, with_dxdir="/usr/local/dx7sdk")
69    
70  debug_output=no  debug_output=no
71  AC_ARG_ENABLE(debug-output,  AC_ARG_ENABLE(debug-output,
72                AS_HELP_STRING([--enable-debug-output], [Enable debug output @<:@no@:>@]),                AS_HELP_STRING([--enable-debug-output], [Enable debug output @<:@no@:>@]),
73                [if test "x$enableval" != "xno" ; then                [if test "x$enableval" != "xno" ; then
74                    AC_DEFINE(PA_ENABLE_DEBUG_OUTPUT,,[Enable debugging messages])                    AC_DEFINE(PA_ENABLE_DEBUG_OUTPUT,,[Enable debugging messages])
75                    debug_output=yes                    debug_output=yes
76                 fi                 fi
77                ])                ])
78    
79  AC_ARG_ENABLE(cxx,  AC_ARG_ENABLE(cxx,
80                AS_HELP_STRING([--enable-cxx], [Enable C++ bindings @<:@no@:>@]),                AS_HELP_STRING([--enable-cxx], [Enable C++ bindings @<:@no@:>@]),
81                enable_cxx=$enableval, enable_cxx="no")                enable_cxx=$enableval, enable_cxx="no")
82    
83  AC_ARG_ENABLE(mac-debug,  AC_ARG_ENABLE(mac-debug,
84                AS_HELP_STRING([--enable-mac-debug], [Enable Mac debug @<:@no@:>@]),                AS_HELP_STRING([--enable-mac-debug], [Enable Mac debug @<:@no@:>@]),
85                enable_mac_debug=$enableval, enable_mac_debug="no")                enable_mac_debug=$enableval, enable_mac_debug="no")
86    
87  AC_ARG_ENABLE(mac-universal,  AC_ARG_ENABLE(mac-universal,
88                AS_HELP_STRING([--enable-mac-universal], [Build Mac universal binaries @<:@yes@:>@]),                AS_HELP_STRING([--enable-mac-universal], [Build Mac universal binaries @<:@yes@:>@]),
89                enable_mac_universal=$enableval, enable_mac_universal="yes")                enable_mac_universal=$enableval, enable_mac_universal="yes")
90    
91  dnl Continue to accept --host_os for compatibility but do not document  dnl Continue to accept --host_os for compatibility but do not document
92  dnl it (the correct way to change host_os is with --host=...).  Moved  dnl it (the correct way to change host_os is with --host=...).  Moved
93  dnl here because the empty help string generates a blank line which we  dnl here because the empty help string generates a blank line which we
94  dnl can use to separate PA options from libtool options.  dnl can use to separate PA options from libtool options.
95  AC_ARG_WITH(host_os, [], host_os=$withval)  AC_ARG_WITH(host_os, [], host_os=$withval)
96    
97  dnl Checks for programs.  dnl Checks for programs.
98    
99  AC_PROG_CC  AC_PROG_CC
100  AC_LIBTOOL_WIN32_DLL  AC_LIBTOOL_WIN32_DLL
101  AC_PROG_LIBTOOL  AC_PROG_LIBTOOL
102  AC_PROG_INSTALL  AC_PROG_INSTALL
103  AC_PROG_LN_S  AC_PROG_LN_S
104  AC_PATH_PROG(AR, ar, no)  AC_PATH_PROG(AR, ar, no)
105  if [[ $AR = "no" ]] ; then  if [[ $AR = "no" ]] ; then
106      AC_MSG_ERROR("Could not find ar - needed to create a library")      AC_MSG_ERROR("Could not find ar - needed to create a library")
107  fi  fi
108    
109  dnl This must be one of the first tests we do or it will fail...  dnl This must be one of the first tests we do or it will fail...
110  AC_C_BIGENDIAN  AC_C_BIGENDIAN
111    
112  dnl checks for various host APIs and arguments to configure that  dnl checks for various host APIs and arguments to configure that
113  dnl turn them on or off  dnl turn them on or off
114    
115  have_alsa=no  have_alsa=no
116  if test "x$with_alsa" != "xno"; then  if test "x$with_alsa" != "xno"; then
117      AC_CHECK_LIB(asound, snd_pcm_open, have_alsa=yes, have_alsa=no)      AC_CHECK_LIB(asound, snd_pcm_open, have_alsa=yes, have_alsa=no)
118  fi  fi
119  have_asihpi=no  have_asihpi=no
120  if test "x$with_asihpi" != "xno"; then  if test "x$with_asihpi" != "xno"; then
121      AC_CHECK_LIB(hpi, HPI_SubSysCreate, have_asihpi=yes, have_asihpi=no, -lm)      AC_CHECK_LIB(hpi, HPI_SubSysCreate, have_asihpi=yes, have_asihpi=no, -lm)
122  fi  fi
123  have_libossaudio=no  have_libossaudio=no
124  have_oss=no  have_oss=no
125  if test "x$with_oss" != "xno"; then  if test "x$with_oss" != "xno"; then
126      AC_CHECK_HEADERS([sys/soundcard.h linux/soundcard.h machine/soundcard.h], [have_oss=yes])      AC_CHECK_HEADERS([sys/soundcard.h linux/soundcard.h machine/soundcard.h], [have_oss=yes])
127      if test "x$have_oss" = "xyes"; then      if test "x$have_oss" = "xyes"; then
128          AC_CHECK_LIB(ossaudio, _oss_ioctl, have_libossaudio=yes, have_libossaudio=no)          AC_CHECK_LIB(ossaudio, _oss_ioctl, have_libossaudio=yes, have_libossaudio=no)
129      fi      fi
130  fi  fi
131  have_jack=no  have_jack=no
132  if test "x$with_jack" != "xno"; then  if test "x$with_jack" != "xno"; then
133      PKG_CHECK_MODULES(JACK, jack, have_jack=yes, have_jack=no)      PKG_CHECK_MODULES(JACK, jack, have_jack=yes, have_jack=no)
134  fi  fi
135    
136    
137  dnl sizeof checks: we will need a 16-bit and a 32-bit type  dnl sizeof checks: we will need a 16-bit and a 32-bit type
138    
139  AC_CHECK_SIZEOF(short)  AC_CHECK_SIZEOF(short)
140  AC_CHECK_SIZEOF(int)  AC_CHECK_SIZEOF(int)
141  AC_CHECK_SIZEOF(long)  AC_CHECK_SIZEOF(long)
142    
143  save_LIBS="${LIBS}"  save_LIBS="${LIBS}"
144  AC_CHECK_LIB(rt, clock_gettime, [rt_libs=" -lrt"])  AC_CHECK_LIB(rt, clock_gettime, [rt_libs=" -lrt"])
145  LIBS="${LIBS}${rt_libs}"  LIBS="${LIBS}${rt_libs}"
146  DLL_LIBS="${DLL_LIBS}${rt_libs}"  DLL_LIBS="${DLL_LIBS}${rt_libs}"
147  AC_CHECK_FUNCS([clock_gettime nanosleep])  AC_CHECK_FUNCS([clock_gettime nanosleep])
148  LIBS="${save_LIBS}"  LIBS="${save_LIBS}"
149    
150  dnl LT_RELEASE=19  dnl LT_RELEASE=19
151  LT_CURRENT=2  LT_CURRENT=2
152  LT_REVISION=0  LT_REVISION=0
153  LT_AGE=0  LT_AGE=0
154    
155  AC_SUBST(LT_CURRENT)  AC_SUBST(LT_CURRENT)
156  AC_SUBST(LT_REVISION)  AC_SUBST(LT_REVISION)
157  AC_SUBST(LT_AGE)  AC_SUBST(LT_AGE)
158    
159  dnl extra variables  dnl extra variables
160  AC_SUBST(OTHER_OBJS)  AC_SUBST(OTHER_OBJS)
161  AC_SUBST(PADLL)  AC_SUBST(PADLL)
162  AC_SUBST(SHARED_FLAGS)  AC_SUBST(SHARED_FLAGS)
163  AC_SUBST(THREAD_CFLAGS)  AC_SUBST(THREAD_CFLAGS)
164  AC_SUBST(DLL_LIBS)  AC_SUBST(DLL_LIBS)
165  AC_SUBST(CXXFLAGS)  AC_SUBST(CXXFLAGS)
166  AC_SUBST(NASM)  AC_SUBST(NASM)
167  AC_SUBST(NASMOPT)  AC_SUBST(NASMOPT)
168    
169  dnl -g is optional on darwin  dnl -g is optional on darwin
170  if ( echo "${host_os}" | grep ^darwin >> /dev/null ) &&  if ( echo "${host_os}" | grep ^darwin >> /dev/null ) &&
171        [[ "$enable_mac_universal" = "yes" ] &&        [[ "$enable_mac_universal" = "yes" ] &&
172         [ "$enable_mac_debug" != "yes" ]] ; then         [ "$enable_mac_debug" != "yes" ]] ; then
173     CFLAGS="-O2 -Wall -pedantic -pipe -fPIC -DNDEBUG"     CFLAGS="-O2 -Wall -pedantic -pipe -fPIC -DNDEBUG"
174  else  else
175     CFLAGS=${CFLAGS:-"-g -O2 -Wall -pedantic -pipe -fPIC"}     CFLAGS=${CFLAGS:-"-g -O2 -Wall -pedantic -pipe -fPIC"}
176  fi  fi
177    
178  if [[ $ac_cv_c_bigendian = "yes" ]] ; then  if [[ $ac_cv_c_bigendian = "yes" ]] ; then
179     CFLAGS="$CFLAGS -DPA_BIG_ENDIAN"     CFLAGS="$CFLAGS -DPA_BIG_ENDIAN"
180  else  else
181     CFLAGS="$CFLAGS -DPA_LITTLE_ENDIAN"     CFLAGS="$CFLAGS -DPA_LITTLE_ENDIAN"
182  fi  fi
183    
184  add_objects()  add_objects()
185  {  {
186      for o in $@; do      for o in $@; do
187          test "${OTHER_OBJS#*${o}*}" = "${OTHER_OBJS}" && OTHER_OBJS="$OTHER_OBJS $o"          test "${OTHER_OBJS#*${o}*}" = "${OTHER_OBJS}" && OTHER_OBJS="$OTHER_OBJS $o"
188      done      done
189  }  }
190    
191  case "${host_os}" in  case "${host_os}" in
192    darwin* )    darwin* )
193          dnl Mac OS X configuration          dnl Mac OS X configuration
194    
195          AC_DEFINE(PA_USE_COREAUDIO)          AC_DEFINE(PA_USE_COREAUDIO)
196    
197          CFLAGS="$CFLAGS -Werror"          CFLAGS="$CFLAGS -Werror"
198          LIBS="-framework CoreAudio -framework AudioToolbox -framework AudioUnit -framework Carbon"          LIBS="-framework CoreAudio -framework AudioToolbox -framework AudioUnit -framework Carbon"
199    
200          if test "x$enable_mac_universal" = "xyes" ; then          if test "x$enable_mac_universal" = "xyes" ; then
201             mac_version_min="-mmacosx-version-min=10.3"             mac_version_min="-mmacosx-version-min=10.3"
202             if [[ -d /Developer/SDKs/MacOSX10.5.sdk ]] ; then             if [[ -d /Developer/SDKs/MacOSX10.5.sdk ]] ; then
203                mac_arches="-arch i386 -arch ppc -arch x86_64 -arch ppc64"                mac_arches="-arch i386 -arch ppc -arch x86_64 -arch ppc64"
204                mac_sysroot="-isysroot /Developer/SDKs/MacOSX10.5.sdk"                mac_sysroot="-isysroot /Developer/SDKs/MacOSX10.5.sdk"
205             else             else
206                mac_arches="-arch i386 -arch ppc"                mac_arches="-arch i386 -arch ppc"
207                mac_sysroot="-isysroot /Developer/SDKs/MacOSX10.4u.sdk"                mac_sysroot="-isysroot /Developer/SDKs/MacOSX10.4u.sdk"
208             fi             fi
209          else          else
210             mac_arches=""             mac_arches=""
211             mac_sysroot=""             mac_sysroot=""
212             mac_version=""             mac_version=""
213          fi          fi
214          SHARED_FLAGS="$LIBS -dynamiclib $mac_arches $mac_sysroot $mac_version_min"          SHARED_FLAGS="$LIBS -dynamiclib $mac_arches $mac_sysroot $mac_version_min"
215          CFLAGS="-std=c99 $CFLAGS $mac_arches $mac_sysroot $mac_version_min"          CFLAGS="-std=c99 $CFLAGS $mac_arches $mac_sysroot $mac_version_min"
216          OTHER_OBJS="src/os/unix/pa_unix_hostapis.o src/os/unix/pa_unix_util.o src/hostapi/coreaudio/pa_mac_core.o src/hostapi/coreaudio/pa_mac_core_utilities.o src/hostapi/coreaudio/pa_mac_core_blocking.o src/common/pa_ringbuffer.o"          OTHER_OBJS="src/os/unix/pa_unix_hostapis.o src/os/unix/pa_unix_util.o src/hostapi/coreaudio/pa_mac_core.o src/hostapi/coreaudio/pa_mac_core_utilities.o src/hostapi/coreaudio/pa_mac_core_blocking.o src/common/pa_ringbuffer.o"
217          PADLL="libportaudio.dylib"          PADLL="libportaudio.dylib"
218          ;;          ;;
219    
220    mingw* )    mingw* )
221          dnl MingW configuration          dnl MingW configuration
222    
223          PADLL="portaudio.dll"          PADLL="portaudio.dll"
224          THREAD_CFLAGS="-mthreads"          THREAD_CFLAGS="-mthreads"
225          SHARED_FLAGS="-shared"          SHARED_FLAGS="-shared"
226          CFLAGS="$CFLAGS -I\$(top_srcdir)/include -DPA_NO_WMME -DPA_NO_ASIO -DPA_NO_WDMKS -DPA_NO_DS -DPA_NO_WASAPI"          CFLAGS="$CFLAGS -I\$(top_srcdir)/include -DPA_NO_WMME -DPA_NO_ASIO -DPA_NO_WDMKS -DPA_NO_DS -DPA_NO_WASAPI"
227    
228          if [[ "x$with_directx" = "xyes" ]]; then          if [[ "x$with_directx" = "xyes" ]]; then
229              DXDIR="$with_dxdir"              DXDIR="$with_dxdir"
230              add_objects src/hostapi/dsound/pa_win_ds.o src/hostapi/dsound/pa_win_ds_dynlink.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o src/os/win/pa_win_waveformat.o              add_objects src/hostapi/dsound/pa_win_ds.o src/hostapi/dsound/pa_win_ds_dynlink.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o src/os/win/pa_win_waveformat.o
231              LIBS="-lwinmm -lm -ldsound -lole32"              LIBS="-lwinmm -lm -ldsound -lole32"
232              DLL_LIBS="${DLL_LIBS} -lwinmm -lm -L$DXDIR/lib -ldsound -lole32"              DLL_LIBS="${DLL_LIBS} -lwinmm -lm -L$DXDIR/lib -ldsound -lole32"
233              #VC98="\"/c/Program Files/Microsoft Visual Studio/VC98/Include\""              #VC98="\"/c/Program Files/Microsoft Visual Studio/VC98/Include\""
234              #CFLAGS="$CFLAGS -I$VC98 -DPA_NO_WMME -DPA_NO_ASIO"              #CFLAGS="$CFLAGS -I$VC98 -DPA_NO_WMME -DPA_NO_ASIO"
235              CFLAGS="$CFLAGS -I\$(top_srcdir)/src/os/win -I$DXDIR/include -UPA_NO_DS"              CFLAGS="$CFLAGS -I\$(top_srcdir)/src/os/win -I$DXDIR/include -UPA_NO_DS"
236          fi          fi
237    
238          if [[ "x$with_asio" = "xyes" ]]; then          if [[ "x$with_asio" = "xyes" ]]; then
239              ASIODIR="$with_asiodir"              ASIODIR="$with_asiodir"
240              add_objects src/hostapi/asio/pa_asio.o src/common/pa_ringbuffer.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o src/hostapi/asio/iasiothiscallresolver.o $ASIODIR/common/asio.o $ASIODIR/host/asiodrivers.o $ASIODIR/host/pc/asiolist.o              add_objects src/hostapi/asio/pa_asio.o src/common/pa_ringbuffer.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o src/hostapi/asio/iasiothiscallresolver.o $ASIODIR/common/asio.o $ASIODIR/host/asiodrivers.o $ASIODIR/host/pc/asiolist.o
241              LIBS="-lwinmm -lm -lole32 -luuid"              LIBS="-lwinmm -lm -lole32 -luuid"
242              DLL_LIBS="${DLL_LIBS} -lwinmm -lm -lole32 -luuid"              DLL_LIBS="${DLL_LIBS} -lwinmm -lm -lole32 -luuid"
243              CFLAGS="$CFLAGS -ffast-math -fomit-frame-pointer -I\$(top_srcdir)/src/common -I\$(top_srcdir)/src/hostapi/asio -I$ASIODIR/host/pc -I$ASIODIR/common -I$ASIODIR/host -UPA_NO_ASIO -DWINDOWS"              CFLAGS="$CFLAGS -ffast-math -fomit-frame-pointer -I\$(top_srcdir)/src/common -I\$(top_srcdir)/src/hostapi/asio -I$ASIODIR/host/pc -I$ASIODIR/common -I$ASIODIR/host -UPA_NO_ASIO -DWINDOWS"
244              CXXFLAGS="$CFLAGS"              CXXFLAGS="$CFLAGS"
245          fi          fi
246    
247          if [[ "x$with_wdmks" = "xyes" ]]; then          if [[ "x$with_wdmks" = "xyes" ]]; then
248              DXDIR="$with_dxdir"              DXDIR="$with_dxdir"
249              add_objects src/hostapi/wdmks/pa_win_wdmks.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o              add_objects src/hostapi/wdmks/pa_win_wdmks.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o
250              LIBS="-lwinmm -lm -luuid -lsetupapi -lole32"              LIBS="-lwinmm -lm -luuid -lsetupapi -lole32"
251              DLL_LIBS="${DLL_LIBS} -lwinmm -lm -L$DXDIR/lib -luuid -lsetupapi -lole32"              DLL_LIBS="${DLL_LIBS} -lwinmm -lm -L$DXDIR/lib -luuid -lsetupapi -lole32"
252              #VC98="\"/c/Program Files/Microsoft Visual Studio/VC98/Include\""              #VC98="\"/c/Program Files/Microsoft Visual Studio/VC98/Include\""
253              #CFLAGS="$CFLAGS -I$VC98 -DPA_NO_WMME -DPA_NO_ASIO"              #CFLAGS="$CFLAGS -I$VC98 -DPA_NO_WMME -DPA_NO_ASIO"
254              CFLAGS="$CFLAGS -I\$(top_srcdir)/src/common -I$DXDIR/include -UPA_NO_WDMKS"              CFLAGS="$CFLAGS -I\$(top_srcdir)/src/common -I$DXDIR/include -UPA_NO_WDMKS"
255          fi          fi
256    
257          if [[ "x$with_wmme" = "xyes" ]]; then          if [[ "x$with_wmme" = "xyes" ]]; then
258              add_objects src/hostapi/wmme/pa_win_wmme.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o src/os/win/pa_win_waveformat.o              add_objects src/hostapi/wmme/pa_win_wmme.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o src/os/win/pa_win_waveformat.o
259              LIBS="-lwinmm -lm -lole32 -luuid"              LIBS="-lwinmm -lm -lole32 -luuid"
260              DLL_LIBS="${DLL_LIBS} -lwinmm"              DLL_LIBS="${DLL_LIBS} -lwinmm"
261              CFLAGS="$CFLAGS -I\$(top_srcdir)/src/common -UPA_NO_WMME"              CFLAGS="$CFLAGS -I\$(top_srcdir)/src/common -UPA_NO_WMME"
262          fi          fi
263    
264          if [[ "x$with_wasapi" = "xyes" ]]; then          if [[ "x$with_wasapi" = "xyes" ]]; then
265              add_objects src/hostapi/wasapi/pa_win_wasapi.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o src/os/win/pa_win_waveformat.o              add_objects src/hostapi/wasapi/pa_win_wasapi.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o src/os/win/pa_win_waveformat.o
266              LIBS="-lwinmm -lm -lole32 -luuid"              LIBS="-lwinmm -lm -lole32 -luuid"
267              DLL_LIBS="${DLL_LIBS} -lwinmm"              DLL_LIBS="${DLL_LIBS} -lwinmm"
268              CFLAGS="$CFLAGS -I\$(top_srcdir)/src/common -I\$(top_srcdir)/src/hostapi/wasapi/mingw-include -UPA_NO_WASAPI"              CFLAGS="$CFLAGS -I\$(top_srcdir)/src/common -I\$(top_srcdir)/src/hostapi/wasapi/mingw-include -UPA_NO_WASAPI"
269          fi          fi
270          ;;          ;;
271    
272    cygwin* )    cygwin* )
273          dnl Cygwin configuration          dnl Cygwin configuration
274    
275          OTHER_OBJS="src/hostapi/wmme/pa_win_wmme.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o src/os/win/pa_win_waveformat.o"          OTHER_OBJS="src/hostapi/wmme/pa_win_wmme.o src/os/win/pa_win_hostapis.o src/os/win/pa_win_util.o src/os/win/pa_win_waveformat.o"
276          CFLAGS="$CFLAGS -DPA_NO_DS -DPA_NO_WDMKS -DPA_NO_ASIO -DPA_NO_WASAPI"          CFLAGS="$CFLAGS -DPA_NO_DS -DPA_NO_WDMKS -DPA_NO_ASIO -DPA_NO_WASAPI"
277          LIBS="-lwinmm -lm"          LIBS="-lwinmm -lm"
278          PADLL="portaudio.dll"          PADLL="portaudio.dll"
279          THREAD_CFLAGS="-mthreads"          THREAD_CFLAGS="-mthreads"
280          SHARED_FLAGS="-shared"          SHARED_FLAGS="-shared"
281          DLL_LIBS="${DLL_LIBS} -lwinmm"          DLL_LIBS="${DLL_LIBS} -lwinmm"
282          ;;          ;;
283    
284    irix* )    irix* )
285          dnl SGI IRIX audio library (AL) configuration (Pieter, oct 2-13, 2003).          dnl SGI IRIX audio library (AL) configuration (Pieter, oct 2-13, 2003).
286          dnl The 'dmedia' library is needed to read the Unadjusted System Time (UST).          dnl The 'dmedia' library is needed to read the Unadjusted System Time (UST).
287          dnl          dnl
288          AC_CHECK_LIB(pthread, pthread_create, , AC_MSG_ERROR([IRIX posix thread library not found!]))          AC_CHECK_LIB(pthread, pthread_create, , AC_MSG_ERROR([IRIX posix thread library not found!]))
289          AC_CHECK_LIB(audio,   alOpenPort,     , AC_MSG_ERROR([IRIX audio library not found!]))          AC_CHECK_LIB(audio,   alOpenPort,     , AC_MSG_ERROR([IRIX audio library not found!]))
290          AC_CHECK_LIB(dmedia,  dmGetUST,       , AC_MSG_ERROR([IRIX digital media library not found!]))          AC_CHECK_LIB(dmedia,  dmGetUST,       , AC_MSG_ERROR([IRIX digital media library not found!]))
291    
292          dnl See the '#ifdef PA_USE_SGI' in file pa_unix/pa_unix_hostapis.c          dnl See the '#ifdef PA_USE_SGI' in file pa_unix/pa_unix_hostapis.c
293          dnl which selects the appropriate PaXXX_Initialize() function.          dnl which selects the appropriate PaXXX_Initialize() function.
294          dnl          dnl
295          AC_DEFINE(PA_USE_SGI)          AC_DEFINE(PA_USE_SGI)
296    
297          dnl The _REENTRANT option for pthread safety. Perhaps not necessary but it 'll do no harm.          dnl The _REENTRANT option for pthread safety. Perhaps not necessary but it 'll do no harm.
298          dnl          dnl
299          THREAD_CFLAGS="-D_REENTRANT"          THREAD_CFLAGS="-D_REENTRANT"
300            
301          OTHER_OBJS="pa_sgi/pa_sgi.o src/os/unix/pa_unix_hostapis.o src/os/unix/pa_unix_util.o"          OTHER_OBJS="pa_sgi/pa_sgi.o src/os/unix/pa_unix_hostapis.o src/os/unix/pa_unix_util.o"
302    
303          dnl SGI books say -lpthread should be the last of the libs mentioned.          dnl SGI books say -lpthread should be the last of the libs mentioned.
304          dnl          dnl
305          LIBS="-lm -ldmedia -laudio -lpthread"          LIBS="-lm -ldmedia -laudio -lpthread"
306          PADLL="libportaudio.so"          PADLL="libportaudio.so"
307          SHARED_FLAGS=""          SHARED_FLAGS=""
308          ;;          ;;
309    
310    *)    *)
311          dnl Unix configuration          dnl Unix configuration
312    
313          AC_CHECK_LIB(pthread, pthread_create,[have_pthread="yes"],          AC_CHECK_LIB(pthread, pthread_create,[have_pthread="yes"],
314                  AC_MSG_ERROR([libpthread not found!]))                  AC_MSG_ERROR([libpthread not found!]))
315    
316          if [[ "$have_alsa" = "yes" ] && [ "$with_alsa" != "no" ]] ; then          if [[ "$have_alsa" = "yes" ] && [ "$with_alsa" != "no" ]] ; then
317             DLL_LIBS="$DLL_LIBS -lasound"             DLL_LIBS="$DLL_LIBS -lasound"
318             LIBS="$LIBS -lasound"             LIBS="$LIBS -lasound"
319             OTHER_OBJS="$OTHER_OBJS src/hostapi/alsa/pa_linux_alsa.o"             OTHER_OBJS="$OTHER_OBJS src/hostapi/alsa/pa_linux_alsa.o"
320             AC_DEFINE(PA_USE_ALSA)             AC_DEFINE(PA_USE_ALSA)
321          fi          fi
322    
323          if [[ "$have_jack" = "yes" ] && [ "$with_jack" != "no" ]] ; then          if [[ "$have_jack" = "yes" ] && [ "$with_jack" != "no" ]] ; then
324             DLL_LIBS="$DLL_LIBS $JACK_LIBS"             DLL_LIBS="$DLL_LIBS $JACK_LIBS"
325             CFLAGS="$CFLAGS $JACK_CFLAGS"             CFLAGS="$CFLAGS $JACK_CFLAGS"
326             OTHER_OBJS="$OTHER_OBJS src/hostapi/jack/pa_jack.o src/common/pa_ringbuffer.o"             OTHER_OBJS="$OTHER_OBJS src/hostapi/jack/pa_jack.o src/common/pa_ringbuffer.o"
327             AC_DEFINE(PA_USE_JACK)             AC_DEFINE(PA_USE_JACK)
328          fi          fi
329    
330          if [[ "$with_oss" != "no" ]] ; then          if [[ "$with_oss" != "no" ]] ; then
331             OTHER_OBJS="$OTHER_OBJS src/hostapi/oss/pa_unix_oss.o"             OTHER_OBJS="$OTHER_OBJS src/hostapi/oss/pa_unix_oss.o"
332             if [[ "$have_libossaudio" = "yes" ]] ; then             if [[ "$have_libossaudio" = "yes" ]] ; then
333                     DLL_LIBS="$DLL_LIBS -lossaudio"                     DLL_LIBS="$DLL_LIBS -lossaudio"
334                     LIBS="$LIBS -lossaudio"                     LIBS="$LIBS -lossaudio"
335             fi                   fi      
336             AC_DEFINE(PA_USE_OSS)             AC_DEFINE(PA_USE_OSS)
337          fi          fi
338    
339          if [[ "$have_asihpi" = "yes" ] && [ "$with_asihpi" != "no" ]] ; then          if [[ "$have_asihpi" = "yes" ] && [ "$with_asihpi" != "no" ]] ; then
340             LIBS="$LIBS -lhpi"             LIBS="$LIBS -lhpi"
341             DLL_LIBS="$DLL_LIBS -lhpi"             DLL_LIBS="$DLL_LIBS -lhpi"
342             OTHER_OBJS="$OTHER_OBJS src/hostapi/asihpi/pa_linux_asihpi.o"             OTHER_OBJS="$OTHER_OBJS src/hostapi/asihpi/pa_linux_asihpi.o"
343             AC_DEFINE(PA_USE_ASIHPI)             AC_DEFINE(PA_USE_ASIHPI)
344          fi          fi
345    
346          DLL_LIBS="$DLL_LIBS -lm -lpthread"          DLL_LIBS="$DLL_LIBS -lm -lpthread"
347          LIBS="$LIBS -lm -lpthread"          LIBS="$LIBS -lm -lpthread"
348          PADLL="libportaudio.so"          PADLL="libportaudio.so"
349    
350          ## support sun cc compiler flags          ## support sun cc compiler flags
351          case "${host_os}" in          case "${host_os}" in
352             solaris*)             solaris*)
353                SHARED_FLAGS="-G"                SHARED_FLAGS="-G"
354                THREAD_CFLAGS="-mt"                THREAD_CFLAGS="-mt"
355                ;;                ;;
356             *)             *)
357                SHARED_FLAGS="-shared -fPIC"                SHARED_FLAGS="-shared -fPIC"
358                THREAD_CFLAGS="-pthread"                THREAD_CFLAGS="-pthread"
359                ;;                ;;
360          esac          esac
361    
362          OTHER_OBJS="$OTHER_OBJS src/os/unix/pa_unix_hostapis.o src/os/unix/pa_unix_util.o"          OTHER_OBJS="$OTHER_OBJS src/os/unix/pa_unix_hostapis.o src/os/unix/pa_unix_util.o"
363  esac  esac
364  CFLAGS="$CFLAGS $THREAD_CFLAGS"  CFLAGS="$CFLAGS $THREAD_CFLAGS"
365    
366  if test "$enable_cxx" = "yes"; then  if test "$enable_cxx" = "yes"; then
367     AC_CONFIG_SUBDIRS([bindings/cpp])     AC_CONFIG_SUBDIRS([bindings/cpp])
368     ENABLE_CXX_TRUE=""     ENABLE_CXX_TRUE=""
369     ENABLE_CXX_FALSE="#"     ENABLE_CXX_FALSE="#"
370  else  else
371     ENABLE_CXX_TRUE="#"     ENABLE_CXX_TRUE="#"
372     ENABLE_CXX_FALSE=""     ENABLE_CXX_FALSE=""
373  fi  fi
374  AC_SUBST(ENABLE_CXX_TRUE)  AC_SUBST(ENABLE_CXX_TRUE)
375  AC_SUBST(ENABLE_CXX_FALSE)  AC_SUBST(ENABLE_CXX_FALSE)
376    
377  if test "x$with_asio" = "xyes"; then  if test "x$with_asio" = "xyes"; then
378     WITH_ASIO_TRUE=""     WITH_ASIO_TRUE=""
379     WITH_ASIO_FALSE="@ #"     WITH_ASIO_FALSE="@ #"
380  else  else
381     WITH_ASIO_TRUE="@ #"     WITH_ASIO_TRUE="@ #"
382     WITH_ASIO_FALSE=""     WITH_ASIO_FALSE=""
383  fi  fi
384  AC_SUBST(WITH_ASIO_TRUE)  AC_SUBST(WITH_ASIO_TRUE)
385  AC_SUBST(WITH_ASIO_FALSE)  AC_SUBST(WITH_ASIO_FALSE)
386    
387  AC_OUTPUT([Makefile portaudio-2.0.pc])  AC_OUTPUT([Makefile portaudio-2.0.pc])
388    
389  AC_MSG_RESULT([  AC_MSG_RESULT([
390  Configuration summary:  Configuration summary:
391    
392    Target ...................... $target    Target ...................... $target
393    C++ bindings ................ $enable_cxx    C++ bindings ................ $enable_cxx
394    Debug output ................ $debug_output])    Debug output ................ $debug_output])
395    
396  case "$target_os" in *linux*)  case "$target_os" in *linux*)
397      AC_MSG_RESULT([      AC_MSG_RESULT([
398    ALSA ........................ $have_alsa    ALSA ........................ $have_alsa
399    ASIHPI ...................... $have_asihpi])    ASIHPI ...................... $have_asihpi])
400      ;;      ;;
401  esac  esac
402  case "$target_os" in  case "$target_os" in
403      *mingw* | *cygwin*)      *mingw* | *cygwin*)
404          test "x$with_directx" = "xyes" && with_directx="$with_directx (${with_dxdir})"          test "x$with_directx" = "xyes" && with_directx="$with_directx (${with_dxdir})"
405          test "x$with_wdmks" = "xyes" && with_wdmks="$with_wdmks (${with_dxdir})"          test "x$with_wdmks" = "xyes" && with_wdmks="$with_wdmks (${with_dxdir})"
406          test "x$with_asio" = "xyes" && with_asio="$with_asio (${with_asiodir})"          test "x$with_asio" = "xyes" && with_asio="$with_asio (${with_asiodir})"
407          test "x$with_wasapi" = "xyes"          test "x$with_wasapi" = "xyes"
408          AC_MSG_RESULT([          AC_MSG_RESULT([
409    WMME ........................ $with_wmme    WMME ........................ $with_wmme
410    DSound ...................... $with_directx    DSound ...................... $with_directx
411    ASIO ........................ $with_asio    ASIO ........................ $with_asio
412    WASAPI ...................... $with_wasapi    WASAPI ...................... $with_wasapi
413    WDMKS ....................... $with_wdmks    WDMKS ....................... $with_wdmks
414  ])  ])
415          ;;          ;;
416      *darwin*)      *darwin*)
417          AC_MSG_RESULT([          AC_MSG_RESULT([
418    Mac debug flags ............. $enable_mac_debug    Mac debug flags ............. $enable_mac_debug
419  ])  ])
420          ;;          ;;
421       *)       *)
422          AC_MSG_RESULT([          AC_MSG_RESULT([
423    OSS ......................... $have_oss    OSS ......................... $have_oss
424    JACK ........................ $have_jack    JACK ........................ $have_jack
425  ])  ])
426          ;;          ;;
427  esac  esac

Legend:
Removed from v.31  
changed lines
  Added in v.273

  ViewVC Help
Powered by ViewVC 1.1.22