aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Mensching <rob@firegiant.com>2022-08-06 15:38:36 -0700
committerRob Mensching <rob@firegiant.com>2022-08-06 18:45:31 -0700
commit3b870b5493458ec6b2febc7dd7a154688a36152f (patch)
tree621693aba27819885bf9e0254e103ba69b6df9ff
parent93df57931e0c260c413bd1036492354c0d8375de (diff)
downloadwix-3b870b5493458ec6b2febc7dd7a154688a36152f.tar.gz
wix-3b870b5493458ec6b2febc7dd7a154688a36152f.tar.bz2
wix-3b870b5493458ec6b2febc7dd7a154688a36152f.zip
Create setup segment and WixAdditionalTools bundle
The setup segment is scheduled after building the shipping WiX files to use and include the current build's tooling. The WixAdditionalTools bundle currently only contains the ThmViewer package but may include additional tools in the future. At this time, the primary purpose is to produce a shipping MSI and bundle from the WiX v4 build process and dogfood the rest of the tooling. Closes 4919
-rw-r--r--src/Directory.wixproj.props9
-rw-r--r--src/Directory.wixproj.targets16
-rw-r--r--src/build_all.cmd5
-rw-r--r--src/setup/Directory.Build.props14
-rw-r--r--src/setup/ThmViewerPackage/ThmViewerPackage.wixproj11
-rw-r--r--src/setup/ThmViewerPackage/ThmViewerPackage.wxs (renamed from src/tools/ThmViewerPackage/Package.wxs)5
-rw-r--r--src/setup/WixAdditionalTools/WixAdditionalTools.wixproj17
-rw-r--r--src/setup/WixAdditionalTools/WixAdditionalTools.wxl12
-rw-r--r--src/setup/WixAdditionalTools/WixAdditionalTools.wxs27
-rw-r--r--src/setup/WixAdditionalTools/wix-logo-sq.pngbin0 -> 1810 bytes
-rw-r--r--src/setup/setup.cmd41
-rw-r--r--src/setup/setup.sln28
-rw-r--r--src/tools/ThmViewerPackage/ThmViewerPackage.wixproj10
-rw-r--r--src/tools/tools.sln1
14 files changed, 184 insertions, 12 deletions
diff --git a/src/Directory.wixproj.props b/src/Directory.wixproj.props
new file mode 100644
index 00000000..73ac652f
--- /dev/null
+++ b/src/Directory.wixproj.props
@@ -0,0 +1,9 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Project>
5 <PropertyGroup>
6 <!-- TODO: changing the .wixpdb folder does not actually work until issue #6857 is resolved -->
7 <PdbOutputDir>$(PdbsFolder)</PdbOutputDir>
8 </PropertyGroup>
9</Project>
diff --git a/src/Directory.wixproj.targets b/src/Directory.wixproj.targets
new file mode 100644
index 00000000..bac132ec
--- /dev/null
+++ b/src/Directory.wixproj.targets
@@ -0,0 +1,16 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Project>
5 <Target Name="_SetWixVersion"
6 DependsOnTargets="__SetPropertiesFromGit"
7 AfterTargets="_CreateProjectDefineConstants">
8 <PropertyGroup>
9 <DefineConstants>
10 $(DefineConstants);
11 SetupVersion=$(FileVersion);
12 SetupMajorMinorVersion=$(GitBaseVersionMajor).$(GitBaseVersionMinor);
13 </DefineConstants>
14 </PropertyGroup>
15 </Target>
16</Project>
diff --git a/src/build_all.cmd b/src/build_all.cmd
index ce1c08f0..5f3ba14e 100644
--- a/src/build_all.cmd
+++ b/src/build_all.cmd
@@ -54,6 +54,11 @@ call tools\tools.cmd %_C% || exit /b
54call ext\ext.cmd %_C% || exit /b 54call ext\ext.cmd %_C% || exit /b
55 55
56 56
57:: setup
58
59call setup\setup.cmd %_C% || exit /b
60
61
57:: integration tests 62:: integration tests
58 63
59call test\test.cmd %_C% || exit /b 64call test\test.cmd %_C% || exit /b
diff --git a/src/setup/Directory.Build.props b/src/setup/Directory.Build.props
new file mode 100644
index 00000000..cbf8ecc9
--- /dev/null
+++ b/src/setup/Directory.Build.props
@@ -0,0 +1,14 @@
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
3
4<Project>
5 <PropertyGroup>
6 <SegmentName>setup</SegmentName>
7 </PropertyGroup>
8
9 <Import Project="..\Directory.Build.props" />
10
11 <PropertyGroup>
12 <PublishRoot>$(OutputPath)publish\</PublishRoot>
13 </PropertyGroup>
14</Project>
diff --git a/src/setup/ThmViewerPackage/ThmViewerPackage.wixproj b/src/setup/ThmViewerPackage/ThmViewerPackage.wixproj
new file mode 100644
index 00000000..57aeac95
--- /dev/null
+++ b/src/setup/ThmViewerPackage/ThmViewerPackage.wixproj
@@ -0,0 +1,11 @@
1<?xml version="1.0" encoding="utf-8"?>
2<Project Sdk="WixToolset.Sdk">
3 <ItemGroup>
4 <LinkerBindInputPaths Include="$(RootBuildFolder)tools\$(Configuration)\x86" />
5 </ItemGroup>
6
7 <ItemGroup>
8 <PackageReference Include="GitInfo" PrivateAssets="All" />
9 </ItemGroup>
10
11</Project>
diff --git a/src/tools/ThmViewerPackage/Package.wxs b/src/setup/ThmViewerPackage/ThmViewerPackage.wxs
index dae6a9d0..ff33ae7e 100644
--- a/src/tools/ThmViewerPackage/Package.wxs
+++ b/src/setup/ThmViewerPackage/ThmViewerPackage.wxs
@@ -2,7 +2,7 @@
2<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"> 2<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
3 <Package Name="WiX Toolset Theme Viewer" Manufacturer="WiX Toolset" Language="1033" Version="!(bind.fileVersion.ThmViewerFile)" UpgradeCode="59c4b122-5167-445b-8fc4-09dcd4eced89"> 3 <Package Name="WiX Toolset Theme Viewer" Manufacturer="WiX Toolset" Language="1033" Version="!(bind.fileVersion.ThmViewerFile)" UpgradeCode="59c4b122-5167-445b-8fc4-09dcd4eced89">
4 <MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." /> 4 <MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." />
5 <MediaTemplate EmbedCab="yes" /> 5 <MediaTemplate />
6 6
7 <Feature Id="Main"> 7 <Feature Id="Main">
8 <ComponentGroupRef Id="Components" /> 8 <ComponentGroupRef Id="Components" />
@@ -14,13 +14,14 @@
14 <Component> 14 <Component>
15 <File Id="ThmViewerFile" Source="thmviewer.exe" /> 15 <File Id="ThmViewerFile" Source="thmviewer.exe" />
16 <Shortcut Name="!(bind.property.ProductName)" Directory="ShortcutFolder" Advertise="yes" /> 16 <Shortcut Name="!(bind.property.ProductName)" Directory="ShortcutFolder" Advertise="yes" />
17 <RemoveFolder Directory="ShortcutFolder" On="uninstall" />
17 </Component> 18 </Component>
18 </ComponentGroup> 19 </ComponentGroup>
19 </Fragment> 20 </Fragment>
20 21
21 <Fragment> 22 <Fragment>
22 <StandardDirectory Id="ProgramFilesFolder"> 23 <StandardDirectory Id="ProgramFilesFolder">
23 <Directory Id="INSTALLFOLDER" Name="WiX Toolset v4.0" /> 24 <Directory Id="INSTALLFOLDER" Name="WiX Toolset v$(SetupMajorMinorVersion)" />
24 </StandardDirectory> 25 </StandardDirectory>
25 <StandardDirectory Id="ProgramMenuFolder"> 26 <StandardDirectory Id="ProgramMenuFolder">
26 <Directory Id="ShortcutFolder" Name="WiX Toolset" /> 27 <Directory Id="ShortcutFolder" Name="WiX Toolset" />
diff --git a/src/setup/WixAdditionalTools/WixAdditionalTools.wixproj b/src/setup/WixAdditionalTools/WixAdditionalTools.wixproj
new file mode 100644
index 00000000..2d2347b3
--- /dev/null
+++ b/src/setup/WixAdditionalTools/WixAdditionalTools.wixproj
@@ -0,0 +1,17 @@
1<?xml version="1.0" encoding="utf-8"?>
2<Project Sdk="WixToolset.Sdk">
3 <PropertyGroup>
4 <OutputType>Bundle</OutputType>
5 <OutputPath>$(PackageOutputPath)</OutputPath>
6 </PropertyGroup>
7
8 <ItemGroup>
9 <ProjectReference Include="..\ThmViewerPackage\ThmViewerPackage.wixproj" />
10 </ItemGroup>
11
12 <ItemGroup>
13 <PackageReference Include="WixToolset.Bal.wixext" />
14 <PackageReference Include="GitInfo" PrivateAssets="All" />
15 </ItemGroup>
16
17</Project>
diff --git a/src/setup/WixAdditionalTools/WixAdditionalTools.wxl b/src/setup/WixAdditionalTools/WixAdditionalTools.wxl
new file mode 100644
index 00000000..ca3183ab
--- /dev/null
+++ b/src/setup/WixAdditionalTools/WixAdditionalTools.wxl
@@ -0,0 +1,12 @@
1<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
2
3<WixLocalization xmlns="http://wixtoolset.org/schemas/v4/wxl">
4 <String Id="Company" Overridable="yes">.NET Foundation</String>
5 <String Id="Copyright" Overridable="yes">Copyright (c) .NET Foundation and contributors. All rights reserved.</String>
6 <String Id="Name" Overridable="yes">WiX Toolset Additional Tools</String>
7 <String Id="Regid" Overridable="yes">wixtoolset.org</String>
8 <String Id="AboutUrl" Overridable="yes">https://wixtoolset.org/</String>
9 <String Id="LicenseUrl" Overridable="yes">https://wixtoolset.org/about/license/</String>
10 <String Id="SupportUrl" Overridable="yes">https://wixtoolset.org/documentation/</String>
11 <String Id="UpdateUrl" Overridable="yes">https://wixtoolset.org/releases/feed/v$(SetupMajorMinorVersion)</String>
12</WixLocalization>
diff --git a/src/setup/WixAdditionalTools/WixAdditionalTools.wxs b/src/setup/WixAdditionalTools/WixAdditionalTools.wxs
new file mode 100644
index 00000000..a53db9d3
--- /dev/null
+++ b/src/setup/WixAdditionalTools/WixAdditionalTools.wxs
@@ -0,0 +1,27 @@
1<!-- Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. -->
2
3<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"
4 xmlns:bal="http://wixtoolset.org/schemas/v4/wxs/bal">
5 <Bundle Name="!(loc.Name)" Version="$(SetupVersion)" UpgradeCode="fc48131d-214a-439b-9a31-ef2ea5c69ea5"
6 AboutUrl="!(loc.AboutUrl)" HelpUrl="!(loc.SupportUrl)" UpdateUrl="!(loc.UpdateUrl)">
7 <BootstrapperApplication>
8 <bal:WixStandardBootstrapperApplication
9 LicenseUrl="!(loc.LicenseUrl)"
10 Theme="hyperlinkLicense"
11 ShowVersion="true"
12 LogoFile="wix-logo-sq.png" />
13 </BootstrapperApplication>
14
15 <SetVariable Variable="InstallFolder" Value="[ProgramFilesFolder]WiX Toolset v$(SetupMajorMinorVersion)\" />
16 <!-- TODO: bring back SoftwareTag when #6854 fixed -->
17 <!-- <SoftwareTag Regid="!(loc.Regid)" InstallPath="[InstallFolder]" /> -->
18
19 <Update Location="!(loc.UpdateUrl)" />
20
21 <Chain>
22 <MsiPackage SourceFile="ThmViewerPackage.msi">
23 <MsiProperty Name="INSTALLFOLDER" Value="[InstallFolder]" />
24 </MsiPackage>
25 </Chain>
26 </Bundle>
27</Wix>
diff --git a/src/setup/WixAdditionalTools/wix-logo-sq.png b/src/setup/WixAdditionalTools/wix-logo-sq.png
new file mode 100644
index 00000000..373fc718
--- /dev/null
+++ b/src/setup/WixAdditionalTools/wix-logo-sq.png
Binary files differ
diff --git a/src/setup/setup.cmd b/src/setup/setup.cmd
new file mode 100644
index 00000000..8096792b
--- /dev/null
+++ b/src/setup/setup.cmd
@@ -0,0 +1,41 @@
1@setlocal
2@pushd %~dp0
3
4@set _C=Debug
5@set _L=%~dp0..\..\build\logs
6
7:parse_args
8@if /i "%1"=="release" set _C=Release
9@if /i "%1"=="inc" set _INCREMENTAL=1
10@if /i "%1"=="clean" set _INCREMENTAL= & set _CLEAN=1
11@if not "%1"=="" shift & goto parse_args
12
13:: Clean
14@if NOT "%_INCREMENTAL%"=="" call :clean
15@if NOT "%_CLEAN%"=="" goto :end
16
17@echo Building setup %_C%
18
19:: Build
20msbuild -Restore setup.sln -p:Configuration=%_C% -nologo -m -warnaserror -bl:%_L%\setup_build.binlog || exit /b
21
22:: Publish
23
24
25:: Test
26
27
28:: Pack
29
30
31@goto :end
32
33:clean
34@rd /s/q "..\..\build\setup" 2> nul
35@del "..\..\build\artifacts\WixAdditionalTools.*" 2> nul
36@del "..\..\build\logs\pdbs\%_C%\WixAdditionalTools.*" 2> nul
37@exit /b
38
39:end
40@popd
41@endlocal
diff --git a/src/setup/setup.sln b/src/setup/setup.sln
new file mode 100644
index 00000000..3998623e
--- /dev/null
+++ b/src/setup/setup.sln
@@ -0,0 +1,28 @@
1
2Microsoft Visual Studio Solution File, Format Version 12.00
3# Visual Studio Version 16
4VisualStudioVersion = 16.0.30114.105
5MinimumVisualStudioVersion = 10.0.40219.1
6Project("{B7DD6F7E-DEF8-4E67-B5B7-07EF123DB6F0}") = "ThmViewerPackage", "ThmViewerPackage\ThmViewerPackage.wixproj", "{F8C12838-DEC5-4CA5-97A8-DFE2247564C5}"
7EndProject
8Project("{B7DD6F7E-DEF8-4E67-B5B7-07EF123DB6F0}") = "WixAdditionalTools", "WixAdditionalTools\WixAdditionalTools.wixproj", "{59FF3AD3-339A-4048-9F0B-504EE74BC4AF}"
9EndProject
10Global
11 GlobalSection(SolutionConfigurationPlatforms) = preSolution
12 Debug|Any CPU = Debug|Any CPU
13 Release|Any CPU = Release|Any CPU
14 EndGlobalSection
15 GlobalSection(SolutionProperties) = preSolution
16 HideSolutionNode = FALSE
17 EndGlobalSection
18 GlobalSection(ProjectConfigurationPlatforms) = postSolution
19 {F8C12838-DEC5-4CA5-97A8-DFE2247564C5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
20 {F8C12838-DEC5-4CA5-97A8-DFE2247564C5}.Debug|Any CPU.Build.0 = Debug|Any CPU
21 {F8C12838-DEC5-4CA5-97A8-DFE2247564C5}.Release|Any CPU.ActiveCfg = Release|Any CPU
22 {F8C12838-DEC5-4CA5-97A8-DFE2247564C5}.Release|Any CPU.Build.0 = Release|Any CPU
23 {59FF3AD3-339A-4048-9F0B-504EE74BC4AF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
24 {59FF3AD3-339A-4048-9F0B-504EE74BC4AF}.Debug|Any CPU.Build.0 = Debug|Any CPU
25 {59FF3AD3-339A-4048-9F0B-504EE74BC4AF}.Release|Any CPU.ActiveCfg = Release|Any CPU
26 {59FF3AD3-339A-4048-9F0B-504EE74BC4AF}.Release|Any CPU.Build.0 = Release|Any CPU
27 EndGlobalSection
28EndGlobal
diff --git a/src/tools/ThmViewerPackage/ThmViewerPackage.wixproj b/src/tools/ThmViewerPackage/ThmViewerPackage.wixproj
deleted file mode 100644
index 9b2a2b02..00000000
--- a/src/tools/ThmViewerPackage/ThmViewerPackage.wixproj
+++ /dev/null
@@ -1,10 +0,0 @@
1<?xml version="1.0" encoding="utf-8"?>
2<Project Sdk="WixToolset.Sdk">
3 <PropertyGroup>
4 <OutputPath>$(PackageOutputPath)</OutputPath>
5 </PropertyGroup>
6
7 <ItemGroup>
8 <ProjectReference Include="..\thmviewer\thmviewer.vcxproj" />
9 </ItemGroup>
10</Project>
diff --git a/src/tools/tools.sln b/src/tools/tools.sln
index 4df8367e..a51983b3 100644
--- a/src/tools/tools.sln
+++ b/src/tools/tools.sln
@@ -29,6 +29,7 @@ Global
29 {95228C13-97F5-484A-B4A2-ECF4618B0881}.Debug|x86.ActiveCfg = Debug|Win32 29 {95228C13-97F5-484A-B4A2-ECF4618B0881}.Debug|x86.ActiveCfg = Debug|Win32
30 {95228C13-97F5-484A-B4A2-ECF4618B0881}.Debug|x86.Build.0 = Debug|Win32 30 {95228C13-97F5-484A-B4A2-ECF4618B0881}.Debug|x86.Build.0 = Debug|Win32
31 {95228C13-97F5-484A-B4A2-ECF4618B0881}.Release|Any CPU.ActiveCfg = Release|Win32 31 {95228C13-97F5-484A-B4A2-ECF4618B0881}.Release|Any CPU.ActiveCfg = Release|Win32
32 {95228C13-97F5-484A-B4A2-ECF4618B0881}.Release|Any CPU.Build.0 = Release|Win32
32 {95228C13-97F5-484A-B4A2-ECF4618B0881}.Release|x86.ActiveCfg = Release|Win32 33 {95228C13-97F5-484A-B4A2-ECF4618B0881}.Release|x86.ActiveCfg = Release|Win32
33 {95228C13-97F5-484A-B4A2-ECF4618B0881}.Release|x86.Build.0 = Release|Win32 34 {95228C13-97F5-484A-B4A2-ECF4618B0881}.Release|x86.Build.0 = Release|Win32
34 {D1385232-CA10-4092-BAB5-4E5499FE144C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 35 {D1385232-CA10-4092-BAB5-4E5499FE144C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU