1
0
mirror of https://gitlab.xiph.org/xiph/icecast-server.git synced 2024-11-03 04:17:17 -05:00

Copied back from ices/m4/shout.m4 1.2. There must be a better way of keeping

these m4 macros synchronised.

svn path=/trunk/m4/; revision=4944
This commit is contained in:
brendan 2003-06-13 22:20:26 +00:00
parent 055160b09a
commit 4e4a6f9aef

View File

@ -14,26 +14,32 @@ SHOUT_LIBS=""
# Step 1: Use pkg-config if available
m4_ifdef([PKG_CHECK_MODULES],
[# PKG_CHECK_MODULES available
PKG_CHECK_MODULES([SHOUT], [shout >= 2.0])
PKG_CHECK_MODULES([SHOUT], [shout])
have_shout="maybe"],
[# PKG_CHECK_MODULES is unavailable, search for pkg-config program
AC_PATH_PROG([PKGCONFIG], [pkg-config], [none])
if test "$PKGCONFIG" != "none" && `$PKGCONFIG --exists 'shout >= 2.0'`
if test "$PKGCONFIG" != "none" && `$PKGCONFIG --exists shout`
then
SHOUT_CFLAGS=`$PKGCONFIG --cflags`
SHOUT_LIBS=`$PKGCONFIG --libs`
SHOUT_CFLAGS=`$PKGCONFIG --cflags shout`
SHOUT_LIBS=`$PKGCONFIG --libs shout`
have_shout="maybe"
else
if test "$PKGCONFIG" != "none"
then
AC_MSG_NOTICE([$PKGCONFIG couldn't find libshout. Try adjusting PKG_CONFIG_PATH.])
fi
# Step 2: try shout-config
AC_PATH_PROG([SHOUTCONFIG], [shout-config], [none])
if test "$SHOUTCONFIG" != "none" -a `$SHOUTCONFIG --package` = "libshout"
if test "$SHOUTCONFIG" != "none" && test `$SHOUTCONFIG --package` = "libshout"
then
SHOUT_CFLAGS=`$SHOUTCONFIG --cflags`
SHOUT_LIBS=`$SHOUTCONFIG --libs`
have_shout="maybe"
fi
fi
])
# Now try actually using libshout
if test "$have_shout" != "no"
then
ac_save_CFLAGS="$CFLAGS"
@ -55,5 +61,4 @@ m4_ifdef([PKG_CHECK_MODULES],
then
ifelse([$2], , :, [$2])
fi
])
])dnl XIPH_PATH_SHOUT