diff options
| -rw-r--r-- | meta-oe/recipes-connectivity/samba/samba_4.1.12.bb | 41 |
1 files changed, 30 insertions, 11 deletions
diff --git a/meta-oe/recipes-connectivity/samba/samba_4.1.12.bb b/meta-oe/recipes-connectivity/samba/samba_4.1.12.bb index af2cc1fdf2..04df8a3ce8 100644 --- a/meta-oe/recipes-connectivity/samba/samba_4.1.12.bb +++ b/meta-oe/recipes-connectivity/samba/samba_4.1.12.bb | |||
| @@ -38,26 +38,40 @@ SRC_URI = "${SAMBA_MIRROR}/stable/samba-${PV}.tar.gz \ | |||
| 38 | SRC_URI[md5sum] = "232016d7581a1ba11e991ec2674553c4" | 38 | SRC_URI[md5sum] = "232016d7581a1ba11e991ec2674553c4" |
| 39 | SRC_URI[sha256sum] = "033604674936bf5c77d7df299b0626052b84a41505a6a6afe902f6274fc29898" | 39 | SRC_URI[sha256sum] = "033604674936bf5c77d7df299b0626052b84a41505a6a6afe902f6274fc29898" |
| 40 | 40 | ||
| 41 | inherit systemd waf-samba | 41 | inherit systemd waf-samba cpan-base perlnative |
| 42 | 42 | ||
| 43 | DEPENDS += "readline virtual/libiconv zlib popt talloc libtdb libtevent libldb krb5 ctdb cups" | 43 | DEPENDS += "readline virtual/libiconv zlib popt talloc libtdb libtevent libldb krb5 ctdb" |
| 44 | RDEPENDS_${PN} += "openldap" | ||
| 45 | 44 | ||
| 46 | PACKAGECONFIG = "${@base_contains('DISTRO_FEATURES', 'pam', 'pam', '', d)}" | 45 | SYSVINITTYPE_linuxstdbase = "lsb" |
| 47 | PACKAGECONFIG += "${@base_contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)}" | 46 | SYSVINITTYPE = "sysv" |
| 48 | 47 | ||
| 49 | PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam" | 48 | PACKAGECONFIG ??= "${@base_contains('DISTRO_FEATURES', 'pam', 'pam', '', d)} \ |
| 49 | ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', '${SYSVINITTYPE}', '', d)} \ | ||
| 50 | ${@base_contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)} \ | ||
| 51 | ${@base_contains('DISTRO_FEATURES', 'zeroconf', 'zeroconf', '', d)} \ | ||
| 52 | acl aio cups ldap \ | ||
| 53 | " | ||
| 54 | |||
| 55 | RDEPENDS_${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'lsb', 'lsb', '', d)}" | ||
| 56 | |||
| 57 | PACKAGECONFIG[acl] = "--with-acl-support,---without-acl-support,acl" | ||
| 58 | PACKAGECONFIG[aio] = "--with-aio-support,---without-aio-support,libaio" | ||
| 50 | PACKAGECONFIG[fam] = "--with-fam,--without-fam,gamin" | 59 | PACKAGECONFIG[fam] = "--with-fam,--without-fam,gamin" |
| 60 | PACKAGECONFIG[pam] = "--with-pam,--without-pam,libpam" | ||
| 61 | PACKAGECONFIG[lsb] = ",,lsb" | ||
| 62 | PACKAGECONFIG[cups] = "--enable-cups,--disable-cups,cups" | ||
| 63 | PACKAGECONFIG[ldap] = "--with-ldap,--without-ldap,openldap" | ||
| 51 | PACKAGECONFIG[systemd] = "--with-systemd,--without-systemd,systemd" | 64 | PACKAGECONFIG[systemd] = "--with-systemd,--without-systemd,systemd" |
| 65 | PACKAGECONFIG[zeroconf] = "--enable-avahi,--disable-avahi,avahi" | ||
| 52 | 66 | ||
| 53 | SAMBA4_IDMAP_MODULES="idmap_ad,idmap_rid,idmap_adex,idmap_hash,idmap_tdb2" | 67 | SAMBA4_IDMAP_MODULES="idmap_ad,idmap_rid,idmap_adex,idmap_hash,idmap_tdb2" |
| 54 | SAMBA4_PDB_MODULES="pdb_tdbsam,pdb_ldap,pdb_ads,pdb_smbpasswd,pdb_wbc_sam,pdb_samba4" | 68 | SAMBA4_PDB_MODULES="pdb_tdbsam,${@bb.utils.contains('PACKAGECONFIG', 'ldap', 'pdb_ldap,', '', d)}pdb_ads,pdb_smbpasswd,pdb_wbc_sam,pdb_samba4" |
| 55 | SAMBA4_AUTH_MODULES="auth_unix,auth_wbc,auth_server,auth_netlogond,auth_script,auth_samba4" | 69 | SAMBA4_AUTH_MODULES="auth_unix,auth_wbc,auth_server,auth_netlogond,auth_script,auth_samba4" |
| 56 | SAMBA4_MODULES="${SAMBA4_IDMAP_MODULES},${SAMBA4_PDB_MODULES},${SAMBA4_AUTH_MODULES}" | 70 | SAMBA4_MODULES="${SAMBA4_IDMAP_MODULES},${SAMBA4_PDB_MODULES},${SAMBA4_AUTH_MODULES}" |
| 57 | 71 | ||
| 58 | SAMBA4_LIBS="heimdal,!zlib,!popt,!talloc,!pytalloc,!pytalloc-util,!tevent,!pytevent,!tdb,!pytdb,!ldb,!pyldb" | 72 | SAMBA4_LIBS="heimdal,!zlib,!popt,!talloc,!pytalloc,!pytalloc-util,!tevent,!pytevent,!tdb,!pytdb,!ldb,!pyldb" |
| 59 | 73 | ||
| 60 | PERL_VERNDORLIB="${datadir}/perl5/vendor_perl/" | 74 | PERL_VERNDORLIB="${libdir}/perl5/vendor_perl/${PERLVERSION}" |
| 61 | 75 | ||
| 62 | EXTRA_OECONF += "--enable-fhs \ | 76 | EXTRA_OECONF += "--enable-fhs \ |
| 63 | --with-piddir=${localstatedir}/run \ | 77 | --with-piddir=${localstatedir}/run \ |
| @@ -85,7 +99,7 @@ LDFLAGS += "-Wl,-z,relro,-z,now" | |||
| 85 | do_install_append() { | 99 | do_install_append() { |
| 86 | rmdir --ignore-fail-on-non-empty "${D}/${localstatedir}/run" | 100 | rmdir --ignore-fail-on-non-empty "${D}/${localstatedir}/run" |
| 87 | 101 | ||
| 88 | if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then | 102 | if ${@bb.utils.contains('PACKAGECONFIG', 'systemd', 'true', 'false', d)}; then |
| 89 | install -d ${D}${systemd_unitdir}/system | 103 | install -d ${D}${systemd_unitdir}/system |
| 90 | for i in nmb smb winbind; do | 104 | for i in nmb smb winbind; do |
| 91 | install -m 0644 packaging/systemd/$i.service ${D}${systemd_unitdir}/system | 105 | install -m 0644 packaging/systemd/$i.service ${D}${systemd_unitdir}/system |
| @@ -97,11 +111,16 @@ do_install_append() { | |||
| 97 | install -d ${D}${sysconfdir}/tmpfiles.d | 111 | install -d ${D}${sysconfdir}/tmpfiles.d |
| 98 | echo "d ${localstatedir}/log/samba 0755 root root -" \ | 112 | echo "d ${localstatedir}/log/samba 0755 root root -" \ |
| 99 | > ${D}${sysconfdir}/tmpfiles.d/99-${BPN}.conf | 113 | > ${D}${sysconfdir}/tmpfiles.d/99-${BPN}.conf |
| 100 | elif ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then | 114 | elif ${@bb.utils.contains('PACKAGECONFIG', 'lsb', 'true', 'false', d)}; then |
| 101 | install -d ${D}${sysconfdir}/init.d | 115 | install -d ${D}${sysconfdir}/init.d |
| 102 | install -m 0755 packaging/LSB/samba.sh ${D}${sysconfdir}/init.d | 116 | install -m 0755 packaging/LSB/samba.sh ${D}${sysconfdir}/init.d |
| 103 | update-rc.d -r ${D} samba.sh start 20 3 5 . | 117 | update-rc.d -r ${D} samba.sh start 20 3 5 . |
| 104 | update-rc.d -r ${D} samba.sh start 20 0 1 6 . | 118 | update-rc.d -r ${D} samba.sh start 20 0 1 6 . |
| 119 | elif ${@bb.utils.contains('PACKAGECONFIG', 'lsb', 'true', 'false', d)}; then | ||
| 120 | install -d ${D}${sysconfdir}/init.d | ||
| 121 | install -m 0755 packaging/sysv/samba.init ${D}${sysconfdir}/init.d/samba.sh | ||
| 122 | update-rc.d -r ${D} samba.sh start 20 3 5 . | ||
| 123 | update-rc.d -r ${D} samba.sh start 20 0 1 6 . | ||
| 105 | fi | 124 | fi |
| 106 | 125 | ||
| 107 | install -d ${D}${sysconfdir}/samba | 126 | install -d ${D}${sysconfdir}/samba |
| @@ -160,4 +179,4 @@ FILES_${PN}-python-dbg = "${libdir}/python${PYTHON_BASEVERSION}/site-packages/.d | |||
| 160 | ${libdir}/python${PYTHON_BASEVERSION}/site-packages/samba/dcerpc/.debug/* \ | 179 | ${libdir}/python${PYTHON_BASEVERSION}/site-packages/samba/dcerpc/.debug/* \ |
| 161 | " | 180 | " |
| 162 | 181 | ||
| 163 | FILES_${PN}-pidl = "${datadir}/perl5/vendor_perl/*" | 182 | FILES_${PN}-pidl = "${bindir}/pidl ${PERL_VERNDORLIB}/*" |
