pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

icu: start on an upgrade



Module Name:	pkgsrc-wip
Committed By:	Thomas Klausner <wiz%NetBSD.org@localhost>
Pushed By:	wiz
Date:		Tue Dec 30 11:12:12 2025 +0100
Changeset:	4940a2e7705a6f17eaa5a113975751d1df0368f3

Modified Files:
	Makefile
Added Files:
	icu/DESCR
	icu/Makefile
	icu/PLIST
	icu/TODO
	icu/buildlink3.mk
	icu/distinfo
	icu/log
	icu/patches/patch-acinclude.m4
	icu/patches/patch-common_putil.cpp
	icu/patches/patch-common_ubidiimp.h
	icu/patches/patch-common_umutex.h
	icu/patches/patch-common_unicode_platform.h
	icu/patches/patch-common_unicode_ptypes.h
	icu/patches/patch-common_uposixdefs.h
	icu/patches/patch-config_Makefile.inc.in
	icu/patches/patch-config_icu-config-bottom
	icu/patches/patch-config_mh-darwin
	icu/patches/patch-config_mh-scoosr5
	icu/patches/patch-configure
	icu/patches/patch-configure.ac
	icu/patches/patch-i18n_double-conversion-utils.h
	icu/patches/patch-icudefs.mk.in
	icu/patches/patch-runConfigureICU
	icu/patches/patch-tools-toolutil-pkg_genc.cpp

Log Message:
icu: start on an upgrade

doesn't build

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=4940a2e7705a6f17eaa5a113975751d1df0368f3

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 Makefile                                         |   1 +
 icu/DESCR                                        |  16 ++
 icu/Makefile                                     | 182 +++++++++++++++
 icu/PLIST                                        | 273 +++++++++++++++++++++++
 icu/TODO                                         |   2 +
 icu/buildlink3.mk                                |  15 ++
 icu/distinfo                                     |  22 ++
 icu/log                                          |  14 ++
 icu/patches/patch-acinclude.m4                   |  14 ++
 icu/patches/patch-common_putil.cpp               |  19 ++
 icu/patches/patch-common_ubidiimp.h              |  18 ++
 icu/patches/patch-common_umutex.h                |  47 ++++
 icu/patches/patch-common_unicode_platform.h      |  32 +++
 icu/patches/patch-common_unicode_ptypes.h        |  15 ++
 icu/patches/patch-common_uposixdefs.h            |  30 +++
 icu/patches/patch-config_Makefile.inc.in         |  13 ++
 icu/patches/patch-config_icu-config-bottom       |  18 ++
 icu/patches/patch-config_mh-darwin               |  18 ++
 icu/patches/patch-config_mh-scoosr5              |  77 +++++++
 icu/patches/patch-configure                      |  45 ++++
 icu/patches/patch-configure.ac                   |  34 +++
 icu/patches/patch-i18n_double-conversion-utils.h |  15 ++
 icu/patches/patch-icudefs.mk.in                  |  31 +++
 icu/patches/patch-runConfigureICU                |  15 ++
 icu/patches/patch-tools-toolutil-pkg_genc.cpp    |  16 ++
 25 files changed, 982 insertions(+)

diffs:
diff --git a/Makefile b/Makefile
index eba842ddaf..cba75c6966 100644
--- a/Makefile
+++ b/Makefile
@@ -1743,6 +1743,7 @@ SUBDIR+=	icestorm-git
 SUBDIR+=	icestorm_update
 SUBDIR+=	icmpchat
 SUBDIR+=	ics2txt
+SUBDIR+=	icu
 SUBDIR+=	id3
 SUBDIR+=	ideviceinstaller
 SUBDIR+=	ifstat
