aboutsummaryrefslogtreecommitdiffstats
path: root/main/freeswitch/APKBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'main/freeswitch/APKBUILD')
-rw-r--r--main/freeswitch/APKBUILD61
1 files changed, 61 insertions, 0 deletions
diff --git a/main/freeswitch/APKBUILD b/main/freeswitch/APKBUILD
new file mode 100644
index 0000000000..860ec0ffe7
--- /dev/null
+++ b/main/freeswitch/APKBUILD
@@ -0,0 +1,61 @@
+# Contributor: Michael Mason <ms13sp@gmail.com>
+pkgname=freeswitch
+pkgver=1.0.6
+pkgrel=6
+pkgdesc="A communications platform written in C from the ground up"
+url="http://www.freeswitch.org"
+license="GPL"
+depends=""
+makedepends="curl-dev unixodbc-dev zlib-dev openssl-dev
+ autoconf automake libtool"
+install="$pkgname.pre-install $pkgname.post-install"
+subpackages="$pkgname-dev"
+source="http://files.freeswitch.org/freeswitch-$pkgver.tar.gz
+ modules.conf
+ freeswitch.confd
+ freeswitch.initd
+ freeswitch.post-install
+ freeswitch.pre-install
+ "
+
+build() {
+ cd "$srcdir/$pkgname-$pkgver"
+ cp -f "$srcdir/modules.conf" modules.conf || return 1
+
+ # i think our max cmd len is 32768
+ # by specifying it here we save our selves from some CPU cycles
+ export lt_cv_sys_max_cmd_len=8192
+
+ ./configure --prefix=/usr \
+ --sysconfdir=/etc/freeswitch \
+ --with-modinstdir=/usr/lib/freeswitch \
+ --with-rundir=/var/run/freeswitch \
+ --mandir=/usr/share/man \
+ --infodir=/usr/share/info \
+
+ make all || return 1
+}
+package(){
+ cd "$srcdir/$pkgname-$pkgver"
+ make -j1 DESTDIR="$pkgdir" install
+ # we need to do some moving/cleanup to allow some... kind of FHS
+ mkdir -p "$pkgdir"/var/run/freeswitch
+ mkdir -p "$pkgdir"/var/lib/freeswitch
+ mkdir -p "$pkgdir"/var/log
+ mkdir -p "$pkgdir"/usr/share/freeswitch
+ mv "$pkgdir"/usr/db "$pkgdir"/var/lib/freeswitch/
+ mv "$pkgdir"/usr/grammar "$pkgdir"/var/lib/freeswitch/
+ mv "$pkgdir"/usr/htdocs "$pkgdir"/usr/share/freeswitch/
+ mv "$pkgdir"/usr/recordings "$pkgdir"/var/lib/freeswitch/
+ mv "$pkgdir"/usr/scripts "$pkgdir"/usr/share/freeswitch/
+ mv "$pkgdir"/usr/log "$pkgdir"/var/log/freeswitch
+ install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
+ install -m644 -D "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname
+}
+
+md5sums="388effee587887a81fe7f411b7350590 freeswitch-1.0.6.tar.gz
+c05f2356be159e99b3845f5260a33599 modules.conf
+c608cca8ad773acebf201f581438c7e7 freeswitch.confd
+a15f739b6f4f2c1685ab9f8831d30ca6 freeswitch.initd
+107c52398ff88275006b8223ee0b4907 freeswitch.post-install
+25945ad43b7dd988f37bf6f2603e22be freeswitch.pre-install"