add make targets for mod_com_g729 mod_com_g729-activate mod_com_g729-install mod_com_g729-clean mod_com_g729-uninstall

This commit is contained in:
Mike Jerris 2011-02-14 13:52:35 -06:00 committed by Brian West
parent e81e809650
commit 17d5211280
6 changed files with 120 additions and 34 deletions

69
.gitignore vendored
View File

@ -46,45 +46,47 @@ core.*
!/w32/Console/FreeSwitchConsole.vcproj.user
!/w32/Setup/inno_setup/vcredist_x64.exe
!/w32/Setup/inno_setup/vcredist_x86.exe
/.version
/AUTHORS
/COPYING
/ChangeLog
/Makefile
/Makefile.in
/NEWS
/README
/TAGS
.version
AUTHORS
COPYING
ChangeLog
Makefile
Makefile.in
NEWS
README
TAGS
aclocal.m4
autom4te.cache
/build/Makefile
/build/Makefile.in
/build/config/compile
/build/config/config.guess
/build/config/depcomp
/build/config/install-sh
/build/config/ltmain.sh
/build/config/missing
/build/freeswitch.pc
/build/getlib.sh
/build/getsounds.sh
/build/modmake.rules
build/Makefile
build/Makefile.in
build/config/compile
build/config/config.guess
build/config/depcomp
build/config/install-sh
build/config/ltmain.sh
build/config/missing
build/freeswitch.pc
build/getlib.sh
build/getsounds.sh
build/modmake.rules
build/getg729.sh
config.cache
config.log
config.status
/configure
configure
configure.lineno
/freeswitch
/fs_cli
/fs_encode
/fs_ivrd
/libtool
/modules.conf
/quiet_libtool
/tone2wav
/scripts/fsxs
/scripts/gentls_cert
/a.out.dSYM
freeswitch
fs_cli
fs_encode
fs_ivrd
libtool
noreg
modules.conf
quiet_libtool
tone2wav
scripts/fsxs
scripts/gentls_cert
a.out.dSYM
src/mod/applications/mod_easyroute/Makefile
src/mod/applications/mod_lcr/Makefile
src/mod/applications/mod_nibblebill/Makefile
@ -102,6 +104,7 @@ src/mod/say/mod_say_th/Makefile
src/mod/say/mod_say_zh/Makefile
libs/curl/lib/ca-bundle.h
libs/g729/
libs/fsg729-*-installer
src/mod/codecs/mod_com_g729/
src/mod/languages/mod_lua/mod_lua_wrap.cpp.orig
src/mod/languages/mod_perl/mod_perl_wrap.cpp.orig

34
build/getg729.sh.in Executable file
View File

@ -0,0 +1,34 @@
#!/bin/sh
TAR=@TAR@
ZCAT=@ZCAT@
WGET=@WGET@
CURL=@CURL@
if [ -f "$WGET" ] ; then
DOWNLOAD_CMD=$WGET
else
if [ -f "$CURL" ] ; then
DOWNLOAD_CMD="$CURL -O"
fi
fi
base=http://files.freeswitch.org/g729/
tarfile=$1
url=`echo $tarfile | grep "://"`
if [ ! -z $url ] ; then
base=$tarfile/
tarfile=$2
fi
if [ ! -f $tarfile ] ; then
$DOWNLOAD_CMD $base$tarfile
if [ ! -f $tarfile ] ; then
echo cannot find $tarfile
exit 1
fi
fi
exit 0

View File

@ -42,6 +42,7 @@ codecs/mod_amr
#codecs/mod_silk
#codecs/mod_codec2
codecs/mod_g729
#codecs/mod_com_g729
codecs/mod_h26x
codecs/mod_bv
codecs/mod_ilbc

View File

