summaryrefslogtreecommitdiff
path: root/pcr/yate
diff options
context:
space:
mode:
Diffstat (limited to 'pcr/yate')
-rw-r--r--pcr/yate/PKGBUILD71
-rw-r--r--pcr/yate/yate.init61
-rw-r--r--pcr/yate/yate.service9
3 files changed, 44 insertions, 97 deletions
diff --git a/pcr/yate/PKGBUILD b/pcr/yate/PKGBUILD
index bb84d1a67..62931ce29 100644
--- a/pcr/yate/PKGBUILD
+++ b/pcr/yate/PKGBUILD
@@ -1,37 +1,36 @@
- # Maintainer (Arch): said
- # Contributor (Arch): Yejun Yang <yejunx AT gmail DOT com>
- # Contributor (Arch): Biru Ionut <ionut@archlinux.ro>
- pkgname=yate
- pkgver=4.2.0
- pkgrel=1
- pkgdesc="next-generation telephony engine"
- arch=('i686' 'x86_64')
- url="http://yate.null.ro"
- license=('GPL')
- depends=('speex' 'gsm' 'postgresql-libs' 'libmysqlclient' \
- 'alsa-lib' 'qt')
- makedepends=('pkgconfig')
- source=(http://yate.null.ro/tarballs/yate4/${pkgname}-${pkgver}-2.tar.gz yate.init)
- options=(!makeflags)
-
- md5sums=('e6fd37f26ff5c50aa3fa16f6b2803d68'
- 'c0d344607046c47c1d75ac23d323817a')
+# Maintainer (Arch): said
+# Contributor (Arch): Yejun Yang <yejunx AT gmail DOT com>
+# Contributor (Arch): Biru Ionut <ionut@archlinux.ro>
-
- build() {
- cd $srcdir/${pkgname}
- export LDFLAGS="${LDFLAGS//-Wl,--as-needed}"
- ./configure --prefix=/usr \
- --sysconfdir=/etc \
- --with-libpq \
- --with-mysql \
- --without-openh323
- make
- }
-
- package(){
- cd $srcdir/${pkgname}
- make DESTDIR=$pkgdir install
- install -D -m755 $srcdir/yate.init $pkgdir/etc/rc.d/yate
- }
- \ No newline at end of file
+pkgname=yate
+pkgver=5.4.0.1
+pkgrel=1
+pkgdesc="next-generation telephony engine"
+arch=('i686' 'x86_64' 'mips64el')
+url="http://yate.null.ro"
+license=('GPL')
+depends=('speex' 'gsm' 'postgresql-libs' 'libmysqlclient' \
+ 'alsa-lib' 'qt')
+makedepends=('pkgconfig')
+source=(http://$pkgname.null.ro/tarballs/${pkgname}${pkgver%%.*}/$pkgname-${pkgver%.*}-${pkgver##*.}.tar.gz $pkgname.service)
+options=(!makeflags)
+
+md5sums=('427fd2ffde51116271534f398bf913e8'
+ '2fbcac43ec3bef1e386fcd456d1ee6f9')
+
+build() {
+ cd $srcdir/${pkgname}
+ export LDFLAGS="${LDFLAGS//-Wl,--as-needed}"
+ ./configure --prefix=/usr \
+ --sysconfdir=/etc \
+ --with-libpq \
+ --with-mysql \
+ --without-openh323
+ make
+}
+
+package(){
+ cd $srcdir/${pkgname}
+ make DESTDIR=$pkgdir install
+ install -D -m755 $srcdir/yate.service $pkgdir/usr/lib/systemd/system
+}
diff --git a/pcr/yate/yate.init b/pcr/yate/yate.init
deleted file mode 100644
index 762fff8c7..000000000
--- a/pcr/yate/yate.init
+++ /dev/null
@@ -1,61 +0,0 @@
-#!/bin/bash
-OPTS="-rs -vvv -l /var/log/yate"
-
-# Source function library.
-. /etc/rc.conf
-. /etc/rc.d/functions
-
-RETVAL=0
-
-# See how we were called.
-case "$1" in
- start)
- stat_busy "Starting YATE"
- unset DISPLAY
-
- yate -d -p /var/run/yate.pid $OPTS
- RETVAL=$?
- if [ $RETVAL -gt 0 ]; then
- stat_fail
- else
- add_daemon yate
- touch /var/lock/yate
- stat_done
- fi
- ;;
- stop)
- stat_busy "Stopping YATE"
- [ -f /var/run/yate.pid ] && kill $(cat /var/run/yate.pid) > /dev/null 2>&1
- RETVAL=$?
- if [ $RETVAL -gt 0 ]; then
- stat_fail
- else
- rm -f /var/run/yate.pid
- rm -f /var/lock/yate
- rm_daemon yate
- stat_done
- fi
- ;;
- status)
- [ -f /var/run/yate.pid ] && echo -e "Yate is running" || echo -e "Yate is not running"
- ;;
- restart)
- $0 stop
- sleep 1
- $1 start
- ;;
- condrestart)
- if [ -f /var/lock/yate ]; then
- $0 stop
- $0 start
- fi
- ;;
- reload)
- pkill yate -HUP
- RETVAL=$?
- ;;
- *)
- echo $"Usage: $0 {start|stop|status|restart|condrestart|reload}"
- ;;
-esac
-exit $RETVAL
diff --git a/pcr/yate/yate.service b/pcr/yate/yate.service
new file mode 100644
index 000000000..de2fb14a4
--- /dev/null
+++ b/pcr/yate/yate.service
@@ -0,0 +1,9 @@
+[Unit]
+Description=Next-generation telephony engine
+After=network.target
+
+[Service]
+ExecStart=/usr/bin/yate -d -p /run/yate.pid -rs -vvv -l /var/log/yate
+
+[Install]
+WantedBy=multi-user.target