configure and alsa on Fedora Core 2
Huub van den Heuvel <[email protected]> Thu, 17 Jun 2004 21:44:22 +1000
| Newsgroups | gmane.comp.video.ogle.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi all,
I found a bug in the ./configure script that comes with
ogle-0.9.2.tar.gz:
I am using Fedora Core 2 with a custom build kernel (2.6.7-rc3) and ran
$ ./configure --enable-alsa=yes --disable-oss
The alsa version that comes with the 2.6.7 kernel is 1.0.3 but the
configure script disabled the alsa because it couldn't find a version
0.9 or higher:
checking for alsa version... found 0.5.x
configure: WARNING: Disabling ALSA support, install a 0.9.x version
I couldn't quite figure out what the configure script was doing exactly,
but eventually I commented out the version checking (see below). After I
did this, ogle successfully compiled (with alsa) and ogle worked fine
(with sound).
My 2cts in tracking down the problem:
configure looks for sys/asound.h. This does exist (in /usr/include) but
is a depreciated header and only contains an #include <alsa/asound.h>.
The <alsa/asound.h> also only contains #includes, one of which is
<alsa/version.h> - this header contains the SND_LIB_MAJOR and
SND_LIB_MINOR version information. I was wondering if the configure
script is smart enough to jump from <sys/asound.h>, via <alsa/asound.h>
to <alsa/version.h> to egrep the SND_LIB_MAJOR etc. Or perhaps the
version info before alsa 1.0.x used to be in sys/asound.h?
regards and thanks for a nice and simple player,
Huub van den Heuvel
PS what I commented out in the configure script (don't forget the "#fi"
at the end):
from line 13072:
#if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
# egrep "AP_maGiC_VALUE" >/dev/null 2>&1; then
# have_alsa_05x=yes
# echo "$as_me:$LINENO: result: found 0.5.x" >&5
#echo "${ECHO_T}found 0.5.x" >&6
# { echo "$as_me:$LINENO: WARNING: Disabling ALSA support, install a
0.9.x version" >&5
#echo "$as_me: WARNING: Disabling ALSA support, install a 0.9.x version"
>&2;}
#else
cat >conftest.$ac_ext <<_ACEOF
#line $LINENO "configure"
#include "confdefs.h"
#include <sys/asoundlib.h>
#if defined(SND_LIB_MAJOR) && defined(SND_LIB_MINOR)
#if SND_LIB_MAJOR>0 || (SND_LIB_MAJOR==0 && SND_LIB_MINOR>=6)
AP_maGiC_VALUE
#endif
#endif
_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
egrep "AP_maGiC_VALUE" >/dev/null 2>&1; then
have_alsa_final=yes
echo "$as_me:$LINENO: result: found latest" >&5
echo "${ECHO_T}found latest" >&6
else
echo "$as_me:$LINENO: result: no" >&5
echo "${ECHO_T}no" >&6
fi
rm -f conftest*
#fi
rm -f conftest*