Skip to content

Updated MSI creation code and documentation to wix v6 #1188

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 2, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/wix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Install wix toolset
run: dotnet tool install --global wix --version 5.0.2 --verbosity quiet
run: dotnet tool install --global wix --version 6.0.0 --verbosity quiet

- name: Fetch latest Windows version from Adoptium API
run: |
Expand Down
4 changes: 2 additions & 2 deletions wix/Build.OpenJDK_generic.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ REM PRODUCT_CATEGORY=jre|jdk (only one at a time)
REM SKIP_MSI_VALIDATION=true (Add -sval option to light.exe to skip MSI/MSM validation and skip smoke.exe )
REM UPGRADE_CODE_SEED=thisIsAPrivateSecretSeed ( optional ) for upgradable MSI (If none, new PRODUCT_UPGRADE_CODE is generate for each run)
REM OUTPUT_BASE_FILENAME=customFileName (optional) for setting file names that are not based on the default naming convention
REM WIX_VERSION=5.0.2 (optional) for setting the version of Wix Toolset to use
REM WIX_VERSION=6.0.0 (optional) for setting the version of Wix Toolset to use

SETLOCAL ENABLEEXTENSIONS
SET ERR=0
Expand All @@ -38,7 +38,7 @@ IF NOT DEFINED PRODUCT_HELP_LINK SET PRODUCT_HELP_LINK=https://github.com/adopti
IF NOT DEFINED PRODUCT_SUPPORT_LINK SET PRODUCT_SUPPORT_LINK=https://adoptium.net/support
IF NOT DEFINED PRODUCT_UPDATE_INFO_LINK SET PRODUCT_UPDATE_INFO_LINK=https://adoptium.net/temurin/releases
IF NOT DEFINED WIX_HEAT_PATH SET WIX_HEAT_PATH=.\Resources\heat_dir\heat.exe
IF NOT DEFINED WIX_VERSION SET WIX_VERSION=5.0.2
IF NOT DEFINED WIX_VERSION SET WIX_VERSION=6.0.0

REM default windows_SDK version
REM See folder e.g. "C:\Program Files (x86)\Windows Kits\[10]\bin\[10.0.22621.0]\!PLATFORM!"
Expand Down
6 changes: 3 additions & 3 deletions wix/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Requirements for build environment

1. [Windows Installer XML (WiX) toolset, 5.0.0 or later](https://wixtoolset.org/docs/intro/#nettool)
1. [Windows Installer XML (WiX) toolset, 6.0.0 or later](https://wixtoolset.org/docs/intro/#nettool)
1. Install ["Windows SDK for Desktop C++ amd64 Apps" feature from Windows SDK 10](https://developer.microsoft.com/en-us/windows/downloads/windows-10-sdk) for building multi-lingual setups.
1. Digital signature service if the MSI should be signed (optional). If you plan to sign the MSI, you need to install the Windows SDK 10 feature "Windows SDK Signing Tools for Desktops Apps".
1. For reviewing the MSI setup or creating custom MST transforms you can install feature "MSI Tools" from Windows SDK 10 (optional).
Expand All @@ -25,7 +25,7 @@ call powershell.exe ./CreateSourceFolder.AdoptOpenJDK.ps1 ^
-openjdk_filename_regex "^OpenJDK(?<major>\d*)" ^
-platform_regex "(?<platform>x86-32|x64|aarch64)" ^
-jvm_regex "(?<jvm>hotspot|openj9|dragonwell)" ^
-wix_version "5.0.2"
-wix_version "6.0.0"
```

3. Export the following environment variables:
Expand All @@ -42,7 +42,7 @@ call powershell.exe ./CreateSourceFolder.AdoptOpenJDK.ps1 ^
SET ARCH=x64|x86-32|x86|arm64 or all "x64 x86-32 arm64"
SET JVM=hotspot|openj9|dragonwell or both JVM=hotspot openj9
SET PRODUCT_CATEGORY=jre|jdk (only one at a time)
SET WIX_VERSION=5.0.2 (make sure this is the same version that is installed on the build machine)
SET WIX_VERSION=6.0.0 (make sure this is the same version that is installed on the build machine)
```

To customize branding information you can export the following environment variables to override the default values. The default values are listed below:
Expand Down
4 changes: 2 additions & 2 deletions wix/SourceDir/CreateSourceFolder.AdoptOpenJDK.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

.PARAMETER wix_version
The version wix that is currently installed.
Used to determine WixToolset.Heat version to be installed. Default is 5.0.0.
Used to determine WixToolset.Heat version to be installed. Default is 6.0.0.

.NOTES
File Name: CreateSourceFolder.AdoptOpenJDK.ps1
Expand All @@ -45,7 +45,7 @@ param (
[Parameter(Mandatory = $false)]
[string]$jvm = "",
[Parameter(Mandatory = $false)]
[string]$wix_version = "5.0.2"
[string]$wix_version = "6.0.0"
)

Get-ChildItem -Path .\ -Filter *.zip -File -Name | ForEach-Object {
Expand Down