Catalina and the future of Wine on Mac

Questions about Wine on macOS.
Locked
Maximara
Level 2
Level 2
Posts: 14
Joined: Wed Jun 26, 2019 8:01 am

Catalina and the future of Wine on Mac

Post by Maximara »

With 32-bit program support going away on the Mac with Catalina we need to start seriously figuring out how to have WINE run on these newer systems so that reasonable instructions can be provided.

Right now we can use VMs (VirtualBox, Parallels, VM Fusion) using other operating systems (Ubuntu, Red Hat, or if you can actually get it to work an older version of the MacOS) thought doing this correctly is kind of 'uhhh, how do you do that?'

But is that the best (ie easiest) solution we can come up with or is there some other method on the table we could use?
Gcenx
Level 6
Level 6
Posts: 709
Joined: Mon Dec 25, 2017 12:11 pm

Re: Catalina and the future of Wine on Mac

Post by Gcenx »

Multiple options are being looked into by CodeWeavers but no official announcement had been made.

Right now if someone wants to use wine they shouldn’t upgrade past Mojave if you want to use Wine natively on macOS.


Parallels Desktop (since that uses the native hypervisor.framework) can be used to run Windows with DirectX10 support at the moment maybe they will support DirectX11 sooner or later.

Booting Linux would also be an option but I would avoid Ubuntu (recent multilib debacle) instead picking Pop!_OS as its still Ubuntu/Debian based but includes much newer packages/libs and has Lutris/PlayOnLinux already in the store as well as Steam.
User avatar
DarkShadow44
Level 8
Level 8
Posts: 1207
Joined: Tue Nov 22, 2016 5:39 pm

Re: Catalina and the future of Wine on Mac

Post by DarkShadow44 »

It's not really that we need to figure out what needs to be done, someone needs to actually do it. CodeWeavers is working on it, AFAIK.
All the options we have are pretty difficult - Apple was pretty throughout with removing 32bit support. What's left is virtualization and emulation, and integrating that is a PITA. 32bit <-> 64bit thunking is basically a must. And that takes time and a lot of effort. Not to mention getting the performance right...
Gcenx
Level 6
Level 6
Posts: 709
Joined: Mon Dec 25, 2017 12:11 pm

Re: Catalina and the future of Wine on Mac

Post by Gcenx »

DarkShadow44 wrote:It's not really that we need to figure out what needs to be done, someone needs to actually do it. CodeWeavers is working on it, AFAIK.
All the options we have are pretty difficult - Apple was pretty throughout with removing 32bit support. What's left is virtualization and emulation, and integrating that is a PITA. 32bit <-> 64bit thunking is basically a must. And that takes time and a lot of effort. Not to mention getting the performance right...
I agree. Catalina can’t even run 32Bit code natively as someone told me they tested running a 32Bit binary with all needed Dylibs/frameworks but it failed at the kernel level..

It’s possible to use hyperviser.framework but I haven’t seen any Public work on that being used for wine.

The trunking idea public code has even tested but no luck yet

For now anyone running macOS I would recommend not upgrading past macOS Mojave
User avatar
DarkShadow44
Level 8
Level 8
Posts: 1207
Joined: Tue Nov 22, 2016 5:39 pm

Re: Catalina and the future of Wine on Mac

Post by DarkShadow44 »

Gcenx wrote:I agree. Catalina can’t even run 32Bit code natively as someone told me they tested running a 32Bit binary with all needed Dylibs/frameworks but it failed at the kernel level..
I've yet to check their GDT, but it seems they simply don't allow for 32bit segments anymore. If we could load a new GDT...
Would still require tons of thunking though.
Gcenx wrote:The trunking idea public code has even tested but no luck yet
What do you mean? Hangover?
Gcenx
Level 6
Level 6
Posts: 709
Joined: Mon Dec 25, 2017 12:11 pm

Re: Catalina and the future of Wine on Mac

Post by Gcenx »

