diff options
Diffstat (limited to 'testing/kamailio')
-rw-r--r-- | testing/kamailio/APKBUILD | 66 |
1 files changed, 60 insertions, 6 deletions
diff --git a/testing/kamailio/APKBUILD b/testing/kamailio/APKBUILD index 55cd13406..f40d89fac 100644 --- a/testing/kamailio/APKBUILD +++ b/testing/kamailio/APKBUILD @@ -1,14 +1,16 @@ # Contributor: Michael Mason <ms13sp@gmail.com> pkgname=kamailio pkgver=1.5.2 -pkgrel=1 +pkgrel=2 pkgdesc="Open Source SIP Server" url="http://www.kamailio.org/" license="GPL" depends= -makedepends="bison flex expat-dev postgresql-dev mysql-dev" +makedepends="bison flex expat-dev postgresql-dev mysql-dev pcre-dev + libxml2-dev curl-dev" install= -subpackages="$pkgname-doc" +subpackages="$pkgname-doc $pkgname-mysql $pkgname-postgres $pkgname-pcre + $pkgname-presence" source="http://www.kamailio.org/pub/kamailio/$pkgver/src/$pkgname-$pkgver-notls_src.tar.gz kamailio.initd kamailio.pre-install @@ -25,11 +27,63 @@ build() { kamctl.base kamctlrc || return 1 cd .. - make prefix=/usr || return 1 - make prefix=/usr basedir="$pkgdir" install || return 1 + make prefix=/usr \ + MODS_MYSQL=yes \ + MODS_PCRE=yes \ + MODS_PRESENCE=yes \ + MODS_RADIUS= \ + TLS= \ + include_modules=db_postgres \ + all || return 1 + make prefix=/usr \ + MODS_MYSQL=yes \ + MODS_PCRE=yes \ + MODS_PRESENCE=yes \ + MODS_RADIUS= \ + TLS= \ + include_modules=db_postgres \ + basedir="$pkgdir" install || return 1 install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname - # install -m644 -D "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname +} + +_mv_mod() { + local moddir=usr/lib/kamailio/modules i= + mkdir -p "$subpkgdir"/$moddir + for i in $@; do + mv "$pkgdir"/$moddir/$i.so "$subpkgdir"/$moddir/ || return 1 + done +} + + +mysql() { + pkgdesc="MySQL support for kamailio" + depends="kamailio mysql-client" + _mv_mod db_mysql + mkdir -p "$subpkgdir"/usr/share/kamailio + mv "$pkgdir"/usr/share/kamailio/mysql \ + "$subpkgdir"/usr/share/kamailio/ +} + +postgres() { + pkgdesc="PostgreSQL support for kamailio" + depends="kamailio postgresql-client" + _mv_mod db_postgres + mkdir -p "$subpkgdir"/usr/share/kamailio + mv "$pkgdir"/usr/share/kamailio/postgres \ + "$subpkgdir"/usr/share/kamailio/ +} + +pcre() { + pkgdesc="Regular expressions support for kamailio" + _mv_mod dialplan lcr regex +} + +presence() { + pkgdesc="Precense support for kamailio" + _mv_mod presence presence_xml presence_mwi pua pua_bla pua_mi \ + pua_usrloc pua_xmpp rls xcap_client presence_dialoginfo \ + pua_dialoginfo } md5sums="6c6f4ed6fbcb4d008b8ac3de5b99ce99 kamailio-1.5.2-notls_src.tar.gz |