wok-next diff at/receipt @ rev 20762
Add leanify
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Tue Jun 05 17:27:09 2018 +0300 (2018-06-05) |
parents | e3270f32432e |
children | 360e5b4f243b |
line diff
1.1 --- a/at/receipt Wed Jul 06 00:15:11 2016 +0200 1.2 +++ b/at/receipt Tue Jun 05 17:27:09 2018 +0300 1.3 @@ -1,37 +1,52 @@ 1.4 -# SliTaz package receipt. 1.5 +# SliTaz package receipt v2. 1.6 1.7 PACKAGE="at" 1.8 -VERSION="3.1.13" 1.9 +VERSION="3.1.20" 1.10 CATEGORY="system-tools" 1.11 -SHORT_DESC="Schedule commands to be executed once." 1.12 +SHORT_DESC="Schedule commands to be executed once" 1.13 MAINTAINER="pascal.bellard@slitaz.org" 1.14 LICENSE="GPL2" 1.15 WEB_SITE="http://packages.debian.org/lenny/at" 1.16 +LFS="http://www.linuxfromscratch.org/blfs/view/stable/general/at.html" 1.17 + 1.18 TARBALL="${PACKAGE}_${VERSION}.orig.tar.gz" 1.19 -WGET_URL="http://ftp.debian.org/debian/pool/main/${PACKAGE:0:1}/$PACKAGE/$TARBALL" 1.20 +WGET_URL="http://ftp.debian.org/debian/pool/main/a/at/$TARBALL" 1.21 1.22 -BUILD_DEPENDS="bison flex ssmtp" 1.23 +BUILD_DEPENDS="automake bison flex ssmtp" 1.24 1.25 -# Rules to configure and make the package. 1.26 -compile_rules() 1.27 -{ 1.28 - sed -i 's|/doc|/share/doc|' Makefile* 1.29 - ./configure --with-daemon_username=nobody \ 1.30 - --with-daemon_groupname=nogroup \ 1.31 - --with-atspool=/var/spool/atd \ 1.32 - --with-jobdir=/var/spool/atd \ 1.33 - $CONFIGURE_ARGS && 1.34 +compile_rules() { 1.35 + addgroup -g 17 -S atd 1.36 + adduser -S -H -D -g "atd daemon" -G atd -u 17 atd 1.37 + mkdir -p /var/spool/cron 1.38 + 1.39 + sed -i '/docdir/s|=.*|= @docdir@|' Makefile.in 1.40 + autoreconf 1.41 + 1.42 + ./configure \ 1.43 + --with-daemon_username=atd \ 1.44 + --with-daemon_groupname=atd \ 1.45 + SENDMAIL=/usr/sbin/sendmail \ 1.46 + \ 1.47 + --with-atspool=/var/spool/atd \ 1.48 + --with-jobdir=/var/spool/atd \ 1.49 + $CONFIGURE_ARGS && 1.50 make -j1 && 1.51 - make -j1 IROOT=$DESTDIR install 1.52 + make -j1 \ 1.53 + IROOT=$DESTDIR \ 1.54 + docdir=/usr/share/doc/$PACKAGE-$VERSION \ 1.55 + atdocdir=/usr/share/doc/$PACKAGE-$VERSION \ 1.56 + install || return 1 1.57 + 1.58 + install -Dm755 $stuff/atd $install/etc/init.d/atd 1.59 } 1.60 1.61 -# Rules to gen a SliTaz package suitable for Tazpkg. 1.62 -genpkg_rules() 1.63 -{ 1.64 - mkdir -p $fs/usr $fs/etc/init.d 1.65 - cp -a $install/usr/bin $fs/usr 1.66 - cp -a $install/usr/sbin $fs/usr 1.67 - cp -a $install/etc $fs 1.68 - cp -a $install/var $fs 1.69 - cp -a $stuff/atd $fs/etc/init.d 1.70 +genpkg_rules() { 1.71 + copy @std 1.72 } 1.73 + 1.74 +post_install() { 1.75 + if ! grep -q '^atd:' "$1/etc/group"; then 1.76 + chroot "$1/" addgroup -g 17 -S atd 1.77 + chroot "$1/" adduser -S -H -D -g "atd daemon" -G atd -u 17 atd 1.78 + fi 1.79 +}