From 84e520cafd4f4b265983df1edff01f501cdf3dfe Mon Sep 17 00:00:00 2001 From: Tobias Kortkamp Date: Thu, 7 Feb 2019 09:43:16 +0000 Subject: [PATCH] New port: net/mod_amd MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Asterisk app_amd for FreeSWITCH This is an implementation of Asterisk's answering machine detection (voice activity detection) for FreeSWITCH. WWW: https://github.com/seanbright/mod_amd PR: 211773 Submitted by: Šimun Mikecin Reviewed by: koobs --- net/Makefile | 1 + net/mod_amd/Makefile | 32 +++++++++++++++++++++++++++++ net/mod_amd/distinfo | 3 +++ net/mod_amd/files/amd.conf.xml | 13 ++++++++++++ net/mod_amd/files/patch-Makefile | 35 ++++++++++++++++++++++++++++++++ net/mod_amd/pkg-descr | 6 ++++++ 6 files changed, 90 insertions(+) create mode 100644 net/mod_amd/Makefile create mode 100644 net/mod_amd/distinfo create mode 100644 net/mod_amd/files/amd.conf.xml create mode 100644 net/mod_amd/files/patch-Makefile create mode 100644 net/mod_amd/pkg-descr diff --git a/net/Makefile b/net/Makefile index 0c3424711a71..c78be4e01d9e 100644 --- a/net/Makefile +++ b/net/Makefile @@ -470,6 +470,7 @@ SUBDIR += miruo SUBDIR += mlvpn SUBDIR += mobile-broadband-provider-info + SUBDIR += mod_amd SUBDIR += mono-zeroconf SUBDIR += mopd SUBDIR += morebalance diff --git a/net/mod_amd/Makefile b/net/mod_amd/Makefile new file mode 100644 index 000000000000..732a8322c1b9 --- /dev/null +++ b/net/mod_amd/Makefile @@ -0,0 +1,32 @@ +# Created by: Simun Mikecin +# $FreeBSD$ + +PORTNAME= mod_amd +PORTVERSION= g20150926 +CATEGORIES= net + +MAINTAINER= numisemis@yahoo.com +COMMENT= Asterisk app_amd for FreeSWITCH + +LICENSE= CC0-1.0 +LICENSE_FILE= ${WRKSRC}/LICENSE + +LIB_DEPENDS= libfreeswitch.so:net/freeswitch + +USES= pkgconfig +USE_GITHUB= yes +GH_ACCOUNT= seanbright +GH_TAGNAME= 60daa7e + +MAKE_ARGS= prefix=${STAGEDIR}${PREFIX} + +PLIST_FILES= etc/freeswitch/autoload_configs/amd.conf.xml \ + lib/freeswitch/mod/mod_amd.so + +post-install: + ${MKDIR} ${STAGEDIR}${PREFIX}/etc/freeswitch/autoload_configs + ${INSTALL_DATA} ${FILESDIR}/amd.conf.xml \ + ${STAGEDIR}${PREFIX}/etc/freeswitch/autoload_configs + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/freeswitch/mod/mod_amd.so + +.include diff --git a/net/mod_amd/distinfo b/net/mod_amd/distinfo new file mode 100644 index 000000000000..ff144b756a15 --- /dev/null +++ b/net/mod_amd/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1471001403 +SHA256 (seanbright-mod_amd-g20150926-60daa7e_GH0.tar.gz) = 10cce0b849c7165f48cc37d4a0d8e4b030b4905c1cd78c1f31dd8acff86ec5bb +SIZE (seanbright-mod_amd-g20150926-60daa7e_GH0.tar.gz) = 6245 diff --git a/net/mod_amd/files/amd.conf.xml b/net/mod_amd/files/amd.conf.xml new file mode 100644 index 000000000000..1751527407bb --- /dev/null +++ b/net/mod_amd/files/amd.conf.xml @@ -0,0 +1,13 @@ + + + + + + + + + + + + + diff --git a/net/mod_amd/files/patch-Makefile b/net/mod_amd/files/patch-Makefile new file mode 100644 index 000000000000..484c9b690e86 --- /dev/null +++ b/net/mod_amd/files/patch-Makefile @@ -0,0 +1,35 @@ +--- Makefile.orig 2015-10-26 15:12:15 UTC ++++ Makefile +@@ -1,20 +1,19 @@ + MODNAME = mod_amd.so + MODOBJ = mod_amd.o +-MODCFLAGS = -Wall -Werror ++MODCFLAGS = -Wall + # MODLDFLAGS = -lssl + +-CC = gcc +-CFLAGS = -fPIC -g -ggdb `pkg-config --cflags freeswitch` $(MODCFLAGS) ++CFLAGS += -fPIC `pkg-config --cflags freeswitch` $(MODCFLAGS) + LDFLAGS = `pkg-config --libs freeswitch` $(MODLDFLAGS) + + .PHONY: all + all: $(MODNAME) + + $(MODNAME): $(MODOBJ) +- @$(CC) -shared -o $@ $(MODOBJ) $(LDFLAGS) ++ $(CC) -shared -o $@ $(MODOBJ) $(LDFLAGS) + + .c.o: $< +- @$(CC) $(CFLAGS) -o $@ -c $< ++ $(CC) $(CFLAGS) -o $@ -c $< + + .PHONY: clean + clean: +@@ -22,5 +21,5 @@ clean: + + .PHONY: install + install: $(MODNAME) +- install -d $(DESTDIR)/usr/lib/freeswitch/mod +- install $(MODNAME) $(DESTDIR)/usr/lib/freeswitch/mod ++ install -d $(prefix)/lib/freeswitch/mod ++ install $(MODNAME) $(prefix)/lib/freeswitch/mod diff --git a/net/mod_amd/pkg-descr b/net/mod_amd/pkg-descr new file mode 100644 index 000000000000..dd8ed78dca34 --- /dev/null +++ b/net/mod_amd/pkg-descr @@ -0,0 +1,6 @@ +Asterisk app_amd for FreeSWITCH + +This is an implementation of Asterisk's answering machine detection +(voice activity detection) for FreeSWITCH. + +WWW: https://github.com/seanbright/mod_amd