merge of '5135d5b0b85d509b8af80d221f18563d4ce62475'
[vuplus_openembedded] / packages / samba / samba_3.0.23c.bb
1 require samba.inc
2 inherit update-rc.d
3
4 PR = "r2"
5
6 SRC_URI += "file://config-lfs.patch;patch=1 \
7            file://init \
8            file://quota.patch;patch=1;pnum=0 \
9            "
10
11 INITSCRIPT_NAME = "samba"
12 # No dependencies, goes in at level 20 (NOTE: take care with the
13 # level, later levels put the shutdown later too - see the links
14 # in rc6.d, the shutdown must precede network shutdown).
15 INITSCRIPT_PARAMS = "defaults"
16 CONFFILES_${PN} = "${sysconfdir}/samba/smb.conf"
17
18 # The file system settings --foodir=dirfoo and overridden unconditionally
19 # in the samba config by --with-foodir=dirfoo - even if the --with is not
20 # specified!  Fix that here.  Set the privatedir to /etc/samba/private.
21 EXTRA_OECONF += "\
22         samba_cv_struct_timespec=yes \
23         --with-configdir=${sysconfdir}/samba \
24         --with-privatedir=${sysconfdir}/samba/private \
25         --with-lockdir=${localstatedir}/lock \
26         --with-piddir=${localstatedir}/run \
27         --with-logfilebase=${localstatedir}/log \
28         --with-libdir=${libdir} \
29         --with-mandir=${mandir} \
30         --with-swatdir=${datadir}/swat \
31         "
32
33 do_install_append() {
34         install -d "${D}${localstatedir}/log"
35         rm -f ${D}/sbin/mount.smbfs
36         ln -sf smbmount ${D}${sbindir}/mount.smbfs
37         install -d "${D}${sysconfdir}/init.d"
38         install -c -m 755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/samba
39         install -d "${D}${sysconfdir}/samba"
40         install -c -m 644 ../examples/smb.conf.default ${D}${sysconfdir}/samba/smb.conf
41 }
42
43 PACKAGES =+ "swat"
44
45 FILES_swat = "${sbindir}/swat ${datadir}/swat ${libdir}/*.msg"
46 FILES_${PN} += "${libdir}/vfs/*.so ${libdir}/charset/*.so ${libdir}/*.dat ${libdir}/auth/*.so"
47 #
48 # bug fix for samba.inc:
49 FILES_cifs-doc += "${mandir}/man8/mount.cifs.8"