mirror of
https://github.com/alsa-project/alsa-utils
synced 2024-12-23 04:36:32 +01:00
bat: don't link all binaries with fftw library, add missing header
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
parent
9b757e3a64
commit
bc352dfba9
2 changed files with 18 additions and 1 deletions
|
@ -11,7 +11,10 @@ bat_SOURCES = \
|
||||||
convert.c \
|
convert.c \
|
||||||
alsa.c
|
alsa.c
|
||||||
|
|
||||||
|
noinst_HEADERS = \
|
||||||
|
common.h
|
||||||
|
|
||||||
AM_CPPFLAGS = \
|
AM_CPPFLAGS = \
|
||||||
-Wall -I$(top_srcdir)/include
|
-Wall -I$(top_srcdir)/include
|
||||||
|
|
||||||
bat_LDADD = -lasound
|
bat_LDADD = @FFTW_LIB@
|
||||||
|
|
14
configure.ac
14
configure.ac
|
@ -64,9 +64,23 @@ AM_CONDITIONAL(BAT, test x$bat = xtrue)
|
||||||
|
|
||||||
if test x$bat = xtrue; then
|
if test x$bat = xtrue; then
|
||||||
|
|
||||||
|
saved_CFLAGS="$CFLAGS"
|
||||||
|
saved_LDFLAGS="$LDFLAGS"
|
||||||
|
saved_LIBS="$LIBS"
|
||||||
|
FFTW_INC=""
|
||||||
|
FFTW_LIB=""
|
||||||
|
FFTW_CFLAGS=""
|
||||||
AC_CHECK_LIB([fftw3], [fftw_malloc], , [AC_MSG_ERROR([Error: need FFTW3 library])])
|
AC_CHECK_LIB([fftw3], [fftw_malloc], , [AC_MSG_ERROR([Error: need FFTW3 library])])
|
||||||
AC_CHECK_LIB([m], [sqrtf], , [AC_MSG_ERROR([Error: Need sqrtf])])
|
AC_CHECK_LIB([m], [sqrtf], , [AC_MSG_ERROR([Error: Need sqrtf])])
|
||||||
AC_CHECK_LIB([pthread], [pthread_create], , [AC_MSG_ERROR([Error: need PTHREAD library])])
|
AC_CHECK_LIB([pthread], [pthread_create], , [AC_MSG_ERROR([Error: need PTHREAD library])])
|
||||||
|
FFTW_CFLAGS="$CFLAGS"
|
||||||
|
FFTW_LIB="$LIBS"
|
||||||
|
CFLAGS="$saved_CFLAGS"
|
||||||
|
LDFLAGS="$saved_LDFLAGS"
|
||||||
|
LIBS="$saved_LIBS"
|
||||||
|
AC_SUBST(FFTW_INC)
|
||||||
|
AC_SUBST(FFTW_LIB)
|
||||||
|
AC_SUBST(FFTW_CFLAGS)
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue