Wine on arm64 for 32 and 64-bit apps

Questions about Wine on Linux
Locked
scorpion
Level 2
Level 2
Posts: 46
Joined: Sun Dec 02, 2018 12:18 pm

Wine on arm64 for 32 and 64-bit apps

Post by scorpion »

I have an arm64 device I found this project to use wine there: https://github.com/Raezroth/Linux-ARM-Gaming-Chroot.

Installing wine will allow me to run only arm app so I need box86 and/or box64: https://github.com/Raezroth/Linux-ARM-G ... ox86_64.md.

I just want to launch an old game, probably 32-bit, that doesn't need to use steam or others apps.
The last stable version so is more than enough for this

And I prefer to install wine without touching the system apps.
What's a version that I can download and place somewhere in my home?
I am on Debian GNU/Linux bookworm/sid aarch64 (arm64).

Also how can I make sure that wine can do things only in a folder without having to use a chroot and install another system?

I installed box86 and box64.
scorpion
Level 2
Level 2
Posts: 46
Joined: Sun Dec 02, 2018 12:18 pm

Re: Wine on arm64 for 32 and 64-bit apps

Post by scorpion »

I installed wine 32 and 64 on an arm32 chroot (with an arm64 foreign arch):

Code: Select all

WINEARCH=win32 WINEPREFIX=~/.wine winecfg

wine /path/Winmugen.exe
003c:err:service:process_send_command service protocol error - failed to read pipe r = 0  count = 0!
Application could not be started, or no application associated with the specified file.
ShellExecuteEx failed: File not found.

Code: Select all

WINEARCH=win64 WINEPREFIX=~/.wine64 winecfg

WINEPREFIX=~/.wine64 wine64  /path/Winmugen.exe
0108:err:module:load_wow64_ntdll failed to load L"\\??\\C:\\windows\\syswow64\\ntdll.dll" error c0000135

Code: Select all

WINEPREFIX=~/.wine64 wine  /path/Winmugen.exe
wine: could not load kernel32.dll, status c0000135
scorpion
Level 2
Level 2
Posts: 46
Joined: Sun Dec 02, 2018 12:18 pm

Re: Wine on arm64 for 32 and 64-bit apps

Post by scorpion »

I removed wine installed with apt and I followed in part this guide https://github.com/ptitSeb/box86/blob/m ... X86WINE.md.

Now I have this error:

Code: Select all

wine Winmugen.exe 
Box86 with Dynarec v0.2.7 43190d41 built on Oct  2 2022 00:07:32
Box86 with Dynarec v0.2.7 43190d41 built on Oct  2 2022 00:07:32
Box86 with Dynarec v0.2.7 43190d41 built on Oct  2 2022 00:07:32
Box86 with Dynarec v0.2.7 43190d41 built on Oct  2 2022 00:07:32
0024:fixme:d3d:wined3d_guess_card_vendor Received unrecognized GL_VENDOR "lima". Returning HW_VENDOR_NVIDIA.
0024:fixme:ntdll:NtQuerySystemInformation info_class SYSTEM_PERFORMANCE_INFORMATION
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
Loading button config
 for P1 joystick win.
Loading button config
 for P2 joystick win.
0024:fixme:d3d:wined3d_guess_card_vendor Received unrecognized GL_VENDOR "lima". Returning HW_VENDOR_NVIDIA.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
Initializing keyboard
.
Initializing sound.ALSA lib pcm.c:8568:(snd_pcm_recover) underrun occurred
Initializing sound..o
k
Initializing graphics
.
0024:fixme:d3d:wined3d_guess_card_vendor Received unrecognized GL_VENDOR "lima". Returning HW_VENDOR_NVIDIA.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
0024:err:d3d:wined3d_adapter_find_polyoffset_scale PolygonOffset scale factor detection failed, using fallback value 2^23.
wine: Unhandled stack overflow at address 7F5F53FF (thread 011c), starting debugger...
011c:err:virtual:virtual_setup_exception stack overflow 1184 bytes in thread 011c addr 0x7bc3e898 stack 0x2e80b60 (0x2e80000-0x2e81000-0x2f80000)
Can you provide a package that install 32-bit wine for arm devices?
So you can simply install that on arm.
scorpion
Level 2
Level 2
Posts: 46
Joined: Sun Dec 02, 2018 12:18 pm

Re: Wine on arm64 for 32 and 64-bit apps

Post by scorpion »

chroot often don't have binfmt available.
You may want to define BOX86_BASH=/path/to/bash but to the i386 version of bash, not the one from your system (there is one copy in the tests folder of box86 repo).
Launch all you stuff with box86 to compensate for the lack of binfmt....
so like box86 wine myprogram.exe and it should work.
So I need to add box86 in the command.
Otherwise wine won't even start, I managed to get it working (but some problem on this device) somehow with that version that I used.
Instruction from https://box86.org/2022/03/box86-box64-v ... -rosetta2/, you also need box64 in this case:

Code: Select all

cd ~
wget https://www.playonlinux.com/wine/binaries/phoenicis/upstream-linux-amd64/PlayOnLinux-wine-6.0.1-upstream-linux-amd64.tar.gz
mkdir wine
cd wine
tar xf ../PlayOnLinux-wine-6.0.1-upstream-linux-amd64.tar.gz
sudo ln -s $(pwd)/bin/wine /usr/local/bin/wine
sudo ln -s $(pwd)/bin/wine64 /usr/local/bin/wine64
sudo ln -s $(pwd)/bin/wineserver /usr/local/bin/wineserver
sudo ln -s $(pwd)/bin/winecfg /usr/local/bin/winecfg
sudo ln -s $(pwd)/bin/wineboot /usr/local/bin/wineboot
Locked