configure.ac: use MPD_AUTO for libsndio and Haiku
This commit is contained in:
parent
f95e404be1
commit
d30a590d9e
10
Makefile.am
10
Makefile.am
@ -349,7 +349,7 @@ endif
|
|||||||
src/haiku/mpd.rsrc: src/haiku/mpd.rdef
|
src/haiku/mpd.rsrc: src/haiku/mpd.rdef
|
||||||
$(RC) -o $@ $<
|
$(RC) -o $@ $<
|
||||||
|
|
||||||
if HAVE_HAIKU
|
if ENABLE_HAIKU
|
||||||
noinst_DATA = src/haiku/mpd.rdef
|
noinst_DATA = src/haiku/mpd.rdef
|
||||||
|
|
||||||
EXTRA_src_mpd_DEPENDENCIES = src/haiku/mpd.rsrc
|
EXTRA_src_mpd_DEPENDENCIES = src/haiku/mpd.rsrc
|
||||||
@ -1313,9 +1313,11 @@ liboutput_plugins_a_CPPFLAGS = $(AM_CPPFLAGS) \
|
|||||||
$(AO_CFLAGS) \
|
$(AO_CFLAGS) \
|
||||||
$(ALSA_CFLAGS) \
|
$(ALSA_CFLAGS) \
|
||||||
$(JACK_CFLAGS) \
|
$(JACK_CFLAGS) \
|
||||||
|
$(HAIKU_CFLAGS) \
|
||||||
$(OPENAL_CFLAGS) \
|
$(OPENAL_CFLAGS) \
|
||||||
$(OPENSSL_CFLAGS) \
|
$(OPENSSL_CFLAGS) \
|
||||||
$(PULSE_CFLAGS) \
|
$(PULSE_CFLAGS) \
|
||||||
|
$(SNDIO_CFLAGS) \
|
||||||
$(SHOUT_CFLAGS)
|
$(SHOUT_CFLAGS)
|
||||||
|
|
||||||
OUTPUT_LIBS = \
|
OUTPUT_LIBS = \
|
||||||
@ -1325,7 +1327,9 @@ OUTPUT_LIBS = \
|
|||||||
$(ALSA_LIBS) \
|
$(ALSA_LIBS) \
|
||||||
$(ROAR_LIBS) \
|
$(ROAR_LIBS) \
|
||||||
$(JACK_LIBS) \
|
$(JACK_LIBS) \
|
||||||
|
$(HAIKU_LIBS) \
|
||||||
$(OPENAL_LIBS) \
|
$(OPENAL_LIBS) \
|
||||||
|
$(SNDIO_LIBS) \
|
||||||
$(SHOUT_LIBS)
|
$(SHOUT_LIBS)
|
||||||
|
|
||||||
OUTPUT_API_SRC = \
|
OUTPUT_API_SRC = \
|
||||||
@ -1410,13 +1414,13 @@ liboutput_plugins_a_SOURCES += \
|
|||||||
src/output/plugins/FifoOutputPlugin.hxx
|
src/output/plugins/FifoOutputPlugin.hxx
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if HAVE_SNDIO
|
if ENABLE_SNDIO
|
||||||
liboutput_plugins_a_SOURCES += \
|
liboutput_plugins_a_SOURCES += \
|
||||||
src/output/plugins/SndioOutputPlugin.cxx \
|
src/output/plugins/SndioOutputPlugin.cxx \
|
||||||
src/output/plugins/SndioOutputPlugin.hxx
|
src/output/plugins/SndioOutputPlugin.hxx
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if HAVE_HAIKU
|
if ENABLE_HAIKU
|
||||||
liboutput_plugins_a_SOURCES += \
|
liboutput_plugins_a_SOURCES += \
|
||||||
src/output/plugins/HaikuOutputPlugin.cxx \
|
src/output/plugins/HaikuOutputPlugin.cxx \
|
||||||
src/output/plugins/HaikuOutputPlugin.hxx
|
src/output/plugins/HaikuOutputPlugin.hxx
|
||||||
|
41
configure.ac
41
configure.ac
@ -343,16 +343,6 @@ AC_ARG_ENABLE(fifo,
|
|||||||
[disable support for writing audio to a FIFO (default: enable)]),,
|
[disable support for writing audio to a FIFO (default: enable)]),,
|
||||||
enable_fifo=yes)
|
enable_fifo=yes)
|
||||||
|
|
||||||
AC_ARG_ENABLE(sndio,
|
|
||||||
AS_HELP_STRING([--enable-sndio],
|
|
||||||
[enable support for sndio output plugin (default: auto)]),,
|
|
||||||
enable_sndio=auto)
|
|
||||||
|
|
||||||
AC_ARG_ENABLE(haiku,
|
|
||||||
AS_HELP_STRING([--enable-haiku],
|
|
||||||
[enable the Haiku output plugin (default: auto)]),,
|
|
||||||
enable_haiku=auto)
|
|
||||||
|
|
||||||
AC_ARG_ENABLE(httpd-output,
|
AC_ARG_ENABLE(httpd-output,
|
||||||
AS_HELP_STRING([--enable-httpd-output],
|
AS_HELP_STRING([--enable-httpd-output],
|
||||||
[enables the HTTP server output]),,
|
[enables the HTTP server output]),,
|
||||||
@ -1129,31 +1119,16 @@ MPD_DEFINE_CONDITIONAL(enable_fifo, HAVE_FIFO,
|
|||||||
[support for writing audio to a FIFO])
|
[support for writing audio to a FIFO])
|
||||||
|
|
||||||
dnl ----------------------------------- SNDIO ----------------------------------
|
dnl ----------------------------------- SNDIO ----------------------------------
|
||||||
if test x$enable_sndio = xauto; then
|
MPD_ENABLE_AUTO_HEADER([sndio], [SNDIO], [sndio.h],
|
||||||
AC_CHECK_HEADER(sndio.h,
|
[-lsndio], [],
|
||||||
[enable_sndio=yes],
|
[sndio output plugin],
|
||||||
[enable_sndio=no;AC_MSG_WARN([sndio.h not found -- disabling support for sndio output])])
|
[libsndio not found])
|
||||||
fi
|
|
||||||
|
|
||||||
if test x$enable_sndio = xyes; then
|
|
||||||
AC_DEFINE(HAVE_SNDIO,1,[Define for compiling sndio support])
|
|
||||||
LIBS="$LIBS -lsndio"
|
|
||||||
fi
|
|
||||||
|
|
||||||
AM_CONDITIONAL(HAVE_SNDIO, test x$enable_sndio = xyes)
|
|
||||||
|
|
||||||
dnl ----------------------------------- Haiku ---------------------------------
|
dnl ----------------------------------- Haiku ---------------------------------
|
||||||
if test x$enable_haiku = xauto; then
|
MPD_ENABLE_AUTO_HEADER([haiku], [HAIKU], [media/MediaDefs.h],
|
||||||
AC_CHECK_HEADER(media/MediaDefs.h,
|
[-lbe -lmedia], [],
|
||||||
[enable_haiku=yes],
|
[Haiku output plugin],
|
||||||
[enable_haiku=no])
|
[Haiku headers not found])
|
||||||
fi
|
|
||||||
if test x$enable_haiku = xyes; then
|
|
||||||
AC_DEFINE(HAVE_HAIKU,1,[Define for compiling Haiku support])
|
|
||||||
LIBS="$LIBS -lbe -lmedia"
|
|
||||||
fi
|
|
||||||
|
|
||||||
AM_CONDITIONAL(HAVE_HAIKU, test x$enable_haiku = xyes)
|
|
||||||
|
|
||||||
dnl ------------------------------- HTTPD Output ------------------------------
|
dnl ------------------------------- HTTPD Output ------------------------------
|
||||||
if test x$enable_httpd_output = xauto; then
|
if test x$enable_httpd_output = xauto; then
|
||||||
|
@ -89,6 +89,19 @@ AC_DEFUN([MPD_AUTO_LIB], [
|
|||||||
[$5])])
|
[$5])])
|
||||||
])
|
])
|
||||||
|
|
||||||
|
dnl Wrapper for AC_CHECK_HEADER.
|
||||||
|
dnl
|
||||||
|
dnl Parameters: varname1, varname2, header, libs, cflags, description, errmsg
|
||||||
|
AC_DEFUN([MPD_AUTO_HEADER], [
|
||||||
|
AC_SUBST([$2_LIBS], [])
|
||||||
|
AC_SUBST([$2_CFLAGS], [])
|
||||||
|
|
||||||
|
MPD_AUTO([$1], [$6], [$7],
|
||||||
|
[AC_CHECK_HEADER([$3],
|
||||||
|
[found_$1=yes $2_LIBS='$4' $2_CFLAGS='$5'],
|
||||||
|
[found_$1=no])])
|
||||||
|
])
|
||||||
|
|
||||||
dnl Convert the given string into a string for the "default value" in
|
dnl Convert the given string into a string for the "default value" in
|
||||||
dnl the help text. If the string is a literal, then it is returned
|
dnl the help text. If the string is a literal, then it is returned
|
||||||
dnl as-is; if it contains a variable reference, just "auto" is
|
dnl as-is; if it contains a variable reference, just "auto" is
|
||||||
@ -153,6 +166,16 @@ AC_DEFUN([MPD_ENABLE_AUTO_LIB], [
|
|||||||
])
|
])
|
||||||
])
|
])
|
||||||
|
|
||||||
|
dnl Wrapper for AC_ARG_ENABLE and MPD_AUTO_HEADER
|
||||||
|
dnl
|
||||||
|
dnl Parameters: varname1, varname2, header, libs, cflags, description, errmsg, default, pre
|
||||||
|
AC_DEFUN([MPD_ENABLE_AUTO_HEADER], [
|
||||||
|
MPD_ARG_ENABLE([$1], [$2], [$6], [$8], [
|
||||||
|
$9
|
||||||
|
MPD_AUTO_HEADER($1, $2, $3, $4, $5, $6, $7)
|
||||||
|
])
|
||||||
|
])
|
||||||
|
|
||||||
dnl Wrapper for MPD_ENABLE_AUTO_PKG and MPD_DEPENDS
|
dnl Wrapper for MPD_ENABLE_AUTO_PKG and MPD_DEPENDS
|
||||||
dnl
|
dnl
|
||||||
dnl Parameters: varname1, varname2, pkg, description, errmsg, default, dep_variable, dep_errmsg
|
dnl Parameters: varname1, varname2, pkg, description, errmsg, default, dep_variable, dep_errmsg
|
||||||
|
@ -53,10 +53,10 @@ const AudioOutputPlugin *const audio_output_plugins[] = {
|
|||||||
#ifdef HAVE_FIFO
|
#ifdef HAVE_FIFO
|
||||||
&fifo_output_plugin,
|
&fifo_output_plugin,
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_SNDIO
|
#ifdef ENABLE_SNDIO
|
||||||
&sndio_output_plugin,
|
&sndio_output_plugin,
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_HAIKU
|
#ifdef ENABLE_HAIKU
|
||||||
&haiku_output_plugin,
|
&haiku_output_plugin,
|
||||||
#endif
|
#endif
|
||||||
#ifdef ENABLE_PIPE_OUTPUT
|
#ifdef ENABLE_PIPE_OUTPUT
|
||||||
|
Loading…
Reference in New Issue
Block a user