wok view ppp-pam/receipt @ rev 15771

fpm2: add icon
author Dominique Corbex <domcox@slitaz.org>
date Tue Jan 07 22:29:24 2014 +0100 (2014-01-07)
parents a436a235f098
children 44b43b66e908
line source
1 # SliTaz package receipt.
3 PACKAGE="ppp-pam"
4 VERSION="2.4.5"
5 CATEGORY="network"
6 SHORT_DESC="Implements the Point-to-Point Protocol (PPP) with PAM support."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 LICENSE="BSD GPL"
9 SOURCE="ppp"
10 TARBALL="$SOURCE-$VERSION.tar.gz"
11 WEB_SITE="http://ppp.samba.org/"
12 WGET_URL="ftp://ftp.samba.org/pub/ppp/$TARBALL"
13 DEPENDS="pam"
14 BUILD_DEPENDS="pam pam-dev"
15 CONFIG_FILES="/etc/ppp"
16 PROVIDE="ppp:pam"
18 # Rules to configure and make the package.
19 compile_rules()
20 {
21 cd $src
22 if ! grep -qs pppol2tpv3_addr include/linux/if_pppol2tp.h ; then
23 sed -i /#endif/d include/linux/if_pppol2tp.h
24 cat >> include/linux/if_pppol2tp.h <<EOT
25 /* The L2TPv3 protocol changes tunnel and session ids from 16 to 32
26 * bits. So we need a different sockaddr structure.
27 */
28 struct pppol2tpv3_addr {
29 pid_t pid; /* pid that owns the fd. 0 => current */
30 int fd; /* FD of UDP or IP socket to use */
31 struct sockaddr_in addr; /* IP address and port to send to */
32 __u32 s_tunnel, s_session; /* For matching incoming packets */
33 __u32 d_tunnel, d_session; /* For sending outgoing packets */
34 };
35 #endif
36 EOT
37 fi
38 sed -i 's/#USE_PAM/USE_PAM/' pppd/Makefile.linux
39 ./configure --prefix=/usr --mandir=/usr/share/man \
40 $CONFIGURE_ARGS &&
41 make &&
42 make DESTDIR=$DESTDIR/usr install
43 }
45 # Rules to gen a SliTaz package suitable for Tazpkg.
46 genpkg_rules()
47 {
48 mkdir -p $fs/usr
49 cp -a $install/usr/sbin $fs/usr
50 cp -a $install/usr/lib $fs/usr
51 # Config files.
52 mkdir -p $fs/etc/ppp/scripts
53 cp ../$SOURCE/stuff/README.scripts $fs/etc/ppp
54 cp -a $src/etc.ppp/* $fs/etc/ppp
55 # PPP scripts.
56 cp -a $src/scripts/ppp-on $fs/etc/ppp/scripts
57 cp -a $src/scripts/ppp-on-dialer $fs/etc/ppp/scripts
58 sed -i 's,ppp/ppp-on-dialer,ppp/script/ppp-on-dialer,' $fs/etc/ppp/scripts/ppp-on-dialer
59 cp -a $src/scripts/ppp-off $fs/etc/ppp/scripts
60 cp -a $src/scripts/callback $fs/etc/ppp/scripts
61 cp -a $src/scripts/redialer $fs/etc/ppp/scripts
63 cp -a $src/scripts/ip-up.local.add $fs/etc/ppp/scripts/ip-up
64 cp -a $src/scripts/ip-down.local.add $fs/etc/ppp/scripts/ip-down
65 chmod +x $fs/etc/ppp/scripts/ip*
66 # insert #!/bin/sh on top line in ip* scripts
67 sed -i '1i\#!/bin/sh' $fs/etc/ppp/scripts/ip*
68 }
70 pre_remove()
71 {
72 tazpkg get-install ${PACKAGE%-pam}
73 }