wok annotate iaxmodem/receipt @ rev 23043
gcc83-lib-base: add /usr/libgcc83/libstdc++.la (again)
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Thu Mar 05 12:21:44 2020 +0100 (2020-03-05) |
parents | 3132d67b7e38 |
children | ba7cbdb5749c |
rev | line source |
---|---|
pascal@14765 | 1 # SliTaz package receipt. |
pascal@14765 | 2 |
pascal@14765 | 3 PACKAGE="iaxmodem" |
Hans-G?nter@21041 | 4 VERSION="1.3.0" |
pascal@14765 | 5 CATEGORY="network" |
pascal@14765 | 6 SHORT_DESC="Software modem for libiax2." |
pascal@14765 | 7 MAINTAINER="pascal.bellard@slitaz.org" |
pascal@14765 | 8 LICENSE="GPL2" |
Hans-G?nter@21041 | 9 WEB_SITE="https://sourceforge.net/projects/iaxmodem/" |
Hans-G?nter@21041 | 10 |
pascal@14765 | 11 TARBALL="$PACKAGE-$VERSION.tar.gz" |
pascal@14765 | 12 WGET_URL="$SF_MIRROR/$PACKAGE/$TARBALL" |
pascal@14765 | 13 |
pascal@14765 | 14 DEPENDS="jpeg tiff zlib hylafax" |
pascal@20569 | 15 BUILD_DEPENDS="jpeg-dev tiff-dev zlib-dev file" |
Hans-G?nter@21041 | 16 CONFIG_FILES="/etc/iaxmodem" |
pascal@14765 | 17 |
pascal@14765 | 18 # Rules to configure and make the package. |
pascal@14765 | 19 compile_rules() |
pascal@14765 | 20 { |
pascal@14765 | 21 #sed -i 's/uucp/root/' iaxmodem.c |
Hans-G?nter@21041 | 22 |
Hans-G?nter@21041 | 23 ./configure \ |
Hans-G?nter@21041 | 24 --prefix=/usr \ |
Hans-G?nter@21041 | 25 --infodir=/usr/share/info \ |
Hans-G?nter@21041 | 26 --mandir=/usr/share/man \ |
Hans-G?nter@21041 | 27 $CONFIGURE_ARGS && |
Hans-G?nter@21041 | 28 make |
pascal@14765 | 29 } |
pascal@14765 | 30 |
pascal@14765 | 31 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@14765 | 32 genpkg_rules() |
pascal@14765 | 33 { |
Hans-G?nter@21041 | 34 mkdir -p \ |
Hans-G?nter@21041 | 35 $fs/usr/bin \ |
Hans-G?nter@21041 | 36 $fs/etc/iaxmodem \ |
Hans-G?nter@21041 | 37 $fs/var/log/iaxmodem |
Hans-G?nter@21041 | 38 |
pascal@14765 | 39 cp -a $src/iaxmodem $fs/usr/bin |
Hans-G?nter@21041 | 40 |
pascal@14765 | 41 cat > $fs/etc/iaxmodem/ttyIAX0 <<EOT |
pascal@14765 | 42 device /dev/ttyIAX0 |
pascal@14765 | 43 owner root:root |
pascal@14765 | 44 mode 660 |
pascal@14765 | 45 port 4570 |
pascal@14765 | 46 refresh 60 |
pascal@14765 | 47 server 127.0.0.1 |
pascal@14765 | 48 peername iaxmodem |
pascal@14765 | 49 secret password |
pascal@14765 | 50 codec alaw |
pascal@14765 | 51 EOT |
pascal@14765 | 52 #owner uucp:uucp |
pascal@14765 | 53 #refresh 50 |
pascal@14765 | 54 } |
pascal@14765 | 55 |
pascal@14765 | 56 pre_remove() |
pascal@14765 | 57 { |
pascal@18730 | 58 sed -i '/iaxmodem/d' "$1/etc/inittab" |
pascal@14765 | 59 } |
pascal@14765 | 60 |
pascal@14765 | 61 # Pre and post install commands for Tazpkg. |
pascal@14765 | 62 post_install() |
pascal@14765 | 63 { |
pascal@18730 | 64 grep -q ^uucp: "$1/etc/passwd" || { |
pascal@18730 | 65 chroot "$1/" adduser -s /bin/false -S -D -H uucp |
pascal@18730 | 66 sed -i 's/^uucp:x:[0-9]*:[0-9]*:/uucp:x:0:0:/' "$1/etc/passwd" |
pascal@14765 | 67 } |
pascal@18730 | 68 grep -q ^uucp: "$1/etc/group" || chroot "$1/" addgroup uucp |
Hans-G?nter@21041 | 69 |
pascal@18730 | 70 touch "$1/var/log/iaxmodem/ttyIAX0" "$1/var/log/iaxmodem/iaxmodem" |
Hans-G?nter@21041 | 71 |
pascal@18730 | 72 grep iaxmodem "$1/etc/inittab" || cat >> "$1/etc/inittab" << EOT |
pascal@14765 | 73 ::respawn:/usr/bin/iaxmodem ttyIAX0 > /var/log/iaxmodem.log 2>&1 |
pascal@14765 | 74 ::respawn:/usr/sbin/faxgetty ttyIAX0 |
pascal@14765 | 75 EOT |
Hans-G?nter@21041 | 76 |
pascal@18730 | 77 [ "$1" ] || kill -1 1 |
pascal@14765 | 78 } |