wok annotate kamailio/receipt @ rev 23532

updated python-prompt-toolkit (0.57 -> 2.0.10)
author Hans-G?nter Theisgen
date Mon Apr 06 15:37:40 2020 +0100 (2020-04-06)
parents 67b6f615fc27
children 2a0479881723
rev   line source
pascal@19513 1 # SliTaz package receipt.
pascal@19513 2
pascal@19513 3 PACKAGE="kamailio"
Hans-G?nter@22977 4 VERSION="5.3.2"
pascal@19513 5 CATEGORY="network"
pascal@19513 6 SHORT_DESC="Open Source SIP Server."
pascal@19513 7 MAINTAINER="pascal.bellard@slitaz.org"
pascal@19513 8 LICENSE="GPL2"
Hans-G?nter@22977 9 WEB_SITE="https://www.kamailio.org/"
Hans-G?nter@22977 10
pascal@19513 11 TARBALL="$PACKAGE-${VERSION}_src.tar.gz"
pascal@19513 12 WGET_URL="${WEB_SITE}pub/kamailio/$VERSION/src/$TARBALL"
Hans-G?nter@22977 13
Hans-G?nter@22977 14 DEPENDS="curl expat libldap libssl libpostgresqlclient libxml2
Hans-G?nter@22977 15 net-snmp pcre radiusclient-ng"
Hans-G?nter@22977 16 BUILD_DEPENDS="bison curl-dev expat-dev flex libxml2-dev
Hans-G?nter@22977 17 net-snmp-dev openldap-dev openssl-dev pcre-dev
Hans-G?nter@22977 18 postgresql-dev python-dev radiusclient-ng-dev"
Hans-G?nter@22977 19
pascal@19513 20 CONFIG_FILES="/etc/kamailio"
pascal@19513 21
pascal@19513 22 # Rules to configure and make the package.
pascal@19513 23 compile_rules()
pascal@19513 24 {
Hans-G?nter@22979 25 sed -i 's|uname -m|echo i486|' \
Hans-G?nter@22979 26 src/Makefile.defs
Hans-G?nter@22977 27
Hans-G?nter@22977 28 make \
Hans-G?nter@22977 29 PREFIX="/usr" \
Hans-G?nter@22977 30 include_modules="acc_radius app_python auth_radius \
pascal@19513 31 db_postgres ldap presence_conference presence_dialoginfo presence_mwi \
Hans-G?nter@22977 32 presence_profile presence_reginfo presence_xml snmpstats xmpp dialplan" \
Hans-G?nter@22977 33 cfg &&
Hans-G?nter@22977 34 make all &&
pascal@19513 35 make DESTDIR=$DESTDIR install
pascal@19513 36 }
pascal@19513 37
pascal@19513 38 # Rules to gen a SliTaz package suitable for Tazpkg.
pascal@19513 39 genpkg_rules()
pascal@19513 40 {
pascal@19513 41 mkdir -p $fs/var/run/kamailio
Hans-G?nter@22977 42
Hans-G?nter@22977 43 cp -a $install/* $fs
Hans-G?nter@22977 44 mv $fs/usr/etc $fs
Hans-G?nter@22977 45 ln -s /etc $fs/usr/etc
pascal@19513 46 }
pascal@19513 47
pascal@19513 48 # Pre and post install commands for Tazpkg.
pascal@19513 49 post_install()
pascal@19513 50 {
pascal@19513 51
pascal@19513 52 local user
pascal@19513 53 local group
pascal@19513 54
pascal@19513 55 user=kamailio
pascal@19513 56 group=kamailio
pascal@19513 57
Hans-G?nter@22977 58 if ! grep -q $user $1/etc/passwd
Hans-G?nter@22977 59 then
pascal@19513 60 echo -n "Adding user/group $user..."
pascal@19513 61 chroot $1/ addgroup -S $group
pascal@19513 62 chroot $1/ adduser -s /bin/false -S -D -H -G $group $user
pascal@19513 63 status
pascal@19513 64 fi
pascal@19513 65 chroot "$1/" chown $user:$group /var/run/kamailio
pascal@19513 66 }
pascal@19513 67
pascal@19513 68 post_remove()
pascal@19513 69 {
pascal@19513 70 echo "Removing user/group kamailio"
pascal@19513 71 chroot "$1/" deluser kamailio
pascal@19513 72 }