wok-6.x annotate bristuff/receipt @ rev 3807

Update: icedtea6 (BUILD_DEPENDS)
author Matthew Sheets <rcx@zoominternet.net>
date Wed Aug 05 16:07:20 2009 +0000 (2009-08-05)
parents 749730241669
children
rev   line source
pascal@1187 1 #!/bin/sh
pascal@1187 2 # SliTaz package receipt.
pascal@1187 3
pascal@1187 4 PACKAGE="bristuff"
pascal@1187 5 VERSION="0.4.0-test6-xr1"
pascal@1187 6 CATEGORY="meta"
pascal@1187 7 SHORT_DESC="ISDN patches for Asterisk/Zaptel."
pascal@1187 8 MAINTAINER="pascal.bellard@slitaz.org"
pascal@1187 9 TARBALL="$PACKAGE-$VERSION.tar.gz"
pascal@1187 10 WEB_SITE="http://www.junghanns.net/"
pascal@1187 11 WGET_URL="http://updates.xorcom.com/astribank/bristuff/1.4/$TARBALL"
pascal@1187 12 BUILD_DEPENDS="openssl-dev ncurses-dev zlib-dev patch libogg-dev libvorbis-dev \
pascal@1187 13 curl-dev newt-dev libusb-dev sqlite-dev alsa-lib-dev fxload speex-dev \
pascal@1187 14 iksemel-dev mysql-dev glibc-dev spandsp-dev tiff-dev radiusclient-ng-dev \
pascal@1187 15 mysql libmysqlclient cmake postgresql postgresql-dev libpostgresqlclient \
pascal@1629 16 libtool unixODBC-dev libunixODBC nbs nbs-dev mISDNuser-dev mISDNuser \
pascal@1629 17 gnutls-dev"
pascal@1629 18 DEPENDS="asterisk asterisk-sound zaptel nbs mISDNuser"
jozee@3568 19 TAGS="isdn"
pascal@1187 20
pascal@1187 21 #TODO: net-snmp(-dev) vpb-driver(-dev)
pascal@1187 22 #Asterisk: libopenh323-dev (Not so nice addon), libsnmp-dev (Asterisk 1.4)
pascal@1187 23 #Asterisk+=app_ivrdemo? app_osplookup app_rpt? app_skel?
pascal@1187 24 #Asterisk+=cdr_sqlite(sqlite) res_snmp(netsnmp)
pascal@1187 25 #Asterisk+=chan_features? chan_h323(openh323) chan_vpb(vpbapi)
pascal@1187 26 #Asterisk+=pbx_gtkconsole(gtk) pbx_kdeconsole(qt)
pascal@1187 27 #Asterisk+=IMAP_STORAGE(imap_tk,ssl) CORE-SOUNDS-ES-GSM CORE-SOUNDS-FR-GSM
pascal@1187 28 #Asterisk+=MOH-FREEPLAY-GSM EXTRA-SOUNDS-EN-GSM
pascal@1187 29
pascal@1187 30 # Download a source tarball
pascal@1187 31 . /etc/tazwok.conf
pascal@1187 32 slitaz_wget()
pascal@1187 33 {
pascal@1187 34 if [ ! -f $SOURCES_REPOSITORY/$(basename $2) ]; then
pascal@1187 35 local here=$(pwd)
pascal@1187 36 cd $SOURCES_REPOSITORY
pascal@1187 37 wget $1 $2
pascal@1187 38 cd $here
pascal@1187 39 fi
pascal@1187 40 cp $SOURCES_REPOSITORY/$(basename $2) .
pascal@1187 41 }
pascal@1187 42
pascal@1187 43 # Rules to configure and make the package.
pascal@1187 44 compile_rules()
pascal@1187 45 {
pascal@2412 46 if [ -L $(which patch) ]; then
pascal@2412 47 echo "Please reinstall patch !"
pascal@2412 48 return 1
pascal@2412 49 fi
pascal@1187 50 if [ ! -d ../linux/taz ]; then
pascal@1187 51 tazwok cook linux
pascal@1187 52 fi
pascal@2062 53 KVERS=$(grep "kernel version" ../linux/$(ls ../linux/taz)/.config)
pascal@1187 54 KVERS=${KVERS##* }
pascal@2062 55 KSRC=$(cd ../linux/$(ls ../linux/taz) ; pwd)
pascal@1187 56 export KVERS
pascal@1187 57 export KSRC
pascal@1187 58 cd $src
pascal@1187 59 eval $(grep ^ADD_VER= download.sh)
pascal@1187 60 slitaz_wget -c $SF_MIRROR/agx-ast-addons/agx-ast-addons-$ADD_VER.tar.bz2
pascal@1187 61 #bluetooth:
pascal@1187 62 #slitaz_wget -c http://svn.digium.com/view/asterisk-addons/trunk/channels/chan_mobile.c?view=co
pascal@1187 63 #slitaz_wget -c http://www.chan-mobile.org/downloads/chan_mobile-1.4.x.patch
pascal@1187 64 # cd asterisk-addons
pascal@1187 65 # patch -p0 < chan_mobile-1.4.x.patch
pascal@1187 66 tar xjf agx-ast-addons-$ADD_VER.tar.bz2
pascal@1567 67 for i in CMakeLists.u bristuff.u; do
pascal@1567 68 [ -f done.$i ] && continue
pascal@1629 69 echo "Apply $i..."
pascal@1567 70 patch -p0 < ../stuff/$i || return 1
pascal@1567 71 touch done.$i
pascal@1567 72 done
pascal@1187 73 chmod +x apply-patches.sh
pascal@1187 74 sh ./download.sh
pascal@1629 75 echo "Apply sounds.u..."
pascal@1629 76 patch -p0 < ../stuff/sounds.u || return 1
pascal@1187 77 ln -s . zaptel/zaptel
pascal@1187 78 ln -s . zaptel/linux
pascal@1187 79 mkdir -p _pkg/etc/init.d _pkg/usr/include/zaptel
pascal@1567 80 [ -f done.uname ] ||
pascal@1187 81 grep -rsl "uname -r" . | xargs sed -i -e "s/uname -r/echo $KVERS/g"
pascal@1567 82 touch done.uname
pascal@1187 83 export BRISTUFF_ZAP_PARAMS="KBUILD_NOPEDANTIC=1"
pascal@1629 84 sed -i 's/^NO_H323=.*/NO_H323="--with-gsm=internal --without-pwlib --without-h323"/' ./compile.sh
pascal@1187 85 sh ./compile.sh -d $(cd _pkg; pwd) -i
pascal@1187 86 cp asterisk/configs/* _pkg/etc/asterisk/
pascal@1795 87 cp asterisk-addons/configs/* _pkg/etc/asterisk/
pascal@1187 88 cd agx-ast-addons
pascal@1187 89 cmake "." -DCMAKE_INSTALL_PREFIX=../_pkg/usr
pascal@1187 90 make install
pascal@1187 91 cd ..
pascal@1187 92 ln -s libgsmat.so.1.0 _pkg/usr/lib/libgsmat.so.1
pascal@1187 93 cp ../stuff/*.files-list .
pascal@1187 94 }
pascal@1187 95
pascal@1187 96
pascal@1187 97 # Rules to gen a SliTaz package suitable for Tazpkg.
pascal@1187 98 genpkg_rules()
pascal@1187 99 {
pascal@1187 100 # Just to have a dir.
pascal@1187 101 mkdir -p $fs/var/lib/asterisk
pascal@1187 102 # Cook all packages based on bristuff
pascal@1187 103 for i in $(cd $WOK; grep -l '^WANTED="bristuff"$' */receipt)
pascal@1187 104 do
pascal@1187 105 tazwok cook ${i%/receipt}
pascal@1187 106 done
pascal@1187 107 }
pascal@1187 108