diff --git a/Docs/installer-build-guide.md b/Docs/installer-build-guide.md index 33d7a1f127..e6f4702803 100644 --- a/Docs/installer-build-guide.md +++ b/Docs/installer-build-guide.md @@ -21,26 +21,20 @@ Use the installer setup script to validate your environment: ### Required Software 1. **Visual Studio 2026 or 2022** with Desktop workloads (C++ and .NET). Official installers are produced from Visual Studio 2022 (v143) builds; a v145 build gets a warning because the bundled VC++ redistributables predate that toolset. -2. **WiX Toolset v3.14** for the legacy WiX 3 build (default), plus the **Visual Studio WiX Toolset v3 extension** so `Wix.CA.targets` is available under MSBuild +2. **WiX Toolset v3.11** for the legacy WiX 3 build (default), plus the **Visual Studio WiX Toolset v3 extension** so `Wix.CA.targets` is available under MSBuild (see [ReadMe](../ReadMe.md) for instructions) 3. **WiX Toolset v6** via `WixToolset.Sdk` for the opt-in WiX 6 build (restored via NuGet as part of the build) 4. **MSBuild** (included with Visual Studio) 5. **.NET Framework 4.8 SDK** (included with Visual Studio) ### One-Time Setup -Run the developer machine setup script to install WiX and configure your environment: +Run the developer machine setup script to clone additional repositories: ```powershell -# Install WiX and configure PATH/environment variables (including WiX 3 VS extension) -.\Setup-Developer-Machine.ps1 - -# Also clone installer helper repositories .\Setup-Developer-Machine.ps1 -InstallerDeps ``` -### Repository Setup - -If not using `Setup-Developer-Machine.ps1 -InstallerDeps`, clone manually: +Alternatively, clone manually: ```powershell # Clone main repository @@ -50,6 +44,7 @@ cd fieldworks # Clone required helper repositories git clone https://github.com/sillsdev/FwHelps.git DistFiles/Helps git clone https://github.com/sillsdev/FwLocalizations.git Localizations +git clone https://github.com/sillsdev/genericinstaller.git PatchableInstaller git clone https://github.com/sillsdev/liblcm.git Localizations/LCMRepo ``` diff --git a/ReadMe.md b/ReadMe.md index f6346635d0..4f21908826 100644 --- a/ReadMe.md +++ b/ReadMe.md @@ -43,19 +43,15 @@ You can tag lock ownership for diagnostics with `FW_BUILD_STARTED_BY=user|agent` ## Building Installers (WiX 3 default, WiX 6 opt-in) -Installer builds default to **WiX 3** (legacy batch pipeline) using inputs in `FLExInstaller/` and `PatchableInstaller/`. The **Visual Studio WiX Toolset v3 extension** is required so `Wix.CA.targets` is available under the MSBuild extensions path. Use `-InstallerToolset Wix6` to opt into the WiX 6 SDK-style path (restored via NuGet). +Installer builds default to **WiX 3** (legacy batch pipeline) using inputs in `FLExInstaller/` and `PatchableInstaller/`. Use `-InstallerToolset Wix6` to opt into the WiX 6 SDK-style path (restored via NuGet; no setup required). -### WiX 3.14 setup (required for WiX 3 installer builds) +### WiX 3.11 setup (required for WiX 3 installer builds) -We expect the WiX 3.14 toolset to be installed under: - -- `%LOCALAPPDATA%\FieldWorksTools\Wix314` - -Required: - -- Ensure `candle.exe`, `light.exe`, `heat.exe`, and `insignia.exe` are available. The WiX 3.14 tools are in the **root** of that folder (not a `bin` subfolder). -- Set the `WIX` environment variable to the toolset root (e.g., `%LOCALAPPDATA%\FieldWorksTools\Wix314`). -- Add the toolset root to `PATH` (or rerun `Setup-Developer-Machine.ps1` to do it for you). +WiX 3.11 can be installed with Chocolatey: +``` +choco install wixtoolset --version 3.11.2 +``` +- Ensure tools (`heat.exe` etc.) are available in `%WIX%\bin` or on the PATH. - Install the **Visual Studio WiX Toolset v3 extension** so `Wix.CA.targets` is available to MSBuild. ### Running installer builds diff --git a/Setup-Developer-Machine.ps1 b/Setup-Developer-Machine.ps1 index 42872f1500..dddccce4e3 100644 --- a/Setup-Developer-Machine.ps1 +++ b/Setup-Developer-Machine.ps1 @@ -79,37 +79,15 @@ if (-not $SkipVSCheck) { #endregion -#region Tool Installation - -Write-Host "`n--- Installing Development Tools ---" -ForegroundColor Yellow - -# Determine install locations (use standard paths, not C:\ root for dev machines) -$toolsBase = "$env:LOCALAPPDATA\FieldWorksTools" -if (-not (Test-Path $toolsBase)) { - New-Item -ItemType Directory -Path $toolsBase -Force | Out-Null -} - -# Check what's already installed - -# WiX Toolset -# This worktree builds installers with WiX v6 via NuGet PackageReference (restored during build). -# No separate WiX 3.x installation (candle/light) is required. -Write-Host "[INFO] WiX Toolset v6 is restored via NuGet during build (no WiX 3 install needed)" -ForegroundColor Gray - -# Note: Serena MCP language servers auto-download on first use: -# - C# (csharp): Microsoft.CodeAnalysis.LanguageServer (Roslyn) from Azure NuGet -# - C++ (cpp): clangd from GitHub releases -# No manual installation needed! -Write-Host "" -Write-Host "[INFO] Serena language servers (C# Roslyn, clangd) auto-download on first use" -ForegroundColor Gray - -#endregion - #region Installer Dependencies (Optional) if ($InstallerDeps) { Write-Host "`n--- Setting Up Installer Dependencies ---" -ForegroundColor Yellow + # WiX Toolset + Write-Host "[INFO] WiX Toolset v6 is restored via NuGet during build." -ForegroundColor Gray + Write-Host "[INFO] WiX Toolset v3 installation is your responsibility." -ForegroundColor Yellow + # Detect if we're in a git worktree $gitDir = git rev-parse --git-dir 2>$null $isWorktree = $gitDir -and (Test-Path "$gitDir/commondir")