-
Notifications
You must be signed in to change notification settings - Fork 452
Add ARM64 support #641
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
base: master
Are you sure you want to change the base?
Add ARM64 support #641
Conversation
NB: WiX 3.14.0.3910 or higher is required to create the MSI
Unfortunately it seems that AppVeyor images contain 3.11 only :( |
Actually WiX 3.14 is just development build, not stable one. So I guess for now we cannot merge this to master. I'd suggest to not build ARM64 by default. Just add some possibility if one would like to try it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me 👍
Pity that WiX ARM64 support is not in stable yet :(
Re: the AppVeyor build: I agree that it's undesirable to have a build batch file that doesn't work on AppVeyor by default. However I see some problems with the 'optional parameter' approach: the build of An option could be to make a separate 'Release with ARM64' configuration for the Setup project, so that the default Release configuration includes only the x86 and x64 MSIs, and only the new configuration would include all three MSIs. But this would require some additional changes to the Setup project. I see another alternative that may work better: while AppVeyor does not support WiX 3.14, it does provide access to |
Well, I personally don't like idea of using devel version of software just to support very small amount of users. These are my personal views, maybe @coddec, @XenHat have different views on this. But to be constructive, what about this: We can keep installer as it was (x86 + x64) and produce separate ARM64 installer (basically just MSI should be enough). Only ARM64 build will then use devel version of WiX (that can be downloaded when needed as you proposed). What do you think? |
I agree with you @ge0rdi |
Thanks for the feedback. Summarizing, so far it seems like the way forward for ARM64 is to make a separate installer (and maybe even split x86 and x64 into separate installers as well? I'll leave this up to you guys). This is fine by me, and as has been pointed out it will reduce the download size for both binaries. What should be the preferred way to build the ARM64 setup? Should there be (a) new batch file(s) to create it (think e.g. If the answer to the above is 'don't worry about this, someone else will take care of the installer', or 'do this in another PR', that's fine by me too. I mostly wanted to make this PR to add ARM64 support to Open-Shell, not necessarily Open-Shell's installer :) Though I'm OK with doing it if this is desirable. |
@Mattiwatti
I think separate BAT may be easier to do. Basically from my POV both ways make sense.
Yup. That would make sense, so it will be backward compatible. Though in case when some argument will be present it probably should mean list of platforms to build.
Right. Depending on the way the ARM64 build will be integrated we can modify |
I've pushed a new commit that separates the x86/x64 installer from the ARM64 one instead of the previous iteration where the setup was combined. The new ARM64 setup can be built with
I agree this would be preferable, but I'll leave this as a "nice to have" TODO for now. I spent some time trying to make this work for generic lists of architecture names (e.g. "x86 x64 ARM64 foo"), but with all the added batch file boilerplate and error checking the batch files (plural, because there are multiple batch files that all need to know which architecture(s) is/are being built) quickly became very unwieldy with most of the lines "wasted" on simply parsing the architecture(s) to build. So I reverted to the simpler method above for now. |
Late to the party here. I agree with the sentiment that architectures should be split. What's the status on this? Waiting for Wix to be stable? |
I just bought an ARM64 device and built from Mattiwatti's branch to install. Is there anything I can do to help move this forward? Getting it installed from source worked in the end but was a rough experience (I've never built this code before.) The only thing I encountered is Utility.rc is trying to include the AMD64 binary (so the x86 binary includes the AMD64 one?) In this build sequence though, BuildBinaries.bat only builds ARM64, not AMD64, so the later x86 build fails because it can't find the AMD64 binary. |
@coddec , could Ibuprophen have the "ownerstate" because he is active here and he is everytime here, have a good character and know what he does.. |
Oki, so I have merged current master to this PR and resolved conflicts. Everyone interested in testing on ARM64 devices, please feel free to use installer from: And again one big thanks to @Mattiwatti who started this and did all the hard work. |
These are meant to be loaded to both x64 and ARM64 processes. We will compile them as ARM64X (when building for ARM64). That way they will contain both x64 and ARM64 code paths. https://learn.microsoft.com/en-us/windows/arm/arm64x-pe
There is another build here: Please, use this one for testing. |
|
@ftc2 Could you try to run installer with (sorry, I have no ARM64 machine at hand atm) |
For what it’s worth, the installer works correctly for me on 23H2/22631. The installer stub is x86 but it correctly found and installed the arm64 MSI. I’m quite surprised by that error – I think it’s from pcasvc indicating a known appcompat problem, not an error indicating a corrupt binary or unsupported architecture. But if that’s true it should affect any Wix 3.14 installer on 26100 arm64.
|
@ftc2 You also seem to be on beta Windows channel, but rather old build. Maybe try to update to latest build to see it that helps? |
i was amused to see that the 'Learn more' button opens anyway, i opened up terminal running powershell and tried these: .\OpenShellSetup_4_4_196-rikfexxu.exe --extractARM64
.\OpenShellSetup_4_4_196-rikfexxu.exe /extractARM64 is that how you run windows software with params? neither worked. both gave the same error as in my last post, and neither extracted anything to the working dir or to the exe's dir. i tried to extract the msi manually but couldn't figure it out. i unpacked the exe:
renaming those files in MSI_FILE to
good eye. it would not surprise me at all if that's the issue. the build's not that old – it was fully up to date a little less than a year ago when i installed it and then ran windows update. it's an airgapped vm (lol) and has to be that way, sorry. that's all i have for now. i have not had trouble installing any other software on this thing, and while i feel it should be supported, i'm ok with just assuming it would work on a slightly more standard installation of windows if you are. maybe revisit the issue if someone else complains? i'll just rock @malxau's build on this vm. if you really want, i can make a new vm with the latest win11 arm64 image test it again, though. lmk. |
Just use the parameter as I wrote without anything else:
Hehe, funny how relative that is. To me a year old Windows is very old ;)
Well, it is up to you how much do you want to test this and spend your time with it. |
ok, i'll make a new vm in the next day or so :) |
same result as my other attempts (didn't work) |
I got access to ARM64 machine with Win11 24H2 and getting the same PCA compatibility issue dialog. |
Windows (24H2 so far?) seems to have some compatibility block for It was enough to rename the installer ( Trying to figure out how to deal with this (without changing the name of installer obviously). |
haha |
Yes. The block was added April 2024, so I don’t have it. It looks like StartMenuHelper64.exe (Amd64) was being injected into Explorer on Arm64 systems, causing Explorer to crash, hence the block. I’ve started an email thread to find the best process to alter or remove it.
|
In case if somebody manually tries to install x64 MSI on ARM64. This is not supported/working scenario.
Hmm, this will actually break built-in updater. As it looks for
Fingers crossed. |
I think the advice is to release an ARM64-capable version and let them know the version number so anything above that can be excluded from the check. As you’ve seen the current block does not have any version restriction, so this still sounds like it will require a Windows Update. On the other hand, note the ARM64 experience doesn’t change – currently users have a block, once an ARM64 build is released they’ll have a block (with a workaround) and it’ll probably take a couple months for the block to be relaxed.
|
This PR adds ARM64 support to Open-Shell. See also #553 where this feature was requested.
The changes are not spectacularly interesting and mostly consist of adding a third supported platform to the two existing ones. The only part I'm not quite sure about is the FNV hashes of the MSIs that go into the setup; while it seems to work (the installer works on all three platforms for me) it probably wouldn't hurt if someone double-checked this.
Note that WiX has only added support for ARM64 in v3.14.0.3910. This means I've had to raise the required version used in the build script and documentation from 3.7 to 3.14. Edit: and I see the AppVeyor build failed because of this.