summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wendler <polynomial-c@gentoo.org>2016-03-08 22:23:04 +0100
committerLars Wendler <polynomial-c@gentoo.org>2016-03-08 22:23:44 +0100
commitde0d7485197291fd0512d23da34d3e3c73207205 (patch)
tree4ce4b6a78ee688489bbf73dbed54a1f7bc1202fb /net-fs/samba
parentsys-libs/tevent: Bump to version 0.9.28 (diff)
downloadgentoo-de0d7485197291fd0512d23da34d3e3c73207205.tar.gz
gentoo-de0d7485197291fd0512d23da34d3e3c73207205.tar.bz2
gentoo-de0d7485197291fd0512d23da34d3e3c73207205.zip
net-fs/samba: Bump to versions 4.2.9, 4.3.6 and 4.4.0_rc4
Package-Manager: portage-2.2.27 Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
Diffstat (limited to 'net-fs/samba')
-rw-r--r--net-fs/samba/Manifest6
-rw-r--r--net-fs/samba/samba-4.2.9.ebuild251
-rw-r--r--net-fs/samba/samba-4.3.6.ebuild243
-rw-r--r--net-fs/samba/samba-4.4.0_rc4.ebuild226
4 files changed, 726 insertions, 0 deletions
diff --git a/net-fs/samba/Manifest b/net-fs/samba/Manifest
index ac8e1407a421..68e40eaa675f 100644
--- a/net-fs/samba/Manifest
+++ b/net-fs/samba/Manifest
@@ -2,9 +2,15 @@ DIST samba-3.5.21.tar.gz 35377315 SHA256 fd9a66056b1ba9496762394efff41fcaa0e58f2
DIST samba-3.5.22.tar.gz 35385144 SHA256 b4c98f77f5634478da109063334acd9b6ad7bcb38151a5b1cac6dc5feb6679dc SHA512 0e1b4816d921ca82f0426a254cf103066634cc54e28d707a62da951118413f7f5ca5f87d60688cab802a58b0af87f797fbbe12f4e1284d5d7f545a98aba97616 WHIRLPOOL 6e59655dd7a537f0c7c889c43ddf5afb8060706e1ec79b3835698181c5c7478059f91c93eefbde50b03e0154a686eda35eabf807bb7ae01dd2b9b39648a009ae
DIST samba-3.6.25.tar.gz 34121828 SHA256 8f2c8a7f2bd89b0dfd228ed917815852f7c625b2bc0936304ac3ed63aaf83751 SHA512 25a5c56dae4517e82e196b59fa301b661ec75db57effbb0ede35fb23b018f78cdea6513e8760966caf58abc43335fcebda77fe5bf5bb9d4b27fd3ca6e5a3b626 WHIRLPOOL 68c4a335b3912bf3c6baecae337b1131127515191052366ca9a04ec6d919f2fb69c912aefb087e2578134f3a9bde7b496ea880f2197a8dbf8221058dd1e8444d
DIST samba-4.2.8.tar.gz 20745527 SHA256 d2c0ca97ab415ede829d15ddad411d76e4f7b6a82e280bf7fbc9910c30fa4593 SHA512 cdee04ebc2303c1cadf2c0a45530909b6c97838e611378498faaaa6fcade8850746253d51ae71fd872c741f54ec2d3a9d452651291355e20001ca443fae9054a WHIRLPOOL 84b3f78b41da98eaa463f9b1c467e3c82268d31ac3d3e48d75b0a4dc04f479d12f2387c045281b0caa3a841c351587d0eabec403163ff479d8c700f0b638e5f4
+DIST samba-4.2.9.tar.gz 20750339 SHA256 ba0229485e8bebac22bd3ae98b1e393e7127f3a958cc90e205a6d752e575354c SHA512 438196f268c0ca0b83e8e7e9eb8e9a8b503d6408d5e2b0dca1d041185e06cfc08147122d5495b72c46ce58dc3cb4be4766551f0101c69b2620b89e749d89ad98 WHIRLPOOL aa7a655a3d2f2bf81d2747d83c86a0c7d464a31414b6e27a413461e1e0ad0ce3d3af5d756d8ce213e775f5141c44ef9c41a792e88d246bcab002b7623552260a
DIST samba-4.3.5.tar.gz 20443260 SHA256 583f927a823b272757fd4df0be267bd20a223b06cfc3c662df17e4870f14bf1c SHA512 0d04eb8d5bbe2e47f3ba810631662083f7d2b5118f47242e27d87c304a6c0f57808e636333c798b5b70c4adbf8c2ea4f89b377c637bfcdfd8a285fdc1f3afc50 WHIRLPOOL 5be389cf08bc83a4ae66da6b2ee78e596cd52df2a693999d311a5a02c194ba7381132a1ec34cefc0926ef24474efaa6677c46d0ed71c8a79efbaff6d094a6ee3
+DIST samba-4.3.6.tar.gz 20445038 SHA256 3251eca5b196854e79978f4a92d5fd2b55bd7b0a252a65131a9be02be6754924 SHA512 2551ece4e17ed855c8faf488e4438229455a063ba7687fd36bf650d72676bab3bef7e2bc9de05a00081285268bf527b9c781024ea31aac493d2fcd5fd2593c21 WHIRLPOOL c1b375323cd925f76d8664d5ec6fc4ee5d0cad415d010e33fb485e178229feccd21ed49f175b69d15655a627f12cdb59c3c0f026ed2c6323c8ce8569ceb984ea
DIST samba-4.4.0rc3.tar.gz 20568791 SHA256 62003df716d8f45fb153ebfce6256e889a2b2239d8486fcb039848fb028e3454 SHA512 c624bd3e2ab2251bd1dd85ca014683c8f628c92e750a82f9707e34a7479773c3a28ccb3fa27c0ce5236ef79a2ad39a0d534398d3935d8b0b7c7b8cf0bff09388 WHIRLPOOL 60b2f2a0ff8bc4cc2219a9c3e8f151830d236f9bbe8628cdd27504f100c984ccbf59ab1802fbe028604cfd43b4f9cca203c2048ca4738a612ca19dc840917368
+DIST samba-4.4.0rc4.tar.gz 20573621 SHA256 868b2637ee07c998d5bfdc2fd54cb76bbc5ea73527e54ee69c59253028615ea0 SHA512 f8a81b9f7d8163eeacdb185b721dec62fef368294c67f8366a21b3c95f864e0872928870f1c2eed227766386b8282f4009562f5c39919b42c68cfb8c82567249 WHIRLPOOL b6ac7cee4a6ff50116b456a5bf26425ae412671f0aa10e0e14351fcc17d810501461fff827fd9f4c1b16173a578962b72b47680f5bcadc5c120568f5fd800d09
DIST samba-disable-python-patches-4.2.7.tar.xz 6296 SHA256 06a1b9aeb91b622d3c2a02a86edfc26e26f10303699c8b2badbd21ce68b10ec0 SHA512 ff746c2969b254d9ccad1440699fccd5958222eea8284a8e068b96df377d6cea8551ec3c6be7103cebf227b0b9038a5b06d3b06d9b247e181403e9fe1ad7eedf WHIRLPOOL 8ea9f34c5f011624b43c0f3f27601574c27e00c5a728d9af5b1cece090da362d51f93ef6cecd37f1204bbd4e608ed58027f52ef5c3d700a1cfdbbb0e5355c3b8
+DIST samba-disable-python-patches-4.2.9.tar.xz 6016 SHA256 222d0153f03dddde28a0b906ee2b27076223ac88b84a998aaa285f658861edfa SHA512 02fc666a36f8e733e522663d80775d130fabee9d5fb4e1c261d28815e07be425ae8977213f9216c7af62dd8b2619e7e13d71f9a25780b058c8119901c2115a18 WHIRLPOOL ebba3a6d41a41844621759672aa8c984d26f44d12007c8e929405470c381bc262523ec68d3972e86cf675c45f092fa287496167e42940e70d704790753e47b03
DIST samba-disable-python-patches-4.3.5.tar.xz 6028 SHA256 6889d77331e74e24becd638b860d6b3a0f8f92f34d0e3af733d44cef24042915 SHA512 1d3171eacff5d009c4e30405ed96c6b57c2ff4fb0d82f0196bb6d63ad331adf11f8b9e81f8a42cdc5d6ebe32c60c20bff0d07013ce7a431e0e35e9d620240e9a WHIRLPOOL f8c97a57f54da0ac956112131bbf790269460abe904b1e0e2d75449696e0451e80b3d2cd43d05fe14b32ab8c2a21a71d41f67ef9c615bf9c0ba5b07354b78b2e
+DIST samba-disable-python-patches-4.3.6.tar.xz 6076 SHA256 95f9194abcba917aa5e2e9623e897eb41127a8c74352ebf6a9bf0f4ba82fd1c0 SHA512 601026aae1fd960e3f4cf53c0f68e843a118f6dd4fc776d9a6503fd16f9789e743eb92b7ebf84179d63aaff20d1ddb1989cb995fc1da3cd2e843f6830f04f08f WHIRLPOOL 5afb076857f049469e65a13eb46af98f21b249d9c7ef9d731bd6f3aeb6e9512efc781b5392c0c7aaeb7a818e9e896f336a70b306122280d3ad432372bc6b0024
DIST samba-disable-python-patches-4.4.0_rc3.tar.xz 6180 SHA256 bfdde228c1cc41cccb489658208402425038ac2834b4cd870bb89dc10510c8e5 SHA512 de88335e0cbcc6f0e47a170bf91efe63f943973e2ae3f5f7b2025426565b09bce28cf2e56d0105424f9f5ffee0b1fb2e9866b8a4c22b7696c7c18e298af2d0cd WHIRLPOOL c8d83d95c87e9bec3efbdecd00a76858da1538b8df05009198d24ed87b8c93f85f3165b0c1d7054dad61ddb46ff701ba03a688327eee7f97ecea1c97e846caa6
+DIST samba-disable-python-patches-4.4.0_rc4.tar.xz 6216 SHA256 5fe1d32eb09218fe5323efc9988fc475e05d05aba46a094ae78fe0771f4d2c27 SHA512 fc8d0667edb2e3a7a99bf821b42c67c39137ab769ceaf5de45ed6f16957c1f0a415631b230c57c613a6a03d23f0e1d0749b6a67e094fdfdad52adaf8186f8ff2 WHIRLPOOL 98f28d78eb136a0a3a74c9a246d44e9f18beafa74f60e89e115a27fd4ca3553578f0049a8d8e63046caebe46d27c459741db3a9bc1b7659f224b58433c4d3aa3
DIST smb_traffic_analyzer_v2.diff.bz2 12226 SHA256 1bae7eafbe8ac2382313d5ab9d43d73ba64b63a714f0f588516952d476fb868d SHA512 aa0e457a0dd282e61e6dfcd5705c29b319832dca9711b1b5baf8373e2f079991399c3537c050219ccb861a93f86353ebff677a5c625d2e3f1f3a13ee5c4087d0 WHIRLPOOL 85ee72a360f67ebe71be5cd400ecd635280a0d7c64ebb8b94656a5ef1a94f74a987de86408af00ce1b81cc8363b1b3cf14726860d29b72ee610d4bab73d6b139
diff --git a/net-fs/samba/samba-4.2.9.ebuild b/net-fs/samba/samba-4.2.9.ebuild
new file mode 100644
index 000000000000..e2131ea9fb31
--- /dev/null
+++ b/net-fs/samba/samba-4.2.9.ebuild
@@ -0,0 +1,251 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE='threads(+),xml(+)'
+
+inherit python-single-r1 waf-utils multilib-minimal linux-info systemd eutils
+
+MY_PV="${PV/_rc/rc}"
+MY_P="${PN}-${MY_PV}"
+
+SRC_PATH="stable"
+[[ ${PV} = *_rc* ]] && SRC_PATH="rc"
+
+SRC_URI="mirror://samba/${SRC_PATH}/${MY_P}.tar.gz
+ https://dev.gentoo.org/~polynomial-c/samba-disable-python-patches-4.2.9.tar.xz"
+KEYWORDS="~amd64 ~hppa ~x86"
+[[ ${PV} = *_rc* ]] && KEYWORDS="~hppa"
+
+DESCRIPTION="Samba Suite Version 4"
+HOMEPAGE="http://www.samba.org/"
+LICENSE="GPL-3"
+
+SLOT="0"
+
+IUSE="acl addc addns ads aio avahi client cluster cups dmapi fam gnutls iprint
+ldap pam quota selinux syslog +system-mitkrb5 systemd test winbind"
+
+MULTILIB_WRAPPED_HEADERS=(
+ /usr/include/samba-4.0/policy.h
+ /usr/include/samba-4.0/dcerpc_server.h
+ /usr/include/samba-4.0/ctdb.h
+ /usr/include/samba-4.0/ctdb_client.h
+ /usr/include/samba-4.0/ctdb_protocol.h
+ /usr/include/samba-4.0/ctdb_private.h
+ /usr/include/samba-4.0/ctdb_typesafe_cb.h
+ /usr/include/samba-4.0/ctdb_version.h
+)
+
+# sys-apps/attr is an automagic dependency (see bug #489748)
+CDEPEND="${PYTHON_DEPS}
+ >=app-arch/libarchive-3.1.2[${MULTILIB_USEDEP}]
+ dev-libs/libbsd[${MULTILIB_USEDEP}]
+ dev-libs/iniparser:0
+ dev-libs/popt[${MULTILIB_USEDEP}]
+ sys-libs/readline:=
+ virtual/libiconv
+ dev-python/subunit[${PYTHON_USEDEP},${MULTILIB_USEDEP}]
+ >=net-libs/socket_wrapper-1.1.2[${MULTILIB_USEDEP}]
+ sys-apps/attr[${MULTILIB_USEDEP}]
+ sys-libs/libcap
+ >=sys-libs/ldb-1.1.24[${MULTILIB_USEDEP}]
+ sys-libs/ncurses:0=[${MULTILIB_USEDEP}]
+ >=sys-libs/nss_wrapper-1.0.2[${MULTILIB_USEDEP}]
+ >=sys-libs/ntdb-1.0[python,${PYTHON_USEDEP},${MULTILIB_USEDEP}]
+ >=sys-libs/talloc-2.1.2[python,${PYTHON_USEDEP},${MULTILIB_USEDEP}]
+ >=sys-libs/tdb-1.3.6[python,${PYTHON_USEDEP},${MULTILIB_USEDEP}]
+ >=sys-libs/tevent-0.9.25[${MULTILIB_USEDEP}]
+ >=sys-libs/uid_wrapper-1.0.1[${MULTILIB_USEDEP}]
+ sys-libs/zlib[${MULTILIB_USEDEP}]
+ virtual/pam
+ acl? ( virtual/acl )
+ addns? ( net-dns/bind-tools[gssapi] )
+ aio? ( dev-libs/libaio )
+ cluster? ( !dev-db/ctdb )
+ cups? ( net-print/cups )
+ dmapi? ( sys-apps/dmapi )
+ fam? ( virtual/fam )
+ gnutls? ( dev-libs/libgcrypt:0
+ >=net-libs/gnutls-1.4.0 )
+ ldap? ( net-nds/openldap[${MULTILIB_USEDEP}] )
+ system-mitkrb5? ( app-crypt/mit-krb5[${MULTILIB_USEDEP}] )
+ !system-mitkrb5? ( >=app-crypt/heimdal-1.5[-ssl,${MULTILIB_USEDEP}] )
+ systemd? ( sys-apps/systemd:0= )"
+DEPEND="${CDEPEND}
+ virtual/pkgconfig"
+RDEPEND="${CDEPEND}
+ client? ( net-fs/cifs-utils[ads?] )
+ selinux? ( sec-policy/selinux-samba )
+"
+
+REQUIRED_USE="addc? ( gnutls !system-mitkrb5 )
+ ads? ( acl gnutls ldap )
+ ${PYTHON_REQUIRED_USE}"
+
+S="${WORKDIR}/${MY_P}"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-4.2.3-heimdal_compilefix.patch"
+ "${FILESDIR}/${PN}-4.2.7-pam.patch"
+)
+
+CONFDIR="${FILESDIR}/$(get_version_component_range 1-2)"
+
+WAF_BINARY="${S}/buildtools/bin/waf"
+
+SHAREDMODS=""
+
+pkg_setup() {
+ python-single-r1_pkg_setup
+ if use aio ; then
+ if ! linux_config_exists || ! linux_chkconfig_present AIO; then
+ ewarn "You must enable AIO support in your kernel config, "
+ ewarn "to be able to support asynchronous I/O. "
+ ewarn "You can find it at"
+ ewarn
+ ewarn "General Support"
+ ewarn " Enable AIO support "
+ ewarn
+ ewarn "and recompile your kernel..."
+ fi
+ fi
+ if use cluster ; then
+ SHAREDMODS="${SHAREDMODS}idmap_rid,idmap_tdb2,idmap_ad"
+ fi
+}
+
+src_prepare() {
+ epatch ${PATCHES[@]}
+
+ # install the patches from tarball(s)
+ EPATCH_SUFFIX="patch" \
+ EPATCH_FORCE="yes" \
+ epatch "${WORKDIR}/patches"
+
+ # Allow user patches
+ epatch_user
+ multilib_copy_sources
+}
+
+multilib_src_configure() {
+ local myconf=()
+ myconf=(
+ --enable-fhs
+ --sysconfdir=/etc
+ --localstatedir=/var
+ --with-modulesdir=/usr/$(get_libdir)/samba
+ --with-piddir=/var/run/${PN}
+ --bundled-libraries=NONE
+ --builtin-libraries=NONE
+ --disable-rpath
+ --disable-rpath-install
+ --nopyc
+ --nopyo
+ )
+ if multilib_is_native_abi ; then
+ myconf+=(
+ $(use_with acl acl-support)
+ $(usex addc '' '--without-ad-dc')
+ $(use_with addns dnsupdate)
+ $(use_with ads)
+ $(usex ads '--with-shared-modules=idmap_ad' '')
+ $(use_with aio aio-support)
+ $(use_enable avahi)
+ $(use_with cluster cluster-support)
+ $(use_enable cups)
+ $(use_with dmapi)
+ $(use_with fam)
+ $(use_enable gnutls)
+ $(use_enable iprint)
+ $(use_with ldap)
+ $(use_with pam)
+ $(use_with pam pam_smbpass)
+ $(usex pam "--with-pammodulesdir=/$(get_libdir)/security" '')
+ $(use_with quota quotas)
+ $(use_with syslog)
+ $(use_with systemd)
+ $(usex system-mitkrb5 '--with-system-mitkrb5' '')
+ $(use_with winbind)
+ $(usex test '--enable-selftest' '')
+ --with-shared-modules=${SHAREDMODS}
+ )
+ else
+ myconf+=(
+ --without-acl-support
+ --without-ad-dc
+ --without-dnsupdate
+ --without-ads
+ --without-aio-support
+ --disable-avahi
+ --without-cluster-support
+ --disable-cups
+ --without-dmapi
+ --without-fam
+ --disable-gnutls
+ --disable-iprint
+ $(use_with ldap)
+ --without-pam
+ --without-pam_smbpass
+ --without-quotas
+ --without-syslog
+ --without-systemd
+ $(usex system-mitkrb5 '--with-system-mitkrb5' '')
+ --without-winbind
+ --disable-python
+ )
+ fi
+
+ CPPFLAGS="-I${SYSROOT}/usr/include/et ${CPPFLAGS}" \
+ waf-utils_src_configure ${myconf[@]}
+}
+
+multilib_src_install() {
+ waf-utils_src_install
+
+ # Make all .so files executable
+ find "${D}" -type f -name "*.so" -exec chmod +x {} +
+
+ if multilib_is_native_abi; then
+ # install ldap schema for server (bug #491002)
+ if use ldap ; then
+ insinto /etc/openldap/schema
+ doins examples/LDAP/samba.schema
+ fi
+
+ # install example config file
+ insinto /etc/samba
+ doins examples/smb.conf.default
+
+ # Install init script and conf.d file
+ newinitd "${CONFDIR}/samba4.initd-r1" samba
+ newconfd "${CONFDIR}/samba4.confd" samba
+
+ systemd_dotmpfilesd "${FILESDIR}"/samba.conf
+ systemd_dounit "${FILESDIR}"/nmbd.service
+ systemd_dounit "${FILESDIR}"/smbd.{service,socket}
+ systemd_newunit "${FILESDIR}"/smbd_at.service 'smbd@.service'
+ systemd_dounit "${FILESDIR}"/winbindd.service
+ systemd_dounit "${FILESDIR}"/samba.service
+ fi
+}
+
+multilib_src_test() {
+ if multilib_is_native_abi ; then
+ "${WAF_BINARY}" test || die "test failed"
+ fi
+}
+
+pkg_postinst() {
+ ewarn "Be aware the this release contains the best of all of Samba's"
+ ewarn "technology parts, both a file server (that you can reasonably expect"
+ ewarn "to upgrade existing Samba 3.x releases to) and the AD domain"
+ ewarn "controller work previously known as 'samba4'."
+
+ elog "For further information and migration steps make sure to read "
+ elog "http://samba.org/samba/history/${P}.html "
+ elog "http://samba.org/samba/history/${PN}-4.2.0.html and"
+ elog "http://wiki.samba.org/index.php/Samba4/HOWTO "
+}
diff --git a/net-fs/samba/samba-4.3.6.ebuild b/net-fs/samba/samba-4.3.6.ebuild
new file mode 100644
index 000000000000..c0c77ccbfea4
--- /dev/null
+++ b/net-fs/samba/samba-4.3.6.ebuild
@@ -0,0 +1,243 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE='threads(+),xml(+)'
+
+inherit python-single-r1 waf-utils multilib-minimal linux-info systemd eutils
+
+MY_PV="${PV/_rc/rc}"
+MY_P="${PN}-${MY_PV}"
+
+SRC_PATH="stable"
+[[ ${PV} = *_rc* ]] && SRC_PATH="rc"
+
+SRC_URI="mirror://samba/${SRC_PATH}/${MY_P}.tar.gz
+ https://dev.gentoo.org/~polynomial-c/samba-disable-python-patches-4.3.6.tar.xz"
+KEYWORDS="~amd64 ~hppa ~x86"
+[[ ${PV} = *_rc* ]] && KEYWORDS="~hppa"
+
+DESCRIPTION="Samba Suite Version 4"
+HOMEPAGE="http://www.samba.org/"
+LICENSE="GPL-3"
+
+SLOT="0"
+
+IUSE="acl addc addns ads aio avahi client cluster cups dmapi fam gnutls iprint
+ldap pam quota selinux syslog +system-mitkrb5 systemd test winbind"
+
+MULTILIB_WRAPPED_HEADERS=(
+ /usr/include/samba-4.0/policy.h
+ /usr/include/samba-4.0/dcerpc_server.h
+ /usr/include/samba-4.0/ctdb.h
+ /usr/include/samba-4.0/ctdb_client.h
+ /usr/include/samba-4.0/ctdb_protocol.h
+ /usr/include/samba-4.0/ctdb_private.h
+ /usr/include/samba-4.0/ctdb_typesafe_cb.h
+ /usr/include/samba-4.0/ctdb_version.h
+)
+
+# sys-apps/attr is an automagic dependency (see bug #489748)
+CDEPEND="${PYTHON_DEPS}
+ >=app-arch/libarchive-3.1.2[${MULTILIB_USEDEP}]
+ dev-libs/libbsd[${MULTILIB_USEDEP}]
+ dev-libs/iniparser:0
+ dev-libs/popt[${MULTILIB_USEDEP}]
+ sys-libs/readline:=
+ virtual/libiconv
+ dev-python/subunit[${PYTHON_USEDEP},${MULTILIB_USEDEP}]
+ sys-apps/attr[${MULTILIB_USEDEP}]
+ sys-libs/libcap
+ >=sys-libs/ldb-1.1.24[${MULTILIB_USEDEP}]
+ sys-libs/ncurses:0=[${MULTILIB_USEDEP}]
+ >=sys-libs/talloc-2.1.3[python,${PYTHON_USEDEP},${MULTILIB_USEDEP}]
+ >=sys-libs/tdb-1.3.7[python,${PYTHON_USEDEP},${MULTILIB_USEDEP}]
+ >=sys-libs/tevent-0.9.25[${MULTILIB_USEDEP}]
+ sys-libs/zlib[${MULTILIB_USEDEP}]
+ virtual/pam
+ acl? ( virtual/acl )
+ addns? ( net-dns/bind-tools[gssapi] )
+ aio? ( dev-libs/libaio )
+ cluster? ( !dev-db/ctdb )
+ cups? ( net-print/cups )
+ dmapi? ( sys-apps/dmapi )
+ fam? ( virtual/fam )
+ gnutls? ( dev-libs/libgcrypt:0
+ >=net-libs/gnutls-1.4.0 )
+ ldap? ( net-nds/openldap[${MULTILIB_USEDEP}] )
+ system-mitkrb5? ( app-crypt/mit-krb5[${MULTILIB_USEDEP}] )
+ !system-mitkrb5? ( >=app-crypt/heimdal-1.5[-ssl,${MULTILIB_USEDEP}] )
+ systemd? ( sys-apps/systemd:0= )"
+DEPEND="${CDEPEND}
+ virtual/pkgconfig"
+RDEPEND="${CDEPEND}
+ client? ( net-fs/cifs-utils[ads?] )
+ selinux? ( sec-policy/selinux-samba )
+"
+
+REQUIRED_USE="addc? ( gnutls !system-mitkrb5 )
+ ads? ( acl gnutls ldap )
+ ${PYTHON_REQUIRED_USE}"
+
+S="${WORKDIR}/${MY_P}"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-4.2.3-heimdal_compilefix.patch"
+ "${FILESDIR}/${PN}-4.2.7-pam.patch"
+)
+
+CONFDIR="${FILESDIR}/$(get_version_component_range 1-2)"
+
+WAF_BINARY="${S}/buildtools/bin/waf"
+
+SHAREDMODS=""
+
+pkg_setup() {
+ python-single-r1_pkg_setup
+ if use aio ; then
+ if ! linux_config_exists || ! linux_chkconfig_present AIO; then
+ ewarn "You must enable AIO support in your kernel config, "
+ ewarn "to be able to support asynchronous I/O. "
+ ewarn "You can find it at"
+ ewarn
+ ewarn "General Support"
+ ewarn " Enable AIO support "
+ ewarn
+ ewarn "and recompile your kernel..."
+ fi
+ fi
+ if use cluster ; then
+ SHAREDMODS="${SHAREDMODS}idmap_rid,idmap_tdb2,idmap_ad"
+ fi
+}
+
+src_prepare() {
+ default
+
+ # install the patches from tarball(s)
+ eapply "${WORKDIR}/patches/"
+
+ multilib_copy_sources
+}
+
+multilib_src_configure() {
+ local myconf=()
+ myconf=(
+ --enable-fhs
+ --sysconfdir=/etc
+ --localstatedir=/var
+ --with-modulesdir=/usr/$(get_libdir)/samba
+ --with-piddir=/var/run/${PN}
+ --bundled-libraries=NONE
+ --builtin-libraries=NONE
+ --disable-rpath
+ --disable-rpath-install
+ --nopyc
+ --nopyo
+ )
+ if multilib_is_native_abi ; then
+ myconf+=(
+ $(use_with acl acl-support)
+ $(usex addc '' '--without-ad-dc')
+ $(use_with addns dnsupdate)
+ $(use_with ads)
+ $(usex ads '--with-shared-modules=idmap_ad' '')
+ $(use_with aio aio-support)
+ $(use_enable avahi)
+ $(use_with cluster cluster-support)
+ $(use_enable cups)
+ $(use_with dmapi)
+ $(use_with fam)
+ $(use_enable gnutls)
+ $(use_enable iprint)
+ $(use_with ldap)
+ $(use_with pam)
+ $(use_with pam pam_smbpass)
+ $(usex pam "--with-pammodulesdir=/$(get_libdir)/security" '')
+ $(use_with quota quotas)
+ $(use_with syslog)
+ $(use_with systemd)
+ $(usex system-mitkrb5 '--with-system-mitkrb5' '')
+ $(use_with winbind)
+ $(usex test '--enable-selftest' '')
+ --with-shared-modules=${SHAREDMODS}
+ )
+ else
+ myconf+=(
+ --without-acl-support
+ --without-ad-dc
+ --without-dnsupdate
+ --without-ads
+ --without-aio-support
+ --disable-avahi
+ --without-cluster-support
+ --disable-cups
+ --without-dmapi
+ --without-fam
+ --disable-gnutls
+ --disable-iprint
+ $(use_with ldap)
+ --without-pam
+ --without-pam_smbpass
+ --without-quotas
+ --without-syslog
+ --without-systemd
+ $(usex system-mitkrb5 '--with-system-mitkrb5' '')
+ --without-winbind
+ --disable-python
+ )
+ fi
+
+ CPPFLAGS="-I${SYSROOT}/usr/include/et ${CPPFLAGS}" \
+ waf-utils_src_configure ${myconf[@]}
+}
+
+multilib_src_install() {
+ waf-utils_src_install
+
+ # Make all .so files executable
+ find "${D}" -type f -name "*.so" -exec chmod +x {} +
+
+ if multilib_is_native_abi; then
+ # install ldap schema for server (bug #491002)
+ if use ldap ; then
+ insinto /etc/openldap/schema
+ doins examples/LDAP/samba.schema
+ fi
+
+ # install example config file
+ insinto /etc/samba
+ doins examples/smb.conf.default
+
+ # Install init script and conf.d file
+ newinitd "${CONFDIR}/samba4.initd-r1" samba
+ newconfd "${CONFDIR}/samba4.confd" samba
+
+ systemd_dotmpfilesd "${FILESDIR}"/samba.conf
+ systemd_dounit "${FILESDIR}"/nmbd.service
+ systemd_dounit "${FILESDIR}"/smbd.{service,socket}
+ systemd_newunit "${FILESDIR}"/smbd_at.service 'smbd@.service'
+ systemd_dounit "${FILESDIR}"/winbindd.service
+ systemd_dounit "${FILESDIR}"/samba.service
+ fi
+}
+
+multilib_src_test() {
+ if multilib_is_native_abi ; then
+ "${WAF_BINARY}" test || die "test failed"
+ fi
+}
+
+pkg_postinst() {
+ ewarn "Be aware the this release contains the best of all of Samba's"
+ ewarn "technology parts, both a file server (that you can reasonably expect"
+ ewarn "to upgrade existing Samba 3.x releases to) and the AD domain"
+ ewarn "controller work previously known as 'samba4'."
+
+ elog "For further information and migration steps make sure to read "
+ elog "http://samba.org/samba/history/${P}.html "
+ elog "http://samba.org/samba/history/${PN}-4.2.0.html and"
+ elog "http://wiki.samba.org/index.php/Samba4/HOWTO "
+}
diff --git a/net-fs/samba/samba-4.4.0_rc4.ebuild b/net-fs/samba/samba-4.4.0_rc4.ebuild
new file mode 100644
index 000000000000..5b5c38f51123
--- /dev/null
+++ b/net-fs/samba/samba-4.4.0_rc4.ebuild
@@ -0,0 +1,226 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE='threads(+),xml(+)'
+
+inherit python-single-r1 waf-utils multilib-minimal linux-info systemd eutils
+
+MY_PV="${PV/_rc/rc}"
+MY_P="${PN}-${MY_PV}"
+
+SRC_PATH="stable"
+[[ ${PV} = *_rc* ]] && SRC_PATH="rc"
+
+SRC_URI="mirror://samba/${SRC_PATH}/${MY_P}.tar.gz
+ https://dev.gentoo.org/~polynomial-c/samba-disable-python-patches-4.4.0_rc4.tar.xz"
+KEYWORDS="~amd64 ~hppa ~x86"
+[[ ${PV} = *_rc* ]] && KEYWORDS="~hppa"
+
+DESCRIPTION="Samba Suite Version 4"
+HOMEPAGE="http://www.samba.org/"
+LICENSE="GPL-3"
+
+SLOT="0"
+
+IUSE="acl addc addns ads avahi client cluster cups dmapi fam gnutls iprint
+ldap pam quota selinux syslog +system-mitkrb5 systemd test winbind"
+
+MULTILIB_WRAPPED_HEADERS=(
+ /usr/include/samba-4.0/policy.h
+ /usr/include/samba-4.0/dcerpc_server.h
+ /usr/include/samba-4.0/ctdb.h
+ /usr/include/samba-4.0/ctdb_client.h
+ /usr/include/samba-4.0/ctdb_protocol.h
+ /usr/include/samba-4.0/ctdb_private.h
+ /usr/include/samba-4.0/ctdb_typesafe_cb.h
+ /usr/include/samba-4.0/ctdb_version.h
+)
+
+# sys-apps/attr is an automagic dependency (see bug #489748)
+CDEPEND="${PYTHON_DEPS}
+ >=app-arch/libarchive-3.1.2[${MULTILIB_USEDEP}]
+ dev-libs/libbsd[${MULTILIB_USEDEP}]
+ dev-libs/iniparser:0
+ dev-libs/popt[${MULTILIB_USEDEP}]
+ sys-libs/readline:=
+ virtual/libiconv
+ dev-python/subunit[${PYTHON_USEDEP},${MULTILIB_USEDEP}]
+ sys-apps/attr[${MULTILIB_USEDEP}]
+ sys-libs/libcap
+ >=sys-libs/ldb-1.1.25[${MULTILIB_USEDEP}]
+ sys-libs/ncurses:0=[${MULTILIB_USEDEP}]
+ >=sys-libs/talloc-2.1.5[python,${PYTHON_USEDEP},${MULTILIB_USEDEP}]
+ >=sys-libs/tdb-1.3.8[python,${PYTHON_USEDEP},${MULTILIB_USEDEP}]
+ >=sys-libs/tevent-0.9.28[${MULTILIB_USEDEP}]
+ sys-libs/zlib[${MULTILIB_USEDEP}]
+ virtual/pam
+ acl? ( virtual/acl )
+ addns? ( net-dns/bind-tools[gssapi] )
+ cluster? ( !dev-db/ctdb )
+ cups? ( net-print/cups )
+ dmapi? ( sys-apps/dmapi )
+ fam? ( virtual/fam )
+ gnutls? ( dev-libs/libgcrypt:0
+ >=net-libs/gnutls-1.4.0 )
+ ldap? ( net-nds/openldap[${MULTILIB_USEDEP}] )
+ system-mitkrb5? ( app-crypt/mit-krb5[${MULTILIB_USEDEP}] )
+ !system-mitkrb5? ( >=app-crypt/heimdal-1.5[-ssl,${MULTILIB_USEDEP}] )
+ systemd? ( sys-apps/systemd:0= )"
+DEPEND="${CDEPEND}
+ virtual/pkgconfig"
+RDEPEND="${CDEPEND}
+ client? ( net-fs/cifs-utils[ads?] )
+ selinux? ( sec-policy/selinux-samba )
+"
+
+REQUIRED_USE="addc? ( gnutls !system-mitkrb5 )
+ ads? ( acl gnutls ldap )
+ ${PYTHON_REQUIRED_USE}"
+
+S="${WORKDIR}/${MY_P}"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-4.2.3-heimdal_compilefix.patch"
+ "${FILESDIR}/${PN}-4.4.0-pam.patch"
+)
+
+CONFDIR="${FILESDIR}/$(get_version_component_range 1-2)"
+
+WAF_BINARY="${S}/buildtools/bin/waf"
+
+SHAREDMODS=""
+
+pkg_setup() {
+ python-single-r1_pkg_setup
+ if use cluster ; then
+ SHAREDMODS="${SHAREDMODS}idmap_rid,idmap_tdb2,idmap_ad"
+ fi
+}
+
+src_prepare() {
+ default
+
+ # install the patches from tarball(s)
+ eapply "${WORKDIR}/patches/"
+
+ multilib_copy_sources
+}
+
+multilib_src_configure() {
+ local myconf=()
+ myconf=(
+ --enable-fhs
+ --sysconfdir=/etc
+ --localstatedir=/var
+ --with-modulesdir=/usr/$(get_libdir)/samba
+ --with-piddir=/var/run/${PN}
+ --bundled-libraries=NONE
+ --builtin-libraries=NONE
+ --disable-rpath
+ --disable-rpath-install
+ --nopyc
+ --nopyo
+ )
+ if multilib_is_native_abi ; then
+ myconf+=(
+ $(use_with acl acl-support)
+ $(usex addc '' '--without-ad-dc')
+ $(use_with addns dnsupdate)
+ $(use_with ads)
+ $(usex ads '--with-shared-modules=idmap_ad' '')
+ $(use_enable avahi)
+ $(use_with cluster cluster-support)
+ $(use_enable cups)
+ $(use_with dmapi)
+ $(use_with fam)
+ $(use_enable gnutls)
+ $(use_enable iprint)
+ $(use_with ldap)
+ $(use_with pam)
+ $(usex pam "--with-pammodulesdir=/$(get_libdir)/security" '')
+ $(use_with quota quotas)
+ $(use_with syslog)
+ $(use_with systemd)
+ $(usex system-mitkrb5 '--with-system-mitkrb5' '')
+ $(use_with winbind)
+ $(usex test '--enable-selftest' '')
+ --with-shared-modules=${SHAREDMODS}
+ )
+ else
+ myconf+=(
+ --without-acl-support
+ --without-ad-dc
+ --without-dnsupdate
+ --without-ads
+ --disable-avahi
+ --without-cluster-support
+ --disable-cups
+ --without-dmapi
+ --without-fam
+ --disable-gnutls
+ --disable-iprint
+ $(use_with ldap)
+ --without-pam
+ --without-quotas
+ --without-syslog
+ --without-systemd
+ $(usex system-mitkrb5 '--with-system-mitkrb5' '')
+ --without-winbind
+ --disable-python
+ )
+ fi
+
+ CPPFLAGS="-I${SYSROOT}/usr/include/et ${CPPFLAGS}" \
+ waf-utils_src_configure ${myconf[@]}
+}
+
+multilib_src_install() {
+ waf-utils_src_install
+
+ # Make all .so files executable
+ find "${D}" -type f -name "*.so" -exec chmod +x {} +
+
+ if multilib_is_native_abi; then
+ # install ldap schema for server (bug #491002)
+ if use ldap ; then
+ insinto /etc/openldap/schema
+ doins examples/LDAP/samba.schema
+ fi
+
+ # install example config file
+ insinto /etc/samba
+ doins examples/smb.conf.default
+
+ # Install init script and conf.d file
+ newinitd "${CONFDIR}/samba4.initd-r1" samba
+ newconfd "${CONFDIR}/samba4.confd" samba
+
+ systemd_dotmpfilesd "${FILESDIR}"/samba.conf
+ systemd_dounit "${FILESDIR}"/nmbd.service
+ systemd_dounit "${FILESDIR}"/smbd.{service,socket}
+ systemd_newunit "${FILESDIR}"/smbd_at.service 'smbd@.service'
+ systemd_dounit "${FILESDIR}"/winbindd.service
+ systemd_dounit "${FILESDIR}"/samba.service
+ fi
+}
+
+multilib_src_test() {
+ if multilib_is_native_abi ; then
+ "${WAF_BINARY}" test || die "test failed"
+ fi
+}
+
+pkg_postinst() {
+ ewarn "Be aware the this release contains the best of all of Samba's"
+ ewarn "technology parts, both a file server (that you can reasonably expect"
+ ewarn "to upgrade existing Samba 3.x releases to) and the AD domain"
+ ewarn "controller work previously known as 'samba4'."
+
+ elog "For further information and migration steps make sure to read "
+ elog "http://samba.org/samba/history/${P}.html "
+ elog "http://samba.org/samba/history/${PN}-4.2.0.html and"
+ elog "http://wiki.samba.org/index.php/Samba4/HOWTO "
+}