0

Someone suggested to look at Cannot build WIX project on windows 10 But this is not the same issue, it actually works on Windows 10, but not on the build server. The real solution is here as I cannot even post the REAL answer anymore dispite asking for opening this case A WEEK AGO

In my current project, I get this error on the buildsever It works on my computer, with Windows 10. The issue is only on the build server. The error will not happen if I remove the WIX installation project from build configuration. The issue has to be related to the Wix project

Error MSB4062: The "WixAssignCulture" task could not be loaded from the assembly C:\Program Files (x86)\WiX Toolset v3.11\bin\WixTasks.dll. Could not load file or assembly 'Microsoft.Build.Utilities, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. The system cannot find the file specified.

I currently have the path to wix 3.11 in the project file, but I can also get the error to WiX Toolset v3.x\bin\WixTasks.dll if I want.

<PropertyGroup>
  ...
  <WixInstallPath>C:\Program Files\Wix Toolset v3.11\bin</WixInstallPath>
</PropertyGroup>

What I really want to know is why WixAssignCulture is not available on the build server but is on local computers. Latest Wix version is on the build server, so it should be fine.

The application itself is made in .Net 6

Any ideas how to fix this?

ANSWER: In order to make it work on a MS Build server, it is needed to add the propery

  <PropertyGroup>
    ...
    <SuppressValidation>true</SuppressValidation>
  </PropertyGroup>

And the wix project does not build with MS Build, as .Net Core does not build wix projects

Then it is possible to make this work on MS Build servers

And now someone can removed the duplicate, as it is not a duplicate - I have asked for this but I never got any response!!!!!

sonnich
  • 151
  • 2
  • 11

0 Answers0