--- libxslt-1.1.32.ebuild +++ libxslt-1.1.32-r1.ebuild @@ -13,28 +13,31 @@ LICENSE="MIT" SLOT="0" -KEYWORDS="alpha amd64 arm arm64 hppa ia64 ~m68k ~mips ppc ppc64 s390 ~sh sparc x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" -IUSE="crypt debug examples python static-libs elibc_Darwin" +IUSE="catalogless crypt debug examples python static-libs elibc_Darwin" REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" RDEPEND=" - >=dev-libs/libxml2-2.9.1-r5:2[${MULTILIB_USEDEP}] - crypt? ( >=dev-libs/libgcrypt-1.5.3:0=[${MULTILIB_USEDEP}] ) + >=dev-libs/libxml2-2.9.1-r5:2[catalogless?,${MULTILIB_USEDEP}] + crypt? ( >=dev-libs/libgcrypt-1.5.3:0=[${MULTILIB_USEDEP}] ) python? ( ${PYTHON_DEPS} dev-libs/libxml2:2[python,${PYTHON_USEDEP}] ) " DEPEND="${RDEPEND}" -MULTILIB_CHOST_TOOLS=( - /usr/bin/xslt-config -) - MULTILIB_WRAPPED_HEADERS=( /usr/include/libxslt/xsltconfig.h ) +pkg_setup() { + MULTILIB_CHOST_TOOLS=( + /usr/bin/xslt-config + $(usex catalogless /usr/bin/xslt-catalogless-config "") + ) +} + src_prepare() { default @@ -45,6 +48,10 @@ eapply "${FILESDIR}"/${PV}-simplify-python.patch eapply "${FILESDIR}"/${PN}-1.1.28-disable-static-modules.patch + if use catalogless; then + cp -pr "${S}" "${S}-catalogless" || die + fi + eautoreconf # If eautoreconf'd with new autoconf, then epunt_cxx is not necessary # and it is propably otherwise too if upstream generated with new @@ -52,11 +59,19 @@ # epunt_cxx # But Prefix always needs elibtoolize if not eautoreconf'd. # elibtoolize + + if use catalogless; then + pushd "${S}-catalogless" > /dev/null || die + eapply "${FILESDIR}"/${P}-catalogless.patch + eapply "${FILESDIR}"/${P}-catalogless-generated.patch + eautoreconf + popd > /dev/null || die + fi } multilib_src_configure() { libxslt_configure() { - ECONF_SOURCE="${S}" econf \ + ECONF_SOURCE="${ECONF_SOURCE-${S}}" econf \ --with-html-dir="${EPREFIX}"/usr/share/doc/${PF} \ --with-html-subdir=html \ $(use_with crypt crypto) \ @@ -73,6 +88,13 @@ libxslt_configure --without-python # build python bindings separately + if use catalogless; then + mkdir -p "$(pwd)-catalogless" || die + pushd "$(pwd)-catalogless" > /dev/null || die + ECONF_SOURCE="${S}-catalogless" libxslt_configure --without-python + popd > /dev/null || die + fi + if multilib_is_native_abi && use python; then python_foreach_impl libxslt_py_configure fi @@ -80,11 +102,25 @@ multilib_src_compile() { default + + if use catalogless; then + pushd "$(pwd)-catalogless" > /dev/null || die + default + popd > /dev/null || die + fi + multilib_is_native_abi && use python && libxslt_foreach_py_emake all } multilib_src_test() { default + + if use catalogless; then + pushd "$(pwd)-catalogless" > /dev/null || die + default + popd > /dev/null || die + fi + multilib_is_native_abi && use python && libxslt_foreach_py_emake test } @@ -92,6 +128,12 @@ # "default" does not work here - docs are installed by multilib_src_install_all emake DESTDIR="${D}" install + if use catalogless; then + pushd "$(pwd)-catalogless" > /dev/null || die + emake DESTDIR="${D}" install + popd > /dev/null || die + fi + if multilib_is_native_abi && use python; then libxslt_foreach_py_emake \ DESTDIR="${D}" \