X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=configure.ac;h=abf8c071b8a53091ec3c263576fa9f6fae5a74cd;hp=06ce1c34a8236f04f2465d18297ea024794a64b1;hb=0f4790f2eb859832419e5aeb3d4549fbde3b0499;hpb=0c86265181e1cc1fa3026d5796767376d8aed15c diff --git a/configure.ac b/configure.ac index 06ce1c34..abf8c071 100644 --- a/configure.ac +++ b/configure.ac @@ -193,9 +193,6 @@ if test "$check_openssl" = "yes"; then openssl_ldflags="$openssl_libs -lssl -lcrypto" AC_SUBST(openssl_ldflags) - client_errlist_objs="$client_errlist_objs crypt" - audiod_errlist_objs="$audiod_errlist_objs crypt" - check_gcrypt="no" else AC_MSG_WARN([openssl libraries not found]) @@ -231,9 +228,6 @@ if test "$check_gcrypt" = "yes"; then AC_SUBST(gcrypt_cppflags) gcrypt_ldflags="$gcrypt_libs -lgcrypt" AC_SUBST(gcrypt_ldflags) - - client_errlist_objs="$client_errlist_objs gcrypt" - audiod_errlist_objs="$audiod_errlist_objs gcrypt" else AC_MSG_WARN([gcrypt library not found]) fi @@ -340,10 +334,6 @@ if test ${have_core_audio} = yes; then f4="-framework CoreServices" core_audio_ldflags="$f1 $f2 $f3 $f4" AC_SUBST(core_audio_ldflags) - - audiod_errlist_objs="$audiod_errlist_objs osx_write ipc" - audiod_cmdline_objs="$audiod_cmdline_objs osx_write.cmdline" - AC_DEFINE(HAVE_CORE_AUDIO, 1, define to 1 on Mac Os X) fi ####################################################### ogg/vorbis/speex/opus @@ -440,10 +430,6 @@ if test "$have_vorbis" = "yes"; then AC_DEFINE(HAVE_OGGVORBIS, 1, define to 1 to turn on ogg/vorbis support) vorbis_ldflags="$vorbis_libs -lvorbis -lvorbisfile" AC_SUBST(vorbis_ldflags) - - audiod_errlist_objs="$audiod_errlist_objs oggdec_filter" - - audiod_audio_formats="$audiod_audio_formats ogg" audio_format_handlers="$audio_format_handlers ogg" fi if test "$have_speex" = "yes"; then @@ -451,11 +437,6 @@ if test "$have_speex" = "yes"; then AC_SUBST(speex_cppflags) speex_ldflags="$speex_libs -lspeex" AC_SUBST(speex_ldflags) - - - audiod_errlist_objs="$audiod_errlist_objs spxdec_filter spx_common" - - audiod_audio_formats="$audiod_audio_formats spx" audio_format_handlers="$audio_format_handlers spx" else AC_MSG_WARN([no ogg/speex $msg]) @@ -465,11 +446,6 @@ if test "$have_opus" = "yes"; then AC_SUBST(opus_cppflags) opus_ldflags="$opus_libs -lopus" AC_SUBST(opus_ldflags) - - - audiod_errlist_objs="$audiod_errlist_objs opusdec_filter opus_common" - - audiod_audio_formats="$audiod_audio_formats opus" audio_format_handlers="$audio_format_handlers opus" else AC_MSG_WARN([no ogg/opus $msg]) @@ -502,9 +478,6 @@ if test "$have_faad" = "yes"; then faad_ldflags="$faad_libs -lfaad" AC_SUBST(faad_ldflags) - audiod_errlist_objs="$audiod_errlist_objs aacdec_filter aac_common" - - audiod_audio_formats="$audiod_audio_formats aac" audio_format_handlers="$audio_format_handlers aac" fi CPPFLAGS="$OLD_CPPFLAGS" @@ -539,9 +512,6 @@ if test "$have_mad" = "yes"; then AC_SUBST(mad_cppflags) mad_ldflags="$mad_libs -lmad" AC_SUBST(mad_ldflags) - audiod_cmdline_objs="$audiod_cmdline_objs mp3dec_filter" - audiod_errlist_objs="$audiod_errlist_objs mp3dec_filter" - audiod_audio_formats="$audiod_audio_formats mp3" else AC_MSG_WARN([no mp3dec support in para_audiod/para_filter]) fi @@ -608,10 +578,7 @@ if test "$have_flac" = "yes"; then AC_SUBST(flac_cppflags) flac_ldflags="$flac_libs -lFLAC" AC_SUBST(flac_ldflags) - - audiod_errlist_objs="$audiod_errlist_objs flacdec_filter" audio_format_handlers="$audio_format_handlers flac" - audiod_audio_formats="$audiod_audio_formats flac" else AC_MSG_WARN([no flac support in para_audiod/para_filter/para_afh/para_server]) fi @@ -627,9 +594,6 @@ have_oss="yes" msg="=> will not build oss writer" AC_CHECK_HEADER(sys/soundcard.h, [ - audiod_errlist_objs="$audiod_errlist_objs oss_write" - audiod_cmdline_objs="$audiod_cmdline_objs oss_write" - fade_errlist_objs="$fade_errlist_objs oss_mix" mixers="${mixers}oss " @@ -678,9 +642,6 @@ fi if test "$have_alsa" = "yes"; then alsa_ldflags="-lasound" AC_SUBST(alsa_ldflags) - audiod_errlist_objs="$audiod_errlist_objs alsa_write" - audiod_cmdline_objs="$audiod_cmdline_objs alsa_write" - fade_errlist_objs="$fade_errlist_objs alsa_mix" mixers="${mixers}alsa " @@ -737,10 +698,6 @@ if test "$have_ao" = "yes"; then AC_SUBST(ao_cppflags) ao_ldflags="$ao_libs -lao -lpthread" AC_SUBST(ao_ldflags) - - audiod_errlist_objs="$audiod_errlist_objs ao_write" - audiod_cmdline_objs="$audiod_cmdline_objs ao_write" - fi CPPFLAGS="$OLD_CPPFLAGS" @@ -802,9 +759,9 @@ if test "$have_readline" = "yes"; then fi if test "$have_readline" = "yes"; then + : AC_SUBST(readline_cppflags) AC_SUBST(readline_ldflags) - client_errlist_objs="$client_errlist_objs interactive" AC_DEFINE(HAVE_READLINE, 1, define to 1 to turn on readline support) else AC_MSG_WARN([libreadline not found or unusable]) @@ -838,9 +795,6 @@ if test "$have_samplerate" = "yes"; then AC_SUBST(samplerate_cppflags) samplerate_ldflags="$samplerate_libs -lsamplerate" AC_SUBST(samplerate_ldflags) - - audiod_errlist_objs="$audiod_errlist_objs resample_filter check_wav" - audiod_cmdline_objs="$audiod_cmdline_objs resample_filter" else AC_MSG_WARN([no resample support in para_audiod/para_filter]) fi @@ -931,7 +885,7 @@ if test "$have_openssl" = "yes" -o "$have_gcrypt" = "yes"; then build_client="yes" executables="$executables client" client_cmdline_objs="client" - client_errlist_objs="$client_errlist_objs + client_errlist_objs=" client net string @@ -947,6 +901,19 @@ if test "$have_openssl" = "yes" -o "$have_gcrypt" = "yes"; then version ggo " + if test "$have_openssl" = "yes"; then + client_errlist_objs="$client_errlist_objs crypt" + fi + if test "$have_gcrypt" = "yes"; then + client_errlist_objs="$client_errlist_objs gcrypt" + fi + if test "$have_readline" = "yes"; then + client_errlist_objs="$client_errlist_objs interactive" + fi + client_objs="add_cmdline($client_cmdline_objs) $client_errlist_objs" + AC_SUBST(client_objs, add_dot_o($client_objs)) + AC_DEFINE_UNQUOTED(INIT_CLIENT_ERRLISTS, + objlist_to_errlist($client_errlist_objs), errors used by para_client) else build_client="no" fi @@ -954,6 +921,7 @@ fi if test "$have_openssl" = "yes" -o "$have_gcrypt" = "yes"; then build_audiod="yes" executables="$executables audiod" + audiod_audio_formats="wma" audiod_cmdline_objs="$audiod_cmdline_objs audiod compress_filter @@ -1002,8 +970,67 @@ if test "$have_openssl" = "yes" -o "$have_gcrypt" = "yes"; then wmadec_filter buffer_tree " - audiod_ldflags="$audiod_ldflags -lm" - audiod_audio_formats="$audiod_audio_formats wma" + if test "$have_openssl" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs crypt" + fi + if test "$have_gcrypt" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs gcrypt" + fi + if test "$have_core_audio" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs osx_write ipc" + audiod_cmdline_objs="$audiod_cmdline_objs osx_write.cmdline" + fi + if test "$have_vorbis" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs oggdec_filter" + audiod_audio_formats="$audiod_audio_formats ogg" + fi + if test "$have_speex" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs spxdec_filter spx_common" + audiod_audio_formats="$audiod_audio_formats spx" + fi + if test "$have_opus" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs opusdec_filter opus_common" + audiod_audio_formats="$audiod_audio_formats opus" + fi + if test "$have_faad" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs aacdec_filter aac_common" + audiod_audio_formats="$audiod_audio_formats aac" + fi + if test "$have_mad" = "yes"; then + audiod_audio_formats="$audiod_audio_formats mp3" + audiod_cmdline_objs="$audiod_cmdline_objs mp3dec_filter" + audiod_errlist_objs="$audiod_errlist_objs mp3dec_filter" + fi + if test "$have_flac" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs flacdec_filter" + audiod_audio_formats="$audiod_audio_formats flac" + fi + if test "$have_oss" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs oss_write" + audiod_cmdline_objs="$audiod_cmdline_objs oss_write" + fi + if test "$have_alsa" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs alsa_write" + audiod_cmdline_objs="$audiod_cmdline_objs alsa_write" + fi + if test "$have_ao" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs ao_write" + audiod_cmdline_objs="$audiod_cmdline_objs ao_write" + fi + if test "$have_samplerate" = "yes"; then + audiod_errlist_objs="$audiod_errlist_objs resample_filter check_wav" + audiod_cmdline_objs="$audiod_cmdline_objs resample_filter" + fi + audiod_objs="add_cmdline($audiod_cmdline_objs) $audiod_errlist_objs" + AC_SUBST(audiod_objs, add_dot_o($audiod_objs)) + AC_DEFINE_UNQUOTED(INIT_AUDIOD_ERRLISTS, objlist_to_errlist($audiod_errlist_objs), + errors used by para_audiod) + + enum="$(for i in $audiod_audio_formats; do printf "AUDIO_FORMAT_${i}, " | tr '[a-z]' '[A-Z]'; done)" + AC_DEFINE_UNQUOTED(AUDIOD_AUDIO_FORMATS_ENUM, $enum NUM_AUDIO_FORMATS, + enum of audio formats supported by audiod) + names="$(for i in $audiod_audio_formats; do printf \"$i\",' ' ; done)" + AC_DEFINE_UNQUOTED(AUDIOD_AUDIO_FORMAT_ARRAY, $names, array of audio formats supported by audiod) else build_audiod="no" fi @@ -1485,23 +1512,11 @@ AC_DEFINE_UNQUOTED(AUDIO_FORMAT_HANDLERS, "$audio_format_handlers", AC_SUBST(executables) filter_objs="add_cmdline($filter_cmdline_objs) $filter_errlist_objs" -audiod_objs="add_cmdline($audiod_cmdline_objs) $audiod_errlist_objs" -client_objs="add_cmdline($client_cmdline_objs) $client_errlist_objs" AC_SUBST(filter_objs, add_dot_o($filter_objs)) AC_DEFINE_UNQUOTED(INIT_FILTER_ERRLISTS, objlist_to_errlist($filter_errlist_objs), errors used by para_filter) -AC_SUBST(audiod_objs, add_dot_o($audiod_objs)) -AC_SUBST(audiod_ldflags, $audiod_ldflags) -AC_DEFINE_UNQUOTED(INIT_AUDIOD_ERRLISTS, objlist_to_errlist($audiod_errlist_objs), - errors used by para_audiod) - -AC_SUBST(client_objs, add_dot_o($client_objs)) -AC_SUBST(client_ldflags, $client_ldflags) -AC_DEFINE_UNQUOTED(INIT_CLIENT_ERRLISTS, - objlist_to_errlist($client_errlist_objs), errors used by para_client) - AC_SUBST(gui_objs, add_dot_o($gui_objs)) AC_DEFINE_UNQUOTED(INIT_GUI_ERRLISTS, objlist_to_errlist($gui_errlist_objs), errors used by para_gui) @@ -1514,12 +1529,6 @@ AC_DEFINE_UNQUOTED(DECLARE_FILTER_INITS, $inits, init functions of the supported array="$(for i in $filters; do printf '{.name = "'$i'", .init = '$i'_filter_init},'; done)" AC_DEFINE_UNQUOTED(FILTER_ARRAY, $array, array of supported filters) -enum="$(for i in $audiod_audio_formats; do printf "AUDIO_FORMAT_${i}, " | tr '[a-z]' '[A-Z]'; done)" -AC_DEFINE_UNQUOTED(AUDIOD_AUDIO_FORMATS_ENUM, $enum NUM_AUDIO_FORMATS, - enum of audio formats supported by audiod) -names="$(for i in $audiod_audio_formats; do printf \"$i\",' ' ; done)" -AC_DEFINE_UNQUOTED(AUDIOD_AUDIO_FORMAT_ARRAY, $names, array of audio formats supported by audiod) - AC_OUTPUT AC_MSG_NOTICE([ paraslash configuration: