Skip to content

Commit a273858

Browse files
fthevenetshipilev
authored andcommitted
8318669: Target OS detection in 'test-prebuilt' makefile target is incorrect when running on MSYS2
Backport-of: 202c0137b86cd7bcbe0c1eddf2657f45698ab667
1 parent 348a703 commit a273858

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

make/RunTestsPrebuilt.gmk

+7
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,10 @@ ifeq ($(UNAME_OS), CYGWIN)
157157
OPENJDK_TARGET_OS := windows
158158
OPENJDK_TARGET_OS_TYPE := windows
159159
OPENJDK_TARGET_OS_ENV := windows.cygwin
160+
else ifeq ($(UNAME_OS), MINGW64)
161+
OPENJDK_TARGET_OS := windows
162+
OPENJDK_TARGET_OS_TYPE := windows
163+
OPENJDK_TARGET_OS_ENV := windows.msys2
160164
else
161165
OPENJDK_TARGET_OS_TYPE:=unix
162166
ifeq ($(UNAME_OS), Linux)
@@ -169,6 +173,9 @@ else
169173
OPENJDK_TARGET_OS_ENV := $(OPENJDK_TARGET_OS)
170174
endif
171175

176+
# Sanity check env detection
177+
$(info Detected target OS, type and env: [$(OPENJDK_TARGET_OS)] [$(OPENJDK_TARGET_OS_TYPE)] [$(OPENJDK_TARGET_OS_ENV)])
178+
172179
# Assume little endian unless otherwise specified
173180
OPENJDK_TARGET_CPU_ENDIAN := little
174181

0 commit comments

Comments
 (0)