diff options
author | Bert Belder <bertbelder@gmail.com> | 2013-03-07 17:48:43 +0100 |
---|---|---|
committer | Bert Belder <bertbelder@gmail.com> | 2013-03-08 18:00:38 +0100 |
commit | fb6253209e0e7d5a09862af1c64ad4596dea0cc6 (patch) | |
tree | a4a292f639704e2cc86594521f8eb1cf1379dbdb /tools | |
parent | 2320ffbdff5a361f8ed3f14578b51ae741af897d (diff) | |
download | node-new-fb6253209e0e7d5a09862af1c64ad4596dea0cc6.tar.gz |
win/msi: refactor 'node.js runtime' feature
* This feature now includes the start menu items.
* 'nodejsvars.bat' was renamed to 'nodevars.bat'.
* Improved feature description.
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/msvs/msi/product.wxs | 96 | ||||
-rw-r--r-- | tools/msvs/nodevars.bat (renamed from tools/msvs/nodejsvars.bat) | 0 |
2 files changed, 50 insertions, 46 deletions
diff --git a/tools/msvs/msi/product.wxs b/tools/msvs/msi/product.wxs index ba9a0ad0d5..ab04c08540 100755 --- a/tools/msvs/msi/product.wxs +++ b/tools/msvs/msi/product.wxs @@ -38,9 +38,15 @@ Name="InstallPath"/> </Property> - <Feature Id="nodejs" Title="node.js engine" Level="1" Description="$(var.ProductDescription)" Absent="disallow"> - <ComponentGroupRef Id="allfiles" /> - <ComponentGroupRef Id="Product.Generated" /> + <Feature Id="NodeRuntime" + Level="1" + Title="Node.js runtime" + Description="Install the core Node.js runtime (node.exe)." + Absent="disallow"> + <ComponentRef Id="NodeExecutable"/> + <ComponentRef Id="NodeVarsScript"/> + <ComponentRef Id="NodeStartMenuAndRegistryEntries"/> + <ComponentGroupRef Id="Product.Generated"/> <Feature Id="NodePerfCtrSupport" Level="1" @@ -68,9 +74,6 @@ </Feature> <Feature Id="nodejs.shortcuts" Title="node.js shortcuts" Level="1" Description="$(var.ProductDescription) Shortcuts"> - <Feature Id="nodejs.shortcuts.application" Title="Application Shortcuts" Level="1" Description="$(var.ProductDescription) standard application shortcuts"> - <ComponentGroupRef Id="application.shortcuts"/> - </Feature> <Feature Id="nodejs.shortcuts.internet" Title="Internet Shortcuts" Level="1" Description="$(var.ProductDescription) internet shortcuts to the project's website and online documentation for this version"> <ComponentGroupRef Id="internet.shortcuts"/> </Feature> @@ -97,28 +100,24 @@ <Directory Id="TARGETDIR" Name="SourceDir"> <Directory Id="ProgramMenuFolder"> - <Directory Id="ApplicationProgramsFolder" Name="Node.js ($(var.Platform))"/> + <Directory Id="ApplicationProgramsFolder" Name="Node.js ($(var.Platform))"/> </Directory> <Directory Id="$(var.ProgramFilesFolderId)"> <Directory Id="INSTALLDIR" Name="nodejs"> - <Component Id="nodeexe" Guid="AEC0F08E-89B3-4C35-A286-8DB8598597F2"> - <File Id="filenodeexe" KeyPath="yes" Source="$(var.SourceDir)\node.exe" /> - </Component> - <Component Id="nodejsvars" Guid="*"> - <File Id="filenodejsvars" KeyPath="yes" Source="$(var.RepoDir)\tools\msvs\nodejsvars.bat" /> - </Component> - <Component Id="noderegistry" Guid="*" > - <RegistryKey Root="HKCU" Key="$(var.RegistryKeyPath)"> - <RegistryValue Name="InstallPath" Type="string" Value="[INSTALLDIR]" KeyPath="yes" /> - <RegistryValue Name="Version" Type="string" Value="$(var.ProductVersion)" /> - </RegistryKey> - </Component> </Directory> </Directory> </Directory> <DirectoryRef Id="INSTALLDIR"> + <Component Id="NodeExecutable"> + <File Id="node.exe" KeyPath="yes" Source="$(var.SourceDir)\node.exe"/> + </Component> + + <Component Id="NodeVarsScript"> + <File Id="nodevars.bat" KeyPath="yes" Source="$(var.RepoDir)\tools\msvs\nodevars.bat"/> + </Component> + <?if $(var.NoPerfCtr) != 1 ?> <Component Id="NodePerfCtrSupport"> <File Id="node_perfctr_provider_man" Name="node_perfctr_provider.man" Source="$(var.RepoDir)\src\res\node_perfctr_provider.man"> @@ -136,6 +135,38 @@ <?endif?> </DirectoryRef> + <DirectoryRef Id="ApplicationProgramsFolder"> + <Component Id="NodeStartMenuAndRegistryEntries"> + <RegistryValue Root="HKCU" + Key="$(var.RegistryKeyPath)" + Name="InstallPath" + Type="string" + Value="[INSTALLDIR]" + KeyPath="yes"/> + <RegistryValue Root="HKCU" + Key="$(var.RegistryKeyPath)" + Name="Version" + Type="string" + Value="$(var.ProductVersion)"/> + <Shortcut Id="NodeVarsScriptShortcut" + Name="Node.js command prompt" + Target="[%ComSpec]" + Arguments='/k "[INSTALLDIR]nodevars.bat"' + Show="normal" + WorkingDirectory="INSTALLDIR"/> + <Shortcut Id="NodeExecutableShortcut" + Name="Node.js" + Target="[INSTALLDIR]node.exe" + WorkingDirectory="INSTALLDIR"/> + <Shortcut Id="UninstallProduct" + Name="Uninstall Node.js" + Target="[SystemFolder]msiexec.exe" + Arguments="/x [ProductCode]"/> + <RemoveFolder Id="RemoveApplicationProgramsFolder" + On="uninstall"/> + </Component> + </DirectoryRef> + <DirectoryRef Id="INSTALLDIR"> <Component Id="NpmCmdScript"> <File Id="npm.cmd" KeyPath="yes" Source="$(var.NpmSourceDir)\bin\npm.cmd"/> @@ -187,23 +218,6 @@ </DirectoryRef> <DirectoryRef Id="ApplicationProgramsFolder"> - <Component Id="ApplicationShortcut" Guid="9b1ab94a-8f54-4f19-a5c4-b890de474162"> - <Shortcut Id="ApplicationStartMenuShortcut" Name="Node.js" - Description="$(var.ProductDescription)" Target="[INSTALLDIR]node.exe" - WorkingDirectory="INSTALLDIR"/> - <Shortcut Id="NodePromptStartMenuShortcut" Name="Node.js command prompt" - Description="Node.js Command Prompt" Target="[%ComSpec]" - Arguments='/k "[INSTALLDIR]nodejsvars.bat"' - Show="normal" - WorkingDirectory="INSTALLDIR"/> - <Shortcut Id="UninstallProduct" - Name="Uninstall Node.js" - Target="[SystemFolder]msiexec.exe" - Arguments="/x [ProductCode]" - Description="Uninstalls $(var.ProductName)" /> - <RemoveFolder Id="ApplicationProgramsFolder" On="uninstall"/> - <RegistryValue Root="HKCU" Key="$(var.RegistryKeyPath)" Name="installed" Type="integer" Value="1" KeyPath="yes"/> - </Component> <Component Id="InternetShortcuts" Guid="3351B877-49BA-4BC0-BF5E-21BA623FD07C"> <util:InternetShortcut Id="OnlineWebsiteShortcut" Name="Node.js website" @@ -217,16 +231,6 @@ </Component> </DirectoryRef> - <ComponentGroup Id="allfiles"> - <ComponentRef Id="nodeexe"/> - <ComponentRef Id="nodejsvars" /> - <ComponentRef Id="noderegistry" /> - </ComponentGroup> - - <ComponentGroup Id="application.shortcuts"> - <ComponentRef Id="ApplicationShortcut" /> - </ComponentGroup> - <ComponentGroup Id="internet.shortcuts"> <ComponentRef Id="InternetShortcuts"/> </ComponentGroup> diff --git a/tools/msvs/nodejsvars.bat b/tools/msvs/nodevars.bat index b79bc823bc..b79bc823bc 100644 --- a/tools/msvs/nodejsvars.bat +++ b/tools/msvs/nodevars.bat |