diff options
author | Sam James <sam@gentoo.org> | 2023-04-02 03:31:58 +0100 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2023-04-02 03:55:37 +0100 |
commit | fed81fe07d8f174f22b119cae25c71f5dae71066 (patch) | |
tree | 433557d167737c3c4e0723435a10a5abc0f6703a /dev-libs/xerces-c | |
parent | app-text/blahtexml: add 1.0 (diff) | |
download | gentoo-fed81fe07d8f174f22b119cae25c71f5dae71066.tar.gz gentoo-fed81fe07d8f174f22b119cae25c71f5dae71066.tar.bz2 gentoo-fed81fe07d8f174f22b119cae25c71f5dae71066.zip |
dev-libs/xerces-c: add 3.2.4
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-libs/xerces-c')
-rw-r--r-- | dev-libs/xerces-c/Manifest | 1 | ||||
-rw-r--r-- | dev-libs/xerces-c/xerces-c-3.2.4.ebuild | 115 | ||||
-rw-r--r-- | dev-libs/xerces-c/xerces-c-9999.ebuild | 6 |
3 files changed, 119 insertions, 3 deletions
diff --git a/dev-libs/xerces-c/Manifest b/dev-libs/xerces-c/Manifest index 4e22c2a7639e..68c113209e2a 100644 --- a/dev-libs/xerces-c/Manifest +++ b/dev-libs/xerces-c/Manifest @@ -1 +1,2 @@ DIST xerces-c-3.2.3.tar.xz 4184368 BLAKE2B e582ecfa13d521061d0a0ba2e53b595047b325b53d5b634eadc0ed1967410733142e11951d907edf96386b1417adc938bf2f2f4eab760dcb81c0e718a48cf300 SHA512 8b8ac9a8377788753a918af2bd4437af5bb94b275e50fe1ab7cc6af88a8531248518705bc794da702a3e06a82a064cbd25e4149c2526aff7f61cf49ded4fdfab +DIST xerces-c-3.2.4.tar.xz 4260560 BLAKE2B 5d9fed1e9a461f8b348f3259216c5181bd03d2b5d8790cad88621d601065d0d79f8766ae70ed0aa7afe05005e2bcaf37a88da25b17f0e028bf074a31cea5fe71 SHA512 4d58d25b59b4528ad1f2d60681ddd6d2a4dba945613cee9ce978605f006da03703ea85a1bd89f781eeb3ad4dbdadf485a310f29d4c07036b0322f0755f87fddf diff --git a/dev-libs/xerces-c/xerces-c-3.2.4.ebuild b/dev-libs/xerces-c/xerces-c-3.2.4.ebuild new file mode 100644 index 000000000000..d839bf7df2ca --- /dev/null +++ b/dev-libs/xerces-c/xerces-c-3.2.4.ebuild @@ -0,0 +1,115 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +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.xz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos" +fi + +LICENSE="Apache-2.0" +SLOT="0" +IUSE="cpu_flags_x86_sse2 curl doc 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 ) + +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" + 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 +} diff --git a/dev-libs/xerces-c/xerces-c-9999.ebuild b/dev-libs/xerces-c/xerces-c-9999.ebuild index 133712bc42a3..d839bf7df2ca 100644 --- a/dev-libs/xerces-c/xerces-c-9999.ebuild +++ b/dev-libs/xerces-c/xerces-c-9999.ebuild @@ -1,7 +1,7 @@ -# Copyright 1999-2022 Gentoo Authors +# Copyright 1999-2023 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 inherit cmake prefix @@ -13,7 +13,7 @@ if [[ ${PV} == *9999 ]] ; then inherit subversion else SRC_URI="mirror://apache/xerces/c/3/sources/${P}.tar.xz" - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos" fi LICENSE="Apache-2.0" |