-
Type:
Bug
-
Resolution: Fixed
-
Priority:
P4
-
Affects Version/s: 8, 11, 17, 21, 25, 26
-
Component/s: infrastructure
-
b11
-
windows
| Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
|---|---|---|---|---|---|---|
| JDK-8378782 | 26.0.2 | Daishi Tabata | P4 | Resolved | Fixed | master |
> The $MSYSTEM_CHOST environment variable will now report x86_64-pc-cygwin instead of x86_64-pc-msys
Source: https://www.msys2.org/news/#2025-06-20-replacing-x86_64-pc-msys-with-x86_64-pc-cygwin
When setting up the JDK build (bash configure), $MSYSTEM_CHOST is referenced. As a result, even though you are actually trying to build with MSYS, it is mistakenly recognized as a Cygwin environment. This causes the build setup (bash configure) to fail.
```
$ bash configure
...
checking build system type... x86_64-pc-cygwin
checking host system type... x86_64-pc-cygwin
checking target system type... x86_64-pc-cygwin
checking openjdk-build os-cpu... windows-x86_64
checking openjdk-target os-cpu... windows-x86_64
checking compilation type... native
checking Windows environment type... cygwin
checking cygwin drive prefix... ''
checking cygwin root directory as Windows path... 'C:\msys64'
checking cygwin temp directory... MicrosoftWindowsVersion10.0.26200.7462MicrosoftCorporation.Allrightsreserved./c/Users/xxx/dev/tmp/jdk>
...
checking for pacman... /c/Users/xxx/dev/tmp/jdk/build/windows-x86_64-server-release/fixpath: line 3: syntax error near unexpected token (' /c/Users/xxx/dev/tmp/jdk/build/windows-x86_64-server-release/fixpath: line 3: . /c/Users/xxx/dev/tmp/jdk/make/scripts/fixpath.sh -e /usr/bin/cygpath -p NONE -r C:\msys64 -t MicrosoftWindowsVersion10.0.26200.7462MicrosoftCorporation.Allrightsreserved./c/Users/xxx/dev/tmp/jdk> -c /c/Windows/System32/cmd.exe "$@"'
/c/Users/xxx/dev/tmp/jdk/build/windows-x86_64-server-release/fixpath: line 3: syntax error near unexpected token (' /c/Users/xxx/dev/tmp/jdk/build/windows-x86_64-server-release/fixpath: line 3: . /c/Users/xxx/dev/tmp/jdk/make/scripts/fixpath.sh -e /usr/bin/cygpath -p NONE -r C:\msys64 -t MicrosoftWindowsVersion10.0.26200.7462MicrosoftCorporation.Allrightsreserved./c/Users/xxx/dev/tmp/jdk> -c /c/Windows/System32/cmd.exe "$@"'
configure: The command for PKGHANDLER, which is given as "/usr/bin/pacman", can not be properly resolved.
configure: Please see the section "Special Considerations" in building.md.
configure: This is the error message given by fixpath:
/c/Users/xxx/dev/tmp/jdk/build/windows-x86_64-server-release/fixpath: line 3: syntax error near unexpected token (' /c/Users/xxx/dev/tmp/jdk/build/windows-x86_64-server-release/fixpath: line 3: . /c/Users/xxx/dev/tmp/jdk/make/scripts/fixpath.sh -e /usr/bin/cygpath -p NONE -r C:\msys64 -t MicrosoftWindowsVersion10.0.26200.7462MicrosoftCorporation.Allrightsreserved./c/Users/xxx/dev/tmp/jdk> -c /c/Windows/System32/cmd.exe "$@"'
configure: error: Cannot continue
configure exiting with result code 2
```
- backported by
-
JDK-8378782 MSYS2 reports cygwin triplet causing bash configure failure
-
- Resolved
-
- links to
-
Commit(master)
openjdk/jdk26u/ab904786
-
Commit(master)
openjdk/jdk/feecb042
-
Review(master)
openjdk/jdk11u-dev/3162
-
Review(master)
openjdk/jdk17u-dev/4282
-
Review(master)
openjdk/jdk21u-dev/2642
-
Review(master)
openjdk/jdk25u-dev/319
-
Review(master)
openjdk/jdk26u/74
-
Review(master)
openjdk/jdk/29810