Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/xiph/speex.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTristan Matthews <le.businessman@gmail.com>2014-10-07 07:00:24 +0400
committerTristan Matthews <le.businessman@gmail.com>2014-10-07 07:02:39 +0400
commit99446819ea60d39dcabac70cb22fac6ba23fdbbe (patch)
tree0734fa5727e38ff3e40a471828ed364f574bc0f9
parentf1cd6279de3055552a9116dc067d6b7012f98a76 (diff)
configure: add --disable-binaries option
This will skip building speexenc, speexdec and the test programs. It will also be automatically enforced if ogg is not detected.
-rw-r--r--Makefile.am2
-rw-r--r--configure.ac10
-rw-r--r--libspeex/Makefile.am2
3 files changed, 12 insertions, 2 deletions
diff --git a/Makefile.am b/Makefile.am
index 4f95f62..dc90415 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -16,7 +16,7 @@ EXTRA_DIST = Speex.spec Speex.spec.in Speex.kdevelop speex.m4 speex.pc.in README
#Fools KDevelop into including all files
SUBDIRS = libspeex include doc win32 symbian ti
-if HAVE_OGG
+if BUILD_BINARIES
SUBDIRS += src
endif
diff --git a/configure.ac b/configure.ac
index 7857eeb..141dc03 100644
--- a/configure.ac
+++ b/configure.ac
@@ -108,7 +108,6 @@ CFLAGS="$SAVE_CFLAGS"
AC_MSG_RESULT($has_visibility)
AC_CHECK_HEADERS(sys/soundcard.h sys/audioio.h)
-PKG_HAVE_WITH_MODULES([OGG], [ogg])
LT_LIB_M
@@ -167,6 +166,15 @@ AC_ARG_ENABLE(float-api, [ --disable-float-api Disable the floating-point A
AC_DEFINE([DISABLE_FLOAT_API], , [Disable all parts of the API that are using floats])
fi])
+AC_ARG_ENABLE(binaries, [ --disable-binaries Do not build the encoder and decoder programs, only the library])
+if test "$enableval" != no; then
+ PKG_CHECK_MODULES([OGG], [ogg],
+ AM_CONDITIONAL([BUILD_BINARIES], true),
+ AM_CONDITIONAL([BUILD_BINARIES], false))
+else
+ AM_CONDITIONAL([BUILD_BINARIES], false)
+fi
+
AC_ARG_ENABLE(vbr, [ --disable-vbr Disable VBR and VAD from the codec],
[if test "$enableval" = no; then
AC_DEFINE([DISABLE_VBR], , [Disable VBR and VAD from the codec])
diff --git a/libspeex/Makefile.am b/libspeex/Makefile.am
index 1181138..8fe9bff 100644
--- a/libspeex/Makefile.am
+++ b/libspeex/Makefile.am
@@ -42,6 +42,7 @@ noinst_HEADERS = arch.h bfin.h cb_search_arm4.h cb_search_bfin.h cb_search_s
libspeex_la_LDFLAGS = -no-undefined -version-info @SPEEX_LT_CURRENT@:@SPEEX_LT_REVISION@:@SPEEX_LT_AGE@
libspeex_la_LIBADD = $(LIBM)
+if BUILD_BINARIES
noinst_PROGRAMS = testenc testenc_wb testenc_uwb
testenc_SOURCES = testenc.c
testenc_LDADD = libspeex.la $(LIBM)
@@ -49,3 +50,4 @@ testenc_wb_SOURCES = testenc_wb.c
testenc_wb_LDADD = libspeex.la $(LIBM)
testenc_uwb_SOURCES = testenc_uwb.c
testenc_uwb_LDADD = libspeex.la $(LIBM)
+endif