2007-10-09 13:25:56 -04:00
|
|
|
#!/usr/bin/make -f
|
|
|
|
# Sample debian/rules that uses debhelper.
|
|
|
|
# This file is public domain software, originally written by Joey Hess.
|
|
|
|
|
|
|
|
# Uncomment this to turn on verbose mode.
|
2007-12-02 18:50:45 -05:00
|
|
|
# export DH_VERBOSE=1
|
|
|
|
export DH_OPTIONS
|
|
|
|
export DH_COMPAT=4
|
|
|
|
export DEB_DH_INSTALL_SOURCEDIR=debian/tmp
|
|
|
|
export PASSTHRU_CODEC_MODULES=codecs/mod_g729 codecs/mod_g723_1 codecs/mod_amr
|
|
|
|
export SPIDERMONKEY_MODULES=languages/mod_spidermonkey languages/mod_spidermonkey_core_db languages/mod_spidermonkey_odbc languages/mod_spidermonkey_socket languages/mod_spidermonkey_teletone
|
2008-04-01 05:08:46 -04:00
|
|
|
export APPLICATIONS_MODULES=applications/mod_commands applications/mod_conference applications/mod_dptools applications/mod_enum applications/mod_esf applications/mod_expr applications/mod_fifo applications/mod_limit applications/mod_rss applications/mod_voicemail applications/mod_fsv
|
2007-12-02 18:50:45 -05:00
|
|
|
export ASR_TTS_MODULES=asr_tts/mod_openmrcp
|
2008-02-18 15:04:48 -05:00
|
|
|
export CODECS_MODULES=codecs/mod_ilbc codecs/mod_h26x codecs/mod_speex mod_voipcodecs
|
2007-12-02 18:50:45 -05:00
|
|
|
export DIALPLANS_MODULES=dialplans/mod_dialplan_asterisk dialplans/mod_dialplan_directory dialplans/mod_dialplan_xml
|
|
|
|
export DIRECTORIES_MODULES=
|
|
|
|
export DOTNET_MODULES=
|
|
|
|
export ENDPOINTS_MODULES=endpoints/mod_dingaling endpoints/mod_iax endpoints/mod_portaudio endpoints/mod_sofia endpoints/mod_woomera ../../libs/openzap/mod_openzap
|
|
|
|
export EVENT_HANDLERS_MODULES=event_handlers/mod_event_multicast event_handlers/mod_event_socket
|
2008-04-01 05:08:46 -04:00
|
|
|
export FORMATS_MODULES=formats/mod_local_stream formats/mod_native_file formats/mod_sndfile formats/mod_tone_stream
|
2007-12-02 18:50:45 -05:00
|
|
|
export LANGUAGES_MODULES=
|
|
|
|
export LOGGERS_MODULES=loggers/mod_console loggers/mod_logfile loggers/mod_syslog
|
|
|
|
export SAY_MODULES=say/mod_say_de say/mod_say_en say/mod_say_fr
|
|
|
|
export TIMERS_MODULES=
|
2008-02-18 15:04:48 -05:00
|
|
|
export DISABLED_MODULES=applications/mod_soundtouch directories/mod_ldap languages/mod_java languages/mod_python languages/mod_spidermonkey_skel ast_tts/mod_cepstral asr_tts/mod_lumenvox endpoints/mod_wanpipe event_handlers/mod_event_test event_handlers/mod_radius_cdr event_handlers/mod_zeroconf formats/mod_shout say/mod_say_it say/mod_say_es say/mod_say_nl
|
2007-12-02 18:50:45 -05:00
|
|
|
export XML_INT_MODULES=xml_int/mod_xml_rpc xml_int/mod_xml_curl xml_int/mod_xml_cdr
|
|
|
|
export MYMODULES=$(PASSTHRU_CODEC_MODULES) $(SPIDERMONKEY_MODULES) $(APPLICATIONS_MODULES) $(ASR_TTS_MODULES) $(CODECS_MODULES) $(DIALPLANS_MODULES) $(DIRECTORIES_MODULES) $(DOTNET_MODULES) $(ENDPOINTS_MODULES) $(EVENT_HANDLERS_MODULES) $(FORMATS_MODULES) $(LANGUAGES_MODULES) $(LOGGERS_MODULES) $(SAY_MODULES) $(TIMERS_MODULES) $(XML_INT_MODULES)
|
|
|
|
export MODULES=$(MYMODULES)
|
2007-10-09 13:25:56 -04:00
|
|
|
|
2007-11-27 17:51:17 -05:00
|
|
|
ifndef AUTOCONF
|
|
|
|
AUTOCONFS := $(wildcard /usr/bin/autoconf*)
|
|
|
|
AUTOCONF = $(shell which autoconf)
|
|
|
|
ifneq (,$(findstring 2.50,${AUTOCONFS}))
|
|
|
|
AUTOCONF = /usr/bin/autoconf2.50
|
|
|
|
endif
|
|
|
|
endif
|
|
|
|
|
|
|
|
# These are used for cross-compiling and for saving the configure script
|
|
|
|
# from having to guess our platform (since we know it already)
|
|
|
|
DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
|
|
|
|
DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
|
|
|
|
|
|
|
|
|
|
|
|
FEATURES = --enable-core-libedit-support --enable-core-odbc-support --with-libcurl --with-openssl
|
|
|
|
|
|
|
|
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
|
|
|
|
FEATURES += --disable-optimization
|
|
|
|
endif
|
|
|
|
|
|
|
|
config.status: configure
|
|
|
|
dh_testdir
|
2007-12-02 18:50:45 -05:00
|
|
|
rm modules.conf
|
|
|
|
touch modules.conf
|
|
|
|
echo $(MODULES)
|
|
|
|
for i in $(MODULES); do echo $$i >> modules.conf; done
|
2007-11-27 17:51:17 -05:00
|
|
|
./configure --prefix=/opt/freeswitch \
|
|
|
|
--host=$(DEB_HOST_GNU_TYPE) \
|
|
|
|
--build=$(DEB_BUILD_GNU_TYPE) \
|
|
|
|
CFLAGS="-D__VIA_HACK__" ${FEATURES}
|
|
|
|
|
|
|
|
configure: bootstrap.sh
|
|
|
|
AUTOCONF=${AUTOCONF} ./bootstrap.sh
|
|
|
|
|
2007-10-09 13:25:56 -04:00
|
|
|
build: build-stamp
|
2007-11-27 17:51:17 -05:00
|
|
|
build-stamp: config.status
|
2007-10-09 13:25:56 -04:00
|
|
|
dh_testdir
|
|
|
|
|
|
|
|
$(MAKE)
|
|
|
|
|
2007-11-27 17:51:17 -05:00
|
|
|
touch $@
|
2007-10-09 13:25:56 -04:00
|
|
|
|
|
|
|
clean:
|
|
|
|
dh_testdir
|
|
|
|
dh_testroot
|
2007-11-27 17:51:17 -05:00
|
|
|
rm -f build-stamp
|
2007-10-09 13:25:56 -04:00
|
|
|
|
|
|
|
-$(MAKE) clean megaclean
|
2007-11-27 17:51:17 -05:00
|
|
|
ifneq "$(wildcard /usr/share/misc/config.sub)" ""
|
|
|
|
cp -f /usr/share/misc/config.sub build/config/config.sub
|
|
|
|
endif
|
|
|
|
ifneq "$(wildcard /usr/share/misc/config.guess)" ""
|
|
|
|
cp -f /usr/share/misc/config.guess build/config/config.guess
|
|
|
|
endif
|
2007-11-28 19:38:58 -05:00
|
|
|
rm -f config.status
|
|
|
|
rm -f */*/config.status
|
|
|
|
rm -f */*/*/config.status
|
|
|
|
dh_clean
|
2007-10-09 13:25:56 -04:00
|
|
|
|
|
|
|
install: build
|
|
|
|
dh_testdir
|
|
|
|
dh_testroot
|
2007-11-27 17:51:17 -05:00
|
|
|
dh_clean -k
|
2007-12-02 18:50:45 -05:00
|
|
|
dh_installdirs -A --sourcedir=debian/tmp
|
2007-10-09 13:25:56 -04:00
|
|
|
|
2007-11-30 09:12:23 -05:00
|
|
|
$(MAKE) DESTDIR=$(CURDIR)/debian/tmp install
|
2007-11-27 17:51:17 -05:00
|
|
|
|
2007-10-09 13:25:56 -04:00
|
|
|
|
|
|
|
# Build architecture-independent files here.
|
|
|
|
binary-indep: build install
|
|
|
|
# We have nothing to do by default.
|
|
|
|
|
|
|
|
# Build architecture-dependent files here.
|
|
|
|
binary-arch: build install
|
|
|
|
dh_testdir
|
|
|
|
dh_testroot
|
2007-11-27 17:51:17 -05:00
|
|
|
# dh_installchangelogs
|
|
|
|
# dh_installdocs
|
|
|
|
# dh_installexamples
|
2007-10-09 13:25:56 -04:00
|
|
|
# dh_install
|
|
|
|
# dh_installmenu
|
|
|
|
# dh_installdebconf
|
|
|
|
# dh_installlogrotate
|
|
|
|
# dh_installemacsen
|
|
|
|
# dh_installcatalogs
|
|
|
|
# dh_installpam
|
|
|
|
# dh_installmime
|
2007-12-02 18:50:45 -05:00
|
|
|
dh_installinit --sourcedir=debian/tmp
|
2007-10-09 13:25:56 -04:00
|
|
|
# dh_installcron
|
|
|
|
# dh_installinfo
|
|
|
|
# dh_undocumented
|
2007-11-27 17:51:17 -05:00
|
|
|
# dh_installman
|
2007-12-02 18:50:45 -05:00
|
|
|
cp debian/monit/freeswitch.monitrc debian/freeswitch/etc/monit/freswitch.monitrc
|
|
|
|
cp debian/default/freeswitch debian/freeswitch/etc/default
|
2007-11-30 09:12:23 -05:00
|
|
|
dh_install --sourcedir=debian/tmp
|
2007-10-09 13:25:56 -04:00
|
|
|
dh_strip
|
|
|
|
dh_compress
|
2007-11-27 17:51:17 -05:00
|
|
|
dh_fixperms --exclude /opt/freeswitch/conf
|
2007-10-09 13:25:56 -04:00
|
|
|
# dh_perl
|
|
|
|
# dh_python
|
|
|
|
# dh_makeshlibs
|
|
|
|
dh_installdeb
|
2007-11-27 17:51:17 -05:00
|
|
|
dh_shlibdeps --exclude=/opt/freeswitch
|
2007-10-09 13:25:56 -04:00
|
|
|
dh_gencontrol
|
|
|
|
dh_md5sums
|
|
|
|
dh_builddeb
|
|
|
|
|
|
|
|
binary: binary-indep binary-arch
|
2007-11-27 17:51:17 -05:00
|
|
|
.PHONY: build clean binary-indep binary-arch binary install
|