Winetricks / winetricks

Winetricks is an easy way to work around problems in Wine
GNU Lesser General Public License v2.1
2.66k stars 389 forks source link

Update and fix cnc-ddraw #2199

Open Root-Core opened 3 months ago

Root-Core commented 3 months ago

The current implementation fails, if ddraw.dll is a symlink - like in Proton-GE.

Gcenx commented 3 months ago

If special changes are required for GE-Proton that should really be handled within umu-protonfixes, I've never seen any complaints of simply unpacking the archive caused any Linux users issues so I'll assume this would be Proton specific.

Root-Core commented 3 months ago

I've never seen any complaints of simply unpacking the archive caused any Linux users issues so I'll assume this would be Proton specific.

Nah. This is why there is the w_try_cp_dll() function in first place and it is used for other dlls.

https://github.com/Winetricks/winetricks/blob/f87bf9e6a7c67a06487a1ef710c0d9c548ae6f01/src/winetricks#L748-L751

If special changes are required for GE-Proton that should really be handled within umu-protonfixes,

I don't see a single reason it shouldn't be used here.

Gcenx commented 3 months ago

Yes using w_try_cp_dll() would indeed be valid, is wine on Linux using symlinks more heavily now for prefixes?

The Linux specific comment was more aimed at the usage of -u but I see you’ve added thumbs up to both my other comments.

Gcenx commented 3 months ago

Something that might be worth noting is if something is platform specific (not project specific like Proton) it could always be placed behind a platform guard like I’ve done for the Steam verb for macOS.

Root-Core commented 3 months ago

Yes using w_try_cp_dll() would indeed be valid, is wine on Linux using symlinks more heavily now for prefixes?

I think so. I'm not using wine directly that much though. I know Proton-GE and Lutris are using it. I also searched for symlinks in prefixes that use the Proton provided by Steam and they make heavy use out of it. It makes sense to me, as you don't have to duplicate all files and by replacing a symlink with a file - like in this case - only affects a singular prefix.

The Linux specific comment was more aimed at the usage of -u but I see you’ve added thumbs up to both my other comments.

I will fix it soon. I have only little experience with BSD / MacOS, so I missed that.

I thought an update might be a good thing, but we could just delete files in order to update them.. if necessary. Afaik there isn't really a mechanism to update a fix to a newer version what so ever, so just forget what I just said. :)

Something that might be worth noting is if something is platform specific (not project specific like Proton) it could always be placed behind a platform guard like I’ve done for the Steam verb for macOS.

Good to know, but I don't think that's necessary here. This fix should work on all platforms.