diff --git a/icu/DESCR b/icu/DESCR
new file mode 100644
index 0000000000..b3738df28e
--- /dev/null
+++ b/icu/DESCR
@@ -0,0 +1,16 @@
+The International Components for Unicode(ICU) is a C and C++ library that
+provides robust and full-featured Unicode support on a wide variety of
+platforms. The library provides:
+
+- Calendar support
+- Character set conversions
+- Collation (language-sensitive)
+- Date & time formatting
+- Locales (140+ supported)
+- Message catalogs (resources)
+- Message formatting
+- Normalization
+- Number & currency formatting
+- Time zones
+- Transliteration
+- Word, line & sentence breaks
diff --git a/icu/Makefile b/icu/Makefile
new file mode 100644
index 0000000000..7f342f309b
--- /dev/null
+++ b/icu/Makefile
@@ -0,0 +1,182 @@
+# $NetBSD: Makefile,v 1.166 2025/04/17 22:03:48 wiz Exp $
+
+DISTNAME=	icu4c-78.1-sources
+PKGNAME=	${DISTNAME:S/4c//:S/-sources//}
+CATEGORIES=	textproc
+MASTER_SITES=	${MASTER_SITE_GITHUB:=unicode-org/}
+GITHUB_PROJECT=	icu
+GITHUB_RELEASE=	release-${PKGVERSION_NOREV}
+EXTRACT_SUFX=	.tgz
+
+MAINTAINER=	pkgsrc-users%NetBSD.org@localhost
+HOMEPAGE=	https://icu.unicode.org/
+COMMENT=	Robust and full-featured Unicode services
+LICENSE=	unicode-v3 AND modified-bsd AND mit
+
+POLICY_UPDATE_LIMITED=	abi
+
+WRKSRC=			${WRKDIR}/icu/source
+USE_LANGUAGES=		c c++
+USE_CC_FEATURES=	c11
+USE_CXX_FEATURES=	c++17
+USE_TOOLS+=		gmake pkg-config
+TEST_TARGET=		check
+UNLIMIT_RESOURCES+=	datasize
+GNU_CONFIGURE=		yes
+CONFIGURE_ARGS+=	--enable-static
+CONFIGURE_ENV+=		U_MAKE=${TOOLS_GMAKE}
+# Avoid Python; not really needed for build.
+# Fixes circular dependency on Python and Sqlite3 with ICU.
+CONFIGURE_ENV+=		ac_cv_prog_PYTHON=""
+
+.include "../../mk/bsd.prefs.mk"
+
+.if ${USE_CROSS_COMPILE:tl} == "yes"
+
+TOOL_DEPENDS+=		${PKGNAME}:../../${PKGPATH}
+
+ICU_CROSS_DIR=		${WRKDIR}/.icu_cross
+ICU_CROSS_COOKIE=	${ICU_CROSS_DIR}/.cookie
+
+CONFIGURE_ARGS+=	--with-cross-build=${ICU_CROSS_DIR}
+pre-configure: ${ICU_CROSS_COOKIE}
+
+ICU_CROSS_TOOLS=	\
+	${HOST_PKG_INFO} -qL ${PKGNAME} \
+	| ${GREP} -e '^'${TOOLBASE}/bin -e '^'${TOOLBASE}/sbin
+
+show-icu-cross-tools: .PHONY
+	@${ICU_CROSS_TOOLS}
+
+icu-cross-clean: .PHONY
+	${RUN}${RM} -f ${ICU_CROSS_COOKIE}
+icu-cross-tools: .PHONY ${ICU_CROSS_COOKIE}
+${ICU_CROSS_COOKIE}:
+	@${STEP_MSG} Faking ICU cross-build directory
+	${RUN}${TEST} -d ${ICU_CROSS_DIR} || ${MKDIR} ${ICU_CROSS_DIR}
+.  for d in bin config lib
+	${RUN}${TEST} -d ${ICU_CROSS_DIR}/${d} || \
+		${MKDIR} ${ICU_CROSS_DIR}/${d}
+.  endfor
+	${RUN}cd ${ICU_CROSS_DIR} && ${ICU_CROSS_TOOLS} \
+	| while read f; do \
+		${LN} -sfn "$$f" bin/; \
+	done
+	${RUN} {							\
+		${ECHO} CROSS_ICU_VERSION=${PKGREVISION_NOREV};		\
+		${ECHO} TOOLEXEEXT=;					\
+		${ECHO} TOOLBINDIR='$$(cross_buildroot)/bin';		\
+		${ECHO} TOOLLIBDIR='$$(cross_buildroot)/lib';		\
+		${ECHO} INVOKE=;					\
+		${ECHO} PKGDATA_INVOKE=;				\
+	} >${ICU_CROSS_DIR}/config/icucross.mk
+	${RUN}${ECHO} ${:UCURR_FULL_DIR?=$$(shell pwd | sed 's/ /\\ /g'):Q} \
+		>${ICU_CROSS_DIR}/config/icucross.inc
+	${RUN}${ECHO} > ${.TARGET}
+
+.endif
+
+CHECK_SSP_SKIP=		lib/libicudata.so*
+
+.include "../../mk/pthread.buildlink3.mk"
+
+.if defined(PTHREAD_TYPE) && ${PTHREAD_TYPE} != "native"
+CONFIGURE_ARGS+=	--disable-threads
+.endif
+
+.include "../../mk/compiler.mk"
+
+# from ICU_CHECK_MH_FRAG in source/acinclude.m4
+.if ${OPSYS} == "SunOS"
+.  if ${PKGSRC_COMPILER:Mclang} || ${PKGSRC_COMPILER:Mgcc}
+PLIST_SUBST+=		MH_NAME=mh-solaris-gcc
+.  else
+PLIST_SUBST+=		MH_NAME=mh-solaris
+.  endif
+.  if ${CC_VERSION:Mgcc-4.[6-9].*}
+BUILDLINK_TRANSFORM+=	rm:-D__STDC__=0
+.  endif
+BUILDLINK_TRANSFORM+=	rm:-ansi
+.elif ${MACHINE_PLATFORM:MLinux-*-alpha}
+.  if ${CC_VERSION:Mgcc*}
+PLIST_SUBST+=		MH_NAME=mh-alpha-linux-gcc
+.  else
+PLIST_SUBST+=		MH_NAME=mh-alpha-linux-cc
+.  endif
+.elif ${MACHINE_PLATFORM:MLinux-*-powerpc*}
+.  if ${CC_VERSION:Mgcc*}
+PLIST_SUBST+=		MH_NAME=mh-linux
+.  else
+PLIST_SUBST+=		MH_NAME=mh-linux-va
+.  endif
+.elif ${OPSYS} == "Linux"
+PLIST_SUBST+=		MH_NAME=mh-linux
+.elif ${OPSYS} == "Cygwin"
+PLIST_SUBST+=		MH_NAME=mh-cygwin
+.elif ${OPSYS:M*BSD*} || ${OPSYS} == "DragonFly"
+PLIST_SUBST+=		MH_NAME=mh-bsd-gcc
+.elif ${OPSYS} == "AIX"
+.  if ${CC_VERSION:Mgcc*}
+PLIST_SUBST+=		MH_NAME=mh-aix-gcc
+.  else
+PLIST_SUBST+=		MH_NAME=mh-aix-va
+.  endif
+.elif ${OPSYS} == "HPUX"
+.  if ${CC_VERSION:Mgcc*}
+PLIST_SUBST+=		MH_NAME=mh-hpux-gcc
+.  else
+PLIST_SUBST+=		MH_NAME=mh-hpux-acc
+.  endif
+.elif ${OPSYS} == "Darwin"
+PLIST_SUBST+=		MH_NAME=mh-darwin
+.elif ${OPSYS} == "Haiku"
+PLIST_SUBST+=		MH_NAME=mh-haiku
+.elif ${OPSYS} == "IRIX"
+PLIST_SUBST+=		MH_NAME=mh-irix
+.elif ${OPSYS} == "Cygwin"
+PLIST_SUBST+=		MH_NAME=mh-cygwin
+.elif ${OS_VARIANT} == "SCOOSR5"
+PLIST_SUBST+=		MH_NAME=mh-scoosr5
+.elif ${OPSYS} == "OSF1"
+PLIST_SUBST+=		MH_NAME=mh-alpha-osf
+.elif ${OPSYS} == "QNX"
+PLIST_SUBST+=		MH_NAME=mh-qnx
+.else
+# For unknown systems, set the filename to mh-unknown so that the user
+# gets a warning about missing files.
+PLIST_SUBST+=		MH_NAME=mh-unknown
+.endif
+
+PKGCONFIG_OVERRIDE+=		config/icu*.pc
+PKGCONFIG_OVERRIDE_STAGE=	post-build
+
+REPLACE_SH=	config/icu-config-top
+
+# work around ICU-20533 (build failure on big endian machines)
+post-configure:
+	${MKDIR} ${WRKSRC}/data/out
+
+.if ${OPSYS} == "Cygwin"
+INSTALL_UNSTRIPPED=	yes
+SO_MAJOR=		${PKGVERSION_NOREV:R}
+.  for l in data i18n io le lx test tu uc
+GENERATE_PLIST+=	${ECHO} bin/cygicu${l}${SO_MAJOR}.dll;
+GENERATE_PLIST+=	${ECHO} lib/libicu${l}${SO_MAJOR}.dll.a;
+.  endfor
+
+post-install:
+	mv ${DESTDIR}${PREFIX}/lib/cygicu*.dll ${DESTDIR}${PREFIX}/bin/
+.  for l in data i18n io le lx test tu uc
+	${LN} -s libicu${l}${SO_MAJOR}.dll.a ${DESTDIR}${PREFIX}/lib/libicu${l}.dll.a
+.  endfor
+
+SUBST_CLASSES+=		icu-config
+SUBST_STAGE.icu-config=	post-install
+SUBST_FILES.icu-config=	${DESTDIR}${PREFIX}/bin/icu-config
+SUBST_SED.icu-config+=	-e '/^ICUUC_FILE=/ s/libdir/bindir/'
+SUBST_SED.icu-config+=	-e 's/l$${LIBICU}/l$${ICUPREFIX}/g'
+SUBST_SED.icu-config+=	-e '/l$${ICUPREFIX}/ s/$${ICULIBSUFFIX_VERSION}//g'
+.endif
+
+.include "../../mk/atomic64.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/icu/PLIST b/icu/PLIST
new file mode 100644
index 0000000000..a539aa3cf7
--- /dev/null
+++ b/icu/PLIST
@@ -0,0 +1,273 @@
+@comment $NetBSD: PLIST,v 1.61 2025/04/17 21:32:21 wiz Exp $
+bin/derb
+bin/genbrk
+bin/gencfu
+bin/gencnval
+bin/gendict
+bin/genrb
+bin/icu-config
+bin/icuexportdata
+bin/icuinfo
+bin/makeconv
+bin/pkgdata
+bin/uconv
+include/unicode/alphaindex.h
+include/unicode/appendable.h
+include/unicode/basictz.h
+include/unicode/brkiter.h
+include/unicode/bytestream.h
+include/unicode/bytestrie.h
+include/unicode/bytestriebuilder.h
+include/unicode/calendar.h
+include/unicode/caniter.h
+include/unicode/casemap.h
+include/unicode/char16ptr.h
+include/unicode/chariter.h
+include/unicode/choicfmt.h
+include/unicode/coleitr.h
+include/unicode/coll.h
+include/unicode/compactdecimalformat.h
+include/unicode/curramt.h
+include/unicode/currpinf.h
+include/unicode/currunit.h
+include/unicode/datefmt.h
+include/unicode/dbbi.h
+include/unicode/dcfmtsym.h
+include/unicode/decimfmt.h
+include/unicode/displayoptions.h
+include/unicode/docmain.h
+include/unicode/dtfmtsym.h
+include/unicode/dtintrv.h
+include/unicode/dtitvfmt.h
+include/unicode/dtitvinf.h
+include/unicode/dtptngen.h
+include/unicode/dtrule.h
+include/unicode/edits.h
+include/unicode/enumset.h
+include/unicode/errorcode.h
+include/unicode/fieldpos.h
+include/unicode/filteredbrk.h
+include/unicode/fmtable.h
+include/unicode/format.h
+include/unicode/formattednumber.h
+include/unicode/formattedvalue.h
+include/unicode/fpositer.h
+include/unicode/gender.h
+include/unicode/gregocal.h
+include/unicode/icudataver.h
+include/unicode/icuplug.h
+include/unicode/idna.h
+include/unicode/listformatter.h
+include/unicode/localebuilder.h
+include/unicode/localematcher.h
+include/unicode/localpointer.h
+include/unicode/locdspnm.h
+include/unicode/locid.h
+include/unicode/measfmt.h
+include/unicode/measunit.h
+include/unicode/measure.h
+include/unicode/messageformat2.h
+include/unicode/messageformat2_arguments.h
+include/unicode/messageformat2_data_model.h
+include/unicode/messageformat2_data_model_names.h
+include/unicode/messageformat2_formattable.h
+include/unicode/messageformat2_function_registry.h
+include/unicode/messagepattern.h
+include/unicode/msgfmt.h
+include/unicode/normalizer2.h
+include/unicode/normlzr.h
+include/unicode/nounit.h
+include/unicode/numberformatter.h
+include/unicode/numberrangeformatter.h
+include/unicode/numfmt.h
+include/unicode/numsys.h
+include/unicode/parseerr.h
+include/unicode/parsepos.h
+include/unicode/platform.h
+include/unicode/plurfmt.h
+include/unicode/plurrule.h
+include/unicode/ptypes.h
+include/unicode/putil.h
+include/unicode/rbbi.h
+include/unicode/rbnf.h
+include/unicode/rbtz.h
+include/unicode/regex.h
+include/unicode/region.h
+include/unicode/reldatefmt.h
+include/unicode/rep.h
+include/unicode/resbund.h
+include/unicode/schriter.h
+include/unicode/scientificnumberformatter.h
+include/unicode/search.h
+include/unicode/selfmt.h
+include/unicode/simpleformatter.h
+include/unicode/simplenumberformatter.h
+include/unicode/simpletz.h
+include/unicode/smpdtfmt.h
+include/unicode/sortkey.h
+include/unicode/std_string.h
+include/unicode/strenum.h
+include/unicode/stringoptions.h
+include/unicode/stringpiece.h
+include/unicode/stringtriebuilder.h
+include/unicode/stsearch.h
+include/unicode/symtable.h
+include/unicode/tblcoll.h
+include/unicode/timezone.h
+include/unicode/tmunit.h
+include/unicode/tmutamt.h
+include/unicode/tmutfmt.h
+include/unicode/translit.h
+include/unicode/tzfmt.h
+include/unicode/tznames.h
+include/unicode/tzrule.h
+include/unicode/tztrans.h
+include/unicode/ubidi.h
+include/unicode/ubiditransform.h
+include/unicode/ubrk.h
+include/unicode/ucal.h
+include/unicode/ucasemap.h
+include/unicode/ucat.h
+include/unicode/uchar.h
+include/unicode/ucharstrie.h
+include/unicode/ucharstriebuilder.h
+include/unicode/uchriter.h
+include/unicode/uclean.h
+include/unicode/ucnv.h
+include/unicode/ucnv_cb.h
+include/unicode/ucnv_err.h
+include/unicode/ucnvsel.h
+include/unicode/ucol.h
+include/unicode/ucoleitr.h
+include/unicode/uconfig.h
+include/unicode/ucpmap.h
+include/unicode/ucptrie.h
+include/unicode/ucsdet.h
+include/unicode/ucurr.h
+include/unicode/udat.h
+include/unicode/udata.h
+include/unicode/udateintervalformat.h
+include/unicode/udatpg.h
+include/unicode/udisplaycontext.h
+include/unicode/udisplayoptions.h
+include/unicode/uenum.h
+include/unicode/ufieldpositer.h
+include/unicode/uformattable.h
+include/unicode/uformattednumber.h
+include/unicode/uformattedvalue.h
+include/unicode/ugender.h
+include/unicode/uidna.h
+include/unicode/uiter.h
+include/unicode/uldnames.h
+include/unicode/ulistformatter.h
+include/unicode/uloc.h
+include/unicode/ulocale.h
+include/unicode/ulocbuilder.h
+include/unicode/ulocdata.h
+include/unicode/umachine.h
+include/unicode/umisc.h
+include/unicode/umsg.h
+include/unicode/umutablecptrie.h
+include/unicode/unifilt.h
+include/unicode/unifunct.h
+include/unicode/unimatch.h
+include/unicode/unirepl.h
+include/unicode/uniset.h
+include/unicode/unistr.h
+include/unicode/unorm.h
+include/unicode/unorm2.h
+include/unicode/unum.h
+include/unicode/unumberformatter.h
+include/unicode/unumberoptions.h
+include/unicode/unumberrangeformatter.h
+include/unicode/unumsys.h
+include/unicode/uobject.h
+include/unicode/upluralrules.h
+include/unicode/uregex.h
+include/unicode/uregion.h
+include/unicode/ureldatefmt.h
+include/unicode/urename.h
+include/unicode/urep.h
+include/unicode/ures.h
+include/unicode/uscript.h
+include/unicode/usearch.h
+include/unicode/uset.h
+include/unicode/usetiter.h
+include/unicode/ushape.h
+include/unicode/usimplenumberformatter.h
+include/unicode/uspoof.h
+include/unicode/usprep.h
+include/unicode/ustdio.h
+include/unicode/ustream.h
+include/unicode/ustring.h
+include/unicode/ustringtrie.h
+include/unicode/utext.h
+include/unicode/utf.h
+include/unicode/utf16.h
+include/unicode/utf32.h
+include/unicode/utf8.h
+include/unicode/utf_old.h
+include/unicode/utmscale.h
+include/unicode/utrace.h
+include/unicode/utrans.h
+include/unicode/utypes.h
+include/unicode/uvernum.h
+include/unicode/uversion.h
+include/unicode/vtzone.h
+lib/icu/${PKGVERSION}/Makefile.inc
+lib/icu/${PKGVERSION}/pkgdata.inc
+lib/icu/Makefile.inc
+lib/icu/current
+lib/icu/pkgdata.inc
+lib/libicudata.a
+lib/libicudata.so
+lib/libicudata.so.${PKGVERSION}
+lib/libicudata.so.77
+lib/libicui18n.a
+lib/libicui18n.so
+lib/libicui18n.so.${PKGVERSION}
+lib/libicui18n.so.77
+lib/libicuio.a
+lib/libicuio.so
+lib/libicuio.so.${PKGVERSION}
+lib/libicuio.so.77
+lib/libicutest.a
+lib/libicutest.so
+lib/libicutest.so.${PKGVERSION}
+lib/libicutest.so.77
+lib/libicutu.a
+lib/libicutu.so
+lib/libicutu.so.${PKGVERSION}
+lib/libicutu.so.77
+lib/libicuuc.a
+lib/libicuuc.so
+lib/libicuuc.so.${PKGVERSION}
+lib/libicuuc.so.77
+lib/pkgconfig/icu-i18n.pc
+lib/pkgconfig/icu-io.pc
+lib/pkgconfig/icu-uc.pc
+man/man1/derb.1
+man/man1/genbrk.1
+man/man1/gencfu.1
+man/man1/gencnval.1
+man/man1/gendict.1
+man/man1/genrb.1
+man/man1/icu-config.1
+man/man1/icuexportdata.1
+man/man1/makeconv.1
+man/man1/pkgdata.1
+man/man1/uconv.1
+man/man8/genccode.8
+man/man8/gencmn.8
+man/man8/gensprep.8
+man/man8/icupkg.8
+sbin/escapesrc
+sbin/genccode
+sbin/gencmn
+sbin/gennorm2
+sbin/gensprep
+sbin/icupkg
+share/icu/${PKGVERSION}/LICENSE
+share/icu/${PKGVERSION}/config/${MH_NAME}
+share/icu/${PKGVERSION}/install-sh
+share/icu/${PKGVERSION}/mkinstalldirs
diff --git a/icu/TODO b/icu/TODO
new file mode 100644
index 0000000000..705197a0bd
--- /dev/null
+++ b/icu/TODO
@@ -0,0 +1,2 @@
+../../bin/genrb: can not initialize ICU.  status = U_INVALID_FORMAT_ERROR
+../../bin/genrb: can not initialize ICU.  status = U_INVALID_FORMAT_ERROR
diff --git a/icu/buildlink3.mk b/icu/buildlink3.mk
new file mode 100644
index 0000000000..5f6818648c
--- /dev/null
+++ b/icu/buildlink3.mk
@@ -0,0 +1,15 @@
+# $NetBSD: buildlink3.mk,v 1.57 2025/04/17 21:49:41 wiz Exp $
+
+BUILDLINK_TREE+=	icu
+
+.if !defined(ICU_BUILDLINK3_MK)
+ICU_BUILDLINK3_MK:=
+
+BUILDLINK_API_DEPENDS.icu+=	icu>=3.4
+BUILDLINK_ABI_DEPENDS.icu+=	icu>=77.1
+BUILDLINK_PKGSRCDIR.icu?=	../../textproc/icu
+
+GCC_REQD+=		4.9
+.endif # ICU_BUILDLINK3_MK
+
+BUILDLINK_TREE+=	-icu
diff --git a/icu/distinfo b/icu/distinfo
new file mode 100644
index 0000000000..b410ce38b9
--- /dev/null
+++ b/icu/distinfo
@@ -0,0 +1,22 @@
+$NetBSD: distinfo,v 1.110 2025/04/17 21:32:21 wiz Exp $
+
+BLAKE2s (icu4c-78.1-sources.tgz) = 3a307d2b1bbea81b488d43b53b6af8351b5367d31d450b0c0b1aa9109cf733a1
+SHA512 (icu4c-78.1-sources.tgz) = c366398fdb50afc6355a8c45ed1d68a18eaa5f07a5d1c4555becbcfb9d4073e65ebe1e9caf24b93779b11b36cd813c98dd59e4b19f008851f25c7262811c112d
+Size (icu4c-78.1-sources.tgz) = 27979449 bytes
+SHA1 (patch-acinclude.m4) = 64311d903a85c868e3a87502ea58b916089afb70
+SHA1 (patch-common_putil.cpp) = cc867aaef753c23ff12db019e41836c0dd5ac6d1
+SHA1 (patch-common_ubidiimp.h) = 180eb1fe1069c393ddf1deb46da00f466d8438e8
+SHA1 (patch-common_umutex.h) = b22b7c02b4645a87f71d54885d858d0cf9005988
+SHA1 (patch-common_unicode_platform.h) = 8b7b8bcf6f5185225a1ca516ac212a495f7b47e8
+SHA1 (patch-common_unicode_ptypes.h) = b0fd74429b217580d1957c241b9c7a187a00f8c3
+SHA1 (patch-common_uposixdefs.h) = 2900a3747b49bcf1a81dbb5a20692c120f28cb04
+SHA1 (patch-config_Makefile.inc.in) = e7cee161315321d2580074054d87714b55319886
+SHA1 (patch-config_icu-config-bottom) = 168b89ee9180d4ae545125866ee91eb004010501
+SHA1 (patch-config_mh-darwin) = 4fd2c664b23078692b61557ebb66693712d333cd
+SHA1 (patch-config_mh-scoosr5) = 47703dcc184f58c0382da3225f849424ab74d472
+SHA1 (patch-configure) = d490321c93d67f7d3a70319ce8a86ca36fd3825c
+SHA1 (patch-configure.ac) = 86f4b142afddb9784f2aec98f147ee29217b6124
+SHA1 (patch-i18n_double-conversion-utils.h) = 9bee115bb9ddc597607e30f95050de7b21751fca
+SHA1 (patch-icudefs.mk.in) = 15be482cf7541c9b518b8bfb05865ac994313cb7
+SHA1 (patch-runConfigureICU) = 6aa0de86506440aeb13005959e9014a53ed63036
+SHA1 (patch-tools-toolutil-pkg_genc.cpp) = 3cbcf3387d6a39315b26a3e2a2ffb715507e9110
diff --git a/icu/log b/icu/log
new file mode 100644
index 0000000000..aed34ead57
--- /dev/null
+++ b/icu/log
@@ -0,0 +1,14 @@
+We are pleased to announce the release of Unicode® ICU 78. It
+updates to Unicode 17, including new characters and scripts,
+emoji, collation & IDNA changes, and corresponding APIs and
+implementations.
+
+It also updates to CLDR 48 locale data with new locales, and various
+additions and corrections.
+
+In C++, there is a new set of APIs for Unicode string (UTF-8/16/32)
+code point iteration that works seamlessly with modern C++ iterators
+and ranges.
+
+The C++ implementation of MessageFormat 2.0 is at CLDR 47 level
+and remains in technology preview.
diff --git a/icu/patches/patch-acinclude.m4 b/icu/patches/patch-acinclude.m4
new file mode 100644
index 0000000000..83d439ad19
--- /dev/null
+++ b/icu/patches/patch-acinclude.m4
@@ -0,0 +1,14 @@
+$NetBSD: patch-acinclude.m4,v 1.5 2025/03/30 21:10:47 wiz Exp $
+
+Solaris seems to need -std=c99 with recent pkgsrc so keep it.
+
+--- acinclude.m4.orig	Fri Mar 27 21:17:48 2015
++++ acinclude.m4
+@@ -82,6 +82,7 @@ x86_64-*-cygwin) 
+ *-dec-osf*) icu_cv_host_frag=mh-alpha-osf ;;
+ *-*-nto*)	icu_cv_host_frag=mh-qnx ;;
+ *-ncr-*)	icu_cv_host_frag=mh-mpras ;;
++*-*-sco3.2v5*)	icu_cv_host_frag=mh-scoosr5 ;;
+ *) 		icu_cv_host_frag=mh-unknown ;;
+ esac
+ 		]
diff --git a/icu/patches/patch-common_putil.cpp b/icu/patches/patch-common_putil.cpp
new file mode 100644
index 0000000000..05ad654c42
--- /dev/null
+++ b/icu/patches/patch-common_putil.cpp
@@ -0,0 +1,19 @@
+$NetBSD: patch-common_putil.cpp,v 1.4 2020/11/05 08:58:41 ryoon Exp $
+
+--- common/putil.cpp.orig	2020-10-28 21:21:12.000000000 +0000
++++ common/putil.cpp
+@@ -128,6 +128,14 @@
+ 
+ 
+ /*
++ * Mac OS X 10.4 doesn't use its localtime_r() declaration in <time.h> if either _ANSI_SOURCE or _POSIX_C_SOURCE is #defined.
++ */
++#if defined(U_TZNAME) && U_PLATFORM_IS_DARWIN_BASED && __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ == 1040 \
++	&& (defined(_ANSI_SOURCE) || defined(_POSIX_C_SOURCE))
++U_CFUNC struct tm *localtime_r(const time_t *, struct tm *);
++#endif
++
++/*
+  * Only include langinfo.h if we have a way to get the codeset. If we later
+  * depend on more feature, we can test on U_HAVE_NL_LANGINFO.
+  *
diff --git a/icu/patches/patch-common_ubidiimp.h b/icu/patches/patch-common_ubidiimp.h
new file mode 100644
index 0000000000..0b28c6058e
--- /dev/null
+++ b/icu/patches/patch-common_ubidiimp.h
@@ -0,0 +1,18 @@
+$NetBSD: patch-common_ubidiimp.h,v 1.2 2020/11/05 08:58:41 ryoon Exp $
+
+Avoid sys/regset.h pollution on SunOS.
+
+--- common/ubidiimp.h.orig	2020-10-28 21:21:12.000000000 +0000
++++ common/ubidiimp.h
+@@ -24,6 +24,11 @@
+ #include "unicode/uchar.h"
+ #include "ubidi_props.h"
+ 
++#ifdef __sun
++#undef CS
++#undef ES
++#endif
++
+ /* miscellaneous definitions ---------------------------------------------- */
+ 
+ // ICU-20853=ICU-20935 Solaris #defines CS and ES in sys/regset.h
diff --git a/icu/patches/patch-common_umutex.h b/icu/patches/patch-common_umutex.h
new file mode 100644
index 0000000000..e82ddc4509
--- /dev/null
+++ b/icu/patches/patch-common_umutex.h
@@ -0,0 +1,47 @@
+$NetBSD: patch-common_umutex.h,v 1.2 2019/04/03 00:13:00 ryoon Exp $
+
+* Add NetBSD MI atomic_ops(3) support
+
+--- common/umutex.h.orig	2019-03-27 18:47:14.000000000 +0000
++++ common/umutex.h
+@@ -60,6 +60,31 @@ template struct std::atomic<int32_t>;
+ 
+ U_NAMESPACE_BEGIN
+ 
++#if U_HAVE_NETBSD_ATOMIC_OPS
++/*
++ * NetBSD MI atomic_ops(3)
++ */
++#include <sys/atomic.h>
++typedef volatile uint32_t u_atomic_int32_t;
++#define ATOMIC_INT32_T_INITIALIZER(val) val
++
++inline int32_t umtx_loadAcquire(u_atomic_int32_t &var) {
++    return atomic_cas_32(&var, 0, 0);
++}
++
++inline void umtx_storeRelease(u_atomic_int32_t &var, int32_t val) {
++    atomic_swap_32(&var, val);
++}
++
++inline int32_t umtx_atomic_inc(u_atomic_int32_t *p) {
++    return atomic_inc_32_nv(p);
++}
++
++inline int32_t umtx_atomic_dec(u_atomic_int32_t *p) {
++    return atomic_dec_32_nv(p);
++}
++#else
++
+ /****************************************************************************
+  *
+  *   Low Level Atomic Operations, ICU wrappers for.
+@@ -84,7 +109,7 @@ inline int32_t umtx_atomic_inc(u_atomic_
+ inline int32_t umtx_atomic_dec(u_atomic_int32_t *var) {
+     return var->fetch_sub(1) - 1;
+ }
+-
++#endif
+ 
+ /*************************************************************************************************
+  *
diff --git a/icu/patches/patch-common_unicode_platform.h b/icu/patches/patch-common_unicode_platform.h
new file mode 100644
index 0000000000..d584c3724c
--- /dev/null
+++ b/icu/patches/patch-common_unicode_platform.h
@@ -0,0 +1,32 @@
+$NetBSD: patch-common_unicode_platform.h,v 1.7 2015/10/09 23:15:34 ryoon Exp $
+
+--- common/unicode/platform.h.orig	2015-10-08 03:53:34.000000000 +0000
++++ common/unicode/platform.h
+@@ -159,7 +159,7 @@
+ #   else
+ #       define U_PLATFORM U_PF_DARWIN
+ #   endif
+-#elif defined(BSD) || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__MirBSD__)
++#elif defined(BSD) || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__MirBSD__) || defined(__DragonFly__)
+ #   if defined(__FreeBSD__)
+ #       include <sys/endian.h>
+ #   endif
+@@ -388,6 +388,18 @@
+ #   define U_IS_BIG_ENDIAN 1
+ #elif defined(__LITTLE_ENDIAN__) || defined(_LITTLE_ENDIAN)
+ #   define U_IS_BIG_ENDIAN 0
++#elif U_PLATFORM == U_PF_BSD
++#include <sys/types.h>
++#if defined(__OpenBSD__)
++#include <machine/endian.h>
++#else
++#include <sys/endian.h>
++#endif
++#if _BYTE_ORDER == _LITTLE_ENDIAN
++#   define U_IS_BIG_ENDIAN 0
++#else
++#   define U_IS_BIG_ENDIAN 1
++#endif
+ #elif U_PLATFORM == U_PF_OS390 || U_PLATFORM == U_PF_OS400 || defined(__s390__) || defined(__s390x__)
+     /* These platforms do not appear to predefine any endianness macros. */
+ #   define U_IS_BIG_ENDIAN 1
diff --git a/icu/patches/patch-common_unicode_ptypes.h b/icu/patches/patch-common_unicode_ptypes.h
new file mode 100644
index 0000000000..1534a963d8
--- /dev/null
+++ b/icu/patches/patch-common_unicode_ptypes.h
@@ -0,0 +1,15 @@
+$NetBSD: patch-common_unicode_ptypes.h,v 1.1 2024/05/29 15:38:34 adam Exp $
+
+Fix build: it seems like uchar.h in only available in glibc.
+
+--- common/unicode/ptypes.h.orig	2024-04-16 21:08:53.000000000 +0000
++++ common/unicode/ptypes.h
+@@ -56,7 +56,7 @@
+ // implementations (looking at you, Apple, spring 2024) actually do this, so
+ // ICU4C must detect and deal with that.
+ #if !defined(__cplusplus) && !defined(U_IN_DOXYGEN)
+-#   if U_HAVE_CHAR16_T
++#   if U_HAVE_CHAR16_T && U_PLATFORM_IS_LINUX_BASED
+ #       include <uchar.h>
+ #   else
+         typedef uint16_t char16_t;
diff --git a/icu/patches/patch-common_uposixdefs.h b/icu/patches/patch-common_uposixdefs.h
new file mode 100644
index 0000000000..643c1d975a
--- /dev/null
+++ b/icu/patches/patch-common_uposixdefs.h
@@ -0,0 +1,30 @@
+$NetBSD: patch-common_uposixdefs.h,v 1.7 2023/04/19 08:06:31 adam Exp $
+
+C99 and related define overrides.
+Do not play _XOPEN_SOURCE games on NetBSD, as it breaks at least gcc 6.4 on NetBSD-8.0
+
+--- common/uposixdefs.h.orig	2023-04-13 21:41:15.000000000 +0000
++++ common/uposixdefs.h
+@@ -44,8 +44,10 @@
+      * and define _XOPEN_SOURCE to different values depending on __STDC_VERSION__.
+      * In C++ source code (e.g., putil.cpp), __STDC_VERSION__ is not defined at all.
+      */
++#if !defined(_SCO_DS) && !defined(__NetBSD__)
+ #   define _XOPEN_SOURCE 600
+ #endif
++#endif
+ 
+ /*
+  * Make sure things like realpath and such functions work.
+@@ -54,9 +56,11 @@
+  *
+  * z/OS needs this definition for timeval and to get usleep.
+  */
++#if !defined(__sun) && !defined(_SCO_DS)
+ #if !defined(_XOPEN_SOURCE_EXTENDED) && defined(__TOS_MVS__)
+ #   define _XOPEN_SOURCE_EXTENDED 1
+ #endif
++#endif
+ 
+ /**
+  * Solaris says:
diff --git a/icu/patches/patch-config_Makefile.inc.in b/icu/patches/patch-config_Makefile.inc.in
new file mode 100644
index 0000000000..5553f8d552
--- /dev/null
+++ b/icu/patches/patch-config_Makefile.inc.in
@@ -0,0 +1,13 @@
+$NetBSD: patch-config_Makefile.inc.in,v 1.1 2017/04/22 20:11:45 adam Exp $
+
+--- config/Makefile.inc.in.orig	2010-12-07 11:22:10.000000000 +0000
++++ config/Makefile.inc.in
+@@ -44,7 +44,7 @@ PACKAGE = @PACKAGE@
+ LIBICU = lib$(ICUPREFIX)
+ 
+ # Static library prefix and file extension
+-STATIC_PREFIX = s
++STATIC_PREFIX =
+ LIBSICU = lib$(STATIC_PREFIX)$(ICUPREFIX)
+ A = a
+ 
diff --git a/icu/patches/patch-config_icu-config-bottom b/icu/patches/patch-config_icu-config-bottom
new file mode 100644
index 0000000000..146a2bf23f
--- /dev/null
+++ b/icu/patches/patch-config_icu-config-bottom
@@ -0,0 +1,18 @@
+$NetBSD: patch-config_icu-config-bottom,v 1.3 2013/10/19 08:47:36 adam Exp $
+
+--- config/icu-config-bottom.orig	2013-10-04 20:50:00.000000000 +0000
++++ config/icu-config-bottom
+@@ -355,11 +355,11 @@ do
+ 	    ;;
+ 
+ 	--version)
+-	    echo $ECHO_N $VERSION
++	    echo $ECHO_N $VERSION${ECHO_C}
+ 	    ;;
+ 
+ 	--unicode-version)
+-	    echo $ECHO_N $UNICODE_VERSION
++	    echo $ECHO_N $UNICODE_VERSION${ECHO_C}
+ 	    ;;
+ 
+ 	--host)
diff --git a/icu/patches/patch-config_mh-darwin b/icu/patches/patch-config_mh-darwin
new file mode 100644
index 0000000000..4a7095b23d
--- /dev/null
+++ b/icu/patches/patch-config_mh-darwin
@@ -0,0 +1,18 @@
+$NetBSD: patch-config_mh-darwin,v 1.3 2019/04/24 07:59:36 adam Exp $
+
+On Darwin, -install_name must be a full path.
+
+--- config/mh-darwin.orig	2019-04-24 07:37:10.000000000 +0000
++++ config/mh-darwin
+@@ -30,11 +30,7 @@ SHLIB.c=	$(CC) -dynamiclib -dynamic $(CF
+ SHLIB.cc=	$(CXX) -dynamiclib -dynamic $(CXXFLAGS) $(LDFLAGS) $(LD_SOOPTIONS)
+ 
+ ## Compiler switches to embed a library name and version information
+-ifeq ($(ENABLE_RPATH),YES)
+ LD_SONAME = -Wl,-compatibility_version -Wl,$(SO_TARGET_VERSION_MAJOR) -Wl,-current_version -Wl,$(SO_TARGET_VERSION) -install_name $(libdir)/$(notdir $(MIDDLE_SO_TARGET))
+-else
+-LD_SONAME = -Wl,-compatibility_version -Wl,$(SO_TARGET_VERSION_MAJOR) -Wl,-current_version -Wl,$(SO_TARGET_VERSION) -install_name $(notdir $(MIDDLE_SO_TARGET)) $(PKGDATA_TRAILING_SPACE)
+-endif
+ 
+ ## Compiler switch to embed a runtime search path
+ LD_RPATH=
diff --git a/icu/patches/patch-config_mh-scoosr5 b/icu/patches/patch-config_mh-scoosr5
new file mode 100644
index 0000000000..ff31707998
--- /dev/null
+++ b/icu/patches/patch-config_mh-scoosr5
@@ -0,0 +1,77 @@
+$NetBSD: patch-config_mh-scoosr5,v 1.1 2014/07/18 10:28:11 ryoon Exp $
+
+--- config/mh-scoosr5.orig	2014-03-07 11:43:35.000000000 +0000
++++ config/mh-scoosr5
+@@ -0,0 +1,72 @@
++## -*-makefile-*-
++## SCO OpenServer 5.0.7/3.2-specific setup using gcc
++## Copyright (c) 1999-2010, International Business Machines Corporation and
++## others. All Rights Reserved.
++
++## Flags for position independent code
++SHAREDLIBCFLAGS = -fPIC
++SHAREDLIBCXXFLAGS = -fPIC
++SHAREDLIBCPPFLAGS = -DPIC
++
++## Commands to generate dependency files
++GEN_DEPS.c= 	$(CC) -E -MM $(DEFS) $(CPPFLAGS) $(CFLAGS)
++GEN_DEPS.cc=	$(CXX) -E -MM $(DEFS) $(CPPFLAGS) $(CXXFLAGS)
++
++## These are the library specific LDFLAGS
++LDFLAGSICUDT=-nodefaultlibs -nostdlib
++
++## Additional flags when building libraries and with threads
++THREADSCPPFLAGS = -D_REENTRANT
++
++## Compiler switch to embed a runtime search path
++LD_RPATH=       -R'$$'ORIGIN 
++LD_RPATH_PRE=   -R
++
++## Compiler switch to embed a library name
++LD_SONAME = -h $(notdir $(MIDDLE_SO_TARGET))
++
++## Shared library options
++LD_SOOPTIONS= -Wl,-Bsymbolic
++
++## Shared object suffix
++SO=		so
++## Non-shared intermediate object suffix
++STATIC_O = ao
++
++## Compilation rules
++%.$(STATIC_O): $(srcdir)/%.c
++	$(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $<
++%.o: $(srcdir)/%.c
++	$(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $<
++
++%.$(STATIC_O): $(srcdir)/%.cpp
++	$(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $<
++%.o: $(srcdir)/%.cpp
++	$(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $<
++
++
++## Dependency rules
++%.d : $(srcdir)/%.c
++	@echo "generating dependency information for $<"
++	@$(SHELL) -ec '$(GEN_DEPS.c) $< \
++		| sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \
++		[ -s $@ ] || rm -f $@'
++
++%.d : $(srcdir)/%.cpp
++	@echo "generating dependency information for $<"
++	@$(SHELL) -ec '$(GEN_DEPS.cc) $< \
++		| sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \
++		[ -s $@ ] || rm -f $@'
++
++## Versioned libraries rules
++
++%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION)
++	$(RM) $@ && ln -s ${<F} $@
++%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR)
++	$(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@
++
++## Remove shared library 's'
++STATIC_PREFIX_WHEN_USED = 
++STATIC_PREFIX = 
++
++## End SCO OpenServer 5.0.7/3.2-specific setup
diff --git a/icu/patches/patch-configure b/icu/patches/patch-configure
new file mode 100644
index 0000000000..af3c6adb80
--- /dev/null
+++ b/icu/patches/patch-configure
@@ -0,0 +1,45 @@
+$NetBSD: patch-configure,v 1.15 2025/03/30 21:10:47 wiz Exp $
+
+Portability fix.
+Solaris seems to need -std=c99 with recent pkgsrc so keep it.
+
+--- configure.orig	2024-10-24 18:24:00.000000000 +0000
++++ configure
+@@ -5884,6 +5884,7 @@ powerpc*-apple-darwin*)	icu_cv_host_frag
+ *-dec-osf*) icu_cv_host_frag=mh-alpha-osf ;;
+ *-*-nto*)	icu_cv_host_frag=mh-qnx ;;
+ *-ncr-*)	icu_cv_host_frag=mh-mpras ;;
++-*-sco3.2v5*)	icu_cv_host_frag=mh-scoosr5 ;;
+ *) 		icu_cv_host_frag=mh-unknown ;;
+ esac
+ 
+@@ -6511,6 +6512,29 @@ if test "x$plugins" = "xtrue"; then
+ fi
+ 
+ 
++# check if sys/atomic.h is present.
++for ac_header in sys/atomic.h
++do :
++  ac_fn_c_check_header_mongrel "$LINENO" "sys/atomic.h" "ac_cv_header_sys_atomic_h" "$ac_includes_default"
++if test "x$ac_cv_header_sys_atomic_h" = xyes; then :
++  cat >>confdefs.h <<_ACEOF
++#define HAVE_SYS_ATOMIC_H 1
++_ACEOF
++
++fi
++
++done
++
++case "${host}" in
++*-netbsd*)
++if test "x$ac_cv_header_sys_atomic_h" = "xyes"; then
++    CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DU_HAVE_NETBSD_ATOMIC_OPS=1";
++fi
++;;
++*)
++;;
++esac
++
+ U_ENABLE_DYLOAD=1
+ enable=yes
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable dynamic loading of plugins. Ignored if plugins disabled." >&5
diff --git a/icu/patches/patch-configure.ac b/icu/patches/patch-configure.ac
new file mode 100644
index 0000000000..9adb334b16
--- /dev/null
+++ b/icu/patches/patch-configure.ac
@@ -0,0 +1,34 @@
+$NetBSD: patch-configure.ac,v 1.10 2025/03/30 21:10:47 wiz Exp $
+
+* Detect NetBSD libatomic
+* test(1) portability fix
+
+--- configure.ac.orig	2024-10-24 18:24:00.000000000 +0000
++++ configure.ac
+@@ -426,6 +426,18 @@ if test "x$plugins" = "xtrue"; then
+ fi
+ 
+ 
++# check if sys/atomic.h is present.
++AC_CHECK_HEADERS([sys/atomic.h])
++case "${host}" in
++*-netbsd*)
++if test "x$ac_cv_header_sys_atomic_h" = "xyes"; then
++    CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DU_HAVE_NETBSD_ATOMIC_OPS=1";
++fi
++;;
++*)
++;;
++esac
++
+ U_ENABLE_DYLOAD=1
+ enable=yes
+ AC_MSG_CHECKING([whether to enable dynamic loading of plugins. Ignored if plugins disabled.])
+@@ -1194,6 +1206,7 @@ case "${host}" in
+ 	*-*-haiku)	platform=U_HAIKU ;;
+ 	*-*-irix*)		platform=U_IRIX ;;
+ 	*-ncr-*)		platform=U_MPRAS ;;
++	*-*-sco3.2v5*)		platform=USCOOSR5 ;;
+ 	*) 		platform=U_UNKNOWN_PLATFORM ;;
+ esac
+ AC_SUBST(ICUDATA_CHAR)
diff --git a/icu/patches/patch-i18n_double-conversion-utils.h b/icu/patches/patch-i18n_double-conversion-utils.h
new file mode 100644
index 0000000000..aff28fca56
--- /dev/null
+++ b/icu/patches/patch-i18n_double-conversion-utils.h
@@ -0,0 +1,15 @@
+$NetBSD: patch-i18n_double-conversion-utils.h,v 1.6 2020/05/07 16:01:33 tsutsui Exp $
+
+Add support for sh3.
+
+--- i18n/double-conversion-utils.h.orig	2020-03-11 18:16:11.000000000 +0000
++++ i18n/double-conversion-utils.h
+@@ -107,7 +107,7 @@ int main(int argc, char** argv) {
+     defined(__powerpc__) || defined(__ppc__) || defined(__ppc64__) || \
+     defined(_POWER) || defined(_ARCH_PPC) || defined(_ARCH_PPC64) || \
+     defined(__sparc__) || defined(__sparc) || defined(__s390__) || \
+-    defined(__SH4__) || defined(__alpha__) || \
++    defined(__SH4__) || defined(__sh__) || defined(__alpha__) || \
+     defined(_MIPS_ARCH_MIPS32R2) || defined(__ARMEB__) ||\
+     defined(__AARCH64EL__) || defined(__aarch64__) || defined(__AARCH64EB__) || \
+     defined(__riscv) || defined(__e2k__) || \
diff --git a/icu/patches/patch-icudefs.mk.in b/icu/patches/patch-icudefs.mk.in
new file mode 100644
index 0000000000..7f50752184
--- /dev/null
+++ b/icu/patches/patch-icudefs.mk.in
@@ -0,0 +1,31 @@
+$NetBSD: patch-icudefs.mk.in,v 1.2 2022/08/05 13:29:17 adam Exp $
+
+Install shared libraries correctly.
+
+--- icudefs.mk.in.orig	2022-04-07 22:41:55.000000000 +0000
++++ icudefs.mk.in
+@@ -213,13 +213,13 @@ LIBICU = $(LIBPREFIX)$(ICUPREFIX)
+ 
+ ## If we can't use the shared libraries, use the static libraries
+ ifneq ($(ENABLE_SHARED),YES)
+-STATIC_PREFIX_WHEN_USED = s
++STATIC_PREFIX_WHEN_USED = 
+ else
+ STATIC_PREFIX_WHEN_USED = 
+ endif
+ 
+ # Static library prefix and file extension
+-STATIC_PREFIX = s
++STATIC_PREFIX =
+ LIBSICU = $(LIBPREFIX)$(STATIC_PREFIX)$(ICUPREFIX)
+ A = a
+ SOBJ = $(SO)
+@@ -231,7 +231,7 @@ RMV = rm -rf
+ # INSTALL-L installs libraries. Override in mh-* file to INSTALL_PROGRAM
+ #           when the library needs to have executable permissions
+ INSTALL-S = $(INSTALL_PROGRAM)
+-INSTALL-L = $(INSTALL_PROGRAM)
++INSTALL-L = ${BSD_INSTALL_LIB}
+ #INSTALL-L = $(INSTALL_DATA)
+ 
+ # Location of the libraries before "make install" is used
diff --git a/icu/patches/patch-runConfigureICU b/icu/patches/patch-runConfigureICU
new file mode 100644
index 0000000000..c30520d4d8
--- /dev/null
+++ b/icu/patches/patch-runConfigureICU
@@ -0,0 +1,15 @@
+$NetBSD: patch-runConfigureICU,v 1.3 2025/03/30 21:10:47 wiz Exp $
+
+Add support for DragonFlyBSD.
+
+--- runConfigureICU.orig	2018-10-01 22:39:56.000000000 +0000
++++ runConfigureICU
+@@ -328,7 +328,7 @@ case $platform in
+         DEBUG_CXXFLAGS='-FS -Zi -MDd'
+         DEBUG_LDFLAGS='-DEBUG'
+         ;;
+-    *BSD)
++    *BSD | DragonFly)
+         THE_OS="BSD"
+         THE_COMP="the GNU C++"
+         DEBUG_CFLAGS='-g -O0'
diff --git a/icu/patches/patch-tools-toolutil-pkg_genc.cpp b/icu/patches/patch-tools-toolutil-pkg_genc.cpp
new file mode 100644
index 0000000000..7798faee60
--- /dev/null
+++ b/icu/patches/patch-tools-toolutil-pkg_genc.cpp
@@ -0,0 +1,16 @@
+$NetBSD: patch-tools-toolutil-pkg_genc.cpp,v 1.1 2017/04/22 20:11:45 adam Exp $
+
+Older assemblers for Darwin (like the one from Xcode 2.5) do not
+have .balign, but they take .align 4 to mean 2^4 = 16 bytes.
+
+--- tools/toolutil/pkg_genc.cpp.orig	2015-03-27 21:10:56.000000000 +0000
++++ tools/toolutil/pkg_genc.cpp
+@@ -139,7 +139,7 @@ static const struct AssemblyType {
+         "#endif\n"
+         "\t.data\n"
+         "\t.const\n"
+-        "\t.balign 16\n"
++        "\t.align 4\n"
+         "_%s:\n\n",
+ 
+         ".long ","",HEX_0X



Home | Main Index | Thread Index | Old Index