1998-08-13 17:43:39 +02:00
|
|
|
dnl Process this file with autoconf to produce a configure script.
|
2006-03-21 18:05:19 +01:00
|
|
|
AC_PREREQ(2.59)
|
1999-01-30 20:12:34 +01:00
|
|
|
AC_INIT(alsamixer/alsamixer.c)
|
1998-08-13 17:43:39 +02:00
|
|
|
AC_PREFIX_DEFAULT(/usr)
|
2007-05-31 08:55:26 +02:00
|
|
|
AM_INIT_AUTOMAKE(alsa-utils, 1.0.14)
|
1998-08-13 17:43:39 +02:00
|
|
|
|
2005-01-03 12:57:02 +01:00
|
|
|
AM_GNU_GETTEXT([external])
|
2006-11-26 17:24:59 +01:00
|
|
|
AM_GNU_GETTEXT_VERSION([0.15])
|
2004-12-29 17:10:47 +01:00
|
|
|
|
1998-08-13 17:43:39 +02:00
|
|
|
dnl Checks for programs.
|
2003-06-14 10:32:44 +02:00
|
|
|
|
|
|
|
dnl try to gues cross-compiler if not set
|
|
|
|
if test "x$target" != "x$host" -a -z "`echo $CC | grep -e '-gcc'`";
|
|
|
|
then
|
|
|
|
AC_MSG_CHECKING(for cross-compiler)
|
|
|
|
|
|
|
|
which ${program_prefix}gcc >/dev/null 2>&1 && CC=${program_prefix}gcc
|
|
|
|
which ${target_cpu}-${target_os}-gcc >/dev/null 2>&1 \
|
|
|
|
&& CC=${target_cpu}-${target-os}-gcc
|
|
|
|
which ${target_cpu}-${target_vendor}-${target_os}-gcc >/dev/null 2>&1 \
|
|
|
|
&& CC=${target_cpu}-${target_vendor}-${target_os}-gcc
|
|
|
|
|
|
|
|
AC_MSG_RESULT($CC)
|
|
|
|
fi
|
|
|
|
|
1998-08-13 17:43:39 +02:00
|
|
|
AC_PROG_CC
|
2000-01-05 14:46:58 +01:00
|
|
|
dnl AC_PROG_CXX
|
1998-08-13 17:43:39 +02:00
|
|
|
AC_PROG_INSTALL
|
|
|
|
AC_PROG_LN_S
|
2006-07-05 17:46:10 +02:00
|
|
|
AM_PATH_ALSA(1.0.12)
|
1998-08-13 17:43:39 +02:00
|
|
|
|
2003-06-14 10:32:44 +02:00
|
|
|
AC_ARG_ENABLE(alsamixer,
|
|
|
|
[ --disable-alsamixer Disable alsamixer compilation],
|
|
|
|
[case "${enableval}" in
|
|
|
|
yes) alsamixer=true ;;
|
|
|
|
no) alsamixer=false ;;
|
|
|
|
*) AC_MSG_ERROR(bad value ${enableval} for --enable-alsamixer) ;;
|
|
|
|
esac],[alsamixer=true])
|
|
|
|
AM_CONDITIONAL(ALSAMIXER, test x$alsamixer = xtrue)
|
|
|
|
|
1998-08-13 17:43:39 +02:00
|
|
|
dnl Checks for header files.
|
|
|
|
AC_HEADER_STDC
|
2003-06-16 20:46:06 +02:00
|
|
|
if test x$alsamixer = xtrue; then
|
2004-02-25 12:25:53 +01:00
|
|
|
AC_ARG_WITH(curses,
|
|
|
|
[ --with-curses libname Specify the curses library to use (default=auto)],
|
|
|
|
curseslib="$withval",
|
|
|
|
curseslib="auto")
|
|
|
|
if test "$curseslib" = "ncursesw"; then
|
|
|
|
AC_CHECK_LIB(ncursesw, initscr,
|
|
|
|
[ CURSESINC='<ncurses.h>'; CURSESLIB='-lncursesw'; curseslib="ncursesw"])
|
|
|
|
fi
|
|
|
|
if test "$curseslib" = "ncurses" -o "$curseslib" = "auto"; then
|
|
|
|
AC_CHECK_LIB(ncurses, initscr,
|
|
|
|
[ CURSESINC='<ncurses.h>'; CURSESLIB='-lncurses'; curseslib="ncurses"])
|
|
|
|
fi
|
|
|
|
if test "$curseslib" = "curses" -o "$curseslib" = "auto"; then
|
|
|
|
AC_CHECK_LIB(curses, initscr,
|
|
|
|
[ CURSESINC='<curses.h>'; CURSESLIB='-lcurses'; curseslib="curses"])
|
|
|
|
fi
|
|
|
|
if test -z "$CURSESINC"; then
|
|
|
|
AC_MSG_ERROR(this packages requires a curses library)
|
|
|
|
fi
|
2003-06-16 20:46:06 +02:00
|
|
|
fi
|
1999-01-30 20:12:34 +01:00
|
|
|
|
|
|
|
AC_SUBST(CURSESINC)
|
|
|
|
AC_SUBST(CURSESLIB)
|
|
|
|
|
2005-11-30 18:09:17 +01:00
|
|
|
test "x$prefix" = xNONE && prefix=$ac_default_prefix
|
|
|
|
|
|
|
|
eval dir="$datadir"
|
|
|
|
case "$dir" in
|
|
|
|
/*) ;;
|
2006-11-26 17:24:59 +01:00
|
|
|
*) dir="$prefix/share"
|
2005-11-30 18:09:17 +01:00
|
|
|
esac
|
|
|
|
|
|
|
|
dir="$dir/sounds/alsa"
|
|
|
|
AC_DEFINE_UNQUOTED(DATADIR, "$dir", [directory containing sample data])
|
|
|
|
|
2003-10-29 14:38:23 +01:00
|
|
|
AC_ARG_WITH(testsound,
|
|
|
|
[ --with-testsound=file give the path of test sound file for alsaconf],
|
|
|
|
TESTSOUND="$withval",
|
2005-11-30 18:09:17 +01:00
|
|
|
TESTSOUND="$dir/test.wav")
|
2003-10-29 14:38:23 +01:00
|
|
|
AC_SUBST(TESTSOUND)
|
1999-06-03 22:28:05 +02:00
|
|
|
|
1999-01-30 20:12:34 +01:00
|
|
|
AM_CONFIG_HEADER(include/aconfig.h)
|
1998-08-13 17:43:39 +02:00
|
|
|
|
|
|
|
dnl Checks for typedefs, structures, and compiler characteristics.
|
|
|
|
AC_C_CONST
|
|
|
|
AC_C_INLINE
|
|
|
|
AC_HEADER_TIME
|
|
|
|
|
|
|
|
dnl Checks for library functions.
|
|
|
|
AC_PROG_GCC_TRADITIONAL
|
|
|
|
|
2005-11-08 17:42:22 +01:00
|
|
|
dnl Enable largefile support
|
|
|
|
AC_SYS_LARGEFILE
|
|
|
|
|
1999-03-08 17:51:53 +01:00
|
|
|
SAVE_UTIL_VERSION
|
|
|
|
|
2003-10-28 11:53:43 +01:00
|
|
|
AC_OUTPUT(Makefile alsactl/Makefile alsamixer/Makefile amidi/Makefile amixer/Makefile \
|
2005-08-19 14:44:54 +02:00
|
|
|
m4/Makefile po/Makefile.in \
|
2003-10-29 14:38:23 +01:00
|
|
|
alsaconf/alsaconf alsaconf/Makefile \
|
2004-12-29 17:10:47 +01:00
|
|
|
alsaconf/po/Makefile \
|
2003-10-28 11:53:43 +01:00
|
|
|
aplay/Makefile include/Makefile iecset/Makefile utils/Makefile \
|
2004-02-23 11:58:34 +01:00
|
|
|
utils/alsa-utils.spec seq/Makefile seq/aconnect/Makefile \
|
2005-02-21 09:30:12 +01:00
|
|
|
seq/aplaymidi/Makefile seq/aseqdump/Makefile seq/aseqnet/Makefile \
|
2005-04-16 13:09:26 +02:00
|
|
|
speaker-test/Makefile speaker-test/samples/Makefile)
|