Browse Source

Enable upgrades in MSI.

Fixes #2228.
v0.7.4-release
Igor Zinkovsky 13 years ago
parent
commit
b24cdb3d36
  1. 4
      tools/msvs/msi/nodemsi.wixproj
  2. 5
      tools/msvs/msi/product.wxs
  3. 4
      vcbuild.bat

4
tools/msvs/msi/nodemsi.wixproj

@ -16,12 +16,12 @@
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
<OutputPath>..\..\..\$(Configuration)\</OutputPath>
<IntermediateOutputPath>obj\$(Configuration)\</IntermediateOutputPath>
<DefineConstants>Debug;ProductVersion=$(NodeVersion);NPMSourceDir=..\..\..\deps\npm\</DefineConstants>
<DefineConstants>Debug;ProductVersion=$(NodeVersion);ProductId=$(NodeProductId);NPMSourceDir=..\..\..\deps\npm\</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
<OutputPath>..\..\..\$(Configuration)\</OutputPath>
<IntermediateOutputPath>obj\$(Configuration)\</IntermediateOutputPath>
<DefineConstants>Debug;ProductVersion=$(NodeVersion);NPMSourceDir=..\..\..\deps\npm\</DefineConstants>
<DefineConstants>Debug;ProductVersion=$(NodeVersion);ProductId=$(NodeProductId);NPMSourceDir=..\..\..\deps\npm\</DefineConstants>
</PropertyGroup>
<ItemGroup>
<Compile Include="product.wxs" />

5
tools/msvs/msi/product.wxs

@ -4,7 +4,7 @@
<?define repoDir="$(var.ProjectDir)..\..\..\" ?>
<?define sourcedir="$(var.repoDir)\$(var.Configuration)\" ?>
<Product Id="cc6c176e-e26c-48ec-8970-f58bd1d046cf"
<Product Id="$(var.ProductId)"
Name="node.js"
Language="1033"
Version="$(var.ProductVersion)"
@ -15,6 +15,9 @@
<Media Id="1" Cabinet="media1.cab" EmbedCab="yes" />
<MajorUpgrade AllowSameVersionUpgrades="yes"
DowngradeErrorMessage="A later version of node.js is already installed. Setup will now exit." />
<Directory Id="TARGETDIR" Name="SourceDir">
<Directory Id="ProgramFilesFolder">
<Directory Id="NodeRoot" Name="nodejs">

4
vcbuild.bat

@ -89,7 +89,9 @@ python "%~dp0tools\getnodeversion.py" > "%temp%\node_version.txt"
if not errorlevel 0 echo Cannot determine current version of node.js & goto exit
for /F "tokens=*" %%i in (%temp%\node_version.txt) do set NODE_VERSION=%%i
heat dir deps\npm -var var.NPMSourceDir -dr NodeModulesFolder -cg NPMFiles -gg -template fragment -nologo -out npm.wxs
msbuild "%~dp0tools\msvs\msi\nodemsi.sln" /t:Clean,Build /p:Configuration=%config% /p:NodeVersion=%NODE_VERSION% /clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal /nologo
uuidgen > "%temp%\node_product_id.txt"
set /p NODE_PRODUCT_ID=<"%temp%\node_product_id.txt"
msbuild "%~dp0tools\msvs\msi\nodemsi.sln" /t:Clean,Build /p:Configuration=%config% /p:NodeVersion=%NODE_VERSION% /p:NodeProductId=%NODE_PRODUCT_ID% /clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal /nologo
if errorlevel 1 goto exit
if defined nosign goto run

Loading…
Cancel
Save