wok-6.x annotate sudo-pam/receipt @ rev 4779
Add: libbfd.
author | Eric Joseph-Alexandre <erjo@slitaz.org> |
---|---|
date | Thu Jan 14 22:16:51 2010 +0100 (2010-01-14) |
parents | f231dfc2b819 |
children | 1996b45528ae |
rev | line source |
---|---|
pascal@2191 | 1 # SliTaz package receipt. |
pascal@2191 | 2 |
pascal@2191 | 3 PACKAGE="sudo-pam" |
erjo@4665 | 4 VERSION="1.7.2p2" |
pascal@2191 | 5 CATEGORY="security" |
pascal@2191 | 6 SHORT_DESC="Sudo (su \"do\") allows a system administrator to delegate authority using PAM." |
pascal@2191 | 7 MAINTAINER="erjo@slitaz.org" |
pascal@2191 | 8 DEPENDS="pam" |
pascal@2191 | 9 BUILD_DEPENDS="pam pam-dev" |
pascal@2191 | 10 SOURCE="sudo" |
pascal@2191 | 11 TARBALL="$SOURCE-$VERSION.tar.gz" |
pascal@2191 | 12 WEB_SITE="http://www.gratisoft.us/sudo/" |
pascal@2191 | 13 WGET_URL="http://www.gratisoft.us/sudo/dist/$TARBALL" |
pascal@2191 | 14 PROVIDE="sudo:pam" |
pascal@2191 | 15 |
pascal@2191 | 16 # Rules to configure and make the package. |
pascal@2191 | 17 compile_rules() |
pascal@2191 | 18 { |
pascal@2191 | 19 cd $src |
pascal@2191 | 20 ./configure --prefix=/usr \ |
pascal@2191 | 21 --sysconfdir=/etc \ |
pascal@2191 | 22 --with-pam \ |
pascal@2191 | 23 --with-editor=/bin/vi \ |
pascal@2191 | 24 --libexecdir=/usr/lib \ |
pascal@2191 | 25 $CONFIGURE_ARGS && |
pascal@2191 | 26 |
pascal@2191 | 27 # Build everything |
pascal@2191 | 28 make && |
pascal@2191 | 29 # Install everything |
pascal@2191 | 30 make DESTDIR=$PWD/_pkg install |
pascal@2191 | 31 } |
pascal@2191 | 32 |
pascal@2191 | 33 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@2191 | 34 genpkg_rules() |
pascal@2191 | 35 { |
pascal@2191 | 36 mkdir -p $fs/usr/lib |
pascal@2191 | 37 mkdir -p $fs/etc |
pascal@2191 | 38 cp -a $_pkg/usr/bin $fs/usr |
pascal@2191 | 39 cp -a $_pkg/usr/sbin $fs/usr |
pascal@2191 | 40 cp -a $_pkg/usr/lib/*.so $fs/usr/lib |
pascal@2287 | 41 cp -a ../$SOURCE/stuff/sudoers $fs/etc |
pascal@2191 | 42 strip -s $fs/usr/bin/* |
pascal@2191 | 43 strip -s $fs/usr/sbin/* |
pascal@2191 | 44 strip -s $fs/usr/lib/sudo_noexec.so |
pascal@2191 | 45 } |
pascal@2191 | 46 |
pascal@2191 | 47 pre_install() |
pascal@2191 | 48 { |
pascal@2191 | 49 echo "Processing pre-install commands..." |
pascal@2191 | 50 if [ -f $root/etc/sudoers.bak ]; then |
pascal@2191 | 51 cp $root/etc/sudoers $root/etc/sudoers.bak |
pascal@2191 | 52 fi |
pascal@2191 | 53 } |
pascal@2191 | 54 |
pascal@2191 | 55 post_install() |
pascal@2191 | 56 { |
pascal@2191 | 57 local root |
pascal@2191 | 58 root=$1 |
pascal@2191 | 59 echo "Processing post-install commands..." |
pascal@2191 | 60 if [ -f $root/etc/sudoers.bak ]; then |
pascal@2191 | 61 rm -f $root/etc/sudoers |
pascal@2191 | 62 mv $root/etc/sudoers.bak $root/etc/sudoers |
pascal@2191 | 63 else |
pascal@2191 | 64 chown root.root $root/etc/sudoers |
pascal@2191 | 65 chmod 0440 $root/etc/sudoers |
pascal@2191 | 66 fi |
pascal@2191 | 67 } |