1 |
commit: 04a3486edf82062ddc9dacd30c0bc45101022a72 |
2 |
Author: Ionen Wolkens <ionen <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed May 18 02:14:51 2022 +0000 |
4 |
Commit: Ionen Wolkens <ionen <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri May 20 20:01:45 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=04a3486e |
7 |
|
8 |
app-emulation/wine-vanilla: support building with mingw64-toolchain |
9 |
|
10 |
This allows USE=mingw to be usable without manually using crossdev |
11 |
first to ease usage for users and automated testing. |
12 |
|
13 |
Old behavior using crossdev still available with USE=crossdev-mingw, |
14 |
albeit new one should offer better stability given mingw64-toolchain |
15 |
is intended/tested especially to build wine+dxvk+vkd3d-proton. |
16 |
|
17 |
Given wine is pushing PE conversions and some things work better with |
18 |
PE files (e.g. Blizzard games, Proton also uses --with-mingw), it may |
19 |
be useful for the prospect of making this a default at some point. |
20 |
|
21 |
Note that mingw64-toolchain's ${MULTILIB_USEDEP} does belong in BDEPEND |
22 |
(unless <EAPI-7), as it'll use cross libraries located in BROOT. |
23 |
|
24 |
Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org> |
25 |
|
26 |
app-emulation/wine-vanilla/metadata.xml | 4 ++ |
27 |
.../wine-vanilla/wine-vanilla-6.0.2.ebuild | 46 +++++++++------------- |
28 |
.../wine-vanilla/wine-vanilla-7.0-r2.ebuild | 46 +++++++++------------- |
29 |
app-emulation/wine-vanilla/wine-vanilla-7.0.ebuild | 46 +++++++++------------- |
30 |
.../wine-vanilla/wine-vanilla-7.5-r1.ebuild | 46 +++++++++------------- |
31 |
.../wine-vanilla/wine-vanilla-7.6-r1.ebuild | 46 +++++++++------------- |
32 |
app-emulation/wine-vanilla/wine-vanilla-7.7.ebuild | 46 +++++++++------------- |
33 |
app-emulation/wine-vanilla/wine-vanilla-7.8.ebuild | 46 +++++++++------------- |
34 |
.../wine-vanilla/wine-vanilla-9999.ebuild | 46 +++++++++------------- |
35 |
9 files changed, 148 insertions(+), 224 deletions(-) |
36 |
|
37 |
diff --git a/app-emulation/wine-vanilla/metadata.xml b/app-emulation/wine-vanilla/metadata.xml |
38 |
index 8972283b6d89..dcf09b834f72 100644 |
39 |
--- a/app-emulation/wine-vanilla/metadata.xml |
40 |
+++ b/app-emulation/wine-vanilla/metadata.xml |
41 |
@@ -18,6 +18,10 @@ This variant of the Wine packaging does not include external patchsets |
42 |
</longdescription> |
43 |
<use> |
44 |
<flag name="capi">Enable ISDN support via CAPI</flag> |
45 |
+ <flag name="crossdev-mingw"> |
46 |
+ Use <pkg>sys-devel/crossdev</pkg> for the toolchain rather than |
47 |
+ <pkg>dev-util/mingw64-toolchain</pkg> (requires manual setting up) |
48 |
+ </flag> |
49 |
<flag name="custom-cflags">Bypass strip-flags; use at your own peril</flag> |
50 |
<flag name="dos">Pull in <pkg>games-emulation/dosbox</pkg> to run DOS applications</flag> |
51 |
<flag name="faudio">Pull in <pkg>app-emulation/faudio</pkg> to provide XAudio2 functionality</flag> |
52 |
|
53 |
diff --git a/app-emulation/wine-vanilla/wine-vanilla-6.0.2.ebuild b/app-emulation/wine-vanilla/wine-vanilla-6.0.2.ebuild |
54 |
index 1a3c42a09643..9810db168765 100644 |
55 |
--- a/app-emulation/wine-vanilla/wine-vanilla-6.0.2.ebuild |
56 |
+++ b/app-emulation/wine-vanilla/wine-vanilla-6.0.2.ebuild |
57 |
@@ -34,9 +34,10 @@ SRC_URI="${SRC_URI} |
58 |
|
59 |
LICENSE="LGPL-2.1" |
60 |
SLOT="${PV}" |
61 |
-IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos +faudio +fontconfig +gecko gphoto2 gsm gssapi gstreamer +jpeg kerberos +lcms ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap +png pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama +xml" |
62 |
+IUSE="+abi_x86_32 +abi_x86_64 +alsa capi crossdev-mingw cups custom-cflags dos +faudio +fontconfig +gecko gphoto2 gsm gssapi gstreamer +jpeg kerberos +lcms ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap +png pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama +xml" |
63 |
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 ) |
64 |
X? ( truetype ) |
65 |
+ crossdev-mingw? ( mingw ) |
66 |
elibc_glibc? ( threads ) |
67 |
osmesa? ( opengl ) |
68 |
test? ( abi_x86_32 ) |
69 |
@@ -128,7 +129,8 @@ DEPEND="${COMMON_DEPEND} |
70 |
virtual/pkgconfig |
71 |
virtual/yacc |
72 |
X? ( x11-base/xorg-proto ) |
73 |
- xinerama? ( x11-base/xorg-proto )" |
74 |
+ xinerama? ( x11-base/xorg-proto ) |
75 |
+ !crossdev-mingw? ( dev-util/mingw64-toolchain[${MULTILIB_USEDEP}] )" |
76 |
|
77 |
# These use a non-standard "Wine" category, which is provided by |
78 |
# /etc/xdg/applications-merged/wine.menu |
79 |
@@ -194,32 +196,18 @@ pkg_pretend() { |
80 |
fi |
81 |
fi |
82 |
|
83 |
- if use mingw && use abi_x86_32 && ! has_version "cross-i686-w64-mingw32/gcc"; then |
84 |
- eerror |
85 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
86 |
- eerror "'cross-i686-w64-mingw32' compiler and its runtime for 32-bit builds." |
87 |
- eerror |
88 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
89 |
- eerror |
90 |
- eerror "crossdev --target i686-w64-mingw32" |
91 |
- eerror |
92 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
93 |
- eerror |
94 |
- die "MinGW build was enabled, but no compiler to support it was found." |
95 |
- fi |
96 |
- |
97 |
- if use mingw && use abi_x86_64 && ! has_version "cross-x86_64-w64-mingw32/gcc"; then |
98 |
- eerror |
99 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
100 |
- eerror "'cross-x86_64-w64-mingw32' compiler and its runtime for 64-bit builds." |
101 |
- eerror |
102 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
103 |
- eerror |
104 |
- eerror "crossdev --target x86_64-w64-mingw32" |
105 |
- eerror |
106 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
107 |
- eerror |
108 |
- die "MinGW build was enabled, but no compiler to support it was found." |
109 |
+ if use crossdev-mingw && [[ ! -v MINGW_BYPASS ]]; then |
110 |
+ local mingw=-w64-mingw32 |
111 |
+ for mingw in $(usex abi_x86_64 x86_64${mingw} '') $(usex abi_x86_32 i686${mingw} ''); do |
112 |
+ type -P ${mingw}-gcc && continue |
113 |
+ eerror "With USE=crossdev-mingw, you must prepare the MinGW toolchain" |
114 |
+ eerror "yourself by installing sys-devel/crossdev then running:" |
115 |
+ eerror |
116 |
+ eerror " crossdev --target ${mingw}" |
117 |
+ eerror |
118 |
+ eerror "For more information, please see: https://wiki.gentoo.org/wiki/Mingw" |
119 |
+ die "USE=crossdev-mingw is enabled, but ${mingw}-gcc was not found" |
120 |
+ done |
121 |
fi |
122 |
} |
123 |
|
124 |
@@ -315,6 +303,8 @@ src_configure() { |
125 |
export LDCONFIG=/bin/true |
126 |
use custom-cflags || strip-flags |
127 |
if use mingw; then |
128 |
+ use crossdev-mingw || PATH=${EPREFIX}/usr/lib/mingw64-toolchain/bin:${PATH} |
129 |
+ |
130 |
export CROSSCFLAGS="${CFLAGS}" |
131 |
fi |
132 |
|
133 |
|
134 |
diff --git a/app-emulation/wine-vanilla/wine-vanilla-7.0-r2.ebuild b/app-emulation/wine-vanilla/wine-vanilla-7.0-r2.ebuild |
135 |
index 352885e11423..1992efdf9908 100644 |
136 |
--- a/app-emulation/wine-vanilla/wine-vanilla-7.0-r2.ebuild |
137 |
+++ b/app-emulation/wine-vanilla/wine-vanilla-7.0-r2.ebuild |
138 |
@@ -35,9 +35,10 @@ SRC_URI="${SRC_URI} |
139 |
|
140 |
LICENSE="LGPL-2.1" |
141 |
SLOT="${PV}" |
142 |
-IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama" |
143 |
+IUSE="+abi_x86_32 +abi_x86_64 +alsa capi crossdev-mingw cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama" |
144 |
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 ) |
145 |
X? ( truetype ) |
146 |
+ crossdev-mingw? ( mingw ) |
147 |
elibc_glibc? ( threads ) |
148 |
osmesa? ( opengl ) |
149 |
test? ( abi_x86_32 ) |
150 |
@@ -49,7 +50,8 @@ RESTRICT="test" |
151 |
|
152 |
BDEPEND="sys-devel/flex |
153 |
virtual/yacc |
154 |
- virtual/pkgconfig" |
155 |
+ virtual/pkgconfig |
156 |
+ !crossdev-mingw? ( dev-util/mingw64-toolchain[${MULTILIB_USEDEP}] )" |
157 |
|
158 |
COMMON_DEPEND=" |
159 |
X? ( |
160 |
@@ -185,32 +187,18 @@ pkg_pretend() { |
161 |
fi |
162 |
fi |
163 |
|
164 |
- if use mingw && use abi_x86_32 && ! has_version "cross-i686-w64-mingw32/gcc"; then |
165 |
- eerror |
166 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
167 |
- eerror "'cross-i686-w64-mingw32' compiler and its runtime for 32-bit builds." |
168 |
- eerror |
169 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
170 |
- eerror |
171 |
- eerror "crossdev --target i686-w64-mingw32" |
172 |
- eerror |
173 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
174 |
- eerror |
175 |
- die "MinGW build was enabled, but no compiler to support it was found." |
176 |
- fi |
177 |
- |
178 |
- if use mingw && use abi_x86_64 && ! has_version "cross-x86_64-w64-mingw32/gcc"; then |
179 |
- eerror |
180 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
181 |
- eerror "'cross-x86_64-w64-mingw32' compiler and its runtime for 64-bit builds." |
182 |
- eerror |
183 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
184 |
- eerror |
185 |
- eerror "crossdev --target x86_64-w64-mingw32" |
186 |
- eerror |
187 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
188 |
- eerror |
189 |
- die "MinGW build was enabled, but no compiler to support it was found." |
190 |
+ if use crossdev-mingw && [[ ! -v MINGW_BYPASS ]]; then |
191 |
+ local mingw=-w64-mingw32 |
192 |
+ for mingw in $(usev abi_x86_64 x86_64${mingw}) $(usev abi_x86_32 i686${mingw}); do |
193 |
+ type -P ${mingw}-gcc && continue |
194 |
+ eerror "With USE=crossdev-mingw, you must prepare the MinGW toolchain" |
195 |
+ eerror "yourself by installing sys-devel/crossdev then running:" |
196 |
+ eerror |
197 |
+ eerror " crossdev --target ${mingw}" |
198 |
+ eerror |
199 |
+ eerror "For more information, please see: https://wiki.gentoo.org/wiki/Mingw" |
200 |
+ die "USE=crossdev-mingw is enabled, but ${mingw}-gcc was not found" |
201 |
+ done |
202 |
fi |
203 |
} |
204 |
|
205 |
@@ -306,6 +294,8 @@ src_configure() { |
206 |
export LDCONFIG=/bin/true |
207 |
use custom-cflags || strip-flags |
208 |
if use mingw; then |
209 |
+ use crossdev-mingw || PATH=${BROOT}/usr/lib/mingw64-toolchain/bin:${PATH} |
210 |
+ |
211 |
export CROSSCFLAGS="${CFLAGS}" |
212 |
fi |
213 |
|
214 |
|
215 |
diff --git a/app-emulation/wine-vanilla/wine-vanilla-7.0.ebuild b/app-emulation/wine-vanilla/wine-vanilla-7.0.ebuild |
216 |
index 90894fbc6aef..74051ef469f0 100644 |
217 |
--- a/app-emulation/wine-vanilla/wine-vanilla-7.0.ebuild |
218 |
+++ b/app-emulation/wine-vanilla/wine-vanilla-7.0.ebuild |
219 |
@@ -35,9 +35,10 @@ SRC_URI="${SRC_URI} |
220 |
|
221 |
LICENSE="LGPL-2.1" |
222 |
SLOT="${PV}" |
223 |
-IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama" |
224 |
+IUSE="+abi_x86_32 +abi_x86_64 +alsa capi crossdev-mingw cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama" |
225 |
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 ) |
226 |
X? ( truetype ) |
227 |
+ crossdev-mingw? ( mingw ) |
228 |
elibc_glibc? ( threads ) |
229 |
osmesa? ( opengl ) |
230 |
test? ( abi_x86_32 ) |
231 |
@@ -121,7 +122,8 @@ DEPEND="${COMMON_DEPEND} |
232 |
virtual/pkgconfig |
233 |
virtual/yacc |
234 |
X? ( x11-base/xorg-proto ) |
235 |
- xinerama? ( x11-base/xorg-proto )" |
236 |
+ xinerama? ( x11-base/xorg-proto ) |
237 |
+ !crossdev-mingw? ( dev-util/mingw64-toolchain[${MULTILIB_USEDEP}] )" |
238 |
|
239 |
# These use a non-standard "Wine" category, which is provided by |
240 |
# /etc/xdg/applications-merged/wine.menu |
241 |
@@ -184,32 +186,18 @@ pkg_pretend() { |
242 |
fi |
243 |
fi |
244 |
|
245 |
- if use mingw && use abi_x86_32 && ! has_version "cross-i686-w64-mingw32/gcc"; then |
246 |
- eerror |
247 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
248 |
- eerror "'cross-i686-w64-mingw32' compiler and its runtime for 32-bit builds." |
249 |
- eerror |
250 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
251 |
- eerror |
252 |
- eerror "crossdev --target i686-w64-mingw32" |
253 |
- eerror |
254 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
255 |
- eerror |
256 |
- die "MinGW build was enabled, but no compiler to support it was found." |
257 |
- fi |
258 |
- |
259 |
- if use mingw && use abi_x86_64 && ! has_version "cross-x86_64-w64-mingw32/gcc"; then |
260 |
- eerror |
261 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
262 |
- eerror "'cross-x86_64-w64-mingw32' compiler and its runtime for 64-bit builds." |
263 |
- eerror |
264 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
265 |
- eerror |
266 |
- eerror "crossdev --target x86_64-w64-mingw32" |
267 |
- eerror |
268 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
269 |
- eerror |
270 |
- die "MinGW build was enabled, but no compiler to support it was found." |
271 |
+ if use crossdev-mingw && [[ ! -v MINGW_BYPASS ]]; then |
272 |
+ local mingw=-w64-mingw32 |
273 |
+ for mingw in $(usex abi_x86_64 x86_64${mingw} '') $(usex abi_x86_32 i686${mingw} ''); do |
274 |
+ type -P ${mingw}-gcc && continue |
275 |
+ eerror "With USE=crossdev-mingw, you must prepare the MinGW toolchain" |
276 |
+ eerror "yourself by installing sys-devel/crossdev then running:" |
277 |
+ eerror |
278 |
+ eerror " crossdev --target ${mingw}" |
279 |
+ eerror |
280 |
+ eerror "For more information, please see: https://wiki.gentoo.org/wiki/Mingw" |
281 |
+ die "USE=crossdev-mingw is enabled, but ${mingw}-gcc was not found" |
282 |
+ done |
283 |
fi |
284 |
} |
285 |
|
286 |
@@ -305,6 +293,8 @@ src_configure() { |
287 |
export LDCONFIG=/bin/true |
288 |
use custom-cflags || strip-flags |
289 |
if use mingw; then |
290 |
+ use crossdev-mingw || PATH=${EPREFIX}/usr/lib/mingw64-toolchain/bin:${PATH} |
291 |
+ |
292 |
export CROSSCFLAGS="${CFLAGS}" |
293 |
fi |
294 |
|
295 |
|
296 |
diff --git a/app-emulation/wine-vanilla/wine-vanilla-7.5-r1.ebuild b/app-emulation/wine-vanilla/wine-vanilla-7.5-r1.ebuild |
297 |
index 11829957a62f..e6242d06fb43 100644 |
298 |
--- a/app-emulation/wine-vanilla/wine-vanilla-7.5-r1.ebuild |
299 |
+++ b/app-emulation/wine-vanilla/wine-vanilla-7.5-r1.ebuild |
300 |
@@ -35,9 +35,10 @@ SRC_URI="${SRC_URI} |
301 |
|
302 |
LICENSE="LGPL-2.1" |
303 |
SLOT="${PV}" |
304 |
-IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama" |
305 |
+IUSE="+abi_x86_32 +abi_x86_64 +alsa capi crossdev-mingw cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama" |
306 |
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 ) |
307 |
X? ( truetype ) |
308 |
+ crossdev-mingw? ( mingw ) |
309 |
elibc_glibc? ( threads ) |
310 |
osmesa? ( opengl ) |
311 |
test? ( abi_x86_32 ) |
312 |
@@ -49,7 +50,8 @@ RESTRICT="test" |
313 |
|
314 |
BDEPEND="sys-devel/flex |
315 |
virtual/yacc |
316 |
- virtual/pkgconfig" |
317 |
+ virtual/pkgconfig |
318 |
+ !crossdev-mingw? ( dev-util/mingw64-toolchain[${MULTILIB_USEDEP}] )" |
319 |
|
320 |
COMMON_DEPEND=" |
321 |
X? ( |
322 |
@@ -186,32 +188,18 @@ pkg_pretend() { |
323 |
fi |
324 |
fi |
325 |
|
326 |
- if use mingw && use abi_x86_32 && ! has_version "cross-i686-w64-mingw32/gcc"; then |
327 |
- eerror |
328 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
329 |
- eerror "'cross-i686-w64-mingw32' compiler and its runtime for 32-bit builds." |
330 |
- eerror |
331 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
332 |
- eerror |
333 |
- eerror "crossdev --target i686-w64-mingw32" |
334 |
- eerror |
335 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
336 |
- eerror |
337 |
- die "MinGW build was enabled, but no compiler to support it was found." |
338 |
- fi |
339 |
- |
340 |
- if use mingw && use abi_x86_64 && ! has_version "cross-x86_64-w64-mingw32/gcc"; then |
341 |
- eerror |
342 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
343 |
- eerror "'cross-x86_64-w64-mingw32' compiler and its runtime for 64-bit builds." |
344 |
- eerror |
345 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
346 |
- eerror |
347 |
- eerror "crossdev --target x86_64-w64-mingw32" |
348 |
- eerror |
349 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
350 |
- eerror |
351 |
- die "MinGW build was enabled, but no compiler to support it was found." |
352 |
+ if use crossdev-mingw && [[ ! -v MINGW_BYPASS ]]; then |
353 |
+ local mingw=-w64-mingw32 |
354 |
+ for mingw in $(usev abi_x86_64 x86_64${mingw}) $(usev abi_x86_32 i686${mingw}); do |
355 |
+ type -P ${mingw}-gcc && continue |
356 |
+ eerror "With USE=crossdev-mingw, you must prepare the MinGW toolchain" |
357 |
+ eerror "yourself by installing sys-devel/crossdev then running:" |
358 |
+ eerror |
359 |
+ eerror " crossdev --target ${mingw}" |
360 |
+ eerror |
361 |
+ eerror "For more information, please see: https://wiki.gentoo.org/wiki/Mingw" |
362 |
+ die "USE=crossdev-mingw is enabled, but ${mingw}-gcc was not found" |
363 |
+ done |
364 |
fi |
365 |
} |
366 |
|
367 |
@@ -307,6 +295,8 @@ src_configure() { |
368 |
export LDCONFIG=/bin/true |
369 |
use custom-cflags || strip-flags |
370 |
if use mingw; then |
371 |
+ use crossdev-mingw || PATH=${BROOT}/usr/lib/mingw64-toolchain/bin:${PATH} |
372 |
+ |
373 |
export CROSSCFLAGS="${CFLAGS}" |
374 |
fi |
375 |
|
376 |
|
377 |
diff --git a/app-emulation/wine-vanilla/wine-vanilla-7.6-r1.ebuild b/app-emulation/wine-vanilla/wine-vanilla-7.6-r1.ebuild |
378 |
index 7e5368175d7d..b0609a8bff36 100644 |
379 |
--- a/app-emulation/wine-vanilla/wine-vanilla-7.6-r1.ebuild |
380 |
+++ b/app-emulation/wine-vanilla/wine-vanilla-7.6-r1.ebuild |
381 |
@@ -35,9 +35,10 @@ SRC_URI="${SRC_URI} |
382 |
|
383 |
LICENSE="LGPL-2.1" |
384 |
SLOT="${PV}" |
385 |
-IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama" |
386 |
+IUSE="+abi_x86_32 +abi_x86_64 +alsa capi crossdev-mingw cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama" |
387 |
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 ) |
388 |
X? ( truetype ) |
389 |
+ crossdev-mingw? ( mingw ) |
390 |
elibc_glibc? ( threads ) |
391 |
osmesa? ( opengl ) |
392 |
test? ( abi_x86_32 ) |
393 |
@@ -49,7 +50,8 @@ RESTRICT="test" |
394 |
|
395 |
BDEPEND="sys-devel/flex |
396 |
virtual/yacc |
397 |
- virtual/pkgconfig" |
398 |
+ virtual/pkgconfig |
399 |
+ !crossdev-mingw? ( dev-util/mingw64-toolchain[${MULTILIB_USEDEP}] )" |
400 |
|
401 |
COMMON_DEPEND=" |
402 |
X? ( |
403 |
@@ -185,32 +187,18 @@ pkg_pretend() { |
404 |
fi |
405 |
fi |
406 |
|
407 |
- if use mingw && use abi_x86_32 && ! has_version "cross-i686-w64-mingw32/gcc"; then |
408 |
- eerror |
409 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
410 |
- eerror "'cross-i686-w64-mingw32' compiler and its runtime for 32-bit builds." |
411 |
- eerror |
412 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
413 |
- eerror |
414 |
- eerror "crossdev --target i686-w64-mingw32" |
415 |
- eerror |
416 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
417 |
- eerror |
418 |
- die "MinGW build was enabled, but no compiler to support it was found." |
419 |
- fi |
420 |
- |
421 |
- if use mingw && use abi_x86_64 && ! has_version "cross-x86_64-w64-mingw32/gcc"; then |
422 |
- eerror |
423 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
424 |
- eerror "'cross-x86_64-w64-mingw32' compiler and its runtime for 64-bit builds." |
425 |
- eerror |
426 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
427 |
- eerror |
428 |
- eerror "crossdev --target x86_64-w64-mingw32" |
429 |
- eerror |
430 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
431 |
- eerror |
432 |
- die "MinGW build was enabled, but no compiler to support it was found." |
433 |
+ if use crossdev-mingw && [[ ! -v MINGW_BYPASS ]]; then |
434 |
+ local mingw=-w64-mingw32 |
435 |
+ for mingw in $(usev abi_x86_64 x86_64${mingw}) $(usev abi_x86_32 i686${mingw}); do |
436 |
+ type -P ${mingw}-gcc && continue |
437 |
+ eerror "With USE=crossdev-mingw, you must prepare the MinGW toolchain" |
438 |
+ eerror "yourself by installing sys-devel/crossdev then running:" |
439 |
+ eerror |
440 |
+ eerror " crossdev --target ${mingw}" |
441 |
+ eerror |
442 |
+ eerror "For more information, please see: https://wiki.gentoo.org/wiki/Mingw" |
443 |
+ die "USE=crossdev-mingw is enabled, but ${mingw}-gcc was not found" |
444 |
+ done |
445 |
fi |
446 |
} |
447 |
|
448 |
@@ -306,6 +294,8 @@ src_configure() { |
449 |
export LDCONFIG=/bin/true |
450 |
use custom-cflags || strip-flags |
451 |
if use mingw; then |
452 |
+ use crossdev-mingw || PATH=${BROOT}/usr/lib/mingw64-toolchain/bin:${PATH} |
453 |
+ |
454 |
export CROSSCFLAGS="${CFLAGS}" |
455 |
fi |
456 |
|
457 |
|
458 |
diff --git a/app-emulation/wine-vanilla/wine-vanilla-7.7.ebuild b/app-emulation/wine-vanilla/wine-vanilla-7.7.ebuild |
459 |
index 7e5368175d7d..b0609a8bff36 100644 |
460 |
--- a/app-emulation/wine-vanilla/wine-vanilla-7.7.ebuild |
461 |
+++ b/app-emulation/wine-vanilla/wine-vanilla-7.7.ebuild |
462 |
@@ -35,9 +35,10 @@ SRC_URI="${SRC_URI} |
463 |
|
464 |
LICENSE="LGPL-2.1" |
465 |
SLOT="${PV}" |
466 |
-IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama" |
467 |
+IUSE="+abi_x86_32 +abi_x86_64 +alsa capi crossdev-mingw cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vkd3d vulkan +X +xcomposite xinerama" |
468 |
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 ) |
469 |
X? ( truetype ) |
470 |
+ crossdev-mingw? ( mingw ) |
471 |
elibc_glibc? ( threads ) |
472 |
osmesa? ( opengl ) |
473 |
test? ( abi_x86_32 ) |
474 |
@@ -49,7 +50,8 @@ RESTRICT="test" |
475 |
|
476 |
BDEPEND="sys-devel/flex |
477 |
virtual/yacc |
478 |
- virtual/pkgconfig" |
479 |
+ virtual/pkgconfig |
480 |
+ !crossdev-mingw? ( dev-util/mingw64-toolchain[${MULTILIB_USEDEP}] )" |
481 |
|
482 |
COMMON_DEPEND=" |
483 |
X? ( |
484 |
@@ -185,32 +187,18 @@ pkg_pretend() { |
485 |
fi |
486 |
fi |
487 |
|
488 |
- if use mingw && use abi_x86_32 && ! has_version "cross-i686-w64-mingw32/gcc"; then |
489 |
- eerror |
490 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
491 |
- eerror "'cross-i686-w64-mingw32' compiler and its runtime for 32-bit builds." |
492 |
- eerror |
493 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
494 |
- eerror |
495 |
- eerror "crossdev --target i686-w64-mingw32" |
496 |
- eerror |
497 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
498 |
- eerror |
499 |
- die "MinGW build was enabled, but no compiler to support it was found." |
500 |
- fi |
501 |
- |
502 |
- if use mingw && use abi_x86_64 && ! has_version "cross-x86_64-w64-mingw32/gcc"; then |
503 |
- eerror |
504 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
505 |
- eerror "'cross-x86_64-w64-mingw32' compiler and its runtime for 64-bit builds." |
506 |
- eerror |
507 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
508 |
- eerror |
509 |
- eerror "crossdev --target x86_64-w64-mingw32" |
510 |
- eerror |
511 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
512 |
- eerror |
513 |
- die "MinGW build was enabled, but no compiler to support it was found." |
514 |
+ if use crossdev-mingw && [[ ! -v MINGW_BYPASS ]]; then |
515 |
+ local mingw=-w64-mingw32 |
516 |
+ for mingw in $(usev abi_x86_64 x86_64${mingw}) $(usev abi_x86_32 i686${mingw}); do |
517 |
+ type -P ${mingw}-gcc && continue |
518 |
+ eerror "With USE=crossdev-mingw, you must prepare the MinGW toolchain" |
519 |
+ eerror "yourself by installing sys-devel/crossdev then running:" |
520 |
+ eerror |
521 |
+ eerror " crossdev --target ${mingw}" |
522 |
+ eerror |
523 |
+ eerror "For more information, please see: https://wiki.gentoo.org/wiki/Mingw" |
524 |
+ die "USE=crossdev-mingw is enabled, but ${mingw}-gcc was not found" |
525 |
+ done |
526 |
fi |
527 |
} |
528 |
|
529 |
@@ -306,6 +294,8 @@ src_configure() { |
530 |
export LDCONFIG=/bin/true |
531 |
use custom-cflags || strip-flags |
532 |
if use mingw; then |
533 |
+ use crossdev-mingw || PATH=${BROOT}/usr/lib/mingw64-toolchain/bin:${PATH} |
534 |
+ |
535 |
export CROSSCFLAGS="${CFLAGS}" |
536 |
fi |
537 |
|
538 |
|
539 |
diff --git a/app-emulation/wine-vanilla/wine-vanilla-7.8.ebuild b/app-emulation/wine-vanilla/wine-vanilla-7.8.ebuild |
540 |
index 0ff4ad29a37e..25c7af87ecba 100644 |
541 |
--- a/app-emulation/wine-vanilla/wine-vanilla-7.8.ebuild |
542 |
+++ b/app-emulation/wine-vanilla/wine-vanilla-7.8.ebuild |
543 |
@@ -35,9 +35,10 @@ SRC_URI="${SRC_URI} |
544 |
|
545 |
LICENSE="LGPL-2.1" |
546 |
SLOT="${PV}" |
547 |
-IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vulkan +X +xcomposite xinerama" |
548 |
+IUSE="+abi_x86_32 +abi_x86_64 +alsa capi crossdev-mingw cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vulkan +X +xcomposite xinerama" |
549 |
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 ) |
550 |
X? ( truetype ) |
551 |
+ crossdev-mingw? ( mingw ) |
552 |
elibc_glibc? ( threads ) |
553 |
osmesa? ( opengl ) |
554 |
test? ( abi_x86_32 )" # osmesa-opengl #286560 # X-truetype #551124 |
555 |
@@ -48,7 +49,8 @@ RESTRICT="test" |
556 |
|
557 |
BDEPEND="sys-devel/flex |
558 |
virtual/yacc |
559 |
- virtual/pkgconfig" |
560 |
+ virtual/pkgconfig |
561 |
+ !crossdev-mingw? ( dev-util/mingw64-toolchain[${MULTILIB_USEDEP}] )" |
562 |
|
563 |
COMMON_DEPEND=" |
564 |
X? ( |
565 |
@@ -183,32 +185,18 @@ pkg_pretend() { |
566 |
fi |
567 |
fi |
568 |
|
569 |
- if use mingw && use abi_x86_32 && ! has_version "cross-i686-w64-mingw32/gcc"; then |
570 |
- eerror |
571 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
572 |
- eerror "'cross-i686-w64-mingw32' compiler and its runtime for 32-bit builds." |
573 |
- eerror |
574 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
575 |
- eerror |
576 |
- eerror "crossdev --target i686-w64-mingw32" |
577 |
- eerror |
578 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
579 |
- eerror |
580 |
- die "MinGW build was enabled, but no compiler to support it was found." |
581 |
- fi |
582 |
- |
583 |
- if use mingw && use abi_x86_64 && ! has_version "cross-x86_64-w64-mingw32/gcc"; then |
584 |
- eerror |
585 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
586 |
- eerror "'cross-x86_64-w64-mingw32' compiler and its runtime for 64-bit builds." |
587 |
- eerror |
588 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
589 |
- eerror |
590 |
- eerror "crossdev --target x86_64-w64-mingw32" |
591 |
- eerror |
592 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
593 |
- eerror |
594 |
- die "MinGW build was enabled, but no compiler to support it was found." |
595 |
+ if use crossdev-mingw && [[ ! -v MINGW_BYPASS ]]; then |
596 |
+ local mingw=-w64-mingw32 |
597 |
+ for mingw in $(usev abi_x86_64 x86_64${mingw}) $(usev abi_x86_32 i686${mingw}); do |
598 |
+ type -P ${mingw}-gcc && continue |
599 |
+ eerror "With USE=crossdev-mingw, you must prepare the MinGW toolchain" |
600 |
+ eerror "yourself by installing sys-devel/crossdev then running:" |
601 |
+ eerror |
602 |
+ eerror " crossdev --target ${mingw}" |
603 |
+ eerror |
604 |
+ eerror "For more information, please see: https://wiki.gentoo.org/wiki/Mingw" |
605 |
+ die "USE=crossdev-mingw is enabled, but ${mingw}-gcc was not found" |
606 |
+ done |
607 |
fi |
608 |
} |
609 |
|
610 |
@@ -304,6 +292,8 @@ src_configure() { |
611 |
export LDCONFIG=/bin/true |
612 |
use custom-cflags || strip-flags |
613 |
if use mingw; then |
614 |
+ use crossdev-mingw || PATH=${BROOT}/usr/lib/mingw64-toolchain/bin:${PATH} |
615 |
+ |
616 |
export CROSSCFLAGS="${CFLAGS}" |
617 |
fi |
618 |
|
619 |
|
620 |
diff --git a/app-emulation/wine-vanilla/wine-vanilla-9999.ebuild b/app-emulation/wine-vanilla/wine-vanilla-9999.ebuild |
621 |
index 0ff4ad29a37e..25c7af87ecba 100644 |
622 |
--- a/app-emulation/wine-vanilla/wine-vanilla-9999.ebuild |
623 |
+++ b/app-emulation/wine-vanilla/wine-vanilla-9999.ebuild |
624 |
@@ -35,9 +35,10 @@ SRC_URI="${SRC_URI} |
625 |
|
626 |
LICENSE="LGPL-2.1" |
627 |
SLOT="${PV}" |
628 |
-IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vulkan +X +xcomposite xinerama" |
629 |
+IUSE="+abi_x86_32 +abi_x86_64 +alsa capi crossdev-mingw cups custom-cflags dos +fontconfig +gecko gphoto2 gssapi gstreamer kerberos ldap mingw +mono mp3 netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks +unwind usb v4l vulkan +X +xcomposite xinerama" |
630 |
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 ) |
631 |
X? ( truetype ) |
632 |
+ crossdev-mingw? ( mingw ) |
633 |
elibc_glibc? ( threads ) |
634 |
osmesa? ( opengl ) |
635 |
test? ( abi_x86_32 )" # osmesa-opengl #286560 # X-truetype #551124 |
636 |
@@ -48,7 +49,8 @@ RESTRICT="test" |
637 |
|
638 |
BDEPEND="sys-devel/flex |
639 |
virtual/yacc |
640 |
- virtual/pkgconfig" |
641 |
+ virtual/pkgconfig |
642 |
+ !crossdev-mingw? ( dev-util/mingw64-toolchain[${MULTILIB_USEDEP}] )" |
643 |
|
644 |
COMMON_DEPEND=" |
645 |
X? ( |
646 |
@@ -183,32 +185,18 @@ pkg_pretend() { |
647 |
fi |
648 |
fi |
649 |
|
650 |
- if use mingw && use abi_x86_32 && ! has_version "cross-i686-w64-mingw32/gcc"; then |
651 |
- eerror |
652 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
653 |
- eerror "'cross-i686-w64-mingw32' compiler and its runtime for 32-bit builds." |
654 |
- eerror |
655 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
656 |
- eerror |
657 |
- eerror "crossdev --target i686-w64-mingw32" |
658 |
- eerror |
659 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
660 |
- eerror |
661 |
- die "MinGW build was enabled, but no compiler to support it was found." |
662 |
- fi |
663 |
- |
664 |
- if use mingw && use abi_x86_64 && ! has_version "cross-x86_64-w64-mingw32/gcc"; then |
665 |
- eerror |
666 |
- eerror "USE=\"mingw\" is currently experimental, and requires the" |
667 |
- eerror "'cross-x86_64-w64-mingw32' compiler and its runtime for 64-bit builds." |
668 |
- eerror |
669 |
- eerror "These can be installed by using 'sys-devel/crossdev':" |
670 |
- eerror |
671 |
- eerror "crossdev --target x86_64-w64-mingw32" |
672 |
- eerror |
673 |
- eerror "For more information on setting up MinGW, see: https://wiki.gentoo.org/wiki/Mingw" |
674 |
- eerror |
675 |
- die "MinGW build was enabled, but no compiler to support it was found." |
676 |
+ if use crossdev-mingw && [[ ! -v MINGW_BYPASS ]]; then |
677 |
+ local mingw=-w64-mingw32 |
678 |
+ for mingw in $(usev abi_x86_64 x86_64${mingw}) $(usev abi_x86_32 i686${mingw}); do |
679 |
+ type -P ${mingw}-gcc && continue |
680 |
+ eerror "With USE=crossdev-mingw, you must prepare the MinGW toolchain" |
681 |
+ eerror "yourself by installing sys-devel/crossdev then running:" |
682 |
+ eerror |
683 |
+ eerror " crossdev --target ${mingw}" |
684 |
+ eerror |
685 |
+ eerror "For more information, please see: https://wiki.gentoo.org/wiki/Mingw" |
686 |
+ die "USE=crossdev-mingw is enabled, but ${mingw}-gcc was not found" |
687 |
+ done |
688 |
fi |
689 |
} |
690 |
|
691 |
@@ -304,6 +292,8 @@ src_configure() { |
692 |
export LDCONFIG=/bin/true |
693 |
use custom-cflags || strip-flags |
694 |
if use mingw; then |
695 |
+ use crossdev-mingw || PATH=${BROOT}/usr/lib/mingw64-toolchain/bin:${PATH} |
696 |
+ |
697 |
export CROSSCFLAGS="${CFLAGS}" |
698 |
fi |