wok view samba/receipt @ rev 1250

Add samba
author Pascal Bellard <pascal.bellard@slitaz.org>
date Tue Aug 12 15:43:10 2008 +0000 (2008-08-12)
parents
children bfd918db2ced
line source
1 # SliTaz package receipt.
3 PACKAGE="samba"
4 VERSION="3.2.1"
5 CATEGORY="system-tools"
6 SHORT_DESC="File and print services with SMB/CIFS."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 TARBALL="$PACKAGE-$VERSION.tar.gz"
9 WEB_SITE="http://samba.org/"
10 WGET_URL="${WEB_SITE}$PACKAGE/ftp/stable/$TARBALL"
11 BUILD_DEPENDS="libldap openldap-dev cups cups-dev"
12 DEPENDS="libldap smbclient perl cups"
13 CONFIG_FILES="/etc/samba"
14 BUGS="Open directory needs MIT kerberos support (krb5)"
16 # Rules to configure and make the package.
17 compile_rules()
18 {
19 cd $src/source
20 ./configure --prefix=/usr --infodir=/usr/share/info \
21 --with-piddir=/var/run/samba --with-lockdir=/var/run/samba \
22 --with-winbind --with-ldap --with-fhs --enable-cups --enable-swat \
23 --enable-shared-libs --with-libtalloc --with-libtdb \
24 --with-libsmbsharemodes --with-libsmbclient \
25 --sysconfdir=/etc --localstatedir=/var \
26 --mandir=/usr/share/man $CONFIGURE_ARGS
27 make
28 make DESTDIR=$PWD/../_pkg install
29 ln -s libwbclient.so $PWD/../_pkg/usr/lib/libwbclient.so.0
30 cp ../../stuff/*.files-list ..
31 }
33 # Rules to gen a SliTaz package suitable for Tazpkg.
34 genpkg_rules()
35 {
36 mkdir -p $fs/usr
37 cp -a $_pkg/etc $fs
38 cp -a $_pkg/var $fs
39 cp -a $_pkg/usr/lib $fs/usr
40 cp -a $_pkg/usr/sbin $fs/usr
41 cp -a $_pkg/usr/bin $fs/usr
42 cp -a stuff/etc $fs
43 cat $src/*.files-list | while read file; do
44 rm -rf $fs$file
45 done
46 # Package all samba pkgs
47 for i in $(cd $WOK; grep -l '^WANTED="samba"$' */receipt)
48 do
49 tazwok cook ${i%/receipt}
50 done
51 }
53 # Pre and post install commands for Tazpkg.
54 post_install()
55 {
56 ( cd $1/ ; cpio -o -H newc | gzip -9 ) > \
57 $1/$INSTALLED/$PACKAGE/volatile.cpio.gz <<EOT
58 etc/samba
59 EOT
60 cat <<EOF
61 ----
62 The main configuration file is /etc/samba/smb.conf
63 ----
64 To start $PACKAGE server you can run :
66 /etc/init.d/$PACKAGE start
68 Or add $PACKAGE to RUN_DAEMONS in /etc/rcS.conf
69 ----
70 EOF
71 }
73 repack_cleanup()
74 {
75 zcat $INSTALLED/$PACKAGE/volatile.cpio.gz | ( cd $1 ; cpio -id )
76 }