diff --git a/src/mod/mod_exosip/Makefile b/src/mod/mod_exosip/Makefile index 92356a29c6..91efe15520 100644 --- a/src/mod/mod_exosip/Makefile +++ b/src/mod/mod_exosip/Makefile @@ -1,9 +1,17 @@ #CFLAGS += -I/usr/src/common/src LDFLAGS += -leXosip2 -ljrtp4c +OSARCH=$(shell uname -s) +ifeq ($(OSARCH),Darwin) + LINKER=g++ +else + LINKER=$(CC) +endif + + $(MOD).so: $(MOD).c $(CC) $(CFLAGS) -fPIC -c $(MOD).c -o $(MOD).o - $(CC) $(SOLINK) -o $(MOD).so $(MOD).o $(LDFLAGS) + $(LINKER) $(SOLINK) -o $(MOD).so $(MOD).o $(LDFLAGS) all: $(MOD).so