commit: 92e0e28956dae46cf7a0f79fe72a9013d9731c0d Author: Sam James <sam <AT> gentoo <DOT> org> AuthorDate: Sun Feb 9 08:11:28 2025 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Sun Feb 9 08:11:28 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=92e0e289
dev-libs/tre: add 0.9.0 Bug: https://bugs.gentoo.org/851675 Bug: https://bugs.gentoo.org/889222 Signed-off-by: Sam James <sam <AT> gentoo.org> dev-libs/tre/Manifest | 1 + dev-libs/tre/tre-0.9.0.ebuild | 98 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 99 insertions(+) diff --git a/dev-libs/tre/Manifest b/dev-libs/tre/Manifest index 8a3e6468e4cc..a35214355176 100644 --- a/dev-libs/tre/Manifest +++ b/dev-libs/tre/Manifest @@ -1 +1,2 @@ DIST tre-0.8.0_p20210321.tar.gz 146294 BLAKE2B d740bd0e99f50f5e4d8105f5260e43a81b6af9857a21e386e437ab8d48a9e0de23eae03e96cf6b9f4d2d37f72d0fa73ef7343086271ea80f166bdba3f04475a9 SHA512 950c81f681970fc737cfdd6815445f05a018fc742b964cea3ce19f0249c677dd715ece4ff8e543fa9f3fd23b503eafa00aea00dbae063af9bc7e08dc1bc33aed +DIST tre-0.9.0.tar.gz 579986 BLAKE2B 12586b3309e2c6387f9cb44b86fd1ec2b0dd8d3d7ba43938be7a3cc6c7a4fde625493840fee80f0991065515e68424783e88a1c93d815e140a71d42597effa8d SHA512 228421bcd912c990137478ccddecaa2e21836a32de73d2d9ca56a0e8dd8aab7e785c29e552d2755e7b96e3bcf5338be532f0ef4b096617505bee0d2b639f573a diff --git a/dev-libs/tre/tre-0.9.0.ebuild b/dev-libs/tre/tre-0.9.0.ebuild new file mode 100644 index 000000000000..f2719165f5e0 --- /dev/null +++ b/dev-libs/tre/tre-0.9.0.ebuild @@ -0,0 +1,98 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +DISTUTILS_USE_PEP517=setuptools +PYTHON_COMPAT=( python3_{10..12} pypy3 ) +DISTUTILS_EXT=1 +DISTUTILS_OPTIONAL=1 + +inherit autotools distutils-r1 + +DESCRIPTION="Lightweight, robust, and efficient POSIX compliant regexp matching library" +HOMEPAGE=" + https://laurikari.net/tre/ + https://github.com/laurikari/tre +" +SRC_URI="https://github.com/laurikari/tre/releases/download/v${PV}/${P}.tar.gz" + +LICENSE="BSD-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~x64-macos" +IUSE="+agrep +alloca +approx debug nls profile python" + +RDEPEND=" + agrep? ( + !dev-ruby/amatch + ) + python? ( ${PYTHON_DEPS} ) +" +DEPEND=" + ${RDEPEND} + nls? ( sys-devel/gettext ) +" +BDEPEND=" + python? ( ${DISTUTILS_DEPS} ) + sys-devel/gettext + virtual/pkgconfig" + +REQUIRED_USE=" + agrep? ( approx ) + python? ( ${PYTHON_REQUIRED_USE} ) +" + +PATCHES=( + "${FILESDIR}/0.8.0-pkgcfg.patch" + "${FILESDIR}/${PN}-tests.patch" +) + +src_prepare() { + default + eautoreconf +} + +src_configure() { + local myconf=( + --disable-static + --disable-system-abi + --enable-multibyte + --enable-wchar + $(use_enable agrep) + $(use_enable approx) + $(use_enable debug) + $(use_enable nls) + $(use_enable profile) + $(use_with alloca) + ) + econf "${myconf[@]}" +} + +src_test() { + if locale -a | grep -iq en_US.iso88591; then + emake -j1 check + else + ewarn "If you like to run the test," + ewarn "please make sure en_US.ISO-8859-1 is installed." + die "en_US.ISO-8859-1 locale is missing" + fi +} + +src_compile() { + default + + if use python; then + cd python || die + distutils-r1_src_compile + fi +} + +src_install() { + local HTML_DOCS=( doc/*.{css,html} ) + + default + + use python && distutils-r1_src_install + + find "${ED}" -type f -name '*.la' -delete || die +}
