[sr-dev] git:master: utils: fix libcurl dependency

Ovidiu Sas osas at voipembedded.com
Wed Dec 5 15:21:41 CET 2012


Module: sip-router
Branch: master
Commit: a1e462c1695013d3c74e1c1ec443df7697bb6607
URL:    http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=a1e462c1695013d3c74e1c1ec443df7697bb6607

Author: Ovidiu Sas <osas at voipembedded.com>
Committer: Ovidiu Sas <osas at voipembedded.com>
Date:   Wed Dec  5 09:16:15 2012 -0500

utils: fix libcurl dependency

---

 modules/utils/Makefile |   11 ++++++++++-
 1 files changed, 10 insertions(+), 1 deletions(-)

diff --git a/modules/utils/Makefile b/modules/utils/Makefile
index 727fa8c..ff34623 100644
--- a/modules/utils/Makefile
+++ b/modules/utils/Makefile
@@ -11,6 +11,7 @@ LIBS=
 
 ifeq ($(CROSS_COMPILE),)
 XML2CFG=$(shell which xml2-config)
+CURL2CFG=$(shell which curl-config)
 endif
 
 ifneq ($(XML2CFG),)
@@ -19,7 +20,15 @@ ifneq ($(XML2CFG),)
 else
 	DEFS+=-I$(LOCALBASE)/include/libxml2 \
       -I$(LOCALBASE)/include
-	LIBS+=-L$(LOCALBASE)/lib -lcurl -lxml2
+	LIBS+=-L$(LOCALBASE)/lib -lxml2
+endif
+
+ifneq ($(CURL2CFG),)
+	DEFS += $(shell $(CURL2CFG) --cflags )
+	LIBS += $(shell $(CURL2CFG) --libs)
+else
+	DEFS+=-I$(LOCALBASE)/include
+	LIBS+=-L$(LOCALBASE)/lib -lcurl
 endif
 
 DEFS+=-DKAMAILIO_MOD_INTERFACE




More information about the sr-dev mailing list