build: fix getting OpenSSL version on Windows

Node.js on Windows is built with `clang`, not `gcc`.

PR-URL: https://github.com/nodejs/node/pull/59609
Reviewed-By: Stefan Stojanovic <stefan.stojanovic@janeasystems.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
Michaël Zasso committed 2025-09-09 08:34:13 +02:00
1 parent 8dbd0f13e8
commit 7f347fc551
1 file changed
+3 -3
+3 -3
View File
@@ -20,9 +20,9 @@ os.chdir(Path(__file__).parent)
original_argv = sys.argv[1:]
# gcc and g++ as defaults matches what GYP's Makefile generator does,
# except on OS X.
CC = os.environ.get('CC', 'cc' if sys.platform == 'darwin' else 'gcc')
CXX = os.environ.get('CXX', 'c++' if sys.platform == 'darwin' else 'g++')
# except on macOS and Windows.
CC = os.environ.get('CC', 'cc' if sys.platform == 'darwin' else 'clang' if sys.platform == 'win32' else 'gcc')
CXX = os.environ.get('CXX', 'c++' if sys.platform == 'darwin' else 'clang' if sys.platform == 'win32' else 'g++')
tools_path = Path('tools')