diff options
Diffstat (limited to 'meta-oe/recipes-connectivity/samba/samba.inc')
| -rw-r--r-- | meta-oe/recipes-connectivity/samba/samba.inc | 31 |
1 files changed, 23 insertions, 8 deletions
diff --git a/meta-oe/recipes-connectivity/samba/samba.inc b/meta-oe/recipes-connectivity/samba/samba.inc index e5fa06ef63..faa2be0787 100644 --- a/meta-oe/recipes-connectivity/samba/samba.inc +++ b/meta-oe/recipes-connectivity/samba/samba.inc | |||
| @@ -5,7 +5,8 @@ DEPENDS = "readline virtual/libiconv talloc" | |||
| 5 | SRC_URI = "http://samba.org/samba/ftp/stable/samba-${PV}.tar.gz \ | 5 | SRC_URI = "http://samba.org/samba/ftp/stable/samba-${PV}.tar.gz \ |
| 6 | file://volatiles.03_samba \ | 6 | file://volatiles.03_samba \ |
| 7 | file://smb.conf \ | 7 | file://smb.conf \ |
| 8 | file://init \ | 8 | file://init.samba \ |
| 9 | file://init.winbind \ | ||
| 9 | file://tdb.pc \ | 10 | file://tdb.pc \ |
| 10 | " | 11 | " |
| 11 | 12 | ||
| @@ -13,11 +14,6 @@ S = "${WORKDIR}/samba-${PV}/source" | |||
| 13 | 14 | ||
| 14 | inherit autotools update-rc.d | 15 | inherit autotools update-rc.d |
| 15 | 16 | ||
| 16 | FILES_${PN} += "${libdir}/vfs/*.so ${libdir}/charset/*.so ${libdir}/*.dat \ | ||
| 17 | ${libdir}/auth/*.so ${libdir}/security/*.so" | ||
| 18 | FILES_${PN}-dbg += "${libdir}/vfs/.debug/*.so ${libdir}/charset/.debug/*.so \ | ||
| 19 | ${libdir}/auth/.debug/*.so ${libdir}/security/.debug/*.so" | ||
| 20 | |||
| 21 | SAMBAMMAP = "no" | 17 | SAMBAMMAP = "no" |
| 22 | SAMBAMMAP_libc-glibc = "yes" | 18 | SAMBAMMAP_libc-glibc = "yes" |
| 23 | 19 | ||
| @@ -41,7 +37,9 @@ EXTRA_OECONF='--disable-cups \ | |||
| 41 | samba_cv_struct_timespec=yes \ | 37 | samba_cv_struct_timespec=yes \ |
| 42 | libreplace_cv_HAVE_MMAP=${SAMBAMMAP}' | 38 | libreplace_cv_HAVE_MMAP=${SAMBAMMAP}' |
| 43 | 39 | ||
| 44 | INITSCRIPT_NAME = "samba" | 40 | INITSCRIPT_PACKAGES = "samba winbind" |
| 41 | INITSCRIPT_NAME_samba = "samba" | ||
| 42 | INITSCRIPT_NAME_winbind = "winbind" | ||
| 45 | # No dependencies, goes in at level 20 (NOTE: take care with the | 43 | # No dependencies, goes in at level 20 (NOTE: take care with the |
| 46 | # level, later levels put the shutdown later too - see the links | 44 | # level, later levels put the shutdown later too - see the links |
| 47 | # in rc6.d, the shutdown must precede network shutdown). | 45 | # in rc6.d, the shutdown must precede network shutdown). |
| @@ -79,10 +77,27 @@ do_install_append() { | |||
| 79 | ln -sf ${bindir}/smbmount ${D}${base_sbindir}/mount.smbfs | 77 | ln -sf ${bindir}/smbmount ${D}${base_sbindir}/mount.smbfs |
| 80 | fi | 78 | fi |
| 81 | 79 | ||
| 82 | install -D -m 755 ${WORKDIR}/init ${D}${sysconfdir}/init.d/samba | 80 | install -D -m 755 ${WORKDIR}/init.samba ${D}${sysconfdir}/init.d/samba |
| 81 | install -D -m 755 ${WORKDIR}/init.winbind ${D}${sysconfdir}/init.d/winbind | ||
| 83 | install -D -m 644 ${WORKDIR}/smb.conf ${D}${sysconfdir}/samba/smb.conf | 82 | install -D -m 644 ${WORKDIR}/smb.conf ${D}${sysconfdir}/samba/smb.conf |
| 84 | install -D -m 644 ${WORKDIR}/volatiles.03_samba ${D}${sysconfdir}/default/volatiles/volatiles.03_samba | 83 | install -D -m 644 ${WORKDIR}/volatiles.03_samba ${D}${sysconfdir}/default/volatiles/volatiles.03_samba |
| 85 | install -d ${D}/var/log/samba | 84 | install -d ${D}/var/log/samba |
| 86 | install -d ${D}/var/spool/samba | 85 | install -d ${D}/var/spool/samba |
| 86 | |||
| 87 | # Install other stuff not installed by "make install" | ||
| 88 | install -m 0644 ${WORKDIR}/${PN}-${PV}/nsswitch/libnss_winbind.so ${D}${libdir}/libnss_winbind.so.2 | ||
| 89 | install -m 0644 ${WORKDIR}/${PN}-${PV}/nsswitch/libnss_wins.so ${D}${libdir}/libnss_wins.so.2 | ||
| 90 | |||
| 87 | } | 91 | } |
| 88 | 92 | ||
| 93 | |||
| 94 | |||
| 95 | pkg_postinst_winbind () { | ||
| 96 | # add wins to the list of resolvers | ||
| 97 | ns=$D${sysconfdir}/nsswitch.conf | ||
| 98 | if ! grep "hosts:.*wins" $ns > /dev/null; then | ||
| 99 | hosts="`grep '^hosts:' $ns`" | ||
| 100 | hosts=`echo "$hosts" | sed 's/\[/\\\\[/g; s/\]/\\\\]/g'` | ||
| 101 | sed -i "s/$hosts/$hosts wins/" "$ns" | ||
| 102 | fi | ||
| 103 | } | ||
