wok-6.x annotate bristuff/receipt @ rev 2309
gcc: spin off libgomp
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Wed Feb 25 12:21:35 2009 +0000 (2009-02-25) |
parents | 0cfd1749f087 |
children | 749730241669 |
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" |
pascal@1187 | 19 |
pascal@1187 | 20 #TODO: net-snmp(-dev) vpb-driver(-dev) |
pascal@1187 | 21 #Asterisk: libopenh323-dev (Not so nice addon), libsnmp-dev (Asterisk 1.4) |
pascal@1187 | 22 #Asterisk+=app_ivrdemo? app_osplookup app_rpt? app_skel? |
pascal@1187 | 23 #Asterisk+=cdr_sqlite(sqlite) res_snmp(netsnmp) |
pascal@1187 | 24 #Asterisk+=chan_features? chan_h323(openh323) chan_vpb(vpbapi) |
pascal@1187 | 25 #Asterisk+=pbx_gtkconsole(gtk) pbx_kdeconsole(qt) |
pascal@1187 | 26 #Asterisk+=IMAP_STORAGE(imap_tk,ssl) CORE-SOUNDS-ES-GSM CORE-SOUNDS-FR-GSM |
pascal@1187 | 27 #Asterisk+=MOH-FREEPLAY-GSM EXTRA-SOUNDS-EN-GSM |
pascal@1187 | 28 |
pascal@1187 | 29 # Download a source tarball |
pascal@1187 | 30 . /etc/tazwok.conf |
pascal@1187 | 31 slitaz_wget() |
pascal@1187 | 32 { |
pascal@1187 | 33 if [ ! -f $SOURCES_REPOSITORY/$(basename $2) ]; then |
pascal@1187 | 34 local here=$(pwd) |
pascal@1187 | 35 cd $SOURCES_REPOSITORY |
pascal@1187 | 36 wget $1 $2 |
pascal@1187 | 37 cd $here |
pascal@1187 | 38 fi |
pascal@1187 | 39 cp $SOURCES_REPOSITORY/$(basename $2) . |
pascal@1187 | 40 } |
pascal@1187 | 41 |
pascal@1187 | 42 # Rules to configure and make the package. |
pascal@1187 | 43 compile_rules() |
pascal@1187 | 44 { |
pascal@1187 | 45 if [ ! -d ../linux/taz ]; then |
pascal@1187 | 46 tazwok cook linux |
pascal@1187 | 47 fi |
pascal@2062 | 48 KVERS=$(grep "kernel version" ../linux/$(ls ../linux/taz)/.config) |
pascal@1187 | 49 KVERS=${KVERS##* } |
pascal@2062 | 50 KSRC=$(cd ../linux/$(ls ../linux/taz) ; pwd) |
pascal@1187 | 51 export KVERS |
pascal@1187 | 52 export KSRC |
pascal@1187 | 53 cd $src |
pascal@1187 | 54 eval $(grep ^ADD_VER= download.sh) |
pascal@1187 | 55 slitaz_wget -c $SF_MIRROR/agx-ast-addons/agx-ast-addons-$ADD_VER.tar.bz2 |
pascal@1187 | 56 #bluetooth: |
pascal@1187 | 57 #slitaz_wget -c http://svn.digium.com/view/asterisk-addons/trunk/channels/chan_mobile.c?view=co |
pascal@1187 | 58 #slitaz_wget -c http://www.chan-mobile.org/downloads/chan_mobile-1.4.x.patch |
pascal@1187 | 59 # cd asterisk-addons |
pascal@1187 | 60 # patch -p0 < chan_mobile-1.4.x.patch |
pascal@1187 | 61 tar xjf agx-ast-addons-$ADD_VER.tar.bz2 |
pascal@1567 | 62 for i in CMakeLists.u bristuff.u; do |
pascal@1567 | 63 [ -f done.$i ] && continue |
pascal@1629 | 64 echo "Apply $i..." |
pascal@1567 | 65 patch -p0 < ../stuff/$i || return 1 |
pascal@1567 | 66 touch done.$i |
pascal@1567 | 67 done |
pascal@1187 | 68 chmod +x apply-patches.sh |
pascal@1187 | 69 sh ./download.sh |
pascal@1629 | 70 echo "Apply sounds.u..." |
pascal@1629 | 71 patch -p0 < ../stuff/sounds.u || return 1 |
pascal@1187 | 72 ln -s . zaptel/zaptel |
pascal@1187 | 73 ln -s . zaptel/linux |
pascal@1187 | 74 mkdir -p _pkg/etc/init.d _pkg/usr/include/zaptel |
pascal@1567 | 75 [ -f done.uname ] || |
pascal@1187 | 76 grep -rsl "uname -r" . | xargs sed -i -e "s/uname -r/echo $KVERS/g" |
pascal@1567 | 77 touch done.uname |
pascal@1187 | 78 export BRISTUFF_ZAP_PARAMS="KBUILD_NOPEDANTIC=1" |
pascal@1629 | 79 sed -i 's/^NO_H323=.*/NO_H323="--with-gsm=internal --without-pwlib --without-h323"/' ./compile.sh |
pascal@1187 | 80 sh ./compile.sh -d $(cd _pkg; pwd) -i |
pascal@1187 | 81 cp asterisk/configs/* _pkg/etc/asterisk/ |
pascal@1795 | 82 cp asterisk-addons/configs/* _pkg/etc/asterisk/ |
pascal@1187 | 83 cd agx-ast-addons |
pascal@1187 | 84 cmake "." -DCMAKE_INSTALL_PREFIX=../_pkg/usr |
pascal@1187 | 85 make install |
pascal@1187 | 86 cd .. |
pascal@1187 | 87 ln -s libgsmat.so.1.0 _pkg/usr/lib/libgsmat.so.1 |
pascal@1187 | 88 cp ../stuff/*.files-list . |
pascal@1187 | 89 } |
pascal@1187 | 90 |
pascal@1187 | 91 |
pascal@1187 | 92 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@1187 | 93 genpkg_rules() |
pascal@1187 | 94 { |
pascal@1187 | 95 # Just to have a dir. |
pascal@1187 | 96 mkdir -p $fs/var/lib/asterisk |
pascal@1187 | 97 # Cook all packages based on bristuff |
pascal@1187 | 98 for i in $(cd $WOK; grep -l '^WANTED="bristuff"$' */receipt) |
pascal@1187 | 99 do |
pascal@1187 | 100 tazwok cook ${i%/receipt} |
pascal@1187 | 101 done |
pascal@1187 | 102 } |
pascal@1187 | 103 |