wok annotate asterisk/receipt @ rev 9966
cdrdao: fix bdeps
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Wed May 18 17:24:58 2011 +0200 (2011-05-18) |
parents | 7ba9895e1216 |
children | 8f7d934ebcca |
rev | line source |
---|---|
pascal@1187 | 1 # SliTaz package receipt. |
pascal@1187 | 2 |
pascal@1187 | 3 PACKAGE="asterisk" |
pascal@5452 | 4 VERSION="1.6.2.7" |
pascal@1423 | 5 CATEGORY="misc" |
pascal@1187 | 6 SHORT_DESC="Open Source PBX and telephony toolkit." |
pascal@1187 | 7 MAINTAINER="pascal.bellard@slitaz.org" |
pascal@4111 | 8 TARBALL="$PACKAGE-$VERSION.tar.gz" |
pascal@4111 | 9 WEB_SITE="http://www.asterisk.org/" |
pascal@4111 | 10 WGET_URL="http://downloads.asterisk.org/pub/telephony/asterisk/$TARBALL" |
gokhlayeh@9395 | 11 DEPENDS="openssl ncurses zlib libogg libvorbis curl newt libusb-compat alsa-lib \ |
pascal@1187 | 12 speex iksemel spandsp tiff radiusclient-ng nbs freetds libpostgresqlclient \ |
pascal@4998 | 13 libmysqlclient libunixODBC popt dahdi libpri lua libcap attr net-snmp \ |
pascal@4998 | 14 portaudio sqlite libkrb5 libcomerr3 libsdl-image" |
pascal@8996 | 15 BUILD_DEPENDS="gtk+-dev libxml2-dev postgresql-dev libsdl-dev \ |
pascal@8995 | 16 gmime gmime-dev unixODBC-dev unixODBC openldap-dev openldap" |
pascal@1187 | 17 CONFIG_FILES="/etc/asterisk" |
jozee@4931 | 18 TAGS="telephone toolkit" |
pascal@1187 | 19 |
pascal@4111 | 20 # Rules to configure and make the package. |
pascal@4111 | 21 # |
pascal@4111 | 22 # Graphical configuration: 'make menuconfig' or 'make gmenuconfig' |
pascal@4111 | 23 # |
pascal@4111 | 24 compile_rules() |
pascal@1187 | 25 { |
pascal@4111 | 26 cd $src |
pascal@5442 | 27 busybox sed -i 's/tar xof/tar xf/' sounds/Makefile |
pascal@5442 | 28 busybox sed -i '/LOG_ERROR, "The file/ {nd}' main/config.c |
pascal@5442 | 29 busybox sed -i 's/LOG_ERROR, "The file/LOG_WARNING, "The file/' \ |
pascal@5442 | 30 main/config.c |
pascal@5442 | 31 busybox sed -i 's|lua5.1/||' pbx/pbx_lua.c |
pascal@5442 | 32 busybox sed -i 's/define AST_PBX_MAX_STACK.*/define AST_PBX_MAX_STACK 1024/' \ |
pascal@4851 | 33 main/pbx.c |
pascal@8999 | 34 sed -i 's/| sed .*>/>/' contrib/scripts/get_ilbc_source.sh |
pascal@4615 | 35 echo '' | contrib/scripts/get_ilbc_source.sh |
pascal@5442 | 36 busybox sed -i '/codec_ilbc/{ns/no/yes/}' menuselect-tree |
pascal@4111 | 37 ./configure \ |
pascal@4111 | 38 --prefix=/usr \ |
pascal@4111 | 39 --sysconfdir=/etc \ |
pascal@4111 | 40 --without-pwlib \ |
pascal@4593 | 41 --with-dahdi=$WOK/dahdi/$(ls $WOK/dahdi/taz) \ |
pascal@4111 | 42 $CONFIGURE_ARGS && |
pascal@5804 | 43 make -j 4 && |
pascal@4111 | 44 make DESTDIR=$PWD/_pkg install && |
pascal@4111 | 45 make DESTDIR=$PWD/_pkg samples && |
pascal@4111 | 46 cd contrib/utils && |
pascal@4111 | 47 gcc rawplayer.c -o $src/_pkg/usr/bin/rawplayer |
pascal@1187 | 48 } |
pascal@1187 | 49 |
pascal@1187 | 50 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@1187 | 51 genpkg_rules() |
pascal@1187 | 52 { |
pascal@4111 | 53 mkdir -p $fs/usr |
pascal@4111 | 54 cp -a $_pkg/etc $fs |
pascal@4111 | 55 cp -a $_pkg/var $fs |
pascal@4111 | 56 cp -a $_pkg/usr/bin $fs/usr |
pascal@4111 | 57 cp -a $_pkg/usr/lib $fs/usr |
pascal@4111 | 58 cp -a $_pkg/usr/sbin $fs/usr |
pankso@9697 | 59 cp -a $stuff/* $fs |
pascal@1806 | 60 } |
pascal@1806 | 61 |
pascal@1806 | 62 # Rules to configure package |
pascal@1806 | 63 setup_rules() |
pascal@1806 | 64 { |
pascal@1806 | 65 case "$2" in |
pascal@1806 | 66 mysql_host) |
pascal@1806 | 67 sed -i "s|^hostname=.*|hostname=$3|" $1/etc/asterisk/cdr_mysql.conf |
pascal@1920 | 68 sed -i "s|^dbhost=.*|dbhost=$3|" $1/etc/asterisk/res_mysql.conf |
pascal@1806 | 69 ;; |
pascal@1806 | 70 mysql_user) |
pascal@1806 | 71 sed -i "s|^user=.*|user=$3|" $1/etc/asterisk/cdr_mysql.conf |
pascal@1920 | 72 sed -i "s|^dbuser=.*|dbuser=$3|" $1/etc/asterisk/res_mysql.conf |
pascal@1806 | 73 ;; |
pascal@1806 | 74 mysql_password) |
pascal@1806 | 75 sed -i "s|^password=.*|password=$3|" $1/etc/asterisk/cdr_mysql.conf |
pascal@1920 | 76 sed -i "s|^dbpass=.*|dbpass=$3|" $1/etc/asterisk/res_mysql.conf |
pascal@1806 | 77 ;; |
pascal@1806 | 78 mysql_database) |
pascal@1920 | 79 sed -i "s|^dbname=.*|dbname=$3|" $1/etc/asterisk/res_mysql.conf \ |
pascal@1806 | 80 $1/etc/asterisk/cdr_mysql.conf |
pascal@1806 | 81 ;; |
pascal@1920 | 82 pgsql_host) |
pascal@1920 | 83 sed -i "s|^hostname=.*|hostname=$3|" $1/etc/asterisk/cdr_pgsql.conf |
pascal@1920 | 84 sed -i "s|^dbhost=.*|dbhost=$3|" $1/etc/asterisk/res_pgsql.conf |
pascal@1920 | 85 ;; |
pascal@1920 | 86 pgsql_user) |
pascal@1920 | 87 sed -i "s|^user=.*|user=$3|" $1/etc/asterisk/cdr_pgsql.conf |
pascal@1920 | 88 sed -i "s|^dbuser=.*|dbuser=$3|" $1/etc/asterisk/res_pgsql.conf |
pascal@1920 | 89 ;; |
pascal@1920 | 90 pgsql_password) |
pascal@1920 | 91 sed -i "s|^password=.*|password=$3|" $1/etc/asterisk/cdr_pgsql.conf |
pascal@1920 | 92 sed -i "s|^dbpass=.*|dbpass=$3|" $1/etc/asterisk/res_pgsql.conf |
pascal@1920 | 93 ;; |
pascal@1920 | 94 pgsql_database) |
pascal@1920 | 95 sed -i "s|^dbname=.*|dbname=$3|" $1/etc/asterisk/res_pgsql.conf \ |
pascal@1920 | 96 $1/etc/asterisk/cdr_pgsql.conf |
pascal@1920 | 97 ;; |
pascal@1806 | 98 *) cat <<EOT |
pascal@1806 | 99 mysql_host hostname or ip of mysql server |
pascal@1806 | 100 mysql_user username to connect to mysql server |
pascal@1806 | 101 mysql_password password to connect to mysql server |
pascal@1806 | 102 mysql_database database used by asterisk |
pascal@1920 | 103 pgsql_host hostname or ip of postgresql server |
pascal@1920 | 104 pgsql_user username to connect to postgresql server |
pascal@1920 | 105 pgsql_password password to connect to postgresql server |
pascal@1920 | 106 pgsql_database database used by asterisk |
pascal@1806 | 107 EOT |
pascal@1806 | 108 ;; |
pascal@1806 | 109 esac |
pascal@1187 | 110 } |