aboutsummaryrefslogtreecommitdiffstats
path: root/codecs/Makefile
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2005-12-20 08:16:53 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2005-12-20 08:16:53 +0000
commit34b781be4c88cfed380a2ad818b900665638e337 (patch)
treec83cbab5f4ed2eec57510859562b064cbf15bee0 /codecs/Makefile
parente4e135851c96f51028fbc3d9c65c99369e48aa68 (diff)
use the system libgsm if available (issue #5434, modified to still work with builtin libgsm)
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@7539 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'codecs/Makefile')
-rw-r--r--codecs/Makefile12
1 files changed, 11 insertions, 1 deletions
diff --git a/codecs/Makefile b/codecs/Makefile
index d1feb8a54..c49994174 100644
--- a/codecs/Makefile
+++ b/codecs/Makefile
@@ -60,8 +60,18 @@ ifneq ($(wildcard ilbc/iLBC_decode.h),)
endif
+LIBGSM_PATH:=/usr/local/include /usr/include
+LIBGSM_SYSTEM_HEADERS:=$(wildcard $(LIBGSM_PATH:%=$(CROSS_COMPILE_TARGET)%/gsm/gsm.h))
+ifneq (,$(LIBGSM_SYSTEM_HEADERS))
+LIBGSM=-lgsm
+LIBGSMT=
+CFLAGS+=-DUSE_EXTERNAL_GSM_LIB
+else
LIBGSM=gsm/lib/libgsm.a
-LIBGSMT=gsm/lib/libgsm.a
+LIBGSMT=$(LIBGSM)
+CFLAGS+=-I.
+endif
+
LIBLPC10=lpc10/liblpc10.a
ifeq ($(findstring BSD,${OSARCH}),BSD)