volks73 / cargo-wix

A cargo subcommand to build Windows installers for rust projects using the WiX Toolset
https://volks73.github.io/cargo-wix
Apache License 2.0
306 stars 25 forks source link

Wix V4 Error "The compiler application (candle) could not be found" #202

Open RandyMarsh1 opened 1 year ago

RandyMarsh1 commented 1 year ago

Update Issue is related to using Wix V4, to resolve you must uninstall V4, install V3 from here and reboot.

Original: I'm trying to use cargo-wix for the first time with Wix V4 but get the following error when running 'cargo wix'

Error[2] (Generic): The compiler application (candle) could not be found in the PATH environment variable. Please check the WiX Toolset (http://wixtoolset.org/) is installed and check the WiX Toolset's 'bin' folder has been added to the PATH system environment variable, the WIX system environment variable exists, or use the '-b,--bin-path' command line argument.

Could this be related to Wix V3 to V4 compatibility? If so can we please update the README.md

Versions: Wix 4.0.1 (installed via CLI .NET tool) cargo-wix v0.3.4 .Net 7.0.400 Rust 1.67 Windows 11

volks73 commented 1 year ago

Thank you for your interest and detailed information.

This project does not currently support WiX v4. It currently only supports WiX v3.

There is discussion and planning for support of WiX v4 in #174. In short, WiX v4 is a major release that uses a single command (wix) instead of two commands (candle and light) to create installers and the XML schema has changed. Thus, it is not a simple migration.

roblabla commented 1 year ago

It may be worth rewording the error message to point to wix toolset v3 explicitly. It may be worth detecting if wix is installed, and writing an error message explicitly guiding people to the wix toolset v3 installer.

fdciabdul commented 7 months ago

is there any update for this?

volks73 commented 7 months ago

Are you wondering about progress on an updated error message or support for WiX v4?

RaeveNoir commented 5 months ago

Currently all documentation points to wixtoolset.org which lists installation instructions without any particular version information. This includes installing via dotnet tool install --global wix which installs version 4.0.4.

I would suggest linking more directly to https://github.com/wixtoolset/wix3/releases/ instead, and make this more clear in all documentation.

volks73 commented 5 months ago

I would be happy to review and merge a PR that contains an updated URL for WiX Toolset v3.

Kyu commented 5 months ago

Creating a PR,
But first adding my steps here for future readers.

  1. Download latest Wix3 from here. Latest is 3.14.1 as of writing.
  2. (interactive) Open the Wix3 install executable.
  3. (non interactive) Run command: .\wix314.exe /install /quiet /norestart
  4. Fun and Profit.

edit: cannot find the docs in the source of this repo, they seem to be behind your github page site, which is private

mzdk100 commented 3 weeks ago

I just encountered this issue and I think it's very necessary to clarify the supported versions of Wix in the readme, as Wix is now v5.