[icu] Fix use of fallback install-sh (#53279)

This commit is contained in:
Kai Pastor 2026-08-11 21:05:37 +02:00 committed by GitHub
parent 73e69cfc24
commit 1c67b4d422
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 47 additions and 2 deletions

View File

@ -0,0 +1,39 @@
diff --git a/source/Makefile.in b/source/Makefile.in
index 9e15b6a016..53330a3921 100644
--- a/source/Makefile.in
+++ b/source/Makefile.in
@@ -189,7 +189,10 @@ install-icu: $(INSTALLED_BUILT_FILES)
$(INSTALL_SCRIPT) $(top_srcdir)/mkinstalldirs $(DESTDIR)$(pkgdatadir)/mkinstalldirs
$(INSTALL_SCRIPT) $(top_srcdir)/install-sh $(DESTDIR)$(pkgdatadir)/install-sh
@$(MKINSTALLDIRS) $(DESTDIR)$(libdir)/pkgconfig
- $(INSTALL_DATA) $(ALL_PKGCONFIG_FILES) $(DESTDIR)$(libdir)/pkgconfig/
+ # icu's fallback install-sh does not support multi-file install
+ @for file in $(ALL_PKGCONFIG_FILES); do \
+ $(INSTALL_DATA) "$${file}" $(DESTDIR)$(libdir)/pkgconfig/ ; \
+ done
$(INSTALL_DATA) $(top_srcdir)/../LICENSE $(DESTDIR)$(pkgdatadir)/LICENSE
ifeq ($(INSTALL_ICU_CONFIG),true)
$(INSTALL_SCRIPT) $(top_builddir)/config/icu-config $(DESTDIR)$(bindir)/icu-config
diff --git a/source/configure b/source/configure
index dfa3a091f8..8ee911d42d 100755
--- a/source/configure
+++ b/source/configure
@@ -4935,12 +4935,12 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-# make sure install is relative to srcdir - if a script
-if test "$srcdir" = "."; then
- # If srcdir isn't just ., then (srcdir) is already prepended.
- if test "${ac_install_sh}" = "${INSTALL}"; then
- INSTALL="\\\$(top_srcdir)/${ac_install_sh}"
- fi
+# If using the included install-sh, make INSTALL work from any build dir.
+if test "${ac_install_sh}" = "${INSTALL}"; then
+ case "$srcdir" in
+ .|./*|../*) INSTALL="\\\$(top_builddir)/${ac_install_sh}" ;;
+ *) ;;
+ esac
fi
# TODO(ICU-20301): Remove fallback to Python 2.

View File

@ -12,6 +12,7 @@ vcpkg_extract_source_archive(SOURCE_PATH
fix_bsd_and_solaris.patch
fix_parallel_build_on_windows.patch
fix-python-path-with-spaces.patch
fix-using-install-sh.diff
mh-darwin.patch
mh-mingw.patch
mh-msys-msvc.patch

View File

@ -1,7 +1,7 @@
{
"name": "icu",
"version": "78.3",
"port-version": 1,
"port-version": 2,
"description": "Mature and widely used Unicode and localization library.",
"homepage": "https://icu.unicode.org/home",
"license": "ICU",

View File

@ -3942,7 +3942,7 @@
},
"icu": {
"baseline": "78.3",
"port-version": 1
"port-version": 2
},
"ideep": {
"baseline": "2026-05-11",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "50a263a104075be2c5647af8e723a18914f6ee13",
"version": "78.3",
"port-version": 2
},
{
"git-tree": "931a42f3b3b911ba73dbbaead4c1e0037a158efd",
"version": "78.3",