3 AC_INIT([paraslash], [m4_esyscmd_s(./GIT-VERSION-GEN)],
4 [maan@tuebingen.mpg.de], [], [http://people.tuebingen.mpg.de/maan/paraslash/])
5 AC_CONFIG_HEADERS([config.h])
7 AC_CONFIG_FILES([Makefile])
8 AC_DEFUN([add_dot_o],[$(for i in $@; do printf "$i.o "; done)])
9 AC_DEFUN([add_cmdline],[$(for i in $@; do printf "${i}.cmdline "; done)])
10 AC_DEFUN([LIB_ARG_WITH], [
11 AC_ARG_WITH($1-headers, [AS_HELP_STRING(--with-$1-headers=dir,
12 [look for $1 headers in dir])])
13 AC_ARG_WITH($1-libs, [AS_HELP_STRING(--with-$1-libs=dir,
14 [look for $1 libraries in dir])])
15 if test -n "$with_$1_headers"; then
16 $1_cppflags="-I$with_$1_headers"
17 CPPFLAGS="$CPPFLAGS $$1_cppflags"
19 if test -n "$with_$1_libs"; then
20 $1_ldflags="-L$with_$1_libs $2"
24 LDFLAGS="$LDFLAGS $$1_ldflags"
27 AC_DEFUN([STASH_FLAGS], [
28 OLD_CPPFLAGS="$CPPFLAGS"
29 OLD_LDFLAGS="$LDFLAGS"
33 AC_DEFUN([UNSTASH_FLAGS], [
34 CPPFLAGS="$OLD_CPPFLAGS"
35 LDFLAGS="$OLD_LDFLAGS"
38 AC_DEFUN([LIB_SUBST_FLAGS], [
39 if test "$HAVE_[]m4_toupper([$1])" = 'yes'; then
40 AC_DEFINE(HAVE_[]m4_toupper([$1]), 1,
41 define to 1 to turn on $1 support)
46 AC_SUBST(HAVE_[]m4_toupper([$1]))
51 AC_USE_SYSTEM_EXTENSIONS
54 AC_PATH_PROG([M4], [m4])
55 test -z "$M4" && AC_MSG_ERROR(
56 [The m4 macro processor is required to build this package])
58 AC_PATH_PROG([INSTALL], [install])
59 test -z "$INSTALL" && AC_MSG_ERROR(
60 [The install program is required to build this package])
62 AC_PATH_PROG([lopsubgen], [lopsubgen])
63 test -z "$lopsubgen" && AC_MSG_ERROR(
64 [lopsubgen is required to build this package])
69 executables="recv filter audioc write afh play"
70 ################################################################## clock_gettime
72 AC_CHECK_LIB([c], [clock_gettime], [clock_gettime_lib=c], [
73 AC_CHECK_LIB([rt], [clock_gettime], [clock_gettime_lib=rt], [], [])
75 if test -n "$clock_gettime_lib"; then
76 AC_DEFINE(HAVE_CLOCK_GETTIME, 1, [
77 define to 1 if clock_gettime() is supported])
79 if test "$clock_gettime_lib" = "rt"; then
80 AC_SUBST(clock_gettime_ldflags, -lrt)
83 ########################################################################### osl
85 LIB_ARG_WITH([osl], [-losl])
87 AC_CHECK_HEADER(osl.h, [], [HAVE_OSL=no])
88 AC_CHECK_LIB([osl], [osl_open_table], [], [HAVE_OSL=no])
91 ######################################################################## lopsub
93 LIB_ARG_WITH([lopsub], [-llopsub])
95 AC_CHECK_HEADER(lopsub.h, [], [HAVE_LOPSUB=no])
96 AC_CHECK_LIB([lopsub], [lls_merge], [], [HAVE_LOPSUB=yes])
97 if test $HAVE_LOPSUB = no; then AC_MSG_ERROR([
98 The lopsub library is required to build this software, but
99 the above checks indicate it is not installed on your system.
100 Run the following command to download a copy.
101 git clone git://git.tuebingen.mpg.de/lopsub.git
102 Install the library, then run this configure script again.
105 LIB_SUBST_FLAGS([lopsub])
107 ######################################################################## openssl
110 LIB_ARG_WITH([openssl], [-lssl -lcrypto])
111 AC_CHECK_HEADER(openssl/ssl.h, [], [HAVE_OPENSSL=no])
112 AC_CHECK_LIB([crypto], [RAND_bytes], [], [HAVE_OPENSSL=no])
113 LIB_SUBST_FLAGS(openssl)
114 if test $HAVE_OPENSSL = yes; then
115 AC_CHECK_LIB([crypto], [RSA_set0_key],
116 AC_DEFINE([HAVE_RSA_SET0_KEY], [1], [openssl-1.1]))
119 ######################################################################### gcrypt
122 LIB_ARG_WITH([gcrypt], [-lgcrypt])
123 AC_CHECK_HEADER(gcrypt.h, [], [HAVE_GCRYPT=no])
124 AC_CHECK_LIB([gcrypt], [gcry_randomize], [], [HAVE_GCRYPT=no])
125 LIB_SUBST_FLAGS(gcrypt)
127 ######################################################################### crypto
128 AC_ARG_ENABLE(cryptolib, [AS_HELP_STRING(--enable-cryptolib=lib, [
129 Force using crypto library "lib". This package requires either
130 openssl or libgcrypt being installed. Possible values for "lib"
131 are thus "openssl" and "gcrypt". If this option is not given,
132 openssl is tried first. If openssl was not found, gcrypt is
135 CRYPTOLIB="$enable_cryptolib"
136 case "$enable_cryptolib" in
138 test $HAVE_OPENSSL = no && AC_MSG_ERROR(openssl not found)
139 crypto_ldflags="$openssl_ldflags"
142 test $HAVE_GCRYPT = no && AC_MSG_ERROR(gcrypt not found)
143 crypto_ldflags="$gcrypt_ldflags"
147 if test $HAVE_GCRYPT = yes; then
149 crypto_ldflags="$gcrypt_ldflags"
151 if test $HAVE_OPENSSL = yes; then
153 crypto_ldflags="$openssl_ldflags"
157 AC_MSG_ERROR([invalid value "$enable_cryptolib" for --enable-cryptolib])
160 AC_SUBST(crypto_ldflags)
161 ########################################################################## iconv
164 AC_SEARCH_LIBS([libiconv_open], [iconv],
165 [iconv_ldflags="$LIBS"],
168 AC_SUBST(iconv_ldflags)
169 AC_MSG_CHECKING([whether iconv needs const char ** cast])
174 size_t iconv(iconv_t cd, const char **inbuf,
175 size_t *inbytesleft, char **outbuf,
176 size_t *outbytesleft);
179 [cast='(const char **)'; msg=yes],
182 AC_DEFINE_UNQUOTED(ICONV_CAST, $cast, [cast for second arg to iconv()])
185 ########################################################################### ucred
186 AC_MSG_CHECKING(for struct ucred)
187 AC_LINK_IFELSE([AC_LANG_PROGRAM([[
188 #include <sys/types.h>
189 #include <sys/socket.h>
191 struct ucred sucred; sucred.pid=0;
192 ]])],[have_ucred=yes],[have_ucred=no])
193 AC_MSG_RESULT($have_ucred)
194 if test ${have_ucred} = yes; then
195 AC_DEFINE(HAVE_UCRED, 1, define to 1 you have struct ucred)
197 ########################################################################### curses
199 LIB_ARG_WITH([curses], [])
201 AC_CHECK_HEADER(curses.h, [], [HAVE_CURSES=no])
202 AC_SEARCH_LIBS([initscr], [ncursesw curses], [], [HAVE_CURSES=no])
203 curses_ldflags="$curses_ldflags $LIBS"
204 LIB_SUBST_FLAGS(curses)
206 ########################################################################### ip_mreqn
207 AC_MSG_CHECKING(for struct ip_mreqn (UDPv4 multicast))
208 AC_LINK_IFELSE([AC_LANG_PROGRAM([[
214 ]])],[have_ip_mreqn=yes],[have_ip_mreqn=no])
215 AC_MSG_RESULT($have_ip_mreqn)
216 if test ${have_ip_mreqn} = yes; then
217 AC_DEFINE(HAVE_IP_MREQN, 1, define to 1 you have struct ip_mreqn)
219 ########################################################################### osx
221 AC_MSG_CHECKING(for CoreAudio (MacOs))
222 AC_LINK_IFELSE([AC_LANG_PROGRAM([[
223 #include <CoreAudio/CoreAudio.h>
226 ]])],[have_core_audio=yes],[have_core_audio=no])
227 AC_MSG_RESULT($have_core_audio)
228 if test ${have_core_audio} = yes; then
229 f1="-framework CoreAudio"
230 f2="-framework AudioToolbox"
231 f3="-framework AudioUnit"
232 f4="-framework CoreServices"
233 core_audio_ldflags="$f1 $f2 $f3 $f4"
234 AC_SUBST(core_audio_ldflags)
235 AC_DEFINE(HAVE_CORE_AUDIO, 1, define to 1 on Mac Os X)
237 ########################################################################### ogg
239 LIB_ARG_WITH([ogg], [-logg])
241 AC_CHECK_HEADERS([ogg/ogg.h], [], [HAVE_OGG=no])
242 AC_CHECK_LIB([ogg], [ogg_stream_init], [], [HAVE_OGG=no])
243 AC_CHECK_LIB([ogg], [ogg_stream_flush_fill], [
244 AC_DEFINE(HAVE_OGG_STREAM_FLUSH_FILL, 1, [libogg >= 1.3.0])])
247 ######################################################################### vorbis
249 LIB_ARG_WITH([vorbis], [-lvorbis -lvorbisfile])
251 AC_CHECK_HEADERS([vorbis/codec.h], [], [HAVE_VORBIS=no])
252 AC_CHECK_LIB([vorbis], [vorbis_info_init], [], [HAVE_VORBIS=no])
253 LIB_SUBST_FLAGS(vorbis)
255 ######################################################################### speex
257 LIB_ARG_WITH([speex], [-lspeex])
259 AC_CHECK_HEADERS([speex/speex.h], [], [HAVE_SPEEX=no])
260 AC_CHECK_LIB([speex], [speex_decoder_init], [], [HAVE_SPEEX=no])
261 LIB_SUBST_FLAGS(speex)
263 ######################################################################### opus
265 LIB_ARG_WITH([opus], [-lopus])
267 AC_CHECK_HEADERS([opus/opus.h], [], [HAVE_OPUS=no])
268 AC_CHECK_LIB([opus], [opus_multistream_decode], [], [HAVE_OPUS=no])
269 LIB_SUBST_FLAGS(opus)
271 ########################################################################### flac
273 LIB_ARG_WITH([flac], [-lFLAC -lm])
275 AC_CHECK_HEADER(FLAC/stream_decoder.h, [], HAVE_FLAC=no)
276 AC_CHECK_LIB([FLAC], [FLAC__stream_decoder_init_file], [], HAVE_FLAC=no)
277 LIB_SUBST_FLAGS(flac)
280 # some helper functions for codecs which use the ogg container format
281 AC_DEFUN([NEED_OGG_OBJECTS], [{
282 test "$HAVE_OGG" = 'yes' -a \( \
283 "$HAVE_VORBIS" = 'yes' \
284 -o "$HAVE_SPEEX" = 'yes' \
285 -o "$HAVE_OPUS" = 'yes' \
286 -o "$HAVE_FLAC" = 'yes' \
289 AC_DEFUN([NEED_VORBIS_OBJECTS], [{
290 test "$HAVE_OGG" = 'yes' -a "$HAVE_VORBIS" = 'yes'
292 AC_DEFUN([NEED_SPEEX_OBJECTS], [{
293 test "$HAVE_OGG" = 'yes' -a "$HAVE_SPEEX" = 'yes'
295 AC_DEFUN([NEED_OPUS_OBJECTS], [{
296 test "$HAVE_OGG" = 'yes' -a "$HAVE_OPUS" = 'yes'
298 AC_DEFUN([NEED_FLAC_OBJECTS], [{
299 test "$HAVE_OGG" = 'yes' -a "$HAVE_FLAC" = 'yes'
301 ########################################################################### faad
303 LIB_ARG_WITH([faad], [-lfaad])
305 AC_CHECK_HEADER(neaacdec.h, [], HAVE_FAAD=no)
306 AC_CHECK_LIB([faad], [NeAACDecOpen], [], HAVE_FAAD=no)
307 LIB_SUBST_FLAGS(faad)
309 ########################################################################### mad
311 LIB_ARG_WITH([mad], [-lmad])
313 AC_CHECK_HEADER(mad.h, [], HAVE_MAD=no)
314 AC_CHECK_LIB([mad], [mad_stream_init], [], HAVE_MAD=no)
317 ###################################################################### libid3tag
319 LIB_ARG_WITH([id3tag], [-lid3tag -lz])
321 AC_CHECK_HEADER(id3tag.h, [], HAVE_ID3TAG=no)
322 AC_CHECK_LIB([id3tag], [id3_file_fdopen], [], HAVE_ID3TAG=no)
323 LIB_SUBST_FLAGS(id3tag)
325 ########################################################################### oss
327 LIB_ARG_WITH([oss], [])
328 AC_CHECK_HEADER(sys/soundcard.h, [HAVE_OSS=yes], [HAVE_OSS=no])
329 AC_CHECK_LIB(ossaudio, _oss_ioctl, [oss_ldflags="$oss_ldflags -lossaudio"], [])
332 ########################################################################### alsa
334 LIB_ARG_WITH([alsa], [-lasound])
336 AC_CHECK_HEADER(alsa/asoundlib.h, [], HAVE_ALSA=no)
337 AC_CHECK_LIB([asound], [snd_pcm_open], [], HAVE_ALSA=no)
338 LIB_SUBST_FLAGS(alsa)
340 ######################################################################### pthread
342 LIB_ARG_WITH([pthread], [-lpthread])
344 AC_CHECK_HEADER(pthread.h, [], HAVE_PTHREAD=no)
345 AC_CHECK_LIB([pthread], [pthread_create], [], HAVE_PTHREAD=no)
346 LIB_SUBST_FLAGS(pthread)
348 ########################################################################### libao
350 LIB_ARG_WITH([ao], [-lao])
352 AC_CHECK_HEADER(ao/ao.h, [], HAVE_AO=no)
353 AC_CHECK_LIB([ao], [ao_initialize], [], HAVE_AO=no)
356 AC_DEFUN([NEED_AO_OBJECTS], [{ test $HAVE_AO = yes -a $HAVE_PTHREAD = yes; }])
357 ######################################################################## readline
359 AC_SEARCH_LIBS([tgetent], [tinfo curses terminfo termcap])
360 LIB_ARG_WITH([readline], [-lreadline $LIBS])
362 AC_CHECK_HEADER([readline/readline.h], [], [HAVE_READLINE=no])
363 AC_CHECK_LIB([readline], [rl_free_keymap], [], HAVE_READLINE=no)
366 [AC_DEFINE(RL_FREE_KEYMAP_DECLARED, 1, readline >= 6.3)],
370 #include <readline/readline.h>
373 LIB_SUBST_FLAGS(readline)
375 ############################################################# libsamplerate
377 LIB_ARG_WITH([samplerate], [-lsamplerate])
379 AC_CHECK_HEADER(samplerate.h, [], HAVE_SAMPLERATE=no)
380 AC_CHECK_LIB([samplerate], [src_process], [], HAVE_SAMPLERATE=no)
381 LIB_SUBST_FLAGS(samplerate)
383 ########################################################################## mp4v2
385 LIB_ARG_WITH([mp4v2], [-lmp4v2])
387 AC_CHECK_HEADER([mp4v2/mp4v2.h], [], [HAVE_MP4V2=no])
388 AC_CHECK_LIB([mp4v2], [MP4Read], [], [HAVE_MP4V2=no])
389 LIB_SUBST_FLAGS(mp4v2)
391 ######################################################################### server
392 if test -n "$CRYPTOLIB" && test $HAVE_OSL = yes; then
394 executables="$executables server"
395 server_errlist_objs="
434 if test "$CRYPTOLIB" = openssl; then
435 server_errlist_objs="$server_errlist_objs crypt"
437 server_errlist_objs="$server_errlist_objs gcrypt"
439 NEED_OGG_OBJECTS() && server_errlist_objs="$server_errlist_objs ogg_afh_common"
440 NEED_VORBIS_OBJECTS() && server_errlist_objs="$server_errlist_objs ogg_afh"
441 NEED_SPEEX_OBJECTS() && server_errlist_objs="$server_errlist_objs spx_afh spx_common"
442 NEED_OPUS_OBJECTS() && server_errlist_objs="$server_errlist_objs opus_afh opus_common"
443 NEED_FLAC_OBJECTS && server_errlist_objs="$server_errlist_objs flac_afh"
444 if test $HAVE_FAAD = yes && test $HAVE_MP4V2 = yes; then
445 server_errlist_objs="$server_errlist_objs aac_afh aac_common"
447 server_objs="$server_errlist_objs"
448 AC_SUBST(server_objs, add_dot_o($server_objs))
452 ############################################################# client
453 if test -n "$CRYPTOLIB"; then
455 executables="$executables client"
456 client_errlist_objs="
472 if test "$CRYPTOLIB" = openssl; then
473 client_errlist_objs="$client_errlist_objs crypt"
475 client_errlist_objs="$client_errlist_objs gcrypt"
477 if test $HAVE_READLINE = yes; then
478 client_errlist_objs="$client_errlist_objs interactive"
480 client_objs="$client_errlist_objs"
481 AC_SUBST(client_objs, add_dot_o($client_errlist_objs))
485 ############################################################# audiod
486 if test -n "$CRYPTOLIB"; then
488 executables="$executables audiod"
489 audiod_audio_formats="wma"
490 audiod_errlist_objs="$audiod_errlist_objs
528 if test "$CRYPTOLIB" = openssl; then
529 audiod_errlist_objs="$audiod_errlist_objs crypt"
531 audiod_errlist_objs="$audiod_errlist_objs gcrypt"
533 if test "$have_core_audio" = "yes"; then
534 audiod_errlist_objs="$audiod_errlist_objs osx_write ipc"
536 NEED_VORBIS_OBJECTS && {
537 audiod_errlist_objs="$audiod_errlist_objs oggdec_filter"
538 audiod_audio_formats="$audiod_audio_formats ogg"
540 NEED_SPEEX_OBJECTS && {
541 audiod_errlist_objs="$audiod_errlist_objs spxdec_filter spx_common"
542 audiod_audio_formats="$audiod_audio_formats spx"
544 NEED_OPUS_OBJECTS && {
545 audiod_errlist_objs="$audiod_errlist_objs opusdec_filter opus_common"
546 audiod_audio_formats="$audiod_audio_formats opus"
548 NEED_FLAC_OBJECTS && {
549 audiod_errlist_objs="$audiod_errlist_objs flacdec_filter"
550 audiod_audio_formats="$audiod_audio_formats flac"
552 if test $HAVE_FAAD = yes; then
553 audiod_errlist_objs="$audiod_errlist_objs aacdec_filter aac_common"
554 audiod_audio_formats="$audiod_audio_formats aac"
556 if test $HAVE_MAD = yes; then
557 audiod_audio_formats="$audiod_audio_formats mp3"
558 audiod_errlist_objs="$audiod_errlist_objs mp3dec_filter"
560 if test $HAVE_OSS = yes; then
561 audiod_errlist_objs="$audiod_errlist_objs oss_write"
563 if test $HAVE_ALSA = yes; then
564 audiod_errlist_objs="$audiod_errlist_objs alsa_write"
567 audiod_errlist_objs="$audiod_errlist_objs ao_write"
569 if test $HAVE_SAMPLERATE = yes; then
570 audiod_errlist_objs="$audiod_errlist_objs resample_filter check_wav"
572 audiod_objs="$audiod_errlist_objs"
573 AC_SUBST(audiod_objs, add_dot_o($audiod_objs))
575 enum="$(for i in $audiod_audio_formats; do printf "AUDIO_FORMAT_${i}, " | tr '[a-z]' '[A-Z]'; done)"
576 AC_DEFINE_UNQUOTED(AUDIOD_AUDIO_FORMATS_ENUM, $enum NUM_AUDIO_FORMATS,
577 enum of audio formats supported by audiod)
578 names="$(for i in $audiod_audio_formats; do printf \"$i\",' ' ; done)"
579 AC_DEFINE_UNQUOTED(AUDIOD_AUDIO_FORMAT_ARRAY, $names, array of audio formats supported by audiod)
583 ########################################################################### mixer
584 if test $HAVE_OSS = yes -o $HAVE_ALSA = yes; then
586 executables="$executables mixer"
587 mixer_errlist_objs="mixer exec string fd version"
588 if test $HAVE_OSS = yes; then
589 mixer_errlist_objs="$mixer_errlist_objs oss_mix"
591 if test $HAVE_ALSA = yes; then
592 mixer_errlist_objs="$mixer_errlist_objs alsa_mix"
594 mixer_objs="$mixer_errlist_objs"
595 AC_SUBST(mixer_objs, add_dot_o($mixer_objs))
598 AC_MSG_WARN([no mixer support])
600 ########################################################################### gui
601 if test $HAVE_CURSES = yes; then
603 executables="$executables gui"
617 gui_objs="$gui_errlist_objs"
618 AC_SUBST(gui_objs, add_dot_o($gui_objs))
621 AC_MSG_WARN([no curses lib, cannot build para_gui])
623 ######################################################################## filter
624 filter_errlist_objs="
648 NEED_VORBIS_OBJECTS && filter_errlist_objs="$filter_errlist_objs oggdec_filter"
649 NEED_SPEEX_OBJECTS && filter_errlist_objs="$filter_errlist_objs spxdec_filter spx_common"
650 NEED_OPUS_OBJECTS && filter_errlist_objs="$filter_errlist_objs opusdec_filter opus_common"
651 NEED_FLAC_OBJECTS && filter_errlist_objs="$filter_errlist_objs flacdec_filter"
652 if test $HAVE_FAAD = yes; then
653 filter_errlist_objs="$filter_errlist_objs aacdec_filter aac_common"
655 if test $HAVE_MAD = yes; then
656 filter_errlist_objs="$filter_errlist_objs mp3dec_filter"
658 if test $HAVE_SAMPLERATE = yes; then
659 filter_errlist_objs="$filter_errlist_objs resample_filter check_wav"
661 filter_objs="$filter_errlist_objs"
663 AC_SUBST(filter_objs, add_dot_o($filter_objs))
664 ########################################################################## recv
685 NEED_OGG_OBJECTS && recv_errlist_objs="$recv_errlist_objs ogg_afh_common"
686 NEED_VORBIS_OBJECTS && recv_errlist_objs="$recv_errlist_objs ogg_afh"
687 NEED_SPEEX_OBJECTS && recv_errlist_objs="$recv_errlist_objs spx_afh spx_common"
688 NEED_OPUS_OBJECTS && recv_errlist_objs="$recv_errlist_objs opus_afh opus_common"
689 NEED_FLAC_OBJECTS && recv_errlist_objs="$recv_errlist_objs flac_afh"
691 if test $HAVE_FAAD = yes -a $HAVE_MP4V2 = yes; then
692 recv_errlist_objs="$recv_errlist_objs aac_afh aac_common"
694 recv_objs="$recv_errlist_objs"
695 AC_SUBST(recv_objs, add_dot_o($recv_objs))
696 ########################################################################### afh
697 audio_format_handlers="mp3 wma"
709 NEED_OGG_OBJECTS && afh_errlist_objs="$afh_errlist_objs ogg_afh_common"
710 NEED_VORBIS_OBJECTS && {
711 afh_errlist_objs="$afh_errlist_objs ogg_afh"
712 audio_format_handlers="$audio_format_handlers ogg"
714 NEED_SPEEX_OBJECTS && {
715 afh_errlist_objs="$afh_errlist_objs spx_afh spx_common"
716 audio_format_handlers="$audio_format_handlers spx"
718 NEED_OPUS_OBJECTS && {
719 afh_errlist_objs="$afh_errlist_objs opus_afh opus_common"
720 audio_format_handlers="$audio_format_handlers opus"
722 NEED_FLAC_OBJECTS && {
723 afh_errlist_objs="$afh_errlist_objs flac_afh"
724 audio_format_handlers="$audio_format_handlers flac"
726 if test $HAVE_FAAD = yes -a $HAVE_MP4V2 = yes; then
727 afh_errlist_objs="$afh_errlist_objs aac_afh aac_common"
728 audio_format_handlers="$audio_format_handlers aac"
731 afh_objs="$afh_errlist_objs"
733 AC_SUBST(afh_objs, add_dot_o($afh_objs))
734 ########################################################################## play
767 if test "$have_core_audio" = "yes"; then
768 play_errlist_objs="$play_errlist_objs osx_write ipc"
770 NEED_OGG_OBJECTS && play_errlist_objs="$play_errlist_objs ogg_afh_common"
771 NEED_VORBIS_OBJECTS && {
772 play_errlist_objs="$play_errlist_objs oggdec_filter ogg_afh"
774 NEED_SPEEX_OBJECTS && {
775 play_errlist_objs="$play_errlist_objs spxdec_filter spx_afh spx_common"
778 play_errlist_objs="$play_errlist_objs
783 NEED_FLAC_OBJECTS && {
784 play_errlist_objs="$play_errlist_objs flacdec_filter flac_afh"
786 if test $HAVE_FAAD = yes; then
787 play_errlist_objs="$play_errlist_objs aacdec_filter"
789 if test $HAVE_MP4V2 = yes; then
790 play_errlist_objs="$play_errlist_objs aac_afh"
792 if test $HAVE_MP4V2 = yes || test $HAVE_FAAD = yes; then
793 play_errlist_objs="$play_errlist_objs aac_common"
795 if test $HAVE_MAD = yes; then
796 play_errlist_objs="$play_errlist_objs mp3dec_filter"
798 if test $HAVE_OSS = yes; then
799 play_errlist_objs="$play_errlist_objs oss_write"
801 if test $HAVE_ALSA = yes; then
802 play_errlist_objs="$play_errlist_objs alsa_write"
805 play_errlist_objs="$play_errlist_objs ao_write"
807 if test $HAVE_READLINE = yes; then
808 play_errlist_objs="$play_errlist_objs interactive"
810 if test $HAVE_SAMPLERATE = yes; then
811 play_errlist_objs="$play_errlist_objs resample_filter check_wav"
814 play_objs="$play_errlist_objs"
815 AC_SUBST(play_objs, add_dot_o($play_objs))
816 ######################################################################### write
831 if test "$have_core_audio" = "yes"; then
832 write_errlist_objs="$write_errlist_objs osx_write ipc"
835 write_errlist_objs="$write_errlist_objs ao_write"
837 if test $HAVE_OSS = yes; then
838 write_errlist_objs="$write_errlist_objs oss_write"
840 if test $HAVE_ALSA = yes; then
841 write_errlist_objs="$write_errlist_objs alsa_write"
843 write_objs="$write_errlist_objs"
844 AC_SUBST(write_objs, add_dot_o($write_objs))
845 ######################################################################## audioc
846 audioc_errlist_objs="
853 if test $HAVE_READLINE = yes; then
854 audioc_errlist_objs="$audioc_errlist_objs
861 audioc_objs="$audioc_errlist_objs"
862 AC_SUBST(audioc_objs, add_dot_o($audioc_objs))
863 ################################################################## status items
865 status_items="basename status num_played mtime bitrate frequency file_size
866 status_flags format score techinfo afs_mode
867 attributes_txt decoder_flags audiod_status play_time attributes_bitmap
868 offset seconds_total stream_start current_time audiod_uptime image_id
869 lyrics_id duration directory lyrics_name image_name path hash channels
870 last_played num_chunks chunk_time amplification artist title year album
874 for i in $status_items; do
875 result="$result SI_$(echo $i | tr 'a-z' 'A-Z'), "
877 AC_DEFINE_UNQUOTED(STATUS_ITEM_ENUM, [$result],
878 [enum of all status items])
881 for i in $status_items; do
882 result="$result \"$i\", "
884 AC_DEFINE_UNQUOTED(STATUS_ITEM_ARRAY, [$result],
885 [char * array of all status items])
887 AC_DEFINE_UNQUOTED(AUDIO_FORMAT_HANDLERS, "$audio_format_handlers",
888 [formats supported by para_server and para_afh])
890 AC_SUBST(executables)
894 paraslash configuration:
895 ~~~~~~~~~~~~~~~~~~~~~~~~
896 crypto lib: ${CRYPTOLIB:-[none]}
897 unix socket credentials: $have_ucred
898 readline (interactive CLIs): $HAVE_READLINE
899 id3 version 2 support: $HAVE_ID3TAG
902 audio format handlers: $audio_format_handlers
904 para_server: $build_server
906 para_mixer: $build_mixer
907 para_client: $build_client
908 para_audiod: $build_audiod