From 7295f0091f09bd6b9040e42c382cf21ee1671c43 Mon Sep 17 00:00:00 2001 From: Hrishikesh Kadam Date: Fri, 22 Jul 2022 23:23:36 +0530 Subject: [PATCH] build: shim for invoking node w/o .exe from WSL This issue has been described in - https://github.com/nodejs/node/issues/43861 Reason for using build subsystem - Shims will be just copied in the stage_package label of vcbuild.bat Fixes: https://github.com/nodejs/node/issues/43861 --- tools/msvs/node | 3 +++ vcbuild.bat | 2 ++ 2 files changed, 5 insertions(+) create mode 100755 tools/msvs/node diff --git a/tools/msvs/node b/tools/msvs/node new file mode 100755 index 00000000000000..b3557089c1047f --- /dev/null +++ b/tools/msvs/node @@ -0,0 +1,3 @@ +#!/bin/sh +# Shim for invoking node without .exe from WSL +node.exe "$@" diff --git a/vcbuild.bat b/vcbuild.bat index 62334130f98abe..4e881b1d564bae 100644 --- a/vcbuild.bat +++ b/vcbuild.bat @@ -440,6 +440,8 @@ mkdir %TARGET_NAME%\node_modules > nul 2>nul copy /Y node.exe %TARGET_NAME%\ > nul if errorlevel 1 echo Cannot copy node.exe && goto package_error +copy /Y ..\tools\msvs\node %TARGET_NAME%\ > nul +if errorlevel 1 echo Cannot copy node && goto package_error copy /Y ..\LICENSE %TARGET_NAME%\ > nul if errorlevel 1 echo Cannot copy LICENSE && goto package_error copy /Y ..\README.md %TARGET_NAME%\ > nul