From 30b6b0ece49c143aae06c5da7f9f3c8c6d974431 Mon Sep 17 00:00:00 2001 From: Johannes Schindelin Date: Thu, 23 Nov 2023 12:42:17 +0100 Subject: [PATCH] Synchronize with MSYS2's current version of the MSYS2 runtime Most notably, this integrates the fixes from https://github.com/msys2/msys2-runtime/pull/179. Signed-off-by: Johannes Schindelin --- ...onality-for-converting-UNIX-paths-in.patch | 30 ++++++++++++++++ ...onality-for-converting-UNIX-paths-in.patch | 34 +++++++++++++++++++ msys2-runtime/PKGBUILD | 16 ++++++--- msys2-runtime/msys2-runtime.commit | 2 +- 4 files changed, 76 insertions(+), 6 deletions(-) create mode 100644 msys2-runtime/0062-fixup-Add-functionality-for-converting-UNIX-paths-in.patch create mode 100644 msys2-runtime/0063-fixup-Add-functionality-for-converting-UNIX-paths-in.patch diff --git a/msys2-runtime/0062-fixup-Add-functionality-for-converting-UNIX-paths-in.patch b/msys2-runtime/0062-fixup-Add-functionality-for-converting-UNIX-paths-in.patch new file mode 100644 index 00000000000..1e3eb276c3b --- /dev/null +++ b/msys2-runtime/0062-fixup-Add-functionality-for-converting-UNIX-paths-in.patch @@ -0,0 +1,30 @@ +From 0e7d0755a911149d0c517c6b93887b3155a9cfe0 Mon Sep 17 00:00:00 2001 +From: Kai Pastor +Date: Tue, 21 Nov 2023 09:24:03 +0100 +Subject: [PATCH 62/N] fixup! Add functionality for converting UNIX paths in + arguments and environment variables to Windows form for native Win32 + applications. + +Don't memchr behind end, it+1 +--- + winsup/cygwin/msys2_path_conv.cc | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/winsup/cygwin/msys2_path_conv.cc b/winsup/cygwin/msys2_path_conv.cc +index 2bdf0ae..d4f0192 100644 +--- a/winsup/cygwin/msys2_path_conv.cc ++++ b/winsup/cygwin/msys2_path_conv.cc +@@ -349,6 +349,13 @@ path_type find_path_start_and_type(const char** src, int recurse, const char* en + + path_type result = NONE; + ++ if (it + 1 == end) { ++ switch (*it) { ++ case '/': return ROOTED_PATH ; ++ default: return SIMPLE_WINDOWS_PATH; ++ } ++ } ++ + if (isalpha(*it) && *(it + 1) == ':') { + if (*(it + 2) == '\\') { + return SIMPLE_WINDOWS_PATH; diff --git a/msys2-runtime/0063-fixup-Add-functionality-for-converting-UNIX-paths-in.patch b/msys2-runtime/0063-fixup-Add-functionality-for-converting-UNIX-paths-in.patch new file mode 100644 index 00000000000..8de873cb56a --- /dev/null +++ b/msys2-runtime/0063-fixup-Add-functionality-for-converting-UNIX-paths-in.patch @@ -0,0 +1,34 @@ +From 677ece60fc37b0c5d336db1e345a4c33ffff15f6 Mon Sep 17 00:00:00 2001 +From: Kai Pastor +Date: Tue, 21 Nov 2023 09:25:58 +0100 +Subject: [PATCH 63/N] fixup! Add functionality for converting UNIX paths in + arguments and environment variables to Windows form for native Win32 + applications. + +Don't memchr behind end, it2 +--- + winsup/cygwin/msys2_path_conv.cc | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/winsup/cygwin/msys2_path_conv.cc b/winsup/cygwin/msys2_path_conv.cc +index d4f0192..5c59291 100644 +--- a/winsup/cygwin/msys2_path_conv.cc ++++ b/winsup/cygwin/msys2_path_conv.cc +@@ -431,7 +431,7 @@ path_type find_path_start_and_type(const char** src, int recurse, const char* en + if (isalpha(ch) && (*(it2+1) == ':') && (*(it2+2) == '/')) { + return SIMPLE_WINDOWS_PATH; + } +- if (ch == '/'&& memchr(it2, ',', end - it) == NULL) { ++ if (ch == '/'&& memchr(it2, ',', end - it2) == NULL) { + *src = it2; + return find_path_start_and_type(src, true, end); + } +@@ -458,7 +458,7 @@ path_type find_path_start_and_type(const char** src, int recurse, const char* en + } else { + return POSIX_PATH_LIST; + } +- } else if (memchr(it2, '=', end - it) == NULL) { ++ } else if (memchr(it2, '=', end - it2) == NULL) { + return SIMPLE_WINDOWS_PATH; + } + } diff --git a/msys2-runtime/PKGBUILD b/msys2-runtime/PKGBUILD index c33a1462a14..31c86283ba9 100644 --- a/msys2-runtime/PKGBUILD +++ b/msys2-runtime/PKGBUILD @@ -4,7 +4,7 @@ pkgbase=msys2-runtime pkgname=('msys2-runtime' 'msys2-runtime-devel') pkgver=3.4.9 -pkgrel=1 +pkgrel=2 pkgdesc="Cygwin POSIX emulation engine" arch=('x86_64') url="https://www.cygwin.com/" @@ -87,9 +87,11 @@ source=('msys2-runtime'::git+https://github.com/cygwin/cygwin#tag=cygwin-${pkgve 0058-Avoid-sharing-cygheaps-across-Cygwin-versions.patch 0059-uname-report-msys2-runtime-commit-hash-too.patch 0060-Revert-Cygwin-pipe-Restore-blocking-mode-for-cygwin-.patch - 0061-msys2-runtime-restore-fast-path-for-current-user-pri.patch) + 0061-msys2-runtime-restore-fast-path-for-current-user-pri.patch + 0062-fixup-Add-functionality-for-converting-UNIX-paths-in.patch + 0063-fixup-Add-functionality-for-converting-UNIX-paths-in.patch) sha256sums=('SKIP' - 'daeaa55468ef315aa8796bb8ff416ce2e50d3f94ac34fd507ff4306460066142' + 'f1049252bc3891471b535672a2ef5eb1af794ac4bb0fedbc65852e6d98186932' '021fd67841a12ef09dd72d08e3ed4a1ccc58d38dc475bdf79ecff3a90c7d6197' '6b6187c8e9343cf2875fe8d622762892bfb2d8087f1e510882928ec63584e4bc' '0b8933eb38b42aed816bdded768ed92047e220157085778a0dbf23278d8355d9' @@ -150,7 +152,9 @@ sha256sums=('SKIP' '0c94d7eb14cb56efa4a9b41cb7f99bb7d625942e8d61c4692d98f0c70c4d370f' 'bd6bdc7c022ac9cf7235548c152fed3b303fe69acf5a50e0e237c23a31d6c974' 'a697e81d8abd85fc10e5764afc551e775e99e8b49880c665474c102e005329ed' - '4985310df62a892d938dbd3d6b7a358d1b82bbf6e3a7a0e90fee84ea6dd9e5a4') + '4985310df62a892d938dbd3d6b7a358d1b82bbf6e3a7a0e90fee84ea6dd9e5a4' + '58d6e4c32368af4e31de245d7ee59c0a52f25b6d9407ef23d7483aed24a9aeb5' + '358b8a993127b9e45ba2468b34e2ef24b7ca9309fe76dfb37e873858c214a202') # Helper macros to help make tasks easier # apply_patch_with_msg() { @@ -265,7 +269,9 @@ prepare() { 0058-Avoid-sharing-cygheaps-across-Cygwin-versions.patch \ 0059-uname-report-msys2-runtime-commit-hash-too.patch \ 0060-Revert-Cygwin-pipe-Restore-blocking-mode-for-cygwin-.patch \ - 0061-msys2-runtime-restore-fast-path-for-current-user-pri.patch + 0061-msys2-runtime-restore-fast-path-for-current-user-pri.patch \ + 0062-fixup-Add-functionality-for-converting-UNIX-paths-in.patch \ + 0063-fixup-Add-functionality-for-converting-UNIX-paths-in.patch } build() { diff --git a/msys2-runtime/msys2-runtime.commit b/msys2-runtime/msys2-runtime.commit index af7ded74438..8fc0c84177d 100644 --- a/msys2-runtime/msys2-runtime.commit +++ b/msys2-runtime/msys2-runtime.commit @@ -1 +1 @@ -be826601df87b13be6038bb7e23a01d92be7ef07 +b039495115cdb838e2699ebb1673da471954af9c