Summary: | emulators/wine: Update to 6.0.1 to match emulators/i386-wine ports | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | Ports & Packages | Reporter: | Thibault Payet <monwarez> | ||||||||
Component: | Individual Port(s) | Assignee: | Gerald Pfeifer <gerald> | ||||||||
Status: | Closed FIXED | ||||||||||
Severity: | Affects Only Me | CC: | Alexander88207, damjan.jov, dmenelkir, gerald, iwtcex, kbowling | ||||||||
Priority: | --- | Keywords: | needs-qa | ||||||||
Version: | Latest | Flags: | gerald:
maintainer-feedback+
|
||||||||
Hardware: | Any | ||||||||||
OS: | Any | ||||||||||
See Also: | https://bugs.winehq.org/show_bug.cgi?id=50257 | ||||||||||
Attachments: |
|
Description
Thibault Payet
2021-07-19 19:29:15 UTC
Hello, normally I wait until the main ports emulators/wine or emulators/wine-devel have been updated as this is how the i386 ports are intended. I prioritize that the ports should be up to date so I took the matter into my own hands and created an i386 version of the port quickly since it's been a while since 6.0 came out. Nowadays it is easier to install the i386 packages in a folder and put the env to the folder in there or not? Sorry for the inconvenience. Created attachment 226624 [details]
Patch to update emulators/wine to version 6.0.1
This patch successfully builds, alas will need some additional changes
to account for upstream not working on FreeBSD out of the box now.
Additions/suggestions/patches very welcome!
(In reply to Alexander Vereeken from comment #1) My current setup is to install i386-wine system wide, and then extract wine into a folder. Then I just had to run $WINE_64_BINPREFIX/wine64 to launch a 64bit executable and wine for 32bit executable. Even if I install i386-wine in a folder, I will have the issue of 64bit program that use 32bit executable. Indeed if wine64 is at version 5.0.4 there is no way that it will allow to run with a i386-wine version 6.0.1 . For the moment I have to lock i386-wine. Is there information on what is not working with wine64 (the version 6.0.1) ? (In reply to Thibault Payet from comment #3) We have been hit by this https://bugs.winehq.org/show_bug.cgi?id=50257 The workaround is to use LD_BIND_NOW=1 for 64-bit and LD_32_BIND_NOW=1 for 32-bit. (for WoW64 using both) In practice: LD_BIND_NOW=1 wine64 /path/to/exe Or export LD_BIND_NOW=1 wine64 /path/to/exe I do have included this workaround already in the i386-wine packages but this was not done but for the normal packages. The easiest solution would be to put the env variable before the wine binary in script like similar to the binbounce for the i386-wine packages. So if you update wine 6.0.1 over the ports using geralds patch and have a script that holds your wow64 spagehtti together then just add the above workaround. (In reply to Alexander Vereeken from comment #4) > I prioritize that the ports should be up to date so I took the matter > into my own hands and created an i386 version of the port quickly since > it's been a while since 6.0 came out. The problem is this broke users (when Wine 5.0.x was just working for them). (In reply to Alexander Vereeken from comment #4) > So if you update wine 6.0.1 over the ports using geralds patch and have > a script that holds your wow64 spagehtti together then just add the above > workaround. Let's see how we can help users so that they do not need "spaghetti scripts" of their own. I'm thinking to move the wine/wine64 binaries to something like wine_/wine64_ and put in scripts as wine/wine64 to set LD_32_BIND_NOW/ LD_BIND_NOW and then exec the binaries. (In reply to Gerald Pfeifer from comment #5) > Let's see how we can help users so that they do not need "spaghetti scripts" > of their own. My proposal remains the same: https://gist.github.com/shkhln/e39432d8b5f8d62da9b7d55aad641ddd (slightly revised in https://github.com/freebsd/freebsd-ports/commit/d8fafe84bd58baef7d4e2696cc16bcf67db4cf3d). I'm, however, getting mixed signals whether I should submit a patch for wine or wine-devel. (In reply to Gerald Pfeifer from comment #5) > Let's see how we can help users so that they do not need "spaghetti scripts" > of their own. I don't want to get on your nerves with this too but Alex's installing i386 pkgs method is the easiest and fairly a clean solution when it comes to wow64 without a cross-building system. (In reply to Alex S from comment #6) > I'm, however, getting mixed signals whether I should submit a patch > for wine or wine-devel. Yes, please. :-) I you submit a minimal patch on top of my upgrade that makes Wine 6.0.1 work in your tests/for your purposes, I'll see to get that and the update committed swiftly. Thank you! Created attachment 226662 [details] wow64 wrapper + ld_preload workaround Here's the wow64 wrapper patch. Synth is not in the mood today, so this was only tested with traditional local builds. Notable limitations: 1. pkg32.sh doesn't work with fancy multi-repo setups (bug #257107); 2. This wrapper doesn't attempt to handle the nvidia-driver <= 390 use case, I'd suggest using nvidia.sh from i386-wine for that. Also, as an alternative to pkg32.sh usage, it's possible to build and install 32-bit Wine directly in a chroot. Then one needs to set WINE_i386_ROOT env variable to the chroot's location. For example, `env WINE_i386_ROOT=/compat/i386 wine winecfg`. That's what I actually do for testing. Created attachment 226663 [details]
wow64 wrapper + ld_preload workaround (fixed llvm path)
@Gerald Do you have cycles to self-assign and take this to resolution? Working on this, thank you Alex! A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=dba96eb87fb4df6eb55f0e7d8883ad85d0ee3d82 commit dba96eb87fb4df6eb55f0e7d8883ad85d0ee3d82 Author: Gerald Pfeifer <gerald@FreeBSD.org> AuthorDate: 2021-07-26 08:49:07 +0000 Commit: Gerald Pfeifer <gerald@FreeBSD.org> CommitDate: 2021-07-26 08:49:53 +0000 emulators/wine: Update to Wine 6.0.1 Move from the Wine 5.0 release serious to the Wine 6.0 series and specifically Wine 6.0.1. This represents another year of development effort and over 8,300 individual changes. It contains a large number of improvements. Areas of major changes are: - Core modules in PE format. - Vulkan backend for WineD3D. - DirectShow and Media Foundation support. - Text console redesign. In terms of packaging changes are moderate this time: - As in case of 8c03aa8bb14df712154cfb84506b6501b58caee6 which has sat with wine-devel for eight months remove files/patch-dlls_kernel32_Makefile.in which is not needed any longer. - Our special dependency emulators/wine-gecko goes to version 2.47.2 and emulators/wine-mono to version 5.1.1. - The GLU library is not used any longer. Extensive release notes are at https://www.winehq.org/announce/6.0 and https://www.winehq.org/announce/6.0.1 . PR: 257284 emulators/wine-gecko/Makefile | 2 +- emulators/wine-gecko/distinfo | 6 +- emulators/wine-mono/Makefile | 4 +- emulators/wine-mono/distinfo | 6 +- emulators/wine/Makefile | 14 +- emulators/wine/distinfo | 6 +- .../files/patch-dlls_kernel32_Makefile.in (gone) | 26 --- emulators/wine/pkg-plist | 253 ++++++++++++++++++++- 8 files changed, 268 insertions(+), 49 deletions(-) A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=1d2af6e08958ac78de9fae727283ac8cdaf8705f commit 1d2af6e08958ac78de9fae727283ac8cdaf8705f Author: Alex S <iwtcex@gmail.com> AuthorDate: 2021-07-26 09:06:49 +0000 Commit: Gerald Pfeifer <gerald@FreeBSD.org> CommitDate: 2021-07-26 09:10:27 +0000 emulators/wine: Invoke with LD_BIND_NOW and revampe WoW Wine 6.0 and later need LD_BIND_NOW / LD_32_BIND_NOW on FreeBSD, cf. https://bugs.winehq.org/show_bug.cgi?id=50257 and https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=252307 so move the actual binaries to wine64.bin / wine.bin and invoke them via a script that does those settings. Also revamp the WoW handling/packging which combines 32-bit/i386 Wine into 64-bit/amd64 Wine. Submitted by: Alex S <iwtcex@gmail.com> PR: 257284, 252307 emulators/wine/Makefile | 10 +++++++++ emulators/wine/pkg-plist | 8 ++++++-- emulators/wine/pkg32.sh (new) | 13 ++++++++++++ emulators/wine/wine-wow64.sh (new) | 42 ++++++++++++++++++++++++++++++++++++++ emulators/wine/wine.sh (new) | 14 +++++++++++++ 5 files changed, 85 insertions(+), 2 deletions(-) I realize my comment #8 was too open and we now ended up with quite a bit more than the minimal patch to make Wine 6.0.1 work and now have two approaches for WoW present, don't we? ;-) Still, I did not want to delay and hopefully it proves useful for users. What is missing now, though, is documentation for users on how to go about things (in case of WoW). Can you please propose a draft for pkg-descr? Thank you! Looks like the last line of pkg32.sh (exec ...) is missing in the actual commit. (In reply to Gerald Pfeifer from comment #15) > What is missing now, though, is documentation for users on how to go about > things (in case of WoW). Can you please propose a draft for pkg-descr? Typically, you'll install/upgrade 32-bit libs with pkg32.sh and proceed using Wine as usual. To that extent wine-wow64.sh (the wrapper script that installs to `wine` on amd64) explicitly prints a suggestion to do a relevant action as necessary. Jury is still out on how much elaboration is needed on top of that. A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=ad15b0e748b6bd93ef1e36b1c605c1da29d10565 commit ad15b0e748b6bd93ef1e36b1c605c1da29d10565 Author: Gerald Pfeifer <gerald@FreeBSD.org> AuthorDate: 2021-07-26 09:53:22 +0000 Commit: Gerald Pfeifer <gerald@FreeBSD.org> CommitDate: 2021-07-26 09:56:08 +0000 emulators/wine: Fix up pkg32.sh In my original commit I missed the last line actually invoking pkg. Fix this up and add a comment above. PR: 257284 Reported by: Alex S <iwtcex@gmail.com> emulators/wine/Makefile | 1 + emulators/wine/pkg32.sh | 2 ++ 2 files changed, 3 insertions(+) (In reply to Alex S from comment #16) > Looks like the last line of pkg32.sh (exec ...) is missing in the > actual commit. Oops, fixed. Thanks for advising of that. Re docs, let's give it a try and see what feedback and questions (if any) we get from users, and then attend to that. A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=27ae28dd240c63c37a2fe17d2a2440d1beda5870 commit 27ae28dd240c63c37a2fe17d2a2440d1beda5870 Author: Gerald Pfeifer <gerald@FreeBSD.org> AuthorDate: 2021-08-02 21:40:18 +0000 Commit: Gerald Pfeifer <gerald@FreeBSD.org> CommitDate: 2021-08-02 21:40:19 +0000 emulators/wine-devel: Invoke with LD_BIND_NOW and revampe WoW Forward port 1d2af6e08958ac78de9fae727283ac8cdaf8705f and its two follow-up fixes ad15b0e748b6bd93ef1e36b1c605c1da29d10565 and 1b5885c463320a2af0e7fe2ed0fdca93d760ad19 from emulators/wine: Wine 6.0 and later need LD_BIND_NOW / LD_32_BIND_NOW on FreeBSD, cf. https://bugs.winehq.org/show_bug.cgi?id=50257 and https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=252307 so move the actual binaries to wine64.bin / wine.bin and invoke them via a script that does those settings. [1] Also revamp the WoW handling/packging which combines 32-bit/i386 Wine into 64-bit/amd64 Wine. [1] Submitted by: Alex S <iwtcex@gmail.com> [1] PR: 257284 [1], 252307 [1], 255336, 257020 emulators/wine-devel/Makefile | 12 ++++++++ emulators/wine-devel/files/pkg32.sh (new) | 15 +++++++++ emulators/wine-devel/files/wine-wow64.sh (new) | 42 ++++++++++++++++++++++++++ emulators/wine-devel/files/wine.sh (new) | 14 +++++++++ emulators/wine-devel/pkg-plist | 8 +++-- 5 files changed, 89 insertions(+), 2 deletions(-) |