DarkShadow44 wrote:I've yet to check their GDT, but it seems they simply don't allow for 32bit segments anymore. If we could load a new GDT...
Would still require tons of thunking though.
The kernel blocks 32Bit code execution. I’m not sure what actaniym you mean with GDT?
DarkShadow44 wrote:What do you mean? Hangover?
Tried hangover on macOS and it’s useless at precent it actually loads less things then it does on an arm64 system.

No I’m talking about a custom version of llvm/clang that ccdavis worked with that’s looks like builtin trunking generation code and a new flag -mwine32.

At the moment -mwine32 is useless but the fact it has builtin support for ms_hook_proludge means it’s great for compiling wine as it’s now used within Phoenicis-Winebuild for the macOS environment after I brought it up with qparis.
User avatar
DarkShadow44
Level 8
Level 8
Posts: 1207
Joined: Tue Nov 22, 2016 5:39 pm

Re: Catalina and the future of Wine on Mac

Post by DarkShadow44 »

Gcenx wrote:The kernel blocks 32Bit code execution. I’m not sure what actaniym you mean with GDT?
I mean the Global Descriptor Table. AFAIK 32Bit support is a CPU feature, not a kernel feature. Even when running a 64bit process on linux/windows, you can switch to executing 32bit code easily. But in macOS you can't, because you need a corresponding entry for 32bit in the GDT.
If I'm not mistaken, that would allow us to run 32Bit code without needing emulation or virtualization.
Gcenx wrote:No I’m talking about a custom version of llvm/clang that ccdavis worked with that’s looks like builtin trunking generation code and a new flag -mwine32.
At the moment -mwine32 is useless but the fact it has builtin support for ms_hook_proludge means it’s great for compiling wine as it’s now used within Phoenicis-Winebuild for the macOS environment after I brought it up with qparis.
I don't know about that, where'd you hear this? How does this address the conversion of structures inside the thunks?
Gcenx
Level 6
Level 6
Posts: 709
Joined: Mon Dec 25, 2017 12:11 pm

Re: Catalina and the future of Wine on Mac

Post by Gcenx »

DarkShadow44 wrote: I mean the Global Descriptor Table. AFAIK 32Bit support is a CPU feature, not a kernel feature. Even when running a 64bit process on linux/windows, you can switch to executing 32bit code easily. But in macOS you can't, because you need a corresponding entry for 32bit in the GDT.
If I'm not mistaken, that would allow us to run 32Bit code without needing emulation or virtualization.
Ah ok I was thinking of something else that’s what a lack of sleep does, while it’s true the CPU can still run 32Bit code but if the kernel doesn’t have any 32Bit features embeddd (This is Apple so I expect they didn’t include any 32Bit support within the new Kernel)
DarkShadow44 wrote:I don't know about that, where'd you hear this? How does this address the conversion of structures inside the thunks?
It was mentioned on the last wine conference video I remember them talking about running 32Bit code within a 64bit thread and it ran at native speeds.

As for where I heard about the custom version of Clang I just checked what ccdavis had visible on github https://github.com/cdavis5e/clang/tree/wine32 and he also had a version of llvm to go with it also. Seems they want to use llvm to handle the trunking unless I’m not understanding something check out the code within clang and llvm. As I see mentioning of handling 32>64 bit structures and the reverse or just do a quick check over the commits
sslalani
Newbie
Newbie
Posts: 2
Joined: Fri Jul 19, 2019 1:10 pm

Re: Catalina and the future of Wine on Mac

Post by sslalani »

What's the update for Wine on Catalina? I upgraded yesterday to Catalina beta version and wine stopped working. My MT4 trading platform, especially algos, have stopped working :(
User avatar
DarkShadow44
Level 8
Level 8
Posts: 1207
Joined: Tue Nov 22, 2016 5:39 pm

Re: Catalina and the future of Wine on Mac

Post by DarkShadow44 »

