alt-app-installer icon indicating copy to clipboard operation
alt-app-installer copied to clipboard

arm64 support

Open xgdgsc opened this issue 1 year ago • 9 comments

https://github.com/mjishnu/alt-app-installer/blob/3619afce0a348b3e197daa5cc667a59631fe7306/app/modules/url_gen.py#L27

I had to change this to return "arm64" to download successfully.

The arm version Python PyQt6 has some installation issues so I have to run the x64 Python version. Maybe adding an arm64 checkbox now can be fine.

And how to do the packaging to exe?

xgdgsc avatar Jun 19 '24 07:06 xgdgsc

hey would you be willing to test this, i do not own an arm pc so was unable to test it

import platform

def os_arc():
    if platform.machine().endswith("64"):
        return "x64"
    if platform.machine().endswith("32") or platform.machine().endswith("86"):
        return "x86"
    if platform.machine().endswith("arm64"):
        return "arm64 endswith success"
    if platform.machine().endswith("arm"):
        return "arm endswith success"
    if platform.machine().startswith("arm64"):
        return "arm64 startswith success"
    if platform.machine().startswith("arm"):
        return "arm startswith success"
    return platform.machine()

print(os_arc())

what does the output shows ?

if this works we dont need a toggle it will automatically figure it out, the packaging is done using pyinstaller

mjishnu avatar Jun 19 '24 07:06 mjishnu

image Left is x64 version of Python running on arm and right is native arm64.

The problem for me is installing pyqt6 on arm64 python. Or provide a cli version could be fine.

xgdgsc avatar Jun 19 '24 08:06 xgdgsc

import platform

def os_arc():
    machine = platform.machine().lower()

    if machine.endswith("arm64"):
        return "arm64"
    if machine().endswith("64"):
        return "x64"
    if machine.endswith("32") or machine.endswith("86"):
        return "x86"
    else:
        return "arm"

print(os_arc())

can you try now, i see that even if i do a logic like this it would be waste since you are not able to run it in arm64 python but still in future it might work so if you can please provide output of this test it would be great.

The problem for me is installing pyqt6 on arm64 python. Or provide a cli version could be fine.

try older version of pyqt, currently i am rewriting the program from scratch to c#, and not doing any major changes. let me see what i can do about cli if it aint too complicated i would implement it.

mjishnu avatar Jun 19 '24 08:06 mjishnu

This is fine.

>>> print(os_arc())
arm64

c# can compile arm version pretty easily.

xgdgsc avatar Jun 19 '24 09:06 xgdgsc

here is a cli version of alt app installer: https://github.com/mjishnu/alt-app-installer-cli

mjishnu avatar Jun 20 '24 08:06 mjishnu

image Guess this is because arm python cannot load the dll?

xgdgsc avatar Jun 20 '24 10:06 xgdgsc

did you install python net

mjishnu avatar Jun 20 '24 10:06 mjishnu

image Guess this is because arm python cannot load the dll?

this new release should fix it, no longer using python net using subprocess module instead https://github.com/mjishnu/alt-app-installer-cli/releases/tag/v1.0.1

mjishnu avatar Jun 20 '24 13:06 mjishnu

Great. It works. Might as well adding argument for downloading for other manually specified architecture, rather than relying on the interpreter arch?

xgdgsc avatar Jun 21 '24 04:06 xgdgsc

Great. It works. Might as well adding argument for downloading for other manually specified architecture, rather than relying on the interpreter arch?

i know its been long but if you are still wondering i have added the option to set custom architecture in alt app installer cli

mjishnu avatar Aug 03 '25 20:08 mjishnu