sys-libs/ldb: Build without Python

We don't want Python in the production images, so hack the ldb build to avoid
pulling it in.
This commit is contained in:
Matthew Garrett 2016-04-05 15:12:52 -07:00
parent 2f9b3dff3b
commit 9c2bc3d3ef

View File

@ -3,10 +3,8 @@
# $Id$ # $Id$
EAPI=6 EAPI=6
PYTHON_COMPAT=( python2_7 )
PYTHON_REQ_USE="threads"
inherit python-single-r1 waf-utils multilib-minimal eutils inherit waf-utils multilib-minimal eutils
DESCRIPTION="An LDAP-like embedded database" DESCRIPTION="An LDAP-like embedded database"
HOMEPAGE="http://ldb.samba.org" HOMEPAGE="http://ldb.samba.org"
@ -19,13 +17,12 @@ IUSE="doc"
RDEPEND="!elibc_FreeBSD? ( dev-libs/libbsd[${MULTILIB_USEDEP}] ) RDEPEND="!elibc_FreeBSD? ( dev-libs/libbsd[${MULTILIB_USEDEP}] )
dev-libs/popt[${MULTILIB_USEDEP}] dev-libs/popt[${MULTILIB_USEDEP}]
>=sys-libs/talloc-2.1.5[python,${MULTILIB_USEDEP}] >=sys-libs/talloc-2.1.5[${MULTILIB_USEDEP}]
>=sys-libs/tevent-0.9.27[python(+),${MULTILIB_USEDEP}] >=sys-libs/tevent-0.9.27[${MULTILIB_USEDEP}]
>=sys-libs/tdb-1.3.8[python,${MULTILIB_USEDEP}] >=sys-libs/tdb-1.3.8[${MULTILIB_USEDEP}]
net-nds/openldap net-nds/openldap
!!<net-fs/samba-3.6.0[ldb] !!<net-fs/samba-3.6.0[ldb]
!!>=net-fs/samba-4.0.0[ldb] !!>=net-fs/samba-4.0.0[ldb]
${PYTHON_DEPS}
" "
DEPEND="dev-libs/libxslt DEPEND="dev-libs/libxslt
@ -33,8 +30,6 @@ DEPEND="dev-libs/libxslt
virtual/pkgconfig virtual/pkgconfig
${RDEPEND}" ${RDEPEND}"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
WAF_BINARY="${S}/buildtools/bin/waf" WAF_BINARY="${S}/buildtools/bin/waf"
MULTILIB_WRAPPED_HEADERS=( /usr/include/pyldb.h ) MULTILIB_WRAPPED_HEADERS=( /usr/include/pyldb.h )
@ -43,10 +38,6 @@ PATCHES=(
"${FILESDIR}"/${PN}-1.1.24-optional-python.patch "${FILESDIR}"/${PN}-1.1.24-optional-python.patch
) )
pkg_setup() {
python-single-r1_pkg_setup
}
src_prepare() { src_prepare() {
default default
multilib_copy_sources multilib_copy_sources
@ -57,11 +48,9 @@ multilib_src_configure() {
--disable-rpath \ --disable-rpath \
--disable-rpath-install --bundled-libraries=NONE \ --disable-rpath-install --bundled-libraries=NONE \
--with-modulesdir="${EPREFIX}"/usr/$(get_libdir)/samba \ --with-modulesdir="${EPREFIX}"/usr/$(get_libdir)/samba \
--builtin-libraries=NONE --builtin-libraries=NONE \
--disable-python
) )
if ! multilib_is_native_abi; then
myconf+=( --disable-python )
fi
waf-utils_src_configure "${myconf[@]}" waf-utils_src_configure "${myconf[@]}"
} }