-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[WIP] feature: Add support for ARM64 architecture #4071
Conversation
Okay, I have checked this code today on the "real" Windows 10 on ARM devices, and it seems I was mistaken - PowerShell 5 is running in x86 emulation mode, thus I have tested on PSCore 7.0.3 ARM64 build and now it works, properly recognized architecture, works with my custom manifests for ARM64 apps (like Notepad2), yet there are still some rough edges (testing dependencies, warning on installing ARM apps is shown on ARM platforms), and so on. |
If there isn’t an ARM architecture in the manifest, will it default to installing the 32bit architecture, if one exists in the manifest, (as ARM64 will run 32bit in emulated mode)? |
That's actually a thing to consider. At the moment I've implemented it such it won't install - just throws " does not support 'arm64' architecture". You have to use explicit |
@@ -34,6 +34,10 @@ function install_app($app, $architecture, $global, $suggested, $use_cache = $tru | |||
return | |||
} | |||
|
|||
if ((default_architecture -neq "arm64") -and ($architecture -eq "arm64")) { |
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.
((default_architecture) -ne "arm64")
otherwise the "arm64" will be passed to the function as parameter.
I did a rough test on my ARM64 windows. I installed firefox and vscode. Both work for me:
Hopefully this will get some progress. |
I am sorry I left this one for such a long time without any progress (or even response to @zhzy0077). It's all because of some personal issues and lack of access to WoA device anymore. It seems that apart from It seems that also x64 emulation is planned -- but I do not know if is already working. If it is, we can now only decide what is the preferred architecture: I think it should be ARM64, x64 and x86, in that order. That means if there is no arm64 in the manifest, it will try to install x64. |
@ktos What I'm concerning is the installation order. For example, there will never be 64bit GPU drivers for Qualcomm 835/850, which means apps using GPU can work well in x86 but badly in amd64. My suggestion is to give some notes when the ARM version is not found and let user to decide the fallback architecture. I have my Surface Pro X and can help if any test is needed. |
Superceded by #5154 |
I am not 100% sure if it should be done that way, but I've tried myself in adding basic support for ARM64 architecture, apart from "32bit" and "64bit" scoop has already. The discussion was started in #3146.
It requires of course changes to the manifest - apart from two already existing architectures, third one was added, with "arm64" moniker (while "aarch64" and "armv8" are also supported in parameter list).
To recognize if we are running on Windows on ARM (WoA), the
$env:PROCESSOR_ARCHITECTURE
is used, as WOW64 documentation suggests.I have added warnings when trying to install ARM64 application on non-ARM system (but there should be nothing to stop the user at all - it's their decision) and when there is no architecture given in manifest - on ARM64 system it will require explicit
scoop install -a 32bit foobar
for example.I am marking this as WIP at the moment, as checkhashes/checkurls.ps1 has not been yet modified to work with ARM64.
What do you think?