X-Git-Url: http://git.eversberg.eu/gitweb.cgi?p=lcr.git;a=blobdiff_plain;f=Makefile.am;h=11a2beb959b72da820675d5e73ddda4d3163b210;hp=26e575cf8784f72df8aa7e18e8dd5cb6a71cadcc;hb=a3b269f357b7e6b74d91a942f874ee041320dce7;hpb=1e21f69321ba016120c3640fcad0256234b7a377 diff --git a/Makefile.am b/Makefile.am index 26e575c..11a2beb 100644 --- a/Makefile.am +++ b/Makefile.am @@ -43,31 +43,54 @@ INSTALLATION_DEFINES = \ -DLOG_DIR="\"$(LOGdir)\"" \ -DEXTENSION_DATA="\"$(EXTENSIONdir)\"" +SUBDIRS = include + if ENABLE_MISDN MISDN_INCLUDE = -DWITH_MISDN -DWITH_CRYPT -MISDN_SOURCE = mISDN.cpp dss1.cpp loop.c crypt.cpp remote.cpp joinremote.cpp +MISDN_SOURCE = mISDN.cpp fxs.cpp dss1.cpp crypt.cpp MISDN_LIB = -lmisdn endif +SUBDIRS = + GSM_INCLUDE = GSM_SOURCE = GSM_LIB = if ENABLE_GSM -GSM_INCLUDE += +#if ENABLE_GSMFR -GSM_SOURCE += gsm_audio.c gsm.cpp - -GSM_LIB += /usr/lib/libgsm.a +GSM_INCLUDE += -DWITH_GSMFR + +GSM_LIB += libgsmfr/lib/libgsm.a + +SUBDIRS += libgsmfr + +#endif -#gsm_audio.po: gsm_audio.c gsm_audio.h -# $(CC) -D_GNU_SOURCE -fPIC -c gsm_audio.c -o gsm_audio.po +if ENABLE_GSMHR + +GSM_INCLUDE += -DWITH_GSMHR + +GSM_LIB += libgsmhr/libgsmhr.la + +SUBDIRS += libgsmhr endif +if ENABLE_GSMAMR + +GSM_INCLUDE += -DWITH_GSMAMR + +GSM_LIB += -lopencore-amrnb + +endif + +GSM_SOURCE += gsm_audio.c gsm.cpp + if ENABLE_GSM_BS GSM_INCLUDE += -DWITH_GSM_BS @@ -84,6 +107,9 @@ GSM_SOURCE += gsm_ms.cpp endif +endif + + if ENABLE_SS5 SS5_INCLUDE = -DWITH_SS5 @@ -116,18 +142,15 @@ if ENABLE_ASTERISK_CHANNEL_DRIVER noinst_PROGRAMS = chan_lcr.so chan_lcr_so_SOURCES = chan_lcr_so_LDFLAGS = -shared -chan_lcr_so_LDADD = chan_lcr.po bchannel.po options.po callerid.po select.po +chan_lcr_so_LDADD = chan_lcr.po options.po callerid.po select.po # List chan_lcr specific sources for make dist -EXTRA_chan_lcr_so_SOURCES = chan_lcr.c chan_lcr.h bchannel.c bchannel.h +EXTRA_chan_lcr_so_SOURCES = chan_lcr.c chan_lcr.h chan_lcr.po: chan_lcr.c chan_lcr.h $(CC) $(INCLUDES) $(AST_CFLAGS) $(CPPFLAGS) $(CFLAGS) -D_GNU_SOURCE -fPIC -c $< -o $@ -bchannel.po: bchannel.c bchannel.h - $(CC) $(INCLUDES) -D_GNU_SOURCE $(CPPFLAGS) $(CFLAGS) -fPIC -c $< -o $@ - callerid.po: callerid.c callerid.h $(CC) $(INCLUDES) -D_GNU_SOURCE $(CPPFLAGS) $(CFLAGS) -fPIC -c $< -o $@ @@ -145,11 +168,11 @@ uninstall-hook: cd '$(DESTDIR)$(astmoddir)' && rm -f chan_lcr.so endif -INCLUDES = $(all_includes) $(MISDN_INCLUDE) $(GSM_INCLUDE) $(SS5_INCLUDE) $(SIP_INCLUDE) -Wall $(INSTALLATION_DEFINES) +INCLUDES = $(all_includes) -I$(top_srcdir)/include $(MISDN_INCLUDE) $(GSM_INCLUDE) $(SS5_INCLUDE) $(SIP_INCLUDE) -Wall $(INSTALLATION_DEFINES) lcr_SOURCES = \ main.c select.c trace.c options.c tones.c alawulaw.c cause.c interface.c message.c callerid.c socket_server.c \ - port.cpp vbox.cpp \ + port.cpp vbox.cpp remote.cpp \ $(MISDN_SOURCE) $(GSM_SOURCE) $(SS5_SOURCE) $(SIP_SOURCE) \ endpoint.cpp endpointapp.cpp \ appbridge.cpp apppbx.cpp route.c action.cpp action_efi.cpp action_vbox.cpp extension.c mail.c \ @@ -168,7 +191,7 @@ noinst_HEADERS = \ message.h callerid.h socket_server.h port.h vbox.h endpoint.h endpointapp.h \ appbridge.h apppbx.h route.h extension.h join.h joinpbx.h lcrsocket.h -noinst_HEADERS += myisdn.h mISDN.h dss1.h loop.h crypt.h remote.h joinremote.h +noinst_HEADERS += myisdn.h mISDN.h dss1.h crypt.h remote.h noinst_HEADERS += ss5.h ss5_encode.h ss5_decode.h noinst_HEADERS += mncc.h gsm.h gsm_audio.h gsm_bs.h gsm_ms.h noinst_HEADERS += ie.cpp sip.h @@ -184,7 +207,7 @@ EXTRA_DIST = default debian $(TONEDIRS) install-data-hook: @fns='strcpy strncpy strcat strncat sprintf snprintf' ; \ files=$$( find $(srcdir) -type f -name "*.c*" \ - | $(GREP) -v -e chan_lcr.c -e bchannel.c -e callerid.c ) ; \ + | $(GREP) -v -e chan_lcr.c -e callerid.c ) ; \ test -z "$$files" || { for fn in $$fns ; do \ $(GREP) -n $$fn $$files ; if test $$? = 0 ; then \ ( echo "dont use $$fn, use makro instead." ; exit -1 ) ; \