-
Notifications
You must be signed in to change notification settings - Fork 176
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
Error when specifying Package Platform as ARM64 #1557
Comments
This is a difficult one. WiX4 does not longer accept setting the target architecture of the msi package. Instead it requires setting the Thus I can only guess that it might be Anyway, we can solve this problem with a little manual intervention in the build process
This should build the msi. Let me know if it builds correctly and I will integrate this process into the next release. But just to assist you with our test I have built you pre-release packages (attached) that you can use if you do not want to fiddle with the batch file. project.Platform = Platform.x64;
project.InstallerVersion = 500;
project.WixBuildCommandGenerated +=
cmd => cmd.Replace("-arch x64", "-arch arm64"); |
Alright, so I tested manual steps you you posted and I would like to report success, but with some minor adjustments to Bundle building. The msi I generate is later used to build a bundle. First off, bundle cmd file doesn't have Thanks a ton for your help, for looking into this so quickly and coming up with a temporary solution! |
Excellent. Then it is the way to go. I will now implement arm support by automating all these manual steps.
You can add it as bootstrapper.WixOptions += " -arch arm64"; Can you please confirm that the code above generates the correct bundle cmd. And I will check the |
Yes, it does. Extra spaces before and after
Thank you again! |
Hi, I am facing the same problem, but with x86 architecture. Here you can find the allowed values for -arch switch: Your first proposed solution works only for x64, not for other architectures, because other architectures add Platform attribute to Package element. I think the x86 architecture should be the default option according to wix specification. The second solution worked for me too. I tryied to install your WixSharp_wix4 2.1.9-pre, but it failed:
Anyway I think that setting I tryied to add WixOptions += " -arch x86 ". It didn't work for me. It was overwritten by previously inserted "-arch x64" left in the command line from BuildMsi(), e.g.: Can you resolve this issue also for x86 architecture or even better for any type of architectures? Thank you very much! Edit: Could you internally read Platform property of the project set by business logic, set -arch for wix.exe accordingly and reset it to null for further processing, let the Platform attribute of Project element is not set? |
@artlaskow, great, thank you. I wish @talbotsk, you cannot use Anyway, I am planning to do the release on weekend and I am going to add processing of the platform property as it was in WixSharp for wix3.
yes it does it already I only need to add |
@oleg-shilo does wixsharp\Source\src\WixSharp.Samples\Wix# Samples\External_UI\ConsoleSetup\Properties\Resources.resx missing in your repository wix-v4-master? I can't build: |
Sorry. Done |
- The whole round trip implementation for the elevated events (#1565, #1567). Not integrated to the API yet - added `restart elevated` routine for custom BA sample - Issue #1554: Add custom Wizard-like Installer to Bundle / Burn Installer - Implemented `MsiExePackage`. Triggered by #1554 Dedicates sample `WixBootstrapper_MsiEmbeddedUI` shows how to use it ```C# var bootstrapper = new Bundle("Managed Product Bundle", new MsiExePackage(msi) { Name = "ManagedProduct", }); ``` - Issue #1557: Error when specifying Package Platform as ARM64 - WiX4: added `WixProject.WixBuildCommandGenerated` even. Triggered by #1557 - Added `CommonTasks.MapAsDeferredProperty` extension method: ```C# project.MapAsDeferredProperty("MYPROPERTY"); // instead of project.DefaultDeferredProperties += ",MYPROPERTY"; ``` - Added `string.CompleSelfHostedMsi` extension for building self executable msi files: ```C# msi.CompleSelfHostedMsi(msi + ".exe"); ``` - added calling `dotnet tool restore` when using wix as a local tool. Triggered by #1546
- Implemented `MsiExePackage`. Triggered by #1554 The dedicated sample `WixBootstrapper_MsiEmbeddedUI` shows how to use it ```C# var bootstrapper = new Bundle("Managed Product Bundle", new MsiExePackage(msi) { Name = "ManagedProduct", }); ``` - Issue #1557: Error when specifying Package Platform as ARM64 - Added `restart elevated` routine for custom BA sample - Added `WixProject.WixBuildCommandGenerated` event. Can be used to manipulate `wix.exe` command line arguments. Triggered by #1557 - Added `CommonTasks.MapAsDeferredProperty` extension method: ```C# project.MapAsDeferredProperty("MYPROPERTY"); // instead of project.DefaultDeferredProperties += ",MYPROPERTY"; ``` - Added `string.CompleSelfHostedMsi` extension for building self executable msi files: ```C# msi.CompleSelfHostedMsi(msi + ".exe"); ``` - added calling `dotnet tool restore` when using wix as a local tool. Triggered by #1546
Done. |
SilentBA is still not present here on v2.2.0 (or latest wix4 release). I have cobbled together a replacement @oleg-shilo I noticed you seem to have two of them? One in wixsharp.UI and one in wixsharp core that the netcore build references. I think maybe you have a symlink on disk or something and your git is not committing the file. |
Thank you @smaudet. Indeed is is a mistake from my side. Did you mean to post in a different thread? |
What? Did you maybe mean this? #1582 Not sure what else you could mean... |
This thread is about "Error when specifying Package Platform as ARM64". But your post was not related to that so I am checking if you wanted to post it in a different thread and we need to transfer it there. |
@oleg-shilo no it was the right thread:
@talbotsk mentioned this two weeks ago. I posted here because I was searching for SilentBA when I was trying to build it. |
Package used:
<PackageReference Include="WixSharp_wix4" Version="2.1.7" />
.I'm trying to create definition for installer that can be run only on ARM64 system. When specifying
project.Platform = Platform.x64;
installer builds correctly. Ifproject.Platform = Platform.arm64;
is specified, then following error appears:In this example the project is built for x64. I compiled it for ARM64 and ran it on ARM64 machine with the same result.
According to WiX documentation, Package element indeed doesn't contain Platform property https://wixtoolset.org/docs/schema/wxs/package/. I tried to follow the official sample for x64 to target ARM64, but it appears that additional configuration is needed.
What would be the correct way of creating installer for ARM64? I can specify more information if needed.
The text was updated successfully, but these errors were encountered: