Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 310611

Summary: app-emulation/wine would be nice to be slotted
Product: Gentoo Linux Reporter: Petr Polezhaev <NightNord>
Component: Current packagesAssignee: Wine Maintainers <wine>
Status: RESOLVED FIXED    
Severity: enhancement CC: alex_y_xu, bob.mt.wya, developer, dschridde+gentoobugs, erikdenstore+gbugs, h.mth, hasues+gentoo, hasufell, jj, max, mihais23, steffen, theli.ua, tsmksubc, xms-00
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
URL: https://www.gentoo.org/support/news-items/2017-04-10-split-and-slotted-wine.html
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: wine-1.7.21.ebuild USE=multislot patch
wine.eselect
eselect-wine-0.1.ebuild
wine-1.7.21.ebuild USE=multislot patch v2
wine.eselect v0.2
eselect-wine-0.2.ebuild
wine-gentoo-2013.06.24.ebuild
wine-1.7.28.ebuild USE=multislot patch

Description Petr Polezhaev 2010-03-21 21:49:07 UTC
Anyone who uses wine actively knows, that for particular applications only particular wine versions are working at best. Newer versions may suffer from regressions, while adding some features vital for other applications.

So, it would be very useful to have wine slotted. I'm starting this bug, just to get official devs opinion if it could be done. If answer would be positive I'm up to doing it and posting new ebuilds. My plan to separate man-pages in different package (not slotted), make include, lib dirs and binaries suffixed with ${PV}. Then only 'eselect wine' module would be required to switch between wine versions.

P.S. Please, do not consider this as 'hiding issues under the carpet' (as no-one will test wine for new regressions) - wine is sometimes vital for particular business, so this is absolutely not an option to make users test new versions, if older ones are working perfectly (with particular application).

Reproducible: Always
Comment 1 SpanKY gentoo-dev 2010-03-23 20:45:53 UTC
i have no problem adding support for USE=multislot to wine.  but setting SLOT is obviously the easy part ... it's going to take quite a lot of work i think to have versions install side by side.  everything would have to be versioned.  i.e. /usr/lib/wine-${PV}/... instead of /usr/lib/wine/

honestly, i dont plan on working on this for a long time ...
Comment 2 Jeroen Roovers (RETIRED) gentoo-dev 2013-12-30 03:15:57 UTC
*** Bug 496456 has been marked as a duplicate of this bug. ***
Comment 3 eroen 2014-09-08 15:49:58 UTC
In my somewhat limited testing on wine-1.7.26 (which unfortunately has not entered Gentoo yet), it seems wine works fine with slotted installation. Testing includes creation of a WINEPREFIX, playing a round of winemine and building a Hello world! with winegcc.

I suggest passing `--prefix=/usr/lib/wine-${SLOT} --datadir=/usr/lib/wine-${SLOT} --mandir=/usr/lib/wine-${SLOT}/man` to ./configure , updating the *_install* phases to match and creating wrappers (eg. wine-${SLOT}) for the binaries in $PATH with make_wrapper() (symlinks break the prefix handling in wine).

An eselect module symlinking the binaries ( wine -> wine-${SLOT} ) and man pages, perhaps based on the existance of /usr/lib/wine-${SLOT}/bin/wine should enable the normally expected interfaces to work.


Notes:
wine.desktop needs a bit of further thinking, perhaps it should be renamed wine-${SLOT}.desktop and/or be installed/linked by the eselect module.

My testing does not extend to the un-upstreamed patchsets and loose files installed by the current Gentoo ebuilds as I have no interest in these.

An additional benefit of enabling slotted installation is making it possible to migrate these patchsets to separate wine-whatever packages that can be installed side-by-side with vanilla wine and be selected with the eselect module. In this setup, bumping of vanilla wine would not be delayed by the need to port patchsets to newer versions.
Comment 4 eroen 2014-09-08 22:01:45 UTC
Created attachment 384422 [details, diff]
wine-1.7.21.ebuild USE=multislot patch

I'll upload my attempt at implementing USE=multislot for the current wine version in gentoo.

The biggest unsolved issue is the $WINE_GENTOO tarball not being slottable as-is. I believe the simplest solution to this is a separate (wine-common?) package or installing it along with the eselect module.

There might be a better way to block other slots when USE=-multislot, but repoman didn't complain about this.

I don't know what wine uses sysconfdir for, perhaps that should be slotted too :|
Comment 5 eroen 2014-09-08 22:09:38 UTC
Created attachment 384424 [details]
wine.eselect
Comment 6 eroen 2014-09-08 22:16:25 UTC
Created attachment 384432 [details]
eselect-wine-0.1.ebuild
Comment 7 David Heidelberg (okias) 2014-09-09 11:24:49 UTC
I'm against adding slotted version.

If there is introduced bug or big slowdown, it should be bisected or reported and fixed. There shouldn't be need for using older version (except for testing).
Comment 8 Julian Ospald 2014-09-09 12:36:10 UTC
(In reply to David Heidelberger (okias) from comment #7)
> I'm against adding slotted version.
> 
> If there is introduced bug or big slowdown, it should be bisected or
> reported and fixed. There shouldn't be need for using older version (except
> for testing).

No one prevents you from doing that, even if wine is slotted.
Comment 9 eroen 2014-09-11 20:03:52 UTC
Created attachment 384582 [details, diff]
wine-1.7.21.ebuild USE=multislot patch v2

Please find attached revised version implementing USE=multislot for wine-1.2.21.

Notably, there is now a wine-gentoo package for installing the downstream icons and launchers and the eselect module and ebuilds are tweaked to reduce the chance of broken symlinks.

v1 missed that wine-1.7.21 double-installs libwine when installed with a prefix. AFAICT this is not required for runtime. wine-1.7.26 does not double-install the library.
Comment 10 eroen 2014-09-11 20:05:21 UTC
Created attachment 384584 [details]
wine.eselect v0.2
Comment 11 eroen 2014-09-11 20:06:42 UTC
Created attachment 384586 [details]
eselect-wine-0.2.ebuild
Comment 12 eroen 2014-09-11 20:07:55 UTC
Created attachment 384588 [details]
wine-gentoo-2013.06.24.ebuild
Comment 13 eroen 2014-10-05 21:40:46 UTC
Created attachment 386100 [details, diff]
wine-1.7.28.ebuild USE=multislot patch

Updated patch to match newly added wine-1.7.28 (thanks ryao!)

Fwiw, I currently maintain slotted wine versions in my overlay[1] ("eroen" in layman), with separate packages with and without the compholio patchset selectable through eselect or by calling wine binaries by suffixed names.

http://eroen.eu/cgit/cgit.cgi/eroen-overlay/tree/app-emulation
Comment 14 Adam Feldman gentoo-dev 2015-03-12 15:58:46 UTC
(In reply to eroen from comment #13)
> Created attachment 386100 [details, diff] [details, diff]
> wine-1.7.28.ebuild USE=multislot patch
> 
> Updated patch to match newly added wine-1.7.28 (thanks ryao!)
> 
> Fwiw, I currently maintain slotted wine versions in my overlay[1] ("eroen"
> in layman), with separate packages with and without the compholio patchset
> selectable through eselect or by calling wine binaries by suffixed names.
> 
> http://eroen.eu/cgit/cgit.cgi/eroen-overlay/tree/app-emulation

I'm the proxy maintainer for wine.

eroen's work is currently available in 2 locations: the slotted_wine branch of wine-overlay (https://git.io/wine-overlay) and wine-a-holics (https://git.io/wine-overlay).  Both overlays have slotted versions for wine from 1.7.33 to present.

I personally have been using slotted (via wine-a-holics) for about a month now.  If I get user testing and direct feedback to confirm there are no outstanding issues with the current implementation, we might be able to move forward on this.
Comment 15 Alex Xu (Hello71) 2015-03-15 02:42:00 UTC
one option is just to commit p.u.med USE=multislot.
Comment 16 Ortwin Glueck 2017-05-22 15:19:08 UTC
available in portage now, see: https://www.gentoo.org/support/news-items/2017-04-10-split-and-slotted-wine.html
Comment 17 Adam Feldman gentoo-dev 2017-05-22 20:42:53 UTC
Thanks for updating the bug.


Currently waiting on fixing a bug in winegcc to unmask it.
Comment 18 Hanno Zysik (geki) 2017-07-30 10:54:40 UTC
@NP-Hardass: Is there any URL to see the status of that winegcc bug? Just wonder, if one may be able to help.
Comment 19 jalan 2017-08-17 12:01:58 UTC
If the winegcc bug in question is bug 625560, it looks like it's no longer considered a blocker for unmasking this.

I have been using the slotted wine for a couple months now and can confirm that it is quite nice, haven't had any issues :)
Comment 20 Adam Feldman gentoo-dev 2017-09-25 17:13:42 UTC
Alright, we are unmasked.