@ -730,6 +730,8 @@ AC_PATH_PROGS(WGET, wget)
AC_PATH_PROGS(CURL, curl)
GETLIB="cd $switch_srcdir/libs && ${SHELL} $switch_builddir/build/getlib.sh"
AC_SUBST(GETLIB)
GETG729="cd $switch_srcdir/libs && ${SHELL} $switch_builddir/build/getg729.sh"
AC_SUBST(GETG729)
GETSOUNDS="${SHELL} $switch_builddir/build/getsounds.sh"
AC_SUBST(GETSOUNDS)
@ -916,6 +918,7 @@ AC_CONFIG_FILES([Makefile
src/mod/applications/mod_osp/Makefile
src/mod/applications/mod_stress/Makefile
src/mod/applications/mod_hash/Makefile
src/mod/codecs/mod_com_g729/Makefile
src/mod/endpoints/mod_portaudio/Makefile
src/mod/endpoints/mod_skinny/Makefile
src/mod/endpoints/mod_skypopen/Makefile
@ -930,6 +933,7 @@ AC_CONFIG_FILES([Makefile
src/include/switch_am_config.h
build/getsounds.sh
build/getlib.sh
build/getg729.sh
build/freeswitch.pc
build/modmake.rules
libs/xmlrpc-c/include/xmlrpc-c/config.h
@ -1023,6 +1027,7 @@ AC_OUTPUT
##
## Registering for ClueCon
##
if ! test -f noreg ; then
echo ""
echo ""
echo $ECHO_N "Registering you for ClueCon http://www.cluecon.com $ECHO_C" 1>&6
@ -1040,6 +1045,7 @@ sleep 1
AC_MSG_RESULT([ See you in August. ;-)])
sleep 2
echo ""
fi
##
## Configuration summary

View File

@ -21,7 +21,7 @@ $(OUR_MODULES) $(OUR_CLEAN_MODULES) $(OUR_INSTALL_MODULES) $(OUR_UNINSTALL_MODUL
fi ; \
fi ; \
if test -z "$$target" ; then target="all" ; fi ; \
if ! test -f $$moddir/$$modname.c && ! test -f $$moddir/$$modname.cpp ; \
if ! test -f $$moddir/$$modname.c && ! test -f $$moddir/$$modname.cpp && test $$modname != "mod_com_g729" ; \
then echo ; echo "WARNING $$modname is not a valid FreeSWITCH module dir, skipping it..." ; else \
echo ;\
echo making $$target $$modname ;\
@ -35,6 +35,9 @@ $(OUR_MODULES) $(OUR_CLEAN_MODULES) $(OUR_INSTALL_MODULES) $(OUR_UNINSTALL_MODUL
fi; \
test -z "$$fail" ;
mod_com_g729-activate:
cd $(switch_builddir)/src/mod/codecs/mod_com_g729 && $(MAKE) $(AM_MAKEFLAGS) activate
.DEFAULT:
@if test -z "`echo $@ | grep all`"; then $(MAKE) $(AM_MAKEFLAGS) $@-all ; else echo Unknown target `echo $@ | sed -e 's|-all||'`; exit 1; fi

View File

@ -0,0 +1,39 @@
include $(top_srcdir)/build/modmake.rulesam
MODNAME=mod_com_g729
VERSION=193
if ISLINUX
G729INSTALLER = $(top_srcdir)/libs/fsg729-$(VERSION)-installer
LICSERVER=/usr/sbin/freeswitch_licence_server
VALIDATOR=$(bindir)/validator
MOD=$(moddir)/mod_com_g729.so
BUILT_SOURCES = $(G729INSTALLER)
install: $(LICSERVER) $(VALIDATOR) $(MOD)
$(LICSERVER) $(VALIDATOR) $(MOD): $(G729INSTALLER)
$(SHELL) $(G729INSTALLER) $(bindir) $(moddir) nobanner
$(ECHO)
$(ECHO)
$(ECHO) Now you can activate your license by running $(MAKE) mod_com_g729-activate
$(ECHO)
$(ECHO)
$(G729INSTALLER):
rm -f $(top_srcdir)/libs/fsg729-*-installer*
$(GETG729) fsg729-$(VERSION)-installer
chmod 755 $(G729INSTALLER)
clean:
rm -f $(top_srcdir)/libs/fsg729-*-installer*
rm -rf /tmp/fsg729
activate: $(LICSERVER) $(VALIDATOR) $(MOD)
$(VALIDATOR)
uninstall: clean
rm -f $(LICSERVER) $(VALIDATOR) $(MOD)
endif