Gentoo Archives: gentoo-commits

From: Nick Sarnie <sarnex@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-emulation/wine-staging/
Date: Sun, 31 Mar 2019 16:31:02
Message-Id: 1554049846.8dc21134c918e111fcefa5f8d1a504a653302b74.sarnex@gentoo
1 commit: 8dc21134c918e111fcefa5f8d1a504a653302b74
2 Author: Nick Sarnie <sarnex <AT> gentoo <DOT> org>
3 AuthorDate: Sun Mar 31 16:30:46 2019 +0000
4 Commit: Nick Sarnie <sarnex <AT> gentoo <DOT> org>
5 CommitDate: Sun Mar 31 16:30:46 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8dc21134
7
8 app-emulation/wine-staging: Drop old
9
10 Package-Manager: Portage-2.3.62, Repoman-2.3.12
11 Signed-off-by: Nick Sarnie <sarnex <AT> gentoo.org>
12
13 app-emulation/wine-staging/Manifest | 4 -
14 app-emulation/wine-staging/wine-staging-4.0.ebuild | 615 ---------------------
15 app-emulation/wine-staging/wine-staging-4.1.ebuild | 614 --------------------
16 3 files changed, 1233 deletions(-)
17
18 diff --git a/app-emulation/wine-staging/Manifest b/app-emulation/wine-staging/Manifest
19 index b8920435d8d..17edfaefdf4 100644
20 --- a/app-emulation/wine-staging/Manifest
21 +++ b/app-emulation/wine-staging/Manifest
22 @@ -2,16 +2,12 @@ DIST gentoo-wine-patches-20180120.tar.xz 58672 BLAKE2B 84d621075b65475cec41a0642
23 DIST gentoo-wine-patches-20190316.tar.xz 58848 BLAKE2B 76e66749638589dd6d6eceb4b78690483d14353597a4e47fe9e5325d8bdb2bceff66040c110f63b8bae698bc5838c280c048ff7375ba2ed8cc387cbe0422c79a SHA512 de2cf844ae686144c3f95f0a360c7fa8a62185500758f994b5a65836798bdc3092138dcd9c36d0267a6fcfdc13585258d31b281244a97b45965f40e0f2b29eda
24 DIST wine-3.20.tar.xz 21541928 BLAKE2B 9183dacd1c6ec15ae5283eca3d17db5a869bcba9a93800a422f0dea5d9cfb5d3124a3e942e8b6487cd4ba31cfeacdd66de39128dd66d64e1226d265eae922d3a SHA512 fb66d1d4b427f46dd048b13e53bcd15a5eaeb19039221fe98ec771140c33b3c245a974e52242eab5731ffa0de15f5932204032fe24f86e1a313ff8f11da59cc4
25 DIST wine-3.21.tar.xz 21573872 BLAKE2B 54d8733b19f1377f856c9496f6263eef1916e03caf82c6fcfa39b3e7bec1fecd87466dc92f3739d704a9161a32d9ee680b2cc5e5cdf27a582dc1d89d0b1a6639 SHA512 dd64a6778bf1b848c8fe14dc26cfca21f6c1c92714ca1b2e932a28560a2adc1f69aa1b2cba250f49a5df4f91a4accde677a2afaf960c200d3998eac1957b5c6b
26 -DIST wine-4.0.tar.xz 21644692 BLAKE2B 9c426ef2249c16e908a3617c2844d8b12a2df843721338b1cfb69459815b902cfa0ddf3d74c09dc900fb2ceb003e54d97a7c0afaac51a9caab7d21beb82e26c3 SHA512 7607fa7a3d5f7bcd3d8c4c9e7bb6e1987466110bbfc672782ebe57c6d9da348c58e76abf40b0a70c725dfd703163db6e194ee0e3db11a47b6b60e225163308dd
27 -DIST wine-4.1.tar.xz 21680916 BLAKE2B 1a040606e34e1aec6f63d9692c6cbf915f5b32c817116aed68203e6bdedb8cb129dad440f7e51e9fb2ebaf1aa537d1584333f06b8b2c5d68f9ff37921d5b8b95 SHA512 2b28fc82111552009a042d682ea8f4e54d90f14bb99f1fbe12732090e7562527c229683562630edada0b1f4143de226734337b20d1b23d711191dcc0a834e4dc
28 DIST wine-4.2.tar.xz 21724960 BLAKE2B d3c4381265e5086a17582c28fd4d19c84ed8e9839d039d5f2eba32efcc09ae6dad2a25fa375042d98d35de30065eaa0095e36bb8fbca608ec74abc654bae5196 SHA512 408a846e92a0222f64ddd3c4d2c2a71b387ce51749e346c1fbca1fd57db910fa18dc6bb4ce0a350bef81e13be77c6b2d74537f7a1c0dcbb0e6d4c19d1ade288c
29 DIST wine-4.3.tar.xz 21764500 BLAKE2B dd94b710f2be20ce3225fb58e0a20f0ee46e59834dc77383e262620faa64597c41625382237c39563b3bb67b1850cca2460ca147e2c5ee3052f0fdfdee067ec5 SHA512 45c0519f8f2873ef65e1761d518a7148f3aa54c0e993a41a60849c01c8df17386d57edd83308cff289300adc6a8e3fc5918fb12513f5b85a88e556b420479e83
30 DIST wine-4.4.tar.xz 21805668 BLAKE2B cf973240a3f2a1ad1cac8690cdc5cd86be428220395d90bfe3b15567e6a2be0bb78e5828de3b77b617827122f5b0bb1dfeeef351102ca001722340ceaeb5625e SHA512 6678c9b0e086bdc9fab9f9fd2517226352b49f846bbae7be6000bb60db2f302aad49622192077b45880d45ad33ba4d82bfe3403fb82a1e65159f1352b40933de
31 DIST wine-4.5.tar.xz 21879868 BLAKE2B fc2bc13fefac97570a67a1c48a0144c1194896f779803efc0c3229fc234f128f53c78cadb1d47d28ec6772ecea73831c8850322e537aa1af62b537b7856ecae5 SHA512 261420efdf14595715cff5bb6a61223b0f2090b89dc05dca8c053a8a81abc3018715d41db50769a0f0488c658efc0742ac0f577b578e69eace70be4e463131dd
32 DIST wine-staging-3.20.tar.gz 9950555 BLAKE2B ee66217b708287bd95d61e23fb92009d927a75556f22e89b9c5af66cb6c6445f77a1c3153da168da92ebac58606843c4639f1a99bd5089941595181f390980f0 SHA512 4b92e53e84046d99c3f7ec5e0d0d7e62fdb767b1c44e23605125744686439fe62991c8adea941950b390a01d251ecbb79f3b329cfe5a1b1fbc76c5372283579d
33 DIST wine-staging-3.21.tar.gz 9945982 BLAKE2B 988927c644e9abf472c42021cae39f38cdae24b397072fb53dc803da32bc80e8b6256554d787db0b6bffafac4104a9abf4ab8fa6e78fd0a308bf8906d658a65d SHA512 17f8194954a420d1424d564ba9ad5e6d4dd574dc38da4895d5b6740c1990f8655cb573bd57c77ace2c78c71da4782b511a5ac937ca1f0fc958e3c925abaeefde
34 -DIST wine-staging-4.0.tar.gz 9945756 BLAKE2B bfd27d5677d01b4a14c4ef593b741b6fa6e75194de04a90659ecceaa8b087d594cafdd0a53cc2ad2d05e9c73928d70d0b6681ac0052df79f7b45cbb370b31d3d SHA512 4c2277449be17b83235bab7898818a886e84e82c0c5eb8216a5bc42e3d9a0e1dcf09d4522e1165d503fd9237673fa91c2c07d837cde58897f1b6fc8bc6fa5d33
35 -DIST wine-staging-4.1.tar.gz 9941329 BLAKE2B e455a411d782dcb52b29ad6150b108a4a9b3fd7cd548e35c1392ee3bce581206d99520df19a153ddb80f135156a8d33f6acbbfe086c28f6bfe404fe9eae96556 SHA512 8f52fdae4f98fe67053b00d03234e0937652a9a9506c9e94b717502244eb741c062990678ede11342dc182a4fe9c066227814ebe394ef5f6aedec73983c08554
36 DIST wine-staging-4.2.tar.gz 9850260 BLAKE2B 938d12bb44acef2920c6a47978f170cab532ddd785de394dddc95cc359b301e0db26a3ec9aa08abaf03542b59a97c16dfebb3bf5e4c9ddc9bed829200e529bb9 SHA512 2fb66bdeab084231983569d3884211a4d269a48bd6b25ba2e7c7e83d2dc98a205bd92dfc67c09528d57192086571d3f4f6c988c522b25aade1d525b74e662f2e
37 DIST wine-staging-4.3.tar.gz 9888763 BLAKE2B 095f2789f601822e34b7f9d0a078bd433aa2861e7cc55d5b74520bfedc2c88064bbffa3a73bcea170c4e4fb96e9eaa50f0cb927aba2cc6d1f12480bacfa49968 SHA512 9fd89c54200cf7c8e8a7f978fb6b34c89ece755976789f5c5c361ffb8d2882f14260c81ab8ac14ad140e41d807adbbaba05381a31b0177492aa222ef2fe04e4d
38 DIST wine-staging-4.4.tar.gz 9882230 BLAKE2B 705841e14abf3e3e65ae4b64ac2613f42f0e8caf32258ef6fc7e78b5410038c7cc766293488bb110e1f4c2c06d6b55b4cd3e59acea7e0f15c3bb6304e427f891 SHA512 4ddeddac2e2de9afd95ded71edb47f3eac15d1ca94254481e5369d6b69e401471b00ba16747621eb2d0f7d92c0558590f6efe89b3ea15012d9d3d45553d49196
39
40 diff --git a/app-emulation/wine-staging/wine-staging-4.0.ebuild b/app-emulation/wine-staging/wine-staging-4.0.ebuild
41 deleted file mode 100644
42 index 01089f5e252..00000000000
43 --- a/app-emulation/wine-staging/wine-staging-4.0.ebuild
44 +++ /dev/null
45 @@ -1,615 +0,0 @@
46 -# Copyright 1999-2019 Gentoo Authors
47 -# Distributed under the terms of the GNU General Public License v2
48 -
49 -EAPI=6
50 -
51 -PLOCALES="ar bg ca cs da de el en en_US eo es fa fi fr he hi hr hu it ja ko lt ml nb_NO nl or pa pl pt_BR pt_PT rm ro ru sk sl sr_RS@cyrillic sr_RS@latin sv te th tr uk wa zh_CN zh_TW"
52 -PLOCALE_BACKUP="en"
53 -
54 -inherit autotools eapi7-ver estack eutils flag-o-matic gnome2-utils l10n multilib multilib-minimal pax-utils toolchain-funcs virtualx xdg-utils
55 -
56 -MY_PN="${PN%%-*}"
57 -MY_P="${MY_PN}-${PV}"
58 -
59 -if [[ ${PV} == "9999" ]] ; then
60 - EGIT_REPO_URI="https://source.winehq.org/git/wine.git"
61 - EGIT_BRANCH="master"
62 - inherit git-r3
63 - SRC_URI=""
64 - #KEYWORDS=""
65 -else
66 - MAJOR_V=$(ver_cut 1)
67 - MINOR_V=$(ver_cut 2)
68 - SRC_URI="https://dl.winehq.org/wine/source/${MAJOR_V}.${MINOR_V}/${MY_P}.tar.xz"
69 - KEYWORDS="-* ~amd64 ~x86 ~x86-fbsd"
70 -fi
71 -S="${WORKDIR}/${MY_P}"
72 -
73 -STAGING_P="wine-staging-${PV}"
74 -STAGING_DIR="${WORKDIR}/${STAGING_P}"
75 -GWP_V="20180120"
76 -PATCHDIR="${WORKDIR}/gentoo-wine-patches"
77 -
78 -DESCRIPTION="Free implementation of Windows(tm) on Unix, with Wine-Staging patchset"
79 -HOMEPAGE="https://www.winehq.org/"
80 -SRC_URI="${SRC_URI}
81 - https://dev.gentoo.org/~np-hardass/distfiles/wine/gentoo-wine-patches-${GWP_V}.tar.xz
82 -"
83 -
84 -if [[ ${PV} == "9999" ]] ; then
85 - STAGING_EGIT_REPO_URI="https://github.com/wine-staging/wine-staging.git"
86 -else
87 - SRC_URI="${SRC_URI}
88 - staging? ( https://github.com/wine-staging/wine-staging/archive/v${PV}.tar.gz -> ${STAGING_P}.tar.gz )"
89 -fi
90 -
91 -LICENSE="LGPL-2.1"
92 -SLOT="${PV}"
93 -IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos elibc_glibc ffmpeg +fontconfig +gecko gphoto2 gsm gssapi gstreamer +jpeg kerberos kernel_FreeBSD +lcms ldap +mono mp3 ncurses netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pipelight +png prelink pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl staging test themes +threads +truetype udev +udisks v4l vaapi vkd3d vulkan +X +xcomposite xinerama +xml"
94 -REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 )
95 - X? ( truetype )
96 - elibc_glibc? ( threads )
97 - ffmpeg? ( staging )
98 - osmesa? ( opengl )
99 - pipelight? ( staging )
100 - test? ( abi_x86_32 )
101 - themes? ( staging )
102 - vaapi? ( staging )
103 - vkd3d? ( vulkan )" # osmesa-opengl #286560 # X-truetype #551124
104 -
105 -# FIXME: the test suite is unsuitable for us; many tests require net access
106 -# or fail due to Xvfb's opengl limitations.
107 -RESTRICT="test"
108 -
109 -COMMON_DEPEND="
110 - X? (
111 - x11-libs/libXcursor[${MULTILIB_USEDEP}]
112 - x11-libs/libXext[${MULTILIB_USEDEP}]
113 - x11-libs/libXfixes[${MULTILIB_USEDEP}]
114 - x11-libs/libXrandr[${MULTILIB_USEDEP}]
115 - x11-libs/libXi[${MULTILIB_USEDEP}]
116 - x11-libs/libXxf86vm[${MULTILIB_USEDEP}]
117 - )
118 - alsa? ( media-libs/alsa-lib[${MULTILIB_USEDEP}] )
119 - capi? ( net-libs/libcapi[${MULTILIB_USEDEP}] )
120 - cups? ( net-print/cups:=[${MULTILIB_USEDEP}] )
121 - ffmpeg? ( >=media-video/ffmpeg-4:=[${MULTILIB_USEDEP}] )
122 - fontconfig? ( media-libs/fontconfig:=[${MULTILIB_USEDEP}] )
123 - gphoto2? ( media-libs/libgphoto2:=[${MULTILIB_USEDEP}] )
124 - gsm? ( media-sound/gsm:=[${MULTILIB_USEDEP}] )
125 - gssapi? ( virtual/krb5[${MULTILIB_USEDEP}] )
126 - gstreamer? (
127 - media-libs/gstreamer:1.0[${MULTILIB_USEDEP}]
128 - media-plugins/gst-plugins-meta:1.0[${MULTILIB_USEDEP}]
129 - )
130 - jpeg? ( virtual/jpeg:0=[${MULTILIB_USEDEP}] )
131 - kerberos? ( virtual/krb5:0=[${MULTILIB_USEDEP}] )
132 - lcms? ( media-libs/lcms:2=[${MULTILIB_USEDEP}] )
133 - ldap? ( net-nds/openldap:=[${MULTILIB_USEDEP}] )
134 - mp3? ( >=media-sound/mpg123-1.5.0[${MULTILIB_USEDEP}] )
135 - ncurses? ( >=sys-libs/ncurses-5.2:0=[${MULTILIB_USEDEP}] )
136 - netapi? ( net-fs/samba[netapi(+),${MULTILIB_USEDEP}] )
137 - nls? ( sys-devel/gettext[${MULTILIB_USEDEP}] )
138 - odbc? ( dev-db/unixODBC:=[${MULTILIB_USEDEP}] )
139 - openal? ( media-libs/openal:=[${MULTILIB_USEDEP}] )
140 - opencl? ( virtual/opencl[${MULTILIB_USEDEP}] )
141 - opengl? (
142 - virtual/glu[${MULTILIB_USEDEP}]
143 - virtual/opengl[${MULTILIB_USEDEP}]
144 - )
145 - osmesa? ( >=media-libs/mesa-13[osmesa,${MULTILIB_USEDEP}] )
146 - pcap? ( net-libs/libpcap[${MULTILIB_USEDEP}] )
147 - png? ( media-libs/libpng:0=[${MULTILIB_USEDEP}] )
148 - pulseaudio? ( media-sound/pulseaudio[${MULTILIB_USEDEP}] )
149 - scanner? ( media-gfx/sane-backends:=[${MULTILIB_USEDEP}] )
150 - sdl? ( media-libs/libsdl2:=[haptic,joystick,${MULTILIB_USEDEP}] )
151 - ssl? ( net-libs/gnutls:=[${MULTILIB_USEDEP}] )
152 - staging? ( sys-apps/attr[${MULTILIB_USEDEP}] )
153 - themes? (
154 - dev-libs/glib:2[${MULTILIB_USEDEP}]
155 - x11-libs/cairo[${MULTILIB_USEDEP}]
156 - x11-libs/gtk+:3[${MULTILIB_USEDEP}]
157 - )
158 - truetype? ( >=media-libs/freetype-2.0.0[${MULTILIB_USEDEP}] )
159 - udev? ( virtual/libudev:=[${MULTILIB_USEDEP}] )
160 - udisks? ( sys-apps/dbus[${MULTILIB_USEDEP}] )
161 - v4l? ( media-libs/libv4l[${MULTILIB_USEDEP}] )
162 - vaapi? ( x11-libs/libva[X,${MULTILIB_USEDEP}] )
163 - vkd3d? ( app-emulation/vkd3d[${MULTILIB_USEDEP}] )
164 - vulkan? ( media-libs/vulkan-loader[${MULTILIB_USEDEP}] )
165 - xcomposite? ( x11-libs/libXcomposite[${MULTILIB_USEDEP}] )
166 - xinerama? ( x11-libs/libXinerama[${MULTILIB_USEDEP}] )
167 - xml? (
168 - dev-libs/libxml2[${MULTILIB_USEDEP}]
169 - dev-libs/libxslt[${MULTILIB_USEDEP}]
170 - )"
171 -
172 -RDEPEND="${COMMON_DEPEND}
173 - app-emulation/wine-desktop-common
174 - >app-eselect/eselect-wine-0.3
175 - !app-emulation/wine:0
176 - dos? ( >=games-emulation/dosbox-0.74_p20160629 )
177 - gecko? ( app-emulation/wine-gecko:2.47[abi_x86_32?,abi_x86_64?] )
178 - mono? ( app-emulation/wine-mono:4.7.5 )
179 - perl? (
180 - dev-lang/perl
181 - dev-perl/XML-Simple
182 - )
183 - pulseaudio? (
184 - realtime? ( sys-auth/rtkit )
185 - )
186 - samba? ( >=net-fs/samba-3.0.25[winbind] )
187 - selinux? ( sec-policy/selinux-wine )
188 - udisks? ( sys-fs/udisks:2 )"
189 -
190 -# tools/make_requests requires perl
191 -DEPEND="${COMMON_DEPEND}
192 - sys-devel/flex
193 - >=sys-kernel/linux-headers-2.6
194 - virtual/pkgconfig
195 - virtual/yacc
196 - X? ( x11-base/xorg-proto )
197 - prelink? ( sys-devel/prelink )
198 - staging? (
199 - dev-lang/perl
200 - dev-perl/XML-Simple
201 - )
202 - xinerama? ( x11-base/xorg-proto )"
203 -
204 -# These use a non-standard "Wine" category, which is provided by
205 -# /etc/xdg/applications-merged/wine.menu
206 -QA_DESKTOP_FILE="usr/share/applications/wine-browsedrive.desktop
207 -usr/share/applications/wine-notepad.desktop
208 -usr/share/applications/wine-uninstaller.desktop
209 -usr/share/applications/wine-winecfg.desktop"
210 -
211 -PATCHES=(
212 - "${PATCHDIR}/patches/${MY_PN}-1.5.26-winegcc.patch" #260726
213 - "${PATCHDIR}/patches/${MY_PN}-1.9.5-multilib-portage.patch" #395615
214 - "${PATCHDIR}/patches/${MY_PN}-1.6-memset-O3.patch" #480508
215 - "${PATCHDIR}/patches/${MY_PN}-2.0-multislot-apploader.patch" #310611
216 -)
217 -PATCHES_BIN=()
218 -
219 -# https://bugs.gentoo.org/show_bug.cgi?id=635222
220 -if [[ ${#PATCHES_BIN[@]} -ge 1 ]] || [[ ${PV} == 9999 ]]; then
221 - DEPEND+=" dev-util/patchbin"
222 -fi
223 -
224 -wine_compiler_check() {
225 - [[ ${MERGE_TYPE} = "binary" ]] && return 0
226 -
227 - # GCC-specific bugs
228 - if tc-is-gcc; then
229 - # bug #549768
230 - if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) -le 2 ]]; then
231 - ebegin "Checking for gcc-5 ms_abi compiler bug"
232 - $(tc-getCC) -O2 "${PATCHDIR}/files/pr66838.c" -o "${T}"/pr66838 || die
233 - # Run in subshell to prevent "Aborted" message
234 - ( "${T}"/pr66838 || false ) >/dev/null 2>&1
235 - if ! eend $?; then
236 - eerror "64-bit wine cannot be built with gcc-5.1 or initial patchset of 5.2.0"
237 - eerror "due to compiler bugs; please re-emerge the latest gcc-5.2.x ebuild,"
238 - eerror "or use gcc-config to select a different compiler version."
239 - eerror "See https://bugs.gentoo.org/549768"
240 - eerror
241 - return 1
242 - fi
243 - fi
244 - # bug #574044
245 - if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) = 3 ]]; then
246 - ebegin "Checking for gcc-5-3 stack realignment compiler bug"
247 - # Compile in subshell to prevent "Aborted" message
248 - ( $(tc-getCC) -O2 -mincoming-stack-boundary=3 "${PATCHDIR}/files/pr69140.c" -o "${T}"/pr69140 ) >/dev/null 2>&1
249 - if ! eend $?; then
250 - eerror "Wine cannot be built with this version of gcc-5.3"
251 - eerror "due to compiler bugs; please re-emerge the latest gcc-5.3.x ebuild,"
252 - eerror "or use gcc-config to select a different compiler version."
253 - eerror "See https://bugs.gentoo.org/574044"
254 - eerror
255 - return 1
256 - fi
257 - fi
258 - fi
259 -
260 - # Ensure compiler support
261 - if use abi_x86_64; then
262 - ebegin "Checking for 64-bit compiler with builtin_ms_va_list support"
263 - # Compile in subshell to prevent "Aborted" message
264 - ( $(tc-getCC) -O2 "${PATCHDIR}/files/builtin_ms_va_list.c" -o "${T}"/builtin_ms_va_list >/dev/null 2>&1)
265 - if ! eend $?; then
266 - eerror "This version of $(tc-getCC) does not support builtin_ms_va_list, can't enable 64-bit wine"
267 - eerror
268 - eerror "You need gcc-4.4+ or clang 3.8+ to build 64-bit wine"
269 - eerror
270 - return 1
271 - fi
272 - fi
273 -}
274 -
275 -wine_build_environment_check() {
276 - [[ ${MERGE_TYPE} = "binary" ]] && return 0
277 -
278 - if use abi_x86_64; then
279 - if tc-is-gcc && [[ $(gcc-major-version) -lt 4 || ( $(gcc-major-version) -eq 4 && $(gcc-minor-version) -lt 4 ) ]]; then
280 - eerror "You need gcc-4.4+ to compile 64-bit wine"
281 - die
282 - elif tc-is-clang && [[ $(clang-major-version) -lt 3 || ( $(clang-major-version) -eq 3 && $(clang-minor-version) -lt 8 ) ]]; then
283 - eerror "You need clang-3.8+ to compile 64-bit wine"
284 - die
285 - fi
286 - fi
287 - if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -le 3 ]]; then
288 - ewarn "GCC-5.0-5.3 suffered from compiler bugs and are no longer supported by"
289 - ewarn "Gentoo's Toolchain Team. If your ebuild fails the compiler checks in"
290 - ewarn "the configure phase, either update your compiler or switch to <5.0 || >=5.4"
291 - fi
292 - if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -eq 4 ]]; then
293 - if has "-march=i686" ${CFLAGS} && ! has "-mtune=generic" ${CFLAGS}; then
294 - ewarn "Compilation can hang with CFLAGS=\"-march=i686\". You can temporarily work"
295 - ewarn "around this by adding \"-mtune=generic\" to your CFLAGS for wine."
296 - ewarn "See package.env in man 5 portage for more information on how to do this."
297 - ewarn "See https://bugs.gentoo.org/show_bug.cgi?id=613128 for more details"
298 - fi
299 - fi
300 -
301 - if use abi_x86_32 && use opencl && [[ "$(eselect opencl show 2> /dev/null)" == "intel" ]]; then
302 - eerror "You cannot build wine with USE=opencl because intel-ocl-sdk is 64-bit only."
303 - eerror "See https://bugs.gentoo.org/487864 for more details."
304 - eerror
305 - return 1
306 - fi
307 -}
308 -
309 -wine_env_vcs_vars() {
310 - local pn_live_var="${PN//[-+]/_}_LIVE_COMMIT"
311 - local pn_live_val="${pn_live_var}"
312 - eval pn_live_val='$'${pn_live_val}
313 - if [[ ! -z ${pn_live_val} ]]; then
314 - if use staging; then
315 - eerror "Because of the multi-repo nature of ${MY_PN}, ${pn_live_var}"
316 - eerror "cannot be used to set the commit. Instead, you may use the"
317 - eerror "environment variables:"
318 - eerror " EGIT_OVERRIDE_COMMIT_WINE"
319 - eerror " EGIT_OVERRIDE_COMMIT_WINE_STAGING_WINE_STAGING"
320 - eerror
321 - return 1
322 - fi
323 - fi
324 - if [[ ! -z ${EGIT_COMMIT} ]]; then
325 - eerror "Commits must now be specified using the environment variables:"
326 - eerror " EGIT_OVERRIDE_COMMIT_WINE"
327 - eerror " EGIT_OVERRIDE_COMMIT_WINE_STAGING_WINE_STAGING"
328 - eerror
329 - return 1
330 - fi
331 -}
332 -
333 -pkg_pretend() {
334 - wine_build_environment_check || die
335 -
336 - # Verify OSS support
337 - if use oss && ! use kernel_FreeBSD; then
338 - if ! has_version ">=media-sound/oss-4"; then
339 - eerror "You cannot build wine with USE=oss without having support from a"
340 - eerror "FreeBSD kernel or >=media-sound/oss-4 (only available through external repos)"
341 - eerror
342 - die
343 - fi
344 - fi
345 -}
346 -
347 -pkg_setup() {
348 - wine_build_environment_check || die
349 - wine_env_vcs_vars || die
350 -
351 - WINE_VARIANT="${PN#wine}-${PV}"
352 - WINE_VARIANT="${WINE_VARIANT#-}"
353 -
354 - MY_PREFIX="${EPREFIX}/usr/lib/wine-${WINE_VARIANT}"
355 - MY_DATAROOTDIR="${EPREFIX}/usr/share/wine-${WINE_VARIANT}"
356 - MY_DATADIR="${MY_DATAROOTDIR}"
357 - MY_DOCDIR="${EPREFIX}/usr/share/doc/${PF}"
358 - MY_INCLUDEDIR="${EPREFIX}/usr/include/wine-${WINE_VARIANT}"
359 - MY_LIBEXECDIR="${EPREFIX}/usr/libexec/wine-${WINE_VARIANT}"
360 - MY_LOCALSTATEDIR="${EPREFIX}/var/wine-${WINE_VARIANT}"
361 - MY_MANDIR="${MY_DATADIR}/man"
362 -}
363 -
364 -src_unpack() {
365 - if [[ ${PV} == "9999" ]] ; then
366 - EGIT_CHECKOUT_DIR="${S}" git-r3_src_unpack
367 - if use staging; then
368 - local CURRENT_WINE_COMMIT=${EGIT_VERSION}
369 -
370 - EGIT_CHECKOUT_DIR="${STAGING_DIR}" EGIT_REPO_URI="${STAGING_EGIT_REPO_URI}" git-r3_src_unpack
371 -
372 - local COMPAT_WINE_COMMIT=$("${STAGING_DIR}/patches/patchinstall.sh" --upstream-commit) || die
373 -
374 - if [[ "${CURRENT_WINE_COMMIT}" != "${COMPAT_WINE_COMMIT}" ]]; then
375 - einfo "The current Staging patchset is not guaranteed to apply on this WINE commit."
376 - einfo "If src_prepare fails, try emerging with the env var WINE_COMMIT."
377 - einfo "Example: EGIT_OVERRIDE_COMMIT_WINE=${COMPAT_WINE_COMMIT} emerge -1 wine"
378 - fi
379 - fi
380 - fi
381 -
382 - default
383 -
384 - l10n_find_plocales_changes "${S}/po" "" ".po"
385 -}
386 -
387 -src_prepare() {
388 -
389 - eapply_bin(){
390 - local patch
391 - for patch in ${PATCHES_BIN[@]}; do
392 - patchbin --nogit < "${patch}" || die
393 - done
394 - }
395 -
396 - local md5="$(md5sum server/protocol.def)"
397 -
398 - if use staging; then
399 - ewarn "Applying the Wine-Staging patchset. Any bug reports to the"
400 - ewarn "Wine bugzilla should explicitly state that staging was used."
401 -
402 - local STAGING_EXCLUDE=""
403 - use pipelight || STAGING_EXCLUDE="${STAGING_EXCLUDE} -W Pipelight"
404 -
405 - # Launch wine-staging patcher in a subshell, using eapply as a backend, and gitapply.sh as a backend for binary patches
406 - ebegin "Running Wine-Staging patch installer"
407 - (
408 - set -- DESTDIR="${S}" --backend=eapply --no-autoconf --all ${STAGING_EXCLUDE}
409 - cd "${STAGING_DIR}/patches"
410 - source "${STAGING_DIR}/patches/patchinstall.sh"
411 - )
412 - eend $? || die "Failed to apply Wine-Staging patches"
413 - fi
414 -
415 - default
416 - eapply_bin
417 - eautoreconf
418 -
419 - # Modification of the server protocol requires regenerating the server requests
420 - if [[ "$(md5sum server/protocol.def)" != "${md5}" ]]; then
421 - einfo "server/protocol.def was patched; running tools/make_requests"
422 - tools/make_requests || die #432348
423 - fi
424 - sed -i '/^UPDATE_DESKTOP_DATABASE/s:=.*:=true:' tools/Makefile.in || die
425 - if ! use run-exes; then
426 - sed -i '/^MimeType/d' loader/wine.desktop || die #117785
427 - fi
428 -
429 - # Edit wine.desktop to work for specific variant
430 - sed -e "/^Exec=/s/wine /wine-${WINE_VARIANT} /" -i loader/wine.desktop || die
431 -
432 - # hi-res default icon, #472990, https://bugs.winehq.org/show_bug.cgi?id=24652
433 - cp "${PATCHDIR}/files/oic_winlogo.ico" dlls/user32/resources/ || die
434 -
435 - l10n_get_locales > po/LINGUAS || die # otherwise wine doesn't respect LINGUAS
436 -
437 - # Fix manpage generation for locales #469418 and abi_x86_64 #617864
438 -
439 - # Duplicate manpages input files for wine64
440 - local f
441 - for f in loader/*.man.in; do
442 - cp ${f} ${f/wine/wine64} || die
443 - done
444 - # Add wine64 manpages to Makefile
445 - if use abi_x86_64; then
446 - sed -i "/wine.man.in/i \
447 - \\\twine64.man.in \\\\" loader/Makefile.in || die
448 - sed -i -E 's/(.*wine)(.*\.UTF-8\.man\.in.*)/&\
449 -\164\2/' loader/Makefile.in || die
450 - fi
451 -
452 - rm_man_file(){
453 - local file="${1}"
454 - loc=${2}
455 - sed -i "/${loc}\.UTF-8\.man\.in/d" "${file}" || die
456 - }
457 -
458 - while read f; do
459 - l10n_for_each_disabled_locale_do rm_man_file "${f}"
460 - done < <(find -name "Makefile.in" -exec grep -q "UTF-8.man.in" "{}" \; -print)
461 -}
462 -
463 -src_configure() {
464 - wine_compiler_check || die
465 -
466 - export LDCONFIG=/bin/true
467 - use custom-cflags || strip-flags
468 -
469 - multilib-minimal_src_configure
470 -}
471 -
472 -multilib_src_configure() {
473 - local myconf=(
474 - --prefix="${MY_PREFIX}"
475 - --datarootdir="${MY_DATAROOTDIR}"
476 - --datadir="${MY_DATADIR}"
477 - --docdir="${MY_DOCDIR}"
478 - --includedir="${MY_INCLUDEDIR}"
479 - --libdir="${EPREFIX}/usr/$(get_libdir)/wine-${WINE_VARIANT}"
480 - --libexecdir="${MY_LIBEXECDIR}"
481 - --localstatedir="${MY_LOCALSTATEDIR}"
482 - --mandir="${MY_MANDIR}"
483 - --sysconfdir=/etc/wine
484 - $(use_with alsa)
485 - $(use_with capi)
486 - $(use_with lcms cms)
487 - $(use_with cups)
488 - $(use_with ncurses curses)
489 - $(use_with udisks dbus)
490 - $(use_with ffmpeg)
491 - $(use_with fontconfig)
492 - $(use_with ssl gnutls)
493 - $(use_enable gecko mshtml)
494 - $(use_with gphoto2 gphoto)
495 - $(use_with gsm)
496 - $(use_with gssapi)
497 - $(use_with gstreamer)
498 - --without-hal
499 - $(use_with jpeg)
500 - $(use_with kerberos krb5)
501 - $(use_with ldap)
502 - $(use_enable mono mscoree)
503 - $(use_with mp3 mpg123)
504 - $(use_with netapi)
505 - $(use_with nls gettext)
506 - $(use_with openal)
507 - $(use_with opencl)
508 - $(use_with opengl)
509 - $(use_with osmesa)
510 - $(use_with oss)
511 - $(use_with pcap)
512 - $(use_with png)
513 - $(use_with pulseaudio pulse)
514 - $(use_with threads pthread)
515 - $(use_with scanner sane)
516 - $(use_with sdl)
517 - $(use_enable test tests)
518 - $(use_with truetype freetype)
519 - $(use_with udev)
520 - $(use_with v4l)
521 - $(use_with vkd3d)
522 - $(use_with vulkan)
523 - $(use_with X x)
524 - $(use_with X xfixes)
525 - $(use_with xcomposite)
526 - $(use_with xinerama)
527 - $(use_with xml)
528 - $(use_with xml xslt)
529 - )
530 -
531 - use staging && myconf+=(
532 - --with-xattr
533 - $(use_with themes gtk3)
534 - $(use_with vaapi va)
535 - )
536 -
537 - local PKG_CONFIG AR RANLIB
538 - # Avoid crossdev's i686-pc-linux-gnu-pkg-config if building wine32 on amd64; #472038
539 - # set AR and RANLIB to make QA scripts happy; #483342
540 - tc-export PKG_CONFIG AR RANLIB
541 -
542 - if use amd64; then
543 - if [[ ${ABI} == amd64 ]]; then
544 - myconf+=( --enable-win64 )
545 - else
546 - myconf+=( --disable-win64 )
547 - fi
548 -
549 - # Note: using --with-wine64 results in problems with multilib.eclass
550 - # CC/LD hackery. We're using separate tools instead.
551 - fi
552 -
553 - ECONF_SOURCE=${S} \
554 - econf "${myconf[@]}"
555 - emake depend
556 -}
557 -
558 -multilib_src_test() {
559 - # FIXME: win32-only; wine64 tests fail with "could not find the Wine loader"
560 - if [[ ${ABI} == x86 ]]; then
561 - if [[ $(id -u) == 0 ]]; then
562 - ewarn "Skipping tests since they cannot be run under the root user."
563 - ewarn "To run the test ${MY_PN} suite, add userpriv to FEATURES in make.conf"
564 - return
565 - fi
566 -
567 - WINEPREFIX="${T}/.wine-${ABI}" \
568 - Xemake test
569 - fi
570 -}
571 -
572 -multilib_src_install_all() {
573 - local DOCS=( ANNOUNCE AUTHORS README )
574 - add_locale_docs() {
575 - local locale_doc="documentation/README.$1"
576 - [[ ! -e ${locale_doc} ]] || DOCS+=( ${locale_doc} )
577 - }
578 - l10n_for_each_locale_do add_locale_docs
579 -
580 - einstalldocs
581 - prune_libtool_files --all
582 -
583 - if ! use perl ; then # winedump calls function_grep.pl, and winemaker is a perl script
584 - rm "${D%/}${MY_PREFIX}"/bin/{wine{dump,maker},function_grep.pl} \
585 - "${D%/}${MY_MANDIR}"/man1/wine{dump,maker}.1 || die
586 - fi
587 -
588 - # Remove wineconsole if neither backend is installed #551124
589 - if ! use X && ! use ncurses; then
590 - rm "${D%/}${MY_PREFIX}"/bin/wineconsole* || die
591 - rm "${D%/}${MY_MANDIR}"/man1/wineconsole* || die
592 - rm_wineconsole() {
593 - rm "${D%/}${MY_PREFIX}/$(get_libdir)"/wine/{,fakedlls/}wineconsole.exe* || die
594 - }
595 - multilib_foreach_abi rm_wineconsole
596 - fi
597 -
598 - use abi_x86_32 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine{,-preloader} #255055
599 - use abi_x86_64 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine64{,-preloader}
600 -
601 - if use abi_x86_64 && ! use abi_x86_32; then
602 - dosym wine64 "${MY_PREFIX}"/bin/wine # 404331
603 - dosym wine64-preloader "${MY_PREFIX}"/bin/wine-preloader
604 - fi
605 -
606 - # Failglob for binloops, shouldn't be necessary, but including to stay safe
607 - eshopts_push -s failglob #615218
608 - # Make wrappers for binaries for handling multiple variants
609 - # Note: wrappers instead of symlinks because some are shell which use basename
610 - local b
611 - for b in "${D%/}${MY_PREFIX}"/bin/*; do
612 - make_wrapper "${b##*/}-${WINE_VARIANT}" "${MY_PREFIX}/bin/${b##*/}"
613 - done
614 - eshopts_pop
615 -}
616 -
617 -pkg_postinst() {
618 - eselect wine register ${P}
619 - if [[ ${PN} == "wine-vanilla" ]]; then
620 - eselect wine register --vanilla ${P} || die
621 - else
622 - if use staging; then
623 - eselect wine register --staging ${P} || die
624 - fi
625 - fi
626 -
627 - eselect wine update --all --if-unset || die
628 -
629 - xdg_desktop_database_update
630 -
631 - if ! use gecko; then
632 - ewarn "Without Wine Gecko, wine prefixes will not have a default"
633 - ewarn "implementation of iexplore. Many older windows applications"
634 - ewarn "rely upon the existence of an iexplore implementation, so"
635 - ewarn "you will likely need to install an external one, like via winetricks"
636 - fi
637 - if ! use mono; then
638 - ewarn "Without Wine Mono, wine prefixes will not have a default"
639 - ewarn "implementation of .NET. Many windows applications rely upon"
640 - ewarn "the existence of a .NET implementation, so you will likely need"
641 - ewarn "to install an external one, like via winetricks"
642 - fi
643 -}
644 -
645 -pkg_prerm() {
646 - eselect wine deregister ${P}
647 - if [[ ${PN} == "wine-vanilla" ]]; then
648 - eselect wine deregister --vanilla ${P} || die
649 - else
650 - if use staging; then
651 - eselect wine deregister --staging ${P} || die
652 - fi
653 - fi
654 -
655 - eselect wine update --all --if-unset || die
656 -}
657 -
658 -pkg_postrm() {
659 - xdg_desktop_database_update
660 -}
661
662 diff --git a/app-emulation/wine-staging/wine-staging-4.1.ebuild b/app-emulation/wine-staging/wine-staging-4.1.ebuild
663 deleted file mode 100644
664 index f47ddc85d87..00000000000
665 --- a/app-emulation/wine-staging/wine-staging-4.1.ebuild
666 +++ /dev/null
667 @@ -1,614 +0,0 @@
668 -# Copyright 1999-2019 Gentoo Authors
669 -# Distributed under the terms of the GNU General Public License v2
670 -
671 -EAPI=6
672 -
673 -PLOCALES="ar bg ca cs da de el en en_US eo es fa fi fr he hi hr hu it ja ko lt ml nb_NO nl or pa pl pt_BR pt_PT rm ro ru sk sl sr_RS@cyrillic sr_RS@latin sv te th tr uk wa zh_CN zh_TW"
674 -PLOCALE_BACKUP="en"
675 -
676 -inherit autotools eapi7-ver estack eutils flag-o-matic gnome2-utils l10n multilib multilib-minimal pax-utils toolchain-funcs virtualx xdg-utils
677 -
678 -MY_PN="${PN%%-*}"
679 -MY_P="${MY_PN}-${PV}"
680 -
681 -if [[ ${PV} == "9999" ]] ; then
682 - EGIT_REPO_URI="https://source.winehq.org/git/wine.git"
683 - EGIT_BRANCH="master"
684 - inherit git-r3
685 - SRC_URI=""
686 - #KEYWORDS=""
687 -else
688 - MAJOR_V=$(ver_cut 1)
689 - SRC_URI="https://dl.winehq.org/wine/source/${MAJOR_V}.x/${MY_P}.tar.xz"
690 - KEYWORDS="-* ~amd64 ~x86 ~x86-fbsd"
691 -fi
692 -S="${WORKDIR}/${MY_P}"
693 -
694 -STAGING_P="wine-staging-${PV}"
695 -STAGING_DIR="${WORKDIR}/${STAGING_P}-2"
696 -GWP_V="20180120"
697 -PATCHDIR="${WORKDIR}/gentoo-wine-patches"
698 -
699 -DESCRIPTION="Free implementation of Windows(tm) on Unix, with Wine-Staging patchset"
700 -HOMEPAGE="https://www.winehq.org/"
701 -SRC_URI="${SRC_URI}
702 - https://dev.gentoo.org/~np-hardass/distfiles/wine/gentoo-wine-patches-${GWP_V}.tar.xz
703 -"
704 -
705 -if [[ ${PV} == "9999" ]] ; then
706 - STAGING_EGIT_REPO_URI="https://github.com/wine-staging/wine-staging.git"
707 -else
708 - SRC_URI="${SRC_URI}
709 - staging? ( https://github.com/wine-staging/wine-staging/archive/v${PV}-2.tar.gz -> ${STAGING_P}.tar.gz )"
710 -fi
711 -
712 -LICENSE="LGPL-2.1"
713 -SLOT="${PV}"
714 -IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos elibc_glibc ffmpeg +fontconfig +gecko gphoto2 gsm gssapi gstreamer +jpeg kerberos kernel_FreeBSD +lcms ldap +mono mp3 ncurses netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pipelight +png prelink pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl staging test themes +threads +truetype udev +udisks v4l vaapi vkd3d vulkan +X +xcomposite xinerama +xml"
715 -REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 )
716 - X? ( truetype )
717 - elibc_glibc? ( threads )
718 - ffmpeg? ( staging )
719 - osmesa? ( opengl )
720 - pipelight? ( staging )
721 - test? ( abi_x86_32 )
722 - themes? ( staging )
723 - vaapi? ( staging )
724 - vkd3d? ( vulkan )" # osmesa-opengl #286560 # X-truetype #551124
725 -
726 -# FIXME: the test suite is unsuitable for us; many tests require net access
727 -# or fail due to Xvfb's opengl limitations.
728 -RESTRICT="test"
729 -
730 -COMMON_DEPEND="
731 - X? (
732 - x11-libs/libXcursor[${MULTILIB_USEDEP}]
733 - x11-libs/libXext[${MULTILIB_USEDEP}]
734 - x11-libs/libXfixes[${MULTILIB_USEDEP}]
735 - x11-libs/libXrandr[${MULTILIB_USEDEP}]
736 - x11-libs/libXi[${MULTILIB_USEDEP}]
737 - x11-libs/libXxf86vm[${MULTILIB_USEDEP}]
738 - )
739 - alsa? ( media-libs/alsa-lib[${MULTILIB_USEDEP}] )
740 - capi? ( net-libs/libcapi[${MULTILIB_USEDEP}] )
741 - cups? ( net-print/cups:=[${MULTILIB_USEDEP}] )
742 - ffmpeg? ( >=media-video/ffmpeg-4:=[${MULTILIB_USEDEP}] )
743 - fontconfig? ( media-libs/fontconfig:=[${MULTILIB_USEDEP}] )
744 - gphoto2? ( media-libs/libgphoto2:=[${MULTILIB_USEDEP}] )
745 - gsm? ( media-sound/gsm:=[${MULTILIB_USEDEP}] )
746 - gssapi? ( virtual/krb5[${MULTILIB_USEDEP}] )
747 - gstreamer? (
748 - media-libs/gstreamer:1.0[${MULTILIB_USEDEP}]
749 - media-plugins/gst-plugins-meta:1.0[${MULTILIB_USEDEP}]
750 - )
751 - jpeg? ( virtual/jpeg:0=[${MULTILIB_USEDEP}] )
752 - kerberos? ( virtual/krb5:0=[${MULTILIB_USEDEP}] )
753 - lcms? ( media-libs/lcms:2=[${MULTILIB_USEDEP}] )
754 - ldap? ( net-nds/openldap:=[${MULTILIB_USEDEP}] )
755 - mp3? ( >=media-sound/mpg123-1.5.0[${MULTILIB_USEDEP}] )
756 - ncurses? ( >=sys-libs/ncurses-5.2:0=[${MULTILIB_USEDEP}] )
757 - netapi? ( net-fs/samba[netapi(+),${MULTILIB_USEDEP}] )
758 - nls? ( sys-devel/gettext[${MULTILIB_USEDEP}] )
759 - odbc? ( dev-db/unixODBC:=[${MULTILIB_USEDEP}] )
760 - openal? ( media-libs/openal:=[${MULTILIB_USEDEP}] )
761 - opencl? ( virtual/opencl[${MULTILIB_USEDEP}] )
762 - opengl? (
763 - virtual/glu[${MULTILIB_USEDEP}]
764 - virtual/opengl[${MULTILIB_USEDEP}]
765 - )
766 - osmesa? ( >=media-libs/mesa-13[osmesa,${MULTILIB_USEDEP}] )
767 - pcap? ( net-libs/libpcap[${MULTILIB_USEDEP}] )
768 - png? ( media-libs/libpng:0=[${MULTILIB_USEDEP}] )
769 - pulseaudio? ( media-sound/pulseaudio[${MULTILIB_USEDEP}] )
770 - scanner? ( media-gfx/sane-backends:=[${MULTILIB_USEDEP}] )
771 - sdl? ( media-libs/libsdl2:=[haptic,joystick,${MULTILIB_USEDEP}] )
772 - ssl? ( net-libs/gnutls:=[${MULTILIB_USEDEP}] )
773 - staging? ( sys-apps/attr[${MULTILIB_USEDEP}] )
774 - themes? (
775 - dev-libs/glib:2[${MULTILIB_USEDEP}]
776 - x11-libs/cairo[${MULTILIB_USEDEP}]
777 - x11-libs/gtk+:3[${MULTILIB_USEDEP}]
778 - )
779 - truetype? ( >=media-libs/freetype-2.0.0[${MULTILIB_USEDEP}] )
780 - udev? ( virtual/libudev:=[${MULTILIB_USEDEP}] )
781 - udisks? ( sys-apps/dbus[${MULTILIB_USEDEP}] )
782 - v4l? ( media-libs/libv4l[${MULTILIB_USEDEP}] )
783 - vaapi? ( x11-libs/libva[X,${MULTILIB_USEDEP}] )
784 - vkd3d? ( app-emulation/vkd3d[${MULTILIB_USEDEP}] )
785 - vulkan? ( media-libs/vulkan-loader[${MULTILIB_USEDEP}] )
786 - xcomposite? ( x11-libs/libXcomposite[${MULTILIB_USEDEP}] )
787 - xinerama? ( x11-libs/libXinerama[${MULTILIB_USEDEP}] )
788 - xml? (
789 - dev-libs/libxml2[${MULTILIB_USEDEP}]
790 - dev-libs/libxslt[${MULTILIB_USEDEP}]
791 - )"
792 -
793 -RDEPEND="${COMMON_DEPEND}
794 - app-emulation/wine-desktop-common
795 - >app-eselect/eselect-wine-0.3
796 - !app-emulation/wine:0
797 - dos? ( >=games-emulation/dosbox-0.74_p20160629 )
798 - gecko? ( app-emulation/wine-gecko:2.47[abi_x86_32?,abi_x86_64?] )
799 - mono? ( app-emulation/wine-mono:4.7.5 )
800 - perl? (
801 - dev-lang/perl
802 - dev-perl/XML-Simple
803 - )
804 - pulseaudio? (
805 - realtime? ( sys-auth/rtkit )
806 - )
807 - samba? ( >=net-fs/samba-3.0.25[winbind] )
808 - selinux? ( sec-policy/selinux-wine )
809 - udisks? ( sys-fs/udisks:2 )"
810 -
811 -# tools/make_requests requires perl
812 -DEPEND="${COMMON_DEPEND}
813 - sys-devel/flex
814 - >=sys-kernel/linux-headers-2.6
815 - virtual/pkgconfig
816 - virtual/yacc
817 - X? ( x11-base/xorg-proto )
818 - prelink? ( sys-devel/prelink )
819 - staging? (
820 - dev-lang/perl
821 - dev-perl/XML-Simple
822 - )
823 - xinerama? ( x11-base/xorg-proto )"
824 -
825 -# These use a non-standard "Wine" category, which is provided by
826 -# /etc/xdg/applications-merged/wine.menu
827 -QA_DESKTOP_FILE="usr/share/applications/wine-browsedrive.desktop
828 -usr/share/applications/wine-notepad.desktop
829 -usr/share/applications/wine-uninstaller.desktop
830 -usr/share/applications/wine-winecfg.desktop"
831 -
832 -PATCHES=(
833 - "${PATCHDIR}/patches/${MY_PN}-1.5.26-winegcc.patch" #260726
834 - "${PATCHDIR}/patches/${MY_PN}-1.9.5-multilib-portage.patch" #395615
835 - "${PATCHDIR}/patches/${MY_PN}-1.6-memset-O3.patch" #480508
836 - "${PATCHDIR}/patches/${MY_PN}-2.0-multislot-apploader.patch" #310611
837 -)
838 -PATCHES_BIN=()
839 -
840 -# https://bugs.gentoo.org/show_bug.cgi?id=635222
841 -if [[ ${#PATCHES_BIN[@]} -ge 1 ]] || [[ ${PV} == 9999 ]]; then
842 - DEPEND+=" dev-util/patchbin"
843 -fi
844 -
845 -wine_compiler_check() {
846 - [[ ${MERGE_TYPE} = "binary" ]] && return 0
847 -
848 - # GCC-specific bugs
849 - if tc-is-gcc; then
850 - # bug #549768
851 - if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) -le 2 ]]; then
852 - ebegin "Checking for gcc-5 ms_abi compiler bug"
853 - $(tc-getCC) -O2 "${PATCHDIR}/files/pr66838.c" -o "${T}"/pr66838 || die
854 - # Run in subshell to prevent "Aborted" message
855 - ( "${T}"/pr66838 || false ) >/dev/null 2>&1
856 - if ! eend $?; then
857 - eerror "64-bit wine cannot be built with gcc-5.1 or initial patchset of 5.2.0"
858 - eerror "due to compiler bugs; please re-emerge the latest gcc-5.2.x ebuild,"
859 - eerror "or use gcc-config to select a different compiler version."
860 - eerror "See https://bugs.gentoo.org/549768"
861 - eerror
862 - return 1
863 - fi
864 - fi
865 - # bug #574044
866 - if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) = 3 ]]; then
867 - ebegin "Checking for gcc-5-3 stack realignment compiler bug"
868 - # Compile in subshell to prevent "Aborted" message
869 - ( $(tc-getCC) -O2 -mincoming-stack-boundary=3 "${PATCHDIR}/files/pr69140.c" -o "${T}"/pr69140 ) >/dev/null 2>&1
870 - if ! eend $?; then
871 - eerror "Wine cannot be built with this version of gcc-5.3"
872 - eerror "due to compiler bugs; please re-emerge the latest gcc-5.3.x ebuild,"
873 - eerror "or use gcc-config to select a different compiler version."
874 - eerror "See https://bugs.gentoo.org/574044"
875 - eerror
876 - return 1
877 - fi
878 - fi
879 - fi
880 -
881 - # Ensure compiler support
882 - if use abi_x86_64; then
883 - ebegin "Checking for 64-bit compiler with builtin_ms_va_list support"
884 - # Compile in subshell to prevent "Aborted" message
885 - ( $(tc-getCC) -O2 "${PATCHDIR}/files/builtin_ms_va_list.c" -o "${T}"/builtin_ms_va_list >/dev/null 2>&1)
886 - if ! eend $?; then
887 - eerror "This version of $(tc-getCC) does not support builtin_ms_va_list, can't enable 64-bit wine"
888 - eerror
889 - eerror "You need gcc-4.4+ or clang 3.8+ to build 64-bit wine"
890 - eerror
891 - return 1
892 - fi
893 - fi
894 -}
895 -
896 -wine_build_environment_check() {
897 - [[ ${MERGE_TYPE} = "binary" ]] && return 0
898 -
899 - if use abi_x86_64; then
900 - if tc-is-gcc && [[ $(gcc-major-version) -lt 4 || ( $(gcc-major-version) -eq 4 && $(gcc-minor-version) -lt 4 ) ]]; then
901 - eerror "You need gcc-4.4+ to compile 64-bit wine"
902 - die
903 - elif tc-is-clang && [[ $(clang-major-version) -lt 3 || ( $(clang-major-version) -eq 3 && $(clang-minor-version) -lt 8 ) ]]; then
904 - eerror "You need clang-3.8+ to compile 64-bit wine"
905 - die
906 - fi
907 - fi
908 - if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -le 3 ]]; then
909 - ewarn "GCC-5.0-5.3 suffered from compiler bugs and are no longer supported by"
910 - ewarn "Gentoo's Toolchain Team. If your ebuild fails the compiler checks in"
911 - ewarn "the configure phase, either update your compiler or switch to <5.0 || >=5.4"
912 - fi
913 - if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -eq 4 ]]; then
914 - if has "-march=i686" ${CFLAGS} && ! has "-mtune=generic" ${CFLAGS}; then
915 - ewarn "Compilation can hang with CFLAGS=\"-march=i686\". You can temporarily work"
916 - ewarn "around this by adding \"-mtune=generic\" to your CFLAGS for wine."
917 - ewarn "See package.env in man 5 portage for more information on how to do this."
918 - ewarn "See https://bugs.gentoo.org/show_bug.cgi?id=613128 for more details"
919 - fi
920 - fi
921 -
922 - if use abi_x86_32 && use opencl && [[ "$(eselect opencl show 2> /dev/null)" == "intel" ]]; then
923 - eerror "You cannot build wine with USE=opencl because intel-ocl-sdk is 64-bit only."
924 - eerror "See https://bugs.gentoo.org/487864 for more details."
925 - eerror
926 - return 1
927 - fi
928 -}
929 -
930 -wine_env_vcs_vars() {
931 - local pn_live_var="${PN//[-+]/_}_LIVE_COMMIT"
932 - local pn_live_val="${pn_live_var}"
933 - eval pn_live_val='$'${pn_live_val}
934 - if [[ ! -z ${pn_live_val} ]]; then
935 - if use staging; then
936 - eerror "Because of the multi-repo nature of ${MY_PN}, ${pn_live_var}"
937 - eerror "cannot be used to set the commit. Instead, you may use the"
938 - eerror "environment variables:"
939 - eerror " EGIT_OVERRIDE_COMMIT_WINE"
940 - eerror " EGIT_OVERRIDE_COMMIT_WINE_STAGING_WINE_STAGING"
941 - eerror
942 - return 1
943 - fi
944 - fi
945 - if [[ ! -z ${EGIT_COMMIT} ]]; then
946 - eerror "Commits must now be specified using the environment variables:"
947 - eerror " EGIT_OVERRIDE_COMMIT_WINE"
948 - eerror " EGIT_OVERRIDE_COMMIT_WINE_STAGING_WINE_STAGING"
949 - eerror
950 - return 1
951 - fi
952 -}
953 -
954 -pkg_pretend() {
955 - wine_build_environment_check || die
956 -
957 - # Verify OSS support
958 - if use oss && ! use kernel_FreeBSD; then
959 - if ! has_version ">=media-sound/oss-4"; then
960 - eerror "You cannot build wine with USE=oss without having support from a"
961 - eerror "FreeBSD kernel or >=media-sound/oss-4 (only available through external repos)"
962 - eerror
963 - die
964 - fi
965 - fi
966 -}
967 -
968 -pkg_setup() {
969 - wine_build_environment_check || die
970 - wine_env_vcs_vars || die
971 -
972 - WINE_VARIANT="${PN#wine}-${PV}"
973 - WINE_VARIANT="${WINE_VARIANT#-}"
974 -
975 - MY_PREFIX="${EPREFIX}/usr/lib/wine-${WINE_VARIANT}"
976 - MY_DATAROOTDIR="${EPREFIX}/usr/share/wine-${WINE_VARIANT}"
977 - MY_DATADIR="${MY_DATAROOTDIR}"
978 - MY_DOCDIR="${EPREFIX}/usr/share/doc/${PF}"
979 - MY_INCLUDEDIR="${EPREFIX}/usr/include/wine-${WINE_VARIANT}"
980 - MY_LIBEXECDIR="${EPREFIX}/usr/libexec/wine-${WINE_VARIANT}"
981 - MY_LOCALSTATEDIR="${EPREFIX}/var/wine-${WINE_VARIANT}"
982 - MY_MANDIR="${MY_DATADIR}/man"
983 -}
984 -
985 -src_unpack() {
986 - if [[ ${PV} == "9999" ]] ; then
987 - EGIT_CHECKOUT_DIR="${S}" git-r3_src_unpack
988 - if use staging; then
989 - local CURRENT_WINE_COMMIT=${EGIT_VERSION}
990 -
991 - EGIT_CHECKOUT_DIR="${STAGING_DIR}" EGIT_REPO_URI="${STAGING_EGIT_REPO_URI}" git-r3_src_unpack
992 -
993 - local COMPAT_WINE_COMMIT=$("${STAGING_DIR}/patches/patchinstall.sh" --upstream-commit) || die
994 -
995 - if [[ "${CURRENT_WINE_COMMIT}" != "${COMPAT_WINE_COMMIT}" ]]; then
996 - einfo "The current Staging patchset is not guaranteed to apply on this WINE commit."
997 - einfo "If src_prepare fails, try emerging with the env var WINE_COMMIT."
998 - einfo "Example: EGIT_OVERRIDE_COMMIT_WINE=${COMPAT_WINE_COMMIT} emerge -1 wine"
999 - fi
1000 - fi
1001 - fi
1002 -
1003 - default
1004 -
1005 - l10n_find_plocales_changes "${S}/po" "" ".po"
1006 -}
1007 -
1008 -src_prepare() {
1009 -
1010 - eapply_bin(){
1011 - local patch
1012 - for patch in ${PATCHES_BIN[@]}; do
1013 - patchbin --nogit < "${patch}" || die
1014 - done
1015 - }
1016 -
1017 - local md5="$(md5sum server/protocol.def)"
1018 -
1019 - if use staging; then
1020 - ewarn "Applying the Wine-Staging patchset. Any bug reports to the"
1021 - ewarn "Wine bugzilla should explicitly state that staging was used."
1022 -
1023 - local STAGING_EXCLUDE=""
1024 - use pipelight || STAGING_EXCLUDE="${STAGING_EXCLUDE} -W Pipelight"
1025 -
1026 - # Launch wine-staging patcher in a subshell, using eapply as a backend, and gitapply.sh as a backend for binary patches
1027 - ebegin "Running Wine-Staging patch installer"
1028 - (
1029 - set -- DESTDIR="${S}" --backend=eapply --no-autoconf --all ${STAGING_EXCLUDE}
1030 - cd "${STAGING_DIR}/patches"
1031 - source "${STAGING_DIR}/patches/patchinstall.sh"
1032 - )
1033 - eend $? || die "Failed to apply Wine-Staging patches"
1034 - fi
1035 -
1036 - default
1037 - eapply_bin
1038 - eautoreconf
1039 -
1040 - # Modification of the server protocol requires regenerating the server requests
1041 - if [[ "$(md5sum server/protocol.def)" != "${md5}" ]]; then
1042 - einfo "server/protocol.def was patched; running tools/make_requests"
1043 - tools/make_requests || die #432348
1044 - fi
1045 - sed -i '/^UPDATE_DESKTOP_DATABASE/s:=.*:=true:' tools/Makefile.in || die
1046 - if ! use run-exes; then
1047 - sed -i '/^MimeType/d' loader/wine.desktop || die #117785
1048 - fi
1049 -
1050 - # Edit wine.desktop to work for specific variant
1051 - sed -e "/^Exec=/s/wine /wine-${WINE_VARIANT} /" -i loader/wine.desktop || die
1052 -
1053 - # hi-res default icon, #472990, https://bugs.winehq.org/show_bug.cgi?id=24652
1054 - cp "${PATCHDIR}/files/oic_winlogo.ico" dlls/user32/resources/ || die
1055 -
1056 - l10n_get_locales > po/LINGUAS || die # otherwise wine doesn't respect LINGUAS
1057 -
1058 - # Fix manpage generation for locales #469418 and abi_x86_64 #617864
1059 -
1060 - # Duplicate manpages input files for wine64
1061 - local f
1062 - for f in loader/*.man.in; do
1063 - cp ${f} ${f/wine/wine64} || die
1064 - done
1065 - # Add wine64 manpages to Makefile
1066 - if use abi_x86_64; then
1067 - sed -i "/wine.man.in/i \
1068 - \\\twine64.man.in \\\\" loader/Makefile.in || die
1069 - sed -i -E 's/(.*wine)(.*\.UTF-8\.man\.in.*)/&\
1070 -\164\2/' loader/Makefile.in || die
1071 - fi
1072 -
1073 - rm_man_file(){
1074 - local file="${1}"
1075 - loc=${2}
1076 - sed -i "/${loc}\.UTF-8\.man\.in/d" "${file}" || die
1077 - }
1078 -
1079 - while read f; do
1080 - l10n_for_each_disabled_locale_do rm_man_file "${f}"
1081 - done < <(find -name "Makefile.in" -exec grep -q "UTF-8.man.in" "{}" \; -print)
1082 -}
1083 -
1084 -src_configure() {
1085 - wine_compiler_check || die
1086 -
1087 - export LDCONFIG=/bin/true
1088 - use custom-cflags || strip-flags
1089 -
1090 - multilib-minimal_src_configure
1091 -}
1092 -
1093 -multilib_src_configure() {
1094 - local myconf=(
1095 - --prefix="${MY_PREFIX}"
1096 - --datarootdir="${MY_DATAROOTDIR}"
1097 - --datadir="${MY_DATADIR}"
1098 - --docdir="${MY_DOCDIR}"
1099 - --includedir="${MY_INCLUDEDIR}"
1100 - --libdir="${EPREFIX}/usr/$(get_libdir)/wine-${WINE_VARIANT}"
1101 - --libexecdir="${MY_LIBEXECDIR}"
1102 - --localstatedir="${MY_LOCALSTATEDIR}"
1103 - --mandir="${MY_MANDIR}"
1104 - --sysconfdir=/etc/wine
1105 - $(use_with alsa)
1106 - $(use_with capi)
1107 - $(use_with lcms cms)
1108 - $(use_with cups)
1109 - $(use_with ncurses curses)
1110 - $(use_with udisks dbus)
1111 - $(use_with ffmpeg)
1112 - $(use_with fontconfig)
1113 - $(use_with ssl gnutls)
1114 - $(use_enable gecko mshtml)
1115 - $(use_with gphoto2 gphoto)
1116 - $(use_with gsm)
1117 - $(use_with gssapi)
1118 - $(use_with gstreamer)
1119 - --without-hal
1120 - $(use_with jpeg)
1121 - $(use_with kerberos krb5)
1122 - $(use_with ldap)
1123 - $(use_enable mono mscoree)
1124 - $(use_with mp3 mpg123)
1125 - $(use_with netapi)
1126 - $(use_with nls gettext)
1127 - $(use_with openal)
1128 - $(use_with opencl)
1129 - $(use_with opengl)
1130 - $(use_with osmesa)
1131 - $(use_with oss)
1132 - $(use_with pcap)
1133 - $(use_with png)
1134 - $(use_with pulseaudio pulse)
1135 - $(use_with threads pthread)
1136 - $(use_with scanner sane)
1137 - $(use_with sdl)
1138 - $(use_enable test tests)
1139 - $(use_with truetype freetype)
1140 - $(use_with udev)
1141 - $(use_with v4l)
1142 - $(use_with vkd3d)
1143 - $(use_with vulkan)
1144 - $(use_with X x)
1145 - $(use_with X xfixes)
1146 - $(use_with xcomposite)
1147 - $(use_with xinerama)
1148 - $(use_with xml)
1149 - $(use_with xml xslt)
1150 - )
1151 -
1152 - use staging && myconf+=(
1153 - --with-xattr
1154 - $(use_with themes gtk3)
1155 - $(use_with vaapi va)
1156 - )
1157 -
1158 - local PKG_CONFIG AR RANLIB
1159 - # Avoid crossdev's i686-pc-linux-gnu-pkg-config if building wine32 on amd64; #472038
1160 - # set AR and RANLIB to make QA scripts happy; #483342
1161 - tc-export PKG_CONFIG AR RANLIB
1162 -
1163 - if use amd64; then
1164 - if [[ ${ABI} == amd64 ]]; then
1165 - myconf+=( --enable-win64 )
1166 - else
1167 - myconf+=( --disable-win64 )
1168 - fi
1169 -
1170 - # Note: using --with-wine64 results in problems with multilib.eclass
1171 - # CC/LD hackery. We're using separate tools instead.
1172 - fi
1173 -
1174 - ECONF_SOURCE=${S} \
1175 - econf "${myconf[@]}"
1176 - emake depend
1177 -}
1178 -
1179 -multilib_src_test() {
1180 - # FIXME: win32-only; wine64 tests fail with "could not find the Wine loader"
1181 - if [[ ${ABI} == x86 ]]; then
1182 - if [[ $(id -u) == 0 ]]; then
1183 - ewarn "Skipping tests since they cannot be run under the root user."
1184 - ewarn "To run the test ${MY_PN} suite, add userpriv to FEATURES in make.conf"
1185 - return
1186 - fi
1187 -
1188 - WINEPREFIX="${T}/.wine-${ABI}" \
1189 - Xemake test
1190 - fi
1191 -}
1192 -
1193 -multilib_src_install_all() {
1194 - local DOCS=( ANNOUNCE AUTHORS README )
1195 - add_locale_docs() {
1196 - local locale_doc="documentation/README.$1"
1197 - [[ ! -e ${locale_doc} ]] || DOCS+=( ${locale_doc} )
1198 - }
1199 - l10n_for_each_locale_do add_locale_docs
1200 -
1201 - einstalldocs
1202 - prune_libtool_files --all
1203 -
1204 - if ! use perl ; then # winedump calls function_grep.pl, and winemaker is a perl script
1205 - rm "${D%/}${MY_PREFIX}"/bin/{wine{dump,maker},function_grep.pl} \
1206 - "${D%/}${MY_MANDIR}"/man1/wine{dump,maker}.1 || die
1207 - fi
1208 -
1209 - # Remove wineconsole if neither backend is installed #551124
1210 - if ! use X && ! use ncurses; then
1211 - rm "${D%/}${MY_PREFIX}"/bin/wineconsole* || die
1212 - rm "${D%/}${MY_MANDIR}"/man1/wineconsole* || die
1213 - rm_wineconsole() {
1214 - rm "${D%/}${MY_PREFIX}/$(get_libdir)"/wine/{,fakedlls/}wineconsole.exe* || die
1215 - }
1216 - multilib_foreach_abi rm_wineconsole
1217 - fi
1218 -
1219 - use abi_x86_32 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine{,-preloader} #255055
1220 - use abi_x86_64 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine64{,-preloader}
1221 -
1222 - if use abi_x86_64 && ! use abi_x86_32; then
1223 - dosym wine64 "${MY_PREFIX}"/bin/wine # 404331
1224 - dosym wine64-preloader "${MY_PREFIX}"/bin/wine-preloader
1225 - fi
1226 -
1227 - # Failglob for binloops, shouldn't be necessary, but including to stay safe
1228 - eshopts_push -s failglob #615218
1229 - # Make wrappers for binaries for handling multiple variants
1230 - # Note: wrappers instead of symlinks because some are shell which use basename
1231 - local b
1232 - for b in "${D%/}${MY_PREFIX}"/bin/*; do
1233 - make_wrapper "${b##*/}-${WINE_VARIANT}" "${MY_PREFIX}/bin/${b##*/}"
1234 - done
1235 - eshopts_pop
1236 -}
1237 -
1238 -pkg_postinst() {
1239 - eselect wine register ${P}
1240 - if [[ ${PN} == "wine-vanilla" ]]; then
1241 - eselect wine register --vanilla ${P} || die
1242 - else
1243 - if use staging; then
1244 - eselect wine register --staging ${P} || die
1245 - fi
1246 - fi
1247 -
1248 - eselect wine update --all --if-unset || die
1249 -
1250 - xdg_desktop_database_update
1251 -
1252 - if ! use gecko; then
1253 - ewarn "Without Wine Gecko, wine prefixes will not have a default"
1254 - ewarn "implementation of iexplore. Many older windows applications"
1255 - ewarn "rely upon the existence of an iexplore implementation, so"
1256 - ewarn "you will likely need to install an external one, like via winetricks"
1257 - fi
1258 - if ! use mono; then
1259 - ewarn "Without Wine Mono, wine prefixes will not have a default"
1260 - ewarn "implementation of .NET. Many windows applications rely upon"
1261 - ewarn "the existence of a .NET implementation, so you will likely need"
1262 - ewarn "to install an external one, like via winetricks"
1263 - fi
1264 -}
1265 -
1266 -pkg_prerm() {
1267 - eselect wine deregister ${P}
1268 - if [[ ${PN} == "wine-vanilla" ]]; then
1269 - eselect wine deregister --vanilla ${P} || die
1270 - else
1271 - if use staging; then
1272 - eselect wine deregister --staging ${P} || die
1273 - fi
1274 - fi
1275 -
1276 - eselect wine update --all --if-unset || die
1277 -}
1278 -
1279 -pkg_postrm() {
1280 - xdg_desktop_database_update
1281 -}