From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 13D911382C5 for ; Mon, 15 Feb 2021 09:48:01 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 50006E09E3; Mon, 15 Feb 2021 09:47:59 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 32CE2E09E3 for ; Mon, 15 Feb 2021 09:47:59 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id A0A66340D8A for ; Mon, 15 Feb 2021 09:47:57 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id EC0F2478 for ; Mon, 15 Feb 2021 09:47:55 +0000 (UTC) From: "Andreas Sturmlechner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Andreas Sturmlechner" Message-ID: <1613382461.ef1bd5623b3f1112f25615745553c9ed5827fb44.asturm@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-libs/xerces-c/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-libs/xerces-c/xerces-c-3.2.3-r2.ebuild X-VCS-Directories: dev-libs/xerces-c/ X-VCS-Committer: asturm X-VCS-Committer-Name: Andreas Sturmlechner X-VCS-Revision: ef1bd5623b3f1112f25615745553c9ed5827fb44 X-VCS-Branch: master Date: Mon, 15 Feb 2021 09:47:55 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: b43670d6-db93-4c84-802b-ff806347942f X-Archives-Hash: b75ddf5d65139b61aa0382516b429c72 commit: ef1bd5623b3f1112f25615745553c9ed5827fb44 Author: Andreas Sturmlechner gentoo org> AuthorDate: Mon Feb 15 09:17:04 2021 +0000 Commit: Andreas Sturmlechner gentoo org> CommitDate: Mon Feb 15 09:47:41 2021 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ef1bd562 dev-libs/xerces-c: EAPI-7 bump, switch to cmake.eclass, for 3.2.3 too Package-Manager: Portage-3.0.14, Repoman-3.0.2 Signed-off-by: Andreas Sturmlechner gentoo.org> dev-libs/xerces-c/xerces-c-3.2.3-r2.ebuild | 119 +++++++++++++++++++++++++++++ 1 file changed, 119 insertions(+) diff --git a/dev-libs/xerces-c/xerces-c-3.2.3-r2.ebuild b/dev-libs/xerces-c/xerces-c-3.2.3-r2.ebuild new file mode 100644 index 00000000000..4c29af461e2 --- /dev/null +++ b/dev-libs/xerces-c/xerces-c-3.2.3-r2.ebuild @@ -0,0 +1,119 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit cmake prefix + +DESCRIPTION="A validating XML parser written in a portable subset of C++" +HOMEPAGE="https://xerces.apache.org/xerces-c/" + +if [[ ${PV} == *9999 ]] ; then + ESVN_REPO_URI="https://svn.apache.org/repos/asf/xerces/c/trunk" + inherit subversion +else + SRC_URI="mirror://apache/xerces/c/3/sources/${P}.tar.gz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos" +fi + +LICENSE="Apache-2.0" +SLOT="0" +IUSE="cpu_flags_x86_sse2 curl doc elibc_Darwin elibc_FreeBSD examples iconv icu static-libs test threads" + +RESTRICT="!test? ( test )" + +RDEPEND=" + curl? ( net-misc/curl ) + icu? ( dev-libs/icu:0= ) + virtual/libiconv" +DEPEND="${RDEPEND}" +BDEPEND=" + doc? ( app-doc/doxygen ) + test? ( dev-lang/perl )" + +DOCS=( CREDITS KEYS NOTICE README ) + +PATCHES=( "${FILESDIR}"/${PN}-3.2.2-fix-XERCESC-2163.patch ) + +pkg_setup() { + export ICUROOT="${EPREFIX}/usr" + + if use iconv && use icu; then + ewarn "This package can use iconv or icu for loading messages" + ewarn "and transcoding, but not both. ICU takes precedence." + fi +} + +src_configure() { + # 'cfurl' is only available on OSX and 'socket' isn't supposed to work. + # But the docs aren't clear about it, so we would need some testing... + local netaccessor + if use curl; then + netaccessor="curl" + elif use elibc_Darwin; then + netaccessor="cfurl" + else + netaccessor="socket" + fi + + local msgloader + if use icu; then + msgloader="icu" + elif use iconv; then + msgloader="iconv" + else + msgloader="inmemory" + fi + + local transcoder + if use icu; then + transcoder="icu" + elif use elibc_Darwin; then + transcoder="macosunicodeconverter" + elif use elibc_FreeBSD; then + transcoder="iconv" + else + transcoder="gnuiconv" + fi + # for interix maybe: transcoder="windows" + + local mycmakeargs=( + -DCMAKE_INSTALL_DOCDIR="${EPREFIX}/usr/share/doc/${PF}" + -Dnetwork-accessor="${netaccessor}" + -Dmessage-loader="${msgloader}" + -Dtranscoder="${transcoder}" + -Dthreads:BOOL="$(usex threads)" + -Dsse2:BOOL="$(usex cpu_flags_x86_sse2)" + ) + + cmake_src_configure +} + +src_compile() { + cmake_src_compile + + use doc && cmake_build doc-style createapidocs doc-xml +} + +src_install() { + cmake_src_install + + # package provides .pc files + find "${D}" -name '*.la' -delete || die + + if use examples; then + # clean out object files, executables, Makefiles + # and the like before installing examples + find samples/ \( -type f -executable -o -iname 'runConfigure' -o -iname '*.o' \ + -o -iname '.libs' -o -iname 'Makefile*' \) -exec rm -rf '{}' + || die + docinto examples + dodoc -r samples/. + docompress -x /usr/share/doc/${PF}/examples + fi + + # To make sure an appropriate NLS msg file is around when using + # the iconv msgloader ICU has the messages compiled in. + if use iconv && ! use icu; then + doenvd "$(prefixify_ro "${FILESDIR}/50xerces-c")" + fi +}