[sr-dev] git:master: ims_icscf: fic cross-compilation

Ovidiu Sas osas at voipembedded.com
Thu Jan 10 22:49:21 CET 2013


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

Author: Ovidiu Sas <osas at voipembedded.com>
Committer: Ovidiu Sas <osas at voipembedded.com>
Date:   Thu Jan 10 16:42:34 2013 -0500

ims_icscf: fic cross-compilation

---

 modules/ims_icscf/Makefile |   24 +++++++++++-------------
 1 files changed, 11 insertions(+), 13 deletions(-)

diff --git a/modules/ims_icscf/Makefile b/modules/ims_icscf/Makefile
index 4b30a30..9e74f28 100644
--- a/modules/ims_icscf/Makefile
+++ b/modules/ims_icscf/Makefile
@@ -4,28 +4,26 @@
 #
 # 
 
-
 include ../../Makefile.defs
 auto_gen=
 NAME=ims_icscf.so
-LIBS=
-
-DEFS += -DOPENSER_MOD_INTERFACE
 
-DEFS += -I/usr/include/libxml2
-LIBS += -L$(LOCALBASE)/lib -lxml2
+ifeq ($(CROSS_COMPILE),)
+XML2CFG=$(shell which xml2-config)
+endif
 
-ifneq ($(OS),darwin)
-	LIBS += -lrt
+ifneq ($(XML2CFG),)
+	DEFS += $(shell $(XML2CFG) --cflags )
+	LIBS += $(shell $(XML2CFG) --libs)
+else
+	DEFS+=-I$(LOCALBASE)/include/libxml2 \
+		-I$(LOCALBASE)/include
+	LIBS+=-L$(LOCALBASE)/lib -lxml2
 endif
 
+DEFS += -DOPENSER_MOD_INTERFACE
 
 SERLIBPATH=../../lib
 SER_LIBS+=$(SERLIBPATH)/srdb1/srdb1 $(SERLIBPATH)/kcore/kcore
 SER_LIBS+=$(SERLIBPATH)/ims/kamailio_ims
-
-
-
-
-
 include ../../Makefile.modules




More information about the sr-dev mailing list