|
|
|
|
@ -45,7 +45,9 @@ CPPFLAGS += -D_DEBUG \
|
|
|
|
|
#
|
|
|
|
|
# exclude some modules from compilation?
|
|
|
|
|
# e.g. python modules:
|
|
|
|
|
#exclude_modules ?= py_sems ivr mailbox pin_collect conf_auth mp3 examples
|
|
|
|
|
|
|
|
|
|
#exclude_core_modules =
|
|
|
|
|
#exclude_apps_modules = py_sems ivr mailbox pin_collect conf_auth mp3 examples
|
|
|
|
|
|
|
|
|
|
# build in support for monitoring?
|
|
|
|
|
#
|
|
|
|
|
@ -54,8 +56,11 @@ USE_MONITORING=yes
|
|
|
|
|
|
|
|
|
|
LDFLAGS += -lm
|
|
|
|
|
|
|
|
|
|
OS := $(shell $(CC) $(EXTRA_CFLAGS) -o $(COREPATH)/../getos $(COREPATH)/../getos.c && $(COREPATH)/../getos)
|
|
|
|
|
ARCH := $(shell $(CC) $(EXTRA_CFLAGS) -o $(COREPATH)/../getarch $(COREPATH)/../getarch.c && $(COREPATH)/../getarch)
|
|
|
|
|
GETOS=$(COREPATH)/compat/getos
|
|
|
|
|
GETARCH=$(COREPATH)/compat/getarch
|
|
|
|
|
|
|
|
|
|
OS := $(shell $(CC) $(EXTRA_CFLAGS) -o $(GETOS) $(GETOS).c && $(GETOS))
|
|
|
|
|
ARCH := $(shell $(CC) $(EXTRA_CFLAGS) -o $(GETARCH) $(GETARCH).c && $(GETARCH))
|
|
|
|
|
|
|
|
|
|
ifdef USE_SPANDSP
|
|
|
|
|
ifneq ($(spandsp_defs), 1)
|
|
|
|
|
@ -64,7 +69,7 @@ export spandsp_defs
|
|
|
|
|
CPPFLAGS += -DUSE_SPANDSP -D__STDC_LIMIT_MACROS
|
|
|
|
|
endif
|
|
|
|
|
else
|
|
|
|
|
override exclude_modules += g722
|
|
|
|
|
exclude_core_modules += g722
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
ifdef USE_LIBSAMPLERATE
|
|
|
|
|
@ -90,7 +95,7 @@ ifeq ($(OS),solaris)
|
|
|
|
|
|
|
|
|
|
# I don't have libspeex installed.
|
|
|
|
|
# binrpcctrl does some really weird header stuff that doesn't work.
|
|
|
|
|
exclude_modules += binrpcctrl ilbc speex
|
|
|
|
|
exclude_core_modules += binrpcctrl ilbc speex
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -125,7 +130,7 @@ CPPFLAGS += -DWITH_ZRTP \
|
|
|
|
|
-I/usr/local/include/zrtp
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
TARGET =
|
|
|
|
|
TARGET=
|
|
|
|
|
LIB_LDFLAGS = -shared
|
|
|
|
|
|
|
|
|
|
ifeq ($(OS), linux)
|
|
|
|
|
@ -157,18 +162,47 @@ ifeq ($(OS), macosx)
|
|
|
|
|
LDFLAGS += -L/opt/local/lib
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
override exclude_modules += binrpcctrl ivr examples py_sems
|
|
|
|
|
exclude_core_modules += binrpcctrl
|
|
|
|
|
exclude_app_modules += ivr
|
|
|
|
|
else
|
|
|
|
|
LDFLAGS+= -fPIC -ldl -lsocket -lnsl -lpthread
|
|
|
|
|
ifeq ($(OS), solaris)
|
|
|
|
|
LDFLAGS+= -fPIC -ldl -lsocket -lnsl -lpthread
|
|
|
|
|
TARGET=solaris
|
|
|
|
|
# These don't build on Solaris because of missing Python, invalid make args, or other.
|
|
|
|
|
exclude_app_modules += py_sems py_comp pin_collect mailbox ivr diameter_client conf_auth mp3 cc_acc_xmlrpc xmlrpc2di
|
|
|
|
|
|
|
|
|
|
endif
|
|
|
|
|
endif
|
|
|
|
|
endif
|
|
|
|
|
endif
|
|
|
|
|
endif
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
LDFLAGS += -lstdc++
|
|
|
|
|
|
|
|
|
|
ifeq ($(ARCH),iphone)
|
|
|
|
|
LDFLAGS += -lgcc_eh
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
ifdef USE_SPANDSP
|
|
|
|
|
ifdef LIBSPANDSP_STATIC
|
|
|
|
|
LDFLAGS += $(LIBSPANDSP_LDIR)libspandsp.a
|
|
|
|
|
else
|
|
|
|
|
LDFLAGS += -lspandsp
|
|
|
|
|
endif
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
ifdef USE_LIBSAMPLERATE
|
|
|
|
|
LDFLAGS +=-lsamplerate
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
ifdef WITH_ZRTP
|
|
|
|
|
LDFLAGS +=-lzrtp -lbn
|
|
|
|
|
endif
|
|
|
|
|
|
|
|
|
|
LIB_LDFLAGS += $(LDFLAGS)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# install path is $(basedir) $(prefix)
|
|
|
|
|
# example:
|
|
|
|
|
# creating a bin. archive in /tmp, which unpacks in /usr/local
|
|
|
|
|
@ -266,7 +300,7 @@ export USE_SPANDSP LIBSPANDSP_STATIC LIBSPANDSP_LDIR
|
|
|
|
|
export USE_LIBSAMPLERATE
|
|
|
|
|
export WITH_ZRTP
|
|
|
|
|
export USE_MONITORING
|
|
|
|
|
export exclude_modules
|
|
|
|
|
export exclude_core_modules exclude_app_modules
|
|
|
|
|
endif # ifeq ($(makefile_defs, 1)
|
|
|
|
|
|
|
|
|
|
mk-install-dirs: $(DESTDIR)$(cfg-target) \
|
|
|
|
|
|