sslalani wrote:What's the update for Wine on Catalina? I upgraded yesterday to Catalina beta version and wine stopped working. My MT4 trading platform, especially algos, have stopped working :(
There is none yet. Wine on Catalina isn't able to run 32bit software, currently the only way to run your software is to downgrade macOS.
Gcenx
Level 6
Level 6
Posts: 709
Joined: Mon Dec 25, 2017 12:11 pm

Re: Catalina and the future of Wine on Mac

Post by Gcenx »

sslalani wrote:What's the update for Wine on Catalina? I upgraded yesterday to Catalina beta version and wine stopped working. My MT4 trading platform, especially algos, have stopped working :(
Downgrade back to Mojave or High Sierra if you want to keep using wine, macOS Catalina has no 32Bit and wine needs this to function. You never blind upgrade to a Beta or even a new release if you have mission critical software always test within a controlled environment first.

Nobody knows how long it will take for a viable solution to be implemented making wine usable on macOS Catalina, so if you need wine your stuck on Mojave until this happens.


Seems DarkShadow44 beat me to this.
sslalani
Newbie
Newbie
Posts: 2
Joined: Fri Jul 19, 2019 1:10 pm

Re: Catalina and the future of Wine on Mac

Post by sslalani »

Thanks DarkShadow44 and Gcenx
Maximara
Level 2
Level 2
Posts: 14
Joined: Wed Jun 26, 2019 8:01 am

Re: Catalina and the future of Wine on Mac

Post by Maximara »

DarkShadow44 wrote:
sslalani wrote:What's the update for Wine on Catalina? I upgraded yesterday to Catalina beta version and wine stopped working. My MT4 trading platform, especially algos, have stopped working :(
There is none yet. Wine on Catalina isn't able to run 32bit software, currently the only way to run your software is to downgrade macOS.
So even running in a VM under Catalina doesn't work?
User avatar
DarkShadow44
Level 8
Level 8
Posts: 1207
Joined: Tue Nov 22, 2016 5:39 pm

Re: Catalina and the future of Wine on Mac

Post by DarkShadow44 »

Welp, running a VM should work as well. But I have no idea how the legal status of that is, virtualizing macOS is not what they want.
Gcenx
Level 6
Level 6
Posts: 709
Joined: Mon Dec 25, 2017 12:11 pm

Re: Catalina and the future of Wine on Mac

Post by Gcenx »

Maximara wrote:So even running in a VM under Catalina doesn't work?
If your willing to run a VM might as well just run a Windows 10 VM and get access to DirectX 10, as running macOS within a VM I've found gives terrible performance with current macOS releases.
Or just downgrade to Mojave as that's the latest release that provides 32Bit support and Apple will support that for the next few years.

DarkShadow44 wrote:Welp, running a VM should work as well. But I have no idea how the legal status of that is, virtualizing macOS is not what they want.
You can run a VM of macOS on a system running macOS that's allowed within the License that's why your able to install macOS within VMWare Fusion/Parallels Desktop.


Interesting Side Note;
VMWare's core is actually the same across platforms that's why it's possible to run macOS on Windows/Linux if you patch VMWare Player/Workstation to enable the macOS option. (I'm not going to explain how this is done, just that it's possible)
Maximara
Level 2
Level 2
Posts: 14
Joined: Wed Jun 26, 2019 8:01 am

Re: Catalina and the future of Wine on Mac

Post by Maximara »

Gcenx wrote:
Maximara wrote:So even running in a VM under Catalina doesn't work?
If your willing to run a VM might as well just run a Windows 10 VM and get access to DirectX 10, as running macOS within a VM I've found gives terrible performance with current macOS releases.
Or just downgrade to Mojave as that's the latest release that provides 32Bit support and Apple will support that for the next few years.
I was thinking more along the lines of having Redhat or some other form of Linux if the MacOS wasn't an option. A small Linux with just enough to install and run Wine would be IIUC all we would need.
Gcenx
Level 6
Level 6
Posts: 709
Joined: Mon Dec 25, 2017 12:11 pm

