1 |
commit: adfba2c6ccd2c5cabf65f23247267eb97d65bb0f |
2 |
Author: Ionen Wolkens <ionen <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Nov 27 11:46:19 2022 +0000 |
4 |
Commit: Ionen Wolkens <ionen <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Nov 27 12:25:40 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=adfba2c6 |
7 |
|
8 |
app-emulation/wine-staging: add 7.22 |
9 |
|
10 |
Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org> |
11 |
|
12 |
app-emulation/wine-staging/Manifest | 2 + |
13 |
.../wine-staging/wine-staging-7.22.ebuild | 353 +++++++++++++++++++++ |
14 |
2 files changed, 355 insertions(+) |
15 |
|
16 |
diff --git a/app-emulation/wine-staging/Manifest b/app-emulation/wine-staging/Manifest |
17 |
index 64e77d72fe3f..ece56f286ed3 100644 |
18 |
--- a/app-emulation/wine-staging/Manifest |
19 |
+++ b/app-emulation/wine-staging/Manifest |
20 |
@@ -1,6 +1,8 @@ |
21 |
DIST wine-7.19.tar.xz 28502612 BLAKE2B b7b270656955c7a1e1d84e8bbc7e3e8abff5aedadb5e8a458f0b1109d746875a359f3d2f53b1c9c6caae65d17fd1d205466cd3a884034a8bad6afe9456f13b5d SHA512 f76dbda97cccad4c0f249b5dd4e8d48afa832134f1704ae228650bb73ee82823e628b23bd53a3f8729e06a8933597ff2fffa5551f156fc9c9181b67c066747d5 |
22 |
DIST wine-7.20.tar.xz 28534920 BLAKE2B 2e0cd49a7820f0c885a2a6dbcded6ebbdb5e1ea5576b03dedb7ee066f74f8c675193450cdd45bf5e0224bd588a890138e47a15f513edbfde1eabf1b65c9abe31 SHA512 6e2e65fba2336985df93165050f0f46b752d6aa94fc1581451c58969e2003748378be4b9e16b647ca2922fbdff77920311b12a17bda630a7bccfc7ee8f03b453 |
23 |
DIST wine-7.21.tar.xz 28703308 BLAKE2B 8902ded32b9e635f8ccf659ca4055e9ad45d3659f3ad48d0c218dc5a7a334df456ea0e9441dcaff58e8cac0bbd65140b20e61180acaa06230bc70e28a8382c7e SHA512 15c0c9efda972b84890886fd4b1fb18dd462373ba490f5e607004a5436caba9823f643369ceb5abbc2d2d0e26d7ce002e00136299d9984c0a27f729f3ac129c1 |
24 |
+DIST wine-7.22.tar.xz 28974052 BLAKE2B c86466964817b916ee8f7b687f193eda8bdd3fb17152ab1565971e36f43b12b540033ac1c5fa5d15576041febd32cf1ea2955732c5386debcbda46fb3acca0f1 SHA512 bf58a5b98bef5b291aff1eca3f94c28da95990e4c8da9af5e9e28b9480d57163d088b501b0c1bca5b568bf586dd9933cdc1ea1f371b78d95c94e2d25d0a65efc |
25 |
DIST wine-staging-7.19.tar.gz 9523048 BLAKE2B e53fd47af493cbdc4542f908a39557324d70ad67ff2e06c80296c006a63518e43988750cab2f4d3d9197fc9c8a1e61ed4d96bcc310b82b6cfc8ec12b941f1c5c SHA512 c51cb18c4ae00eccf414f5edda18ebf363674ba7cfa95da135b3a43b7c012c086d454d6ac32b22d98e611bb87e55c3e1ee95571a4a0c9713028b5ac38e8aed3f |
26 |
DIST wine-staging-7.20.tar.gz 9521481 BLAKE2B 5a264460e72ac96d50d23492100c465eeb0b933306200710aa085bd37bb79df3c6ef03aeb5ba2c4c196befb231938457aa9584b9edf938edfd754d06e7cdb574 SHA512 538bf60e760254f3130fe8b6bf07598287e567c0f34d6be2ed04fde10007283d4c675a6f27a0a13d3ce77e833559d5ef853a89f2f96dc5f8cc818bdc3570474a |
27 |
DIST wine-staging-7.21.tar.gz 9530737 BLAKE2B a80476dbc957a9cda1554262777c63276f9b66a5ccd1389a006327810b0b960a600f78dfabc0d8df4ce816cdd7c4c3c29c26bea9b63219fa90dff60142d41da1 SHA512 1261267fe82a25d74dbf3f8cd1926339356eac3cd432667517c2ca65656c1b733c2866a48c1e4ad116ac8094d9079366a07f6a7814b8bde27246d654a792e9ec |
28 |
+DIST wine-staging-7.22.tar.gz 9528424 BLAKE2B e41f24f924117259715505f4f9998ef23a657bca5b0e285feb7f9fd732e6b566a495f48ec59af09b1d4d51db522b051028f6cbba748256e939929fbf978f0e44 SHA512 5fdac19ec290c67767fac71abe07d9350ec431919c67a0f2d2df18ced20f1d3dddb921b3d5586d03add187c6281e1a691cc220e8d2d5ad4eeb94015721479d65 |
29 |
|
30 |
diff --git a/app-emulation/wine-staging/wine-staging-7.22.ebuild b/app-emulation/wine-staging/wine-staging-7.22.ebuild |
31 |
new file mode 100644 |
32 |
index 000000000000..1f7740c6c6b6 |
33 |
--- /dev/null |
34 |
+++ b/app-emulation/wine-staging/wine-staging-7.22.ebuild |
35 |
@@ -0,0 +1,353 @@ |
36 |
+# Copyright 2022 Gentoo Authors |
37 |
+# Distributed under the terms of the GNU General Public License v2 |
38 |
+ |
39 |
+EAPI=8 |
40 |
+ |
41 |
+MULTILIB_COMPAT=( abi_x86_{32,64} ) |
42 |
+inherit autotools flag-o-matic multilib multilib-build toolchain-funcs wrapper |
43 |
+ |
44 |
+WINE_GECKO=2.47.3 |
45 |
+WINE_MONO=7.4.0 |
46 |
+ |
47 |
+if [[ ${PV} == *9999 ]]; then |
48 |
+ inherit git-r3 |
49 |
+ EGIT_REPO_URI="https://github.com/wine-staging/wine-staging.git" |
50 |
+ WINE_EGIT_REPO_URI="https://gitlab.winehq.org/wine/wine.git" |
51 |
+else |
52 |
+ (( $(ver_cut 2) )) && WINE_SDIR=$(ver_cut 1).x || WINE_SDIR=$(ver_cut 1).0 |
53 |
+ SRC_URI=" |
54 |
+ https://dl.winehq.org/wine/source/${WINE_SDIR}/wine-${PV}.tar.xz |
55 |
+ https://github.com/wine-staging/wine-staging/archive/v${PV}.tar.gz -> ${P}.tar.gz" |
56 |
+ KEYWORDS="-* ~amd64 ~x86" |
57 |
+fi |
58 |
+S="${WORKDIR}/wine-${PV}" |
59 |
+ |
60 |
+DESCRIPTION="Free implementation of Windows(tm) on Unix, with Wine-Staging patchset" |
61 |
+HOMEPAGE="https://wiki.winehq.org/Wine-Staging" |
62 |
+ |
63 |
+LICENSE="LGPL-2.1+ BSD-2 IJG MIT OPENLDAP ZLIB gsm libpng2 libtiff" |
64 |
+SLOT="${PV}" |
65 |
+IUSE=" |
66 |
+ +X +abi_x86_32 +abi_x86_64 +alsa capi crossdev-mingw cups dos |
67 |
+ llvm-libunwind debug custom-cflags +fontconfig +gecko gphoto2 |
68 |
+ +gstreamer kerberos +mingw +mono netapi nls odbc opencl +opengl |
69 |
+ osmesa pcap perl pulseaudio samba scanner +sdl selinux +ssl |
70 |
+ +truetype udev udisks +unwind usb v4l +vulkan +xcomposite xinerama" |
71 |
+REQUIRED_USE=" |
72 |
+ X? ( truetype ) |
73 |
+ crossdev-mingw? ( mingw )" # bug #551124 for truetype |
74 |
+ |
75 |
+# tests are non-trivial to run, can hang easily, don't play well with |
76 |
+# sandbox, and several need real opengl/vulkan or network access |
77 |
+RESTRICT="test" |
78 |
+ |
79 |
+# `grep WINE_CHECK_SONAME configure.ac` + if not directly linked |
80 |
+WINE_DLOPEN_DEPEND=" |
81 |
+ X? ( |
82 |
+ x11-libs/libXcursor[${MULTILIB_USEDEP}] |
83 |
+ x11-libs/libXfixes[${MULTILIB_USEDEP}] |
84 |
+ x11-libs/libXi[${MULTILIB_USEDEP}] |
85 |
+ x11-libs/libXrandr[${MULTILIB_USEDEP}] |
86 |
+ x11-libs/libXrender[${MULTILIB_USEDEP}] |
87 |
+ x11-libs/libXxf86vm[${MULTILIB_USEDEP}] |
88 |
+ opengl? ( |
89 |
+ media-libs/libglvnd[X,${MULTILIB_USEDEP}] |
90 |
+ osmesa? ( media-libs/mesa[osmesa,${MULTILIB_USEDEP}] ) |
91 |
+ ) |
92 |
+ xcomposite? ( x11-libs/libXcomposite[${MULTILIB_USEDEP}] ) |
93 |
+ xinerama? ( x11-libs/libXinerama[${MULTILIB_USEDEP}] ) |
94 |
+ ) |
95 |
+ cups? ( net-print/cups[${MULTILIB_USEDEP}] ) |
96 |
+ fontconfig? ( media-libs/fontconfig[${MULTILIB_USEDEP}] ) |
97 |
+ kerberos? ( virtual/krb5[${MULTILIB_USEDEP}] ) |
98 |
+ netapi? ( net-fs/samba[${MULTILIB_USEDEP}] ) |
99 |
+ odbc? ( dev-db/unixODBC[${MULTILIB_USEDEP}] ) |
100 |
+ sdl? ( media-libs/libsdl2[haptic,joystick,${MULTILIB_USEDEP}] ) |
101 |
+ ssl? ( net-libs/gnutls:=[${MULTILIB_USEDEP}] ) |
102 |
+ truetype? ( media-libs/freetype[${MULTILIB_USEDEP}] ) |
103 |
+ udisks? ( sys-apps/dbus[${MULTILIB_USEDEP}] ) |
104 |
+ v4l? ( media-libs/libv4l[${MULTILIB_USEDEP}] ) |
105 |
+ vulkan? ( media-libs/vulkan-loader[${MULTILIB_USEDEP}] )" |
106 |
+WINE_COMMON_DEPEND=" |
107 |
+ ${WINE_DLOPEN_DEPEND} |
108 |
+ X? ( |
109 |
+ x11-libs/libX11[${MULTILIB_USEDEP}] |
110 |
+ x11-libs/libXext[${MULTILIB_USEDEP}] |
111 |
+ ) |
112 |
+ alsa? ( media-libs/alsa-lib[${MULTILIB_USEDEP}] ) |
113 |
+ capi? ( net-libs/libcapi:=[${MULTILIB_USEDEP}] ) |
114 |
+ gphoto2? ( media-libs/libgphoto2:=[${MULTILIB_USEDEP}] ) |
115 |
+ gstreamer? ( |
116 |
+ dev-libs/glib:2[${MULTILIB_USEDEP}] |
117 |
+ media-libs/gst-plugins-base:1.0[${MULTILIB_USEDEP}] |
118 |
+ media-libs/gstreamer:1.0[${MULTILIB_USEDEP}] |
119 |
+ ) |
120 |
+ opencl? ( virtual/opencl[${MULTILIB_USEDEP}] ) |
121 |
+ pcap? ( net-libs/libpcap[${MULTILIB_USEDEP}] ) |
122 |
+ pulseaudio? ( media-libs/libpulse[${MULTILIB_USEDEP}] ) |
123 |
+ scanner? ( media-gfx/sane-backends[${MULTILIB_USEDEP}] ) |
124 |
+ udev? ( virtual/libudev:=[${MULTILIB_USEDEP}] ) |
125 |
+ unwind? ( |
126 |
+ llvm-libunwind? ( sys-libs/llvm-libunwind[${MULTILIB_USEDEP}] ) |
127 |
+ !llvm-libunwind? ( sys-libs/libunwind:=[${MULTILIB_USEDEP}] ) |
128 |
+ ) |
129 |
+ usb? ( dev-libs/libusb:1[${MULTILIB_USEDEP}] )" |
130 |
+RDEPEND=" |
131 |
+ ${WINE_COMMON_DEPEND} |
132 |
+ app-emulation/wine-desktop-common |
133 |
+ dos? ( games-emulation/dosbox ) |
134 |
+ gecko? ( app-emulation/wine-gecko:${WINE_GECKO}[${MULTILIB_USEDEP}] ) |
135 |
+ gstreamer? ( media-plugins/gst-plugins-meta:1.0[${MULTILIB_USEDEP}] ) |
136 |
+ mono? ( app-emulation/wine-mono:${WINE_MONO} ) |
137 |
+ perl? ( |
138 |
+ dev-lang/perl |
139 |
+ dev-perl/XML-LibXML |
140 |
+ ) |
141 |
+ samba? ( net-fs/samba[winbind] ) |
142 |
+ selinux? ( sec-policy/selinux-wine ) |
143 |
+ udisks? ( sys-fs/udisks:2 )" |
144 |
+DEPEND=" |
145 |
+ ${WINE_COMMON_DEPEND} |
146 |
+ sys-kernel/linux-headers |
147 |
+ X? ( x11-base/xorg-proto )" |
148 |
+BDEPEND=" |
149 |
+ dev-lang/perl |
150 |
+ sys-devel/binutils |
151 |
+ sys-devel/bison |
152 |
+ sys-devel/flex |
153 |
+ virtual/pkgconfig |
154 |
+ mingw? ( !crossdev-mingw? ( |
155 |
+ >=dev-util/mingw64-toolchain-10.0.0_p1-r2[${MULTILIB_USEDEP}] |
156 |
+ ) ) |
157 |
+ nls? ( sys-devel/gettext )" |
158 |
+IDEPEND=">=app-eselect/eselect-wine-2" |
159 |
+ |
160 |
+QA_TEXTRELS="usr/lib/*/wine/i386-unix/*.so" # uses -fno-PIC -Wl,-z,notext |
161 |
+ |
162 |
+PATCHES=( |
163 |
+ "${FILESDIR}"/${PN}-7.17-noexecstack.patch |
164 |
+ "${FILESDIR}"/${PN}-7.20-unwind.patch |
165 |
+) |
166 |
+ |
167 |
+pkg_pretend() { |
168 |
+ [[ ${MERGE_TYPE} == binary ]] && return |
169 |
+ |
170 |
+ if use crossdev-mingw && [[ ! -v MINGW_BYPASS ]]; then |
171 |
+ local mingw=-w64-mingw32 |
172 |
+ for mingw in $(usev abi_x86_64 x86_64${mingw}) $(usev abi_x86_32 i686${mingw}); do |
173 |
+ if ! type -P ${mingw}-gcc >/dev/null; then |
174 |
+ eerror "With USE=crossdev-mingw, you must prepare the MinGW toolchain" |
175 |
+ eerror "yourself by installing sys-devel/crossdev then running:" |
176 |
+ eerror |
177 |
+ eerror " crossdev --target ${mingw}" |
178 |
+ eerror |
179 |
+ eerror "For more information, please see: https://wiki.gentoo.org/wiki/Mingw" |
180 |
+ die "USE=crossdev-mingw is enabled, but ${mingw}-gcc was not found" |
181 |
+ fi |
182 |
+ done |
183 |
+ fi |
184 |
+} |
185 |
+ |
186 |
+src_unpack() { |
187 |
+ if [[ ${PV} == *9999 ]]; then |
188 |
+ EGIT_CHECKOUT_DIR=${WORKDIR}/${P} |
189 |
+ git-r3_src_unpack |
190 |
+ |
191 |
+ EGIT_COMMIT=$(<"${EGIT_CHECKOUT_DIR}"/staging/upstream-commit) || die |
192 |
+ EGIT_REPO_URI=${WINE_EGIT_REPO_URI} |
193 |
+ EGIT_CHECKOUT_DIR=${S} |
194 |
+ einfo "Fetching Wine commit matching the current patchset by default (${EGIT_COMMIT})" |
195 |
+ git-r3_src_unpack |
196 |
+ else |
197 |
+ default |
198 |
+ fi |
199 |
+} |
200 |
+ |
201 |
+src_prepare() { |
202 |
+ local staging=( |
203 |
+ ./patchinstall.sh DESTDIR="${S}" |
204 |
+ --all |
205 |
+ --backend=eapply |
206 |
+ --no-autoconf |
207 |
+ -W winemenubuilder-Desktop_Icon_Path #652176 |
208 |
+ ${MY_WINE_STAGING_CONF} |
209 |
+ ) |
210 |
+ |
211 |
+ # source patcher in a subshell so can use eapply as a backend |
212 |
+ ebegin "Running ${staging[*]}" |
213 |
+ ( cd ../${P}/patches && . "${staging[@]}" ) |
214 |
+ eend ${?} || die "Failed to apply the patchset" |
215 |
+ |
216 |
+ # sanity check, bumping these has a history of oversights |
217 |
+ local geckomono=$(sed -En '/^#define (GECKO|MONO)_VER/{s/[^0-9.]//gp}' \ |
218 |
+ dlls/appwiz.cpl/addons.c || die) |
219 |
+ if [[ ${WINE_GECKO}$'\n'${WINE_MONO} != "${geckomono}" ]]; then |
220 |
+ local gmfatal= |
221 |
+ [[ ${PV} == *9999 ]] && gmfatal=nonfatal |
222 |
+ ${gmfatal} die -n "gecko/mono mismatch in ebuild, has: " ${geckomono} " (please file a bug)" |
223 |
+ fi |
224 |
+ |
225 |
+ default |
226 |
+ |
227 |
+ # ensure .desktop calls this variant + slot |
228 |
+ sed -i "/^Exec=/s/wine /${P} /" loader/wine.desktop || die |
229 |
+ |
230 |
+ # always update for patches (including user's wrt #432348) |
231 |
+ eautoreconf |
232 |
+ tools/make_requests || die # perl |
233 |
+} |
234 |
+ |
235 |
+src_configure() { |
236 |
+ WINE_PREFIX=/usr/lib/${P} |
237 |
+ WINE_DATADIR=/usr/share/${P} |
238 |
+ |
239 |
+ local conf=( |
240 |
+ --prefix="${EPREFIX}"${WINE_PREFIX} |
241 |
+ --datadir="${EPREFIX}"${WINE_DATADIR} |
242 |
+ --includedir="${EPREFIX}"/usr/include/${P} |
243 |
+ --libdir="${EPREFIX}"${WINE_PREFIX} |
244 |
+ --mandir="${EPREFIX}"${WINE_DATADIR}/man |
245 |
+ $(use_enable gecko mshtml) |
246 |
+ $(use_enable mono mscoree) |
247 |
+ --disable-tests |
248 |
+ $(use_with X x) |
249 |
+ $(use_with alsa) |
250 |
+ $(use_with capi) |
251 |
+ $(use_with cups) |
252 |
+ $(use_with fontconfig) |
253 |
+ $(use_with gphoto2 gphoto) |
254 |
+ $(use_with gstreamer) |
255 |
+ $(use_with kerberos gssapi) |
256 |
+ $(use_with kerberos krb5) |
257 |
+ $(use_with mingw) |
258 |
+ $(use_with netapi) |
259 |
+ $(use_with nls gettext) |
260 |
+ $(use_with opencl) |
261 |
+ $(use_with opengl) |
262 |
+ $(use_with osmesa) |
263 |
+ --without-oss # media-sound/oss is not packaged (OSSv4) |
264 |
+ $(use_with pcap) |
265 |
+ $(use_with pulseaudio pulse) |
266 |
+ $(use_with scanner sane) |
267 |
+ $(use_with sdl) |
268 |
+ $(use_with ssl gnutls) |
269 |
+ $(use_with truetype freetype) |
270 |
+ $(use_with udev) |
271 |
+ $(use_with udisks dbus) # dbus is only used for udisks |
272 |
+ $(use_with unwind) |
273 |
+ $(use_with usb) |
274 |
+ $(use_with v4l v4l2) |
275 |
+ $(use_with vulkan) |
276 |
+ $(use_with xcomposite) |
277 |
+ $(use_with xinerama) |
278 |
+ $(usev !odbc ac_cv_lib_soname_odbc=) |
279 |
+ ) |
280 |
+ |
281 |
+ tc-ld-force-bfd #867097 |
282 |
+ use custom-cflags || strip-flags # can break in obscure ways, also no lto |
283 |
+ use crossdev-mingw || PATH=${BROOT}/usr/lib/mingw64-toolchain/bin:${PATH} |
284 |
+ |
285 |
+ # temporary workaround for tc-ld-force-bfd not yet enforcing with mold |
286 |
+ # https://github.com/gentoo/gentoo/pull/28355 |
287 |
+ [[ $($(tc-getCC) ${LDFLAGS} -Wl,--version 2>/dev/null) == mold* ]] && |
288 |
+ append-ldflags -fuse-ld=bfd |
289 |
+ |
290 |
+ # build using upstream's way (--with-wine64) |
291 |
+ # order matters: configure+compile 64->32, install 32->64 |
292 |
+ local -i bits |
293 |
+ for bits in $(usev abi_x86_64 64) $(usev abi_x86_32 32); do |
294 |
+ ( |
295 |
+ einfo "Configuring ${PN} for ${bits}bits in ${WORKDIR}/build${bits} ..." |
296 |
+ |
297 |
+ mkdir ../build${bits} || die |
298 |
+ cd ../build${bits} || die |
299 |
+ |
300 |
+ pe_arch=i386 |
301 |
+ if (( bits == 64 )); then |
302 |
+ pe_arch=x86_64 |
303 |
+ : "${CROSSCC:=${CROSSCC_amd64:-x86_64-w64-mingw32-gcc}}" |
304 |
+ conf+=( --enable-win64 ) |
305 |
+ elif use amd64; then |
306 |
+ conf+=( |
307 |
+ $(usev abi_x86_64 --with-wine64=../build64) |
308 |
+ TARGETFLAGS=-m32 # for widl |
309 |
+ ) |
310 |
+ # _setup is optional, but use over Wine's auto-detect (+#472038) |
311 |
+ multilib_toolchain_setup x86 |
312 |
+ fi |
313 |
+ : "${CROSSCC:=${CROSSCC_x86:-i686-w64-mingw32-gcc}}" |
314 |
+ |
315 |
+ if use mingw; then |
316 |
+ # CROSSCC is no longer recognized by Wine, but still use for now |
317 |
+ # (future handling for CROSS* variables is subject to changes) |
318 |
+ conf+=( ac_cv_prog_${pe_arch}_CC="${CROSSCC}" ) |
319 |
+ |
320 |
+ # use *FLAGS for mingw, but strip unsupported |
321 |
+ : "${CROSSCFLAGS:=$( |
322 |
+ # >=wine-7.21 configure.ac no longer adds -fno-strict by mistake |
323 |
+ append-cflags '-fno-strict-aliasing' |
324 |
+ filter-flags '-fstack-clash-protection' #758914 |
325 |
+ filter-flags '-fstack-protector*' #870136 |
326 |
+ filter-flags '-mfunction-return=thunk*' #878849 |
327 |
+ CC=${CROSSCC} test-flags-CC ${CFLAGS:--O2})}" |
328 |
+ : "${CROSSLDFLAGS:=$( |
329 |
+ filter-flags '-fuse-ld=*' |
330 |
+ CC=${CROSSCC} test-flags-CCLD ${LDFLAGS})}" |
331 |
+ export CROSS{C,LD}FLAGS |
332 |
+ fi |
333 |
+ |
334 |
+ ECONF_SOURCE=${S} econf "${conf[@]}" |
335 |
+ ) |
336 |
+ done |
337 |
+} |
338 |
+ |
339 |
+src_compile() { |
340 |
+ use abi_x86_64 && emake -C ../build64 # do first |
341 |
+ use abi_x86_32 && emake -C ../build32 |
342 |
+} |
343 |
+ |
344 |
+src_install() { |
345 |
+ use abi_x86_32 && emake DESTDIR="${D}" -C ../build32 install |
346 |
+ use abi_x86_64 && emake DESTDIR="${D}" -C ../build64 install # do last |
347 |
+ |
348 |
+ # symlink for plain 'wine' and install its man pages if 64bit-only #404331 |
349 |
+ if use abi_x86_64 && use !abi_x86_32; then |
350 |
+ dosym wine64 ${WINE_PREFIX}/bin/wine |
351 |
+ dosym wine64-preloader ${WINE_PREFIX}/bin/wine-preloader |
352 |
+ local man |
353 |
+ for man in ../build64/loader/wine.*man; do |
354 |
+ : "${man##*/wine}" |
355 |
+ : "${_%.*}" |
356 |
+ insinto ${WINE_DATADIR}/man/${_:+${_#.}/}man1 |
357 |
+ newins ${man} wine.1 |
358 |
+ done |
359 |
+ fi |
360 |
+ |
361 |
+ use perl || rm "${ED}"${WINE_DATADIR}/man/man1/wine{dump,maker}.1 \ |
362 |
+ "${ED}"${WINE_PREFIX}/bin/{function_grep.pl,wine{dump,maker}} || die |
363 |
+ |
364 |
+ # create variant wrappers for eselect-wine |
365 |
+ local bin |
366 |
+ for bin in "${ED}"${WINE_PREFIX}/bin/*; do |
367 |
+ make_wrapper "${bin##*/}-${P#wine-}" "${bin#"${ED}"}" |
368 |
+ done |
369 |
+ |
370 |
+ # don't let portage try to strip PE files with the wrong |
371 |
+ # strip executable and instead handle it here (saves ~120MB) |
372 |
+ if use mingw; then |
373 |
+ dostrip -x ${WINE_PREFIX}/wine/{i386,x86_64}-windows |
374 |
+ use debug || |
375 |
+ find "${ED}"${WINE_PREFIX}/wine/*-windows -regex '.*\.\(a\|dll\|exe\)' \ |
376 |
+ -exec $(usex abi_x86_64 x86_64 i686)-w64-mingw32-strip --strip-unneeded {} + || die |
377 |
+ fi |
378 |
+ |
379 |
+ dodoc ANNOUNCE AUTHORS README* documentation/README* |
380 |
+} |
381 |
+ |
382 |
+pkg_postinst() { |
383 |
+ eselect wine update --if-unset || die |
384 |
+} |
385 |
+ |
386 |
+pkg_postrm() { |
387 |
+ eselect wine update --if-unset || die |
388 |
+} |