wok-6.x annotate get-softmodem-driver/stuff/slmodem.receipt @ rev 21309
1) libfm-extra: fix build while using development sources
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Thu Apr 18 17:17:32 2019 +0300 (2019-04-18) |
parents | |
children |
rev | line source |
---|---|
pascal@13591 | 1 # SliTaz package receipt. |
pascal@13591 | 2 |
pascal@13591 | 3 PACKAGE="slmodem" |
pascal@13591 | 4 VERSION="2.9.11-20090222" |
pascal@13591 | 5 CATEGORY="non-free" |
pascal@13591 | 6 SHORT_DESC="Support for the SmartLink Softmodem and ALSA supported chipsets." |
pascal@13591 | 7 MAINTAINER="domcox@slitaz.org" |
pascal@13591 | 8 TARBALL="$PACKAGE-$VERSION.tar.gz" |
pascal@13591 | 9 DEPENDS="alsa-lib module-init-tools linux-source" |
pascal@13591 | 10 WEB_SITE="http://linmodems.technion.ac.il" |
pascal@13591 | 11 WGET_URL="http://linmodems.technion.ac.il/packages/smartlink/$TARBALL" |
pascal@13591 | 12 |
pascal@13591 | 13 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@13591 | 14 |
pascal@13591 | 15 post_install() |
pascal@13591 | 16 { |
pascal@13591 | 17 # Country detection |
pascal@13591 | 18 if [ -e /etc/TZ ]; then |
pascal@13591 | 19 ZONE=`cat /etc/TZ` |
pascal@13591 | 20 CODE=`grep $ZONE /usr/share/slmodem/zone.tab | cut -f1'` |
pascal@13591 | 21 if [ -n $CODE ]; then |
pascal@13591 | 22 COUNTRY=`grep ^$CODE /usr/share/slmodem/slmodem.country | cut -f2` |
pascal@13591 | 23 fi |
pascal@13591 | 24 fi |
pascal@13591 | 25 if [ -z $COUNTRY ]; then |
pascal@13591 | 26 COUNTRY="USA" |
pascal@13591 | 27 fi |
pascal@13591 | 28 echo "Automatic country setting: $COUNTRY" |
pascal@13591 | 29 # Save options |
pascal@13591 | 30 if [ `grep -c SLMODEM_OPTIONS /etc/daemons.conf` -gt 0 ]; then |
pascal@13591 | 31 sed -i 's/SLMODEM_OPTIONS=.*/SLMODEM_OPTIONS="--country='"$COUNTRY"' \/dev\/slamr0"/' /etc/daemons.conf |
pascal@13591 | 32 else |
pascal@13591 | 33 echo "# slmodemd daemon options." >> $root/etc/daemons.conf |
pascal@13591 | 34 echo "SLMODEM_OPTIONS=\"--country=$COUNTRY /dev/slamr0\"" >> $root/etc/daemons.conf |
pascal@13591 | 35 echo >> $root/etc/daemons.conf |
pascal@13591 | 36 fi |
pascal@13591 | 37 # Load module |
pascal@13591 | 38 depmod -a |
pascal@13591 | 39 /sbin/modprobe slamr && /etc/init.d/slmodem start |
pascal@13591 | 40 } |
pascal@13591 | 41 |
pascal@13591 | 42 post_remove() |
pascal@13591 | 43 { |
pascal@13591 | 44 /etc/init.d/slmodem stop |
pascal@13591 | 45 rm -rf /usr/share/slmodem |
pascal@13591 | 46 } |