From 1fd576d2b90065479c4ba91506a38458aeaae461 Mon Sep 17 00:00:00 2001 From: Dennis Ameling Date: Mon, 1 Jun 2020 23:09:16 +0200 Subject: [PATCH 1/3] win,msi: add arm64 config for windows msi Adds configuration to allow building an MSI installer for Windows ARM64. MSI can be created by running `vcbuild.bat release msi arm64` Refs: https://github.com/nodejs/node/issues/25998 Refs: https://github.com/nodejs/node/issues/32582 --- tools/msvs/msi/custom_actions.vcxproj | 78 ++++++++++++++++++++++++++- tools/msvs/msi/nodemsi.sln | 19 ++++++- tools/msvs/msi/nodemsi.wixproj | 15 +++++- 3 files changed, 108 insertions(+), 4 deletions(-) diff --git a/tools/msvs/msi/custom_actions.vcxproj b/tools/msvs/msi/custom_actions.vcxproj index 077f29a52fadac..95884a90a05ef4 100644 --- a/tools/msvs/msi/custom_actions.vcxproj +++ b/tools/msvs/msi/custom_actions.vcxproj @@ -1,6 +1,10 @@  + + Debug + ARM64 + Debug Win32 @@ -9,6 +13,10 @@ Debug x64 + + Release + ARM64 + Release Win32 @@ -31,6 +39,12 @@ Unicode true + + DynamicLibrary + $(PlatformToolset) + Unicode + true + DynamicLibrary $(PlatformToolset) @@ -42,6 +56,11 @@ $(PlatformToolset) Unicode + + DynamicLibrary + $(PlatformToolset) + Unicode + DynamicLibrary $(PlatformToolset) @@ -53,12 +72,18 @@ + + + + + + @@ -69,12 +94,18 @@ true + + true + true false + + false + false @@ -97,6 +128,25 @@ Windows + + + Disabled + $(WixSdkDir)\inc;%(AdditionalIncludeDirectories) + WIN32;_DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) + EnableFastChecks + MultiThreadedDebug + NotUsing + Level3 + ProgramDatabase + + + msi.lib;dutil.lib;wcautil.lib;version.lib;%(AdditionalDependencies) + $(WixSdkDir)\lib\ARM64;%(AdditionalLibraryDirectories) + custom_actions.def + true + Windows + + Disabled @@ -142,6 +192,32 @@ true + + + MaxSpeed + true + $(WixSdkDir)\inc;%(AdditionalIncludeDirectories) + WIN32;NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) + MultiThreaded + true + Level3 + ProgramDatabase + NotUsing + + + + + + + msi.lib;dutil.lib;wcautil.lib;version.lib;%(AdditionalDependencies) + $(WixSdkDir)\lib\ARM64;%(AdditionalLibraryDirectories) + custom_actions.def + true + Windows + true + true + + MaxSpeed @@ -178,4 +254,4 @@ - + \ No newline at end of file diff --git a/tools/msvs/msi/nodemsi.sln b/tools/msvs/msi/nodemsi.sln index 9a3bab3f5cb448..50b6e7af984001 100644 --- a/tools/msvs/msi/nodemsi.sln +++ b/tools/msvs/msi/nodemsi.sln @@ -1,30 +1,42 @@  -Microsoft Visual Studio Solution File, Format Version 11.00 -# Visual Studio 2010 +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.29613.14 +MinimumVisualStudioVersion = 10.0.40219.1 Project("{930C7802-8A8C-48F9-8165-68863BCCD9DD}") = "nodemsi", "nodemsi.wixproj", "{1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}" EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "custom_actions", "custom_actions.vcxproj", "{B70585F8-DAB7-40FA-9904-13CF53A73A06}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|ARM64 = Debug|ARM64 Debug|x64 = Debug|x64 Debug|x86 = Debug|x86 + Release|ARM64 = Release|ARM64 Release|x64 = Release|x64 Release|x86 = Release|x86 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution + {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Debug|ARM64.ActiveCfg = Debug|arm64 + {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Debug|ARM64.Build.0 = Debug|arm64 {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Debug|x64.ActiveCfg = Debug|x64 {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Debug|x64.Build.0 = Debug|x64 {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Debug|x86.ActiveCfg = Debug|x86 {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Debug|x86.Build.0 = Debug|x86 + {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Release|ARM64.ActiveCfg = Release|arm64 + {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Release|ARM64.Build.0 = Release|arm64 {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Release|x64.ActiveCfg = Release|x64 {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Release|x64.Build.0 = Release|x64 {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Release|x86.ActiveCfg = Release|x86 {1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}.Release|x86.Build.0 = Release|x86 + {B70585F8-DAB7-40FA-9904-13CF53A73A06}.Debug|ARM64.ActiveCfg = Debug|ARM64 + {B70585F8-DAB7-40FA-9904-13CF53A73A06}.Debug|ARM64.Build.0 = Debug|ARM64 {B70585F8-DAB7-40FA-9904-13CF53A73A06}.Debug|x64.ActiveCfg = Debug|x64 {B70585F8-DAB7-40FA-9904-13CF53A73A06}.Debug|x64.Build.0 = Debug|x64 {B70585F8-DAB7-40FA-9904-13CF53A73A06}.Debug|x86.ActiveCfg = Debug|Win32 {B70585F8-DAB7-40FA-9904-13CF53A73A06}.Debug|x86.Build.0 = Debug|Win32 + {B70585F8-DAB7-40FA-9904-13CF53A73A06}.Release|ARM64.ActiveCfg = Release|ARM64 + {B70585F8-DAB7-40FA-9904-13CF53A73A06}.Release|ARM64.Build.0 = Release|ARM64 {B70585F8-DAB7-40FA-9904-13CF53A73A06}.Release|x64.ActiveCfg = Release|x64 {B70585F8-DAB7-40FA-9904-13CF53A73A06}.Release|x64.Build.0 = Release|x64 {B70585F8-DAB7-40FA-9904-13CF53A73A06}.Release|x86.ActiveCfg = Release|Win32 @@ -33,4 +45,7 @@ Global GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {7D8C24E8-C37B-4A50-AFF4-987EBA88AF2A} + EndGlobalSection EndGlobal diff --git a/tools/msvs/msi/nodemsi.wixproj b/tools/msvs/msi/nodemsi.wixproj index 66a97f243d8dde..ad4bc218643e79 100644 --- a/tools/msvs/msi/nodemsi.wixproj +++ b/tools/msvs/msi/nodemsi.wixproj @@ -34,6 +34,16 @@ obj\$(Configuration)\ Debug;ProductVersion=$(NodeVersion);FullVersion=$(FullVersion);DistTypeDir=$(DistTypeDir);NoETW=$(NoETW);NpmSourceDir=..\..\..\Release\node-v$(FullVersion)-win-$(Platform)\node_modules\npm\;ProgramFilesFolderId=ProgramFiles64Folder + + ..\..\..\ + obj\$(Configuration)\ + Debug;ProductVersion=$(NodeVersion);FullVersion=$(FullVersion);DistTypeDir=$(DistTypeDir);NoETW=$(NoETW);NpmSourceDir=..\..\..\Release\node-v$(FullVersion)-win-$(Platform)\node_modules\npm\;ProgramFilesFolderId=ProgramFiles64Folder + + + ..\..\..\ + obj\$(Configuration)\ + Debug;ProductVersion=$(NodeVersion);FullVersion=$(FullVersion);DistTypeDir=$(DistTypeDir);NoETW=$(NoETW);NpmSourceDir=..\..\..\Release\node-v$(FullVersion)-win-$(Platform)\node_modules\npm\;ProgramFilesFolderId=ProgramFiles64Folder + True @@ -71,6 +81,9 @@ INSTALLFOLDER + + + @@ -91,4 +104,4 @@ --> - + \ No newline at end of file From 146118f805f65d4323e6b4ea306ffa53c5d59949 Mon Sep 17 00:00:00 2001 From: Dennis Ameling Date: Mon, 8 Jun 2020 19:53:12 +0200 Subject: [PATCH 2/3] win,msi: optimize arm64 config for windows msi --- tools/msvs/msi/custom_actions.vcxproj | 2 +- tools/msvs/msi/nodemsi.sln | 9 ++------- tools/msvs/msi/nodemsi.wixproj | 5 +---- 3 files changed, 4 insertions(+), 12 deletions(-) diff --git a/tools/msvs/msi/custom_actions.vcxproj b/tools/msvs/msi/custom_actions.vcxproj index 95884a90a05ef4..2fed47b6e4a781 100644 --- a/tools/msvs/msi/custom_actions.vcxproj +++ b/tools/msvs/msi/custom_actions.vcxproj @@ -254,4 +254,4 @@ - \ No newline at end of file + diff --git a/tools/msvs/msi/nodemsi.sln b/tools/msvs/msi/nodemsi.sln index 50b6e7af984001..f3235b0bb46fe5 100644 --- a/tools/msvs/msi/nodemsi.sln +++ b/tools/msvs/msi/nodemsi.sln @@ -1,8 +1,6 @@  -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 16 -VisualStudioVersion = 16.0.29613.14 -MinimumVisualStudioVersion = 10.0.40219.1 +Microsoft Visual Studio Solution File, Format Version 11.00 +Visual Studio 2010 Project("{930C7802-8A8C-48F9-8165-68863BCCD9DD}") = "nodemsi", "nodemsi.wixproj", "{1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}" EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "custom_actions", "custom_actions.vcxproj", "{B70585F8-DAB7-40FA-9904-13CF53A73A06}" @@ -45,7 +43,4 @@ Global GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection - GlobalSection(ExtensibilityGlobals) = postSolution - SolutionGuid = {7D8C24E8-C37B-4A50-AFF4-987EBA88AF2A} - EndGlobalSection EndGlobal diff --git a/tools/msvs/msi/nodemsi.wixproj b/tools/msvs/msi/nodemsi.wixproj index ad4bc218643e79..d4bf09cb34c131 100644 --- a/tools/msvs/msi/nodemsi.wixproj +++ b/tools/msvs/msi/nodemsi.wixproj @@ -81,9 +81,6 @@ INSTALLFOLDER - - - @@ -104,4 +101,4 @@ --> - \ No newline at end of file + From f03c158f25061d2a290edbe1f117dd6cf8313ef1 Mon Sep 17 00:00:00 2001 From: Dennis Ameling Date: Mon, 8 Jun 2020 19:54:48 +0200 Subject: [PATCH 3/3] win,msi: optimize arm64 config for windows msi --- tools/msvs/msi/nodemsi.sln | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/msvs/msi/nodemsi.sln b/tools/msvs/msi/nodemsi.sln index f3235b0bb46fe5..86b4b10dcb043f 100644 --- a/tools/msvs/msi/nodemsi.sln +++ b/tools/msvs/msi/nodemsi.sln @@ -1,6 +1,6 @@  Microsoft Visual Studio Solution File, Format Version 11.00 -Visual Studio 2010 +# Visual Studio 2010 Project("{930C7802-8A8C-48F9-8165-68863BCCD9DD}") = "nodemsi", "nodemsi.wixproj", "{1D808FF0-B5A9-4BE9-859D-B334B6F48BE2}" EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "custom_actions", "custom_actions.vcxproj", "{B70585F8-DAB7-40FA-9904-13CF53A73A06}"