From 131d04520294e002d8a6bf925aebe5bd59452203 Mon Sep 17 00:00:00 2001 From: "Peiyao Zhao (from Dev Box)" Date: Wed, 30 Jul 2025 15:14:37 +0800 Subject: [PATCH] update installer related markdown --- Directory.Packages.props | 1 - NOTICE.md | 8 ++++++++ doc/devdocs/core/installer.md | 21 +++++++++++++++++++-- 3 files changed, 27 insertions(+), 3 deletions(-) diff --git a/Directory.Packages.props b/Directory.Packages.props index 558930d46a..ca65a89c91 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -114,7 +114,6 @@ - diff --git a/NOTICE.md b/NOTICE.md index 4dcc82579d..7d62ac8aad 100644 --- a/NOTICE.md +++ b/NOTICE.md @@ -1581,3 +1581,11 @@ SOFTWARE. - WinUIEx 2.2.0 - WPF-UI 3.0.5 - WyHash 1.0.5 +- WixToolset.Heat 5.0.2 +- WixToolset.Firewall.wixext 5.0.2 +- WixToolset.Util.wixext 5.0.2 +- WixToolset.UI.wixext 5.0.2 +- WixToolset.NetFx.wixext 5.0.2 +- WixToolset.Bal.wixext 5.0.2 +- WixToolset.BootstrapperApplicationApi 5.0.2 +- WixToolset.WixStandardBootstrapperApplicationFunctionApi 5.0.2 diff --git a/doc/devdocs/core/installer.md b/doc/devdocs/core/installer.md index 781f31d682..92fc0be4d1 100644 --- a/doc/devdocs/core/installer.md +++ b/doc/devdocs/core/installer.md @@ -1,6 +1,6 @@ # PowerToys Installer -## Installer Architecture (WiX 3) +## Installer Architecture (WiX 3/ WiX 5) - Uses a bootstrapper to check dependencies and close PowerToys - MSI defined in product.wxs @@ -22,7 +22,7 @@ ### MSI Installer Build Process -- First builds `PowerToysSetupCustomActions` DLL and signs it +- First builds `PowerToysSetupCustomActions` DLL and signs it, for WiX5 project, installer will build `PowerToysSetupCustomActionsVNext` DLL. - Then builds the installer without cleaning, to reuse the signed DLL - Uses PowerShell scripts to modify .wxs files before build - Restores original .wxs files after build completes @@ -128,6 +128,23 @@ If you prefer, you can alternatively build prerequisite projects for the install The resulting `PowerToysSetup.msi` installer will be available in the `installer\PowerToysSetup\x64\Release\` folder. +For WiX3 project, run `Developer Command Prompt for VS 2022` in admin mode and execute the following command to build the installer. The generated installer package will be located at `\installer\PowerToysSetup\{platform}\Release\MachineSetup`. + +``` +git clean -xfd -e *exe -- .\installer\ +MSBuild -t:restore .\installer\PowerToysSetup.sln -p:RestorePackagesConfig=true /p:Platform="x64" /p:Configuration=Release +MSBuild -m .\installer\PowerToysSetup.sln /t:PowerToysInstaller /p:Configuration=Release /p:Platform="x64" +MSBuild -m .\installer\PowerToysSetup.sln /t:PowerToysBootstrapper /p:Configuration=Release /p:Platform="x64" +``` +For WiX5 project, run `Developer Command Prompt for VS 2022` in admin mode and execute the following command to build the installer. The generated installer package will be located at `\installer\PowerToysSetupVNext\{platform}\Release\MachineSetup`. + +``` +git clean -xfd -e *exe -- .\installer\ +MSBuild -t:restore .\installer\PowerToysSetup.sln -p:RestorePackagesConfig=true /p:Platform="x64" /p:Configuration=Release +MSBuild -t:Restore -m .\installer\PowerToysSetup.sln /t:PowerToysInstallerVNext /p:Configuration=Release /p:Platform="x64" +MSBuild -t:Restore -m .\installer\PowerToysSetup.sln /t:PowerToysBootstrapperVNext /p:Configuration=Release /p:Platform="x64" +``` + ### Supported arguments for the .EXE Bootstrapper installer Head over to the wiki to see the [full list of supported installer arguments][installerArgWiki].