commit:     aff0227cf462c8a488823c72b4effa4ce67cb5c9
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Wed Jan 14 16:40:47 2026 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed Jan 14 16:40:57 2026 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=aff0227c

dev-libs/icu: add 78.2

Signed-off-by: Sam James <sam <AT> gentoo.org>

 dev-libs/icu/Manifest        |   2 +
 dev-libs/icu/icu-78.2.ebuild | 172 +++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 174 insertions(+)

diff --git a/dev-libs/icu/Manifest b/dev-libs/icu/Manifest
index 75fb2ee3f195..246bea0198f8 100644
--- a/dev-libs/icu/Manifest
+++ b/dev-libs/icu/Manifest
@@ -2,3 +2,5 @@ DIST icu4c-77_1-src.tgz 27384265 BLAKE2B 
7ee4457dbb9abfee543aa91314e052282fb1c73
 DIST icu4c-77_1-src.tgz.asc 228 BLAKE2B 
faabf00cb79427b14286e24770cbed3cd81a367bb5e9dc935c8fa5b8d67d7401fa82425b70259740a4136bd52fe9887bf0494195c6941454cadabec475d5c0e5
 SHA512 
7051e53f5a82a9b72a07adcc9751921c0afee56c733ccfe8ed94701606cadaf3b85135d5815dbe1acddb64ffef30d3d9fc5f37016b20dcd07685baa06d633759
 DIST icu4c-78.1-sources.tgz 27979449 BLAKE2B 
382f57d25642aab2be8eea7713b205928d0a226b0ef5ff3ce2205be7a215a6dca2045617778643f62aa5d174b3f96ea9723c6c3847742dc5649686c131c511c7
 SHA512 
c366398fdb50afc6355a8c45ed1d68a18eaa5f07a5d1c4555becbcfb9d4073e65ebe1e9caf24b93779b11b36cd813c98dd59e4b19f008851f25c7262811c112d
 DIST icu4c-78.1-sources.tgz.asc 228 BLAKE2B 
9b51333e800be3ff79ce60a019a4bd53c264d082f8b8f0c616878dc6e8fa347e18158d102b43d9349662ea0c211480b62cbc762aa807e9a7d04d5581919c63e4
 SHA512 
d38176a5034c9161a9a4db88cbd611d09c303a72b7fa763a9054a3197ded4b52813bbce1ceb1e8a4e0e206a6129d5cbb08de446a1f396490c3af22f4242c653b
+DIST icu4c-78.2-sources.tgz 27970651 BLAKE2B 
1a617708bc67f86b4baa52b4feb4c51353b83a4d863607906d794193b32e90b1e26f6d345298ce4fbac5f749c28e894b952d1c01776d3bcd755fe3e8bcfa10ef
 SHA512 
92feddfe81c57336f386c7cbc9f6d976bf349db148a77a247c4559676f51116115c8c52c4d907feb50933f72ab75fd8e48be092bf9c8ca33a3e8fabc9372a5d6
+DIST icu4c-78.2-sources.tgz.asc 228 BLAKE2B 
1c3ef0a29cf7d1a8c54ef85fa24df14e7ba5185a669e36e4fb23b2ad5be6154221aa8d0c622512f4217f988dff691ca4981ef95826acd1aad5822f4f395ead7c
 SHA512 
7af71f82e1c0d08620a1b27a4adcfa419d14d7726d78a9f8f49f8131008f43cb4723ddbd230689e9b3eeddeca8ac3e3babda64d739e9a17f00d924b53fa18c5d

diff --git a/dev-libs/icu/icu-78.2.ebuild b/dev-libs/icu/icu-78.2.ebuild
new file mode 100644
index 000000000000..a46cfcaaa99e
--- /dev/null
+++ b/dev-libs/icu/icu-78.2.ebuild
@@ -0,0 +1,172 @@
+# Copyright 1999-2026 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+MY_PV=${PV/_rc/-rc}
+PYTHON_COMPAT=( python3_{11..14} )
+VERIFY_SIG_OPENPGP_KEY_PATH=/usr/share/openpgp-keys/icu.asc
+inherit autotools flag-o-matic multilib-minimal python-any-r1 toolchain-funcs 
verify-sig
+
+DESCRIPTION="International Components for Unicode"
+HOMEPAGE="https://icu.unicode.org/";
+SRC_URI="https://github.com/unicode-org/icu/releases/download/release-${MY_PV/_/-}/icu4c-${MY_PV/-rc/rc}-sources.tgz";
+SRC_URI+=" verify-sig? ( 
https://github.com/unicode-org/icu/releases/download/release-${MY_PV/_/-}/icu4c-${MY_PV/-rc/rc}-sources.tgz.asc
 )"
+S="${WORKDIR}"/${PN}/source
+
+LICENSE="BSD"
+SLOT="0/${PV%.*}"
+if [[ ${PV} != *_rc* ]] ; then
+       KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc 
~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos ~x64-solaris"
+fi
+IUSE="debug doc examples static-libs test"
+RESTRICT="!test? ( test )"
+
+BDEPEND="${PYTHON_DEPS}
+       dev-build/autoconf-archive
+       virtual/pkgconfig
+       doc? ( app-text/doxygen[dot] )
+       verify-sig? ( >=sec-keys/openpgp-keys-icu-20241110 )
+"
+
+MULTILIB_CHOST_TOOLS=(
+       /usr/bin/icu-config
+)
+
+PATCHES=(
+       "${FILESDIR}/${PN}-76.1-remove-bashisms.patch"
+       "${FILESDIR}/${PN}-64.2-darwin.patch"
+       "${FILESDIR}/${PN}-68.1-nonunicode.patch"
+
+       # Undo change for now which exposes underlinking in consumers;
+       # revisit when things are a bit quieter and tinderbox its removal.
+       "${FILESDIR}/${PN}-76.1-undo-pkgconfig-change-for-now.patch"
+       # https://unicode-org.atlassian.net/browse/ICU-23120
+       "${FILESDIR}/${PN}-77.1-invalid-malloc.patch"
+)
+
+HTML_DOCS=( ../readme.html )
+
+src_prepare() {
+       default
+
+       # TODO: switch uconfig.h hacks to use uconfig_local
+       #
+       # Disable renaming as it assumes stable ABI and that consumers
+       # won't use unofficial APIs. We need this despite the configure 
argument.
+       sed -i \
+               -e "s/#define U_DISABLE_RENAMING 0/#define U_DISABLE_RENAMING 
1/" \
+               common/unicode/uconfig.h || die
+       #
+       # ODR violations, experimental API
+       sed -i \
+               -e "s/#   define UCONFIG_NO_MF2 0/#define UCONFIG_NO_MF2 1/" \
+               common/unicode/uconfig.h || die
+
+       # Fix linking of icudata
+       sed -i \
+               -e "s:LDFLAGSICUDT=-nodefaultlibs -nostdlib:LDFLAGSICUDT=:" \
+               config/mh-linux || die
+
+       # Append doxygen configuration to configure
+       sed -i \
+               -e 's:icudefs.mk:icudefs.mk Doxyfile:' \
+               configure.ac || die
+
+       eautoreconf
+}
+
+src_configure() {
+       MAKEOPTS+=" VERBOSE=1"
+
+       if tc-is-cross-compiler; then
+               mkdir "${WORKDIR}"/host || die
+               pushd "${WORKDIR}"/host >/dev/null || die
+
+               CFLAGS="" CXXFLAGS="" ASFLAGS="" LDFLAGS="" \
+               CC="$(tc-getBUILD_CC)" CXX="$(tc-getBUILD_CXX)" 
AR="$(tc-getBUILD_AR)" \
+               RANLIB="$(tc-getBUILD_RANLIB)" LD="$(tc-getBUILD_LD)" \
+               "${S}"/configure --disable-renaming --disable-debug \
+                       --disable-samples --enable-static || die
+               emake
+
+               popd >/dev/null || die
+       fi
+
+       # Workaround for bug #963337 (gcc PR122058)
+       tc-is-gcc && [[ $(gcc-major-version) -eq 16 ]] && append-cxxflags 
-fno-devirtualize-speculatively
+
+       multilib-minimal_src_configure
+}
+
+multilib_src_configure() {
+       # https://unicode-org.github.io/icu/userguide/icu4c/packaging
+       local myeconfargs=(
+               --disable-renaming
+               --disable-samples
+               # TODO: Re-enable(?) - planned to do this w/ 73.2 but seem to
+               # get test failures only with --enable-layoutex.
+               --disable-layoutex
+               $(use_enable debug)
+               $(use_enable static-libs static)
+               $(use_enable test tests)
+               $(multilib_native_use_enable examples samples)
+       )
+
+       #if use test ; then
+       #       myeconfargs+=(
+       #               --enable-extras
+       #               --enable-tools
+       #       )
+       #else
+       #       myeconfargs+=(
+       #               $(multilib_native_enable extras)
+       #               $(multilib_native_enable tools)
+       #       )
+       #fi
+
+       tc-is-cross-compiler && myeconfargs+=(
+               --with-cross-build="${WORKDIR}"/host
+       )
+
+       # Work around cross-endian testing failures with LTO, bug #757681
+       if tc-is-cross-compiler && tc-is-lto ; then
+               myeconfargs+=( --disable-strict )
+       fi
+
+       # ICU tries to use clang by default
+       tc-export CC CXX
+
+       # Make sure we configure with the same shell as we run icu-config
+       # with, or ECHO_N, ECHO_T and ECHO_C will be wrongly defined
+       export CONFIG_SHELL="${EPREFIX}/bin/sh"
+       # Probably have no /bin/sh in prefix-chain
+       [[ -x ${CONFIG_SHELL} ]] || CONFIG_SHELL="${BASH}"
+
+       ECONF_SOURCE="${S}" econf "${myeconfargs[@]}"
+}
+
+multilib_src_compile() {
+       default
+
+       if multilib_is_native_abi && use doc; then
+               doxygen -u Doxyfile || die
+               doxygen Doxyfile || die
+
+               HTML_DOCS+=( "${BUILD_DIR}"/doc/html/. )
+       fi
+}
+
+multilib_src_test() {
+       # INTLTEST_OPTS: intltest options
+       #   -e: Exhaustive testing
+       #   -l: Reporting of memory leaks
+       #   -v: Increased verbosity
+       # IOTEST_OPTS: iotest options
+       #   -e: Exhaustive testing
+       #   -v: Increased verbosity
+       # CINTLTST_OPTS: cintltst options
+       #   -e: Exhaustive testing
+       #   -v: Increased verbosity
+       emake check
+}

Reply via email to