Re: Catalina and the future of Wine on Mac

Post by Gcenx »

Maximara wrote:I was thinking more along the lines of having Redhat or some other form of Linux if the MacOS wasn't an option. A small Linux with just enough to install and run Wine would be IIUC all we would need.
A native install of Linux on your Mac if the district fully support the hardware could mostly work but the CPU turning used within macOS isn’t available for any other OS ran on Mac hardware.


Now for running a VM of Linux to then run wine to run a Windows application makes little sense and will end up being much slower then directly running Windows or running an older version of macOS to the run wine.

Let me use Parallels 15 as an example for this since it supports DirectX11.
(VMWare fissions current release supports up to DirectX10 & VirtualBox properly just DirectX9 on macOS due to the OpenGL backend)

Windows 10;
- DirectX1-11 > Metal

Linux;
- WineD3D DirectX > OpenGL > Metal

So running Linux would require an addition layer to translation
rjhancock
Level 1
Level 1
Posts: 9
Joined: Tue Sep 10, 2019 11:26 am

Re: Catalina and the future of Wine on Mac

Post by rjhancock »

Catalina has a release date set for October and CodeWeavers is being quiet on the matter.

Do y'all believe Wine will be ready for Catalina when it is released?
Gcenx
Level 6
Level 6
Posts: 709
Joined: Mon Dec 25, 2017 12:11 pm

Re: Catalina and the future of Wine on Mac

Post by Gcenx »

CodeWeavers are quite because it’s a lot of work that’s involved in making this all work.

It might not even be ready for Catalina’s launch, if wine is so important to you simply don’t upgrade past Mojave until you see an announcement saying wine is now working on Catalina.
User avatar
DarkShadow44
Level 8
Level 8
Posts: 1207
Joined: Tue Nov 22, 2016 5:39 pm

Re: Catalina and the future of Wine on Mac

Post by DarkShadow44 »

Gcenx
Level 6
Level 6
Posts: 709
Joined: Mon Dec 25, 2017 12:11 pm

Re: Catalina and the future of Wine on Mac

Post by Gcenx »

Well at least i now know I was reading the code compactly enough within the custom clang version that they built.

I can’t wait to try out CrossOver19 when beta testers get their usual emails, I just hope later they don’t remove any changes to the source since it hoping to just go and compile CrossOver19 with the custom clang later so I have something to play with
Maximara
Level 2
Level 2
Posts: 14
Joined: Wed Jun 26, 2019 8:01 am

Re: Catalina and the future of Wine on Mac

Post by Maximara »

I must say Codeweavers have a lot of work on their hands but it does raise another question in my mind - are there going to be two parallel versions of WINE in the future? Ie one for *nux and one for MacOS for Catalina and beyond.
Gcenx
Level 6
Level 6
Posts: 709
Joined: Mon Dec 25, 2017 12:11 pm

Re: Catalina and the future of Wine on Mac

Post by Gcenx »

I don’t see the wine codebase splitting, the Darwin specific items are behind already behind if statements.

The custom version of clang also contains Linux sections so it’s possible this will become a universal solution for distributions that don’t provide 32Bit libs.
rjhancock
Level 1
Level 1
Posts: 9
Joined: Tue Sep 10, 2019 11:26 am

Re: Catalina and the future of Wine on Mac

Post by rjhancock »

They have more to deal with than what they posted. The D3D backend needs to be updated to use Metal vs OpenGL (Vulkan might work as a replacement as well) as Apple will be getting rid of OpenGL pretty soon on their platform.
fgamer
Newbie
Newbie
Posts: 3
Joined: Tue Oct 01, 2019 4:22 pm

Re: Catalina and the future of Wine on Mac

Post by fgamer »

Hello guys... I'm follow this topic and I would like to know if there is any update about it...

Thank you!
Locked