diff options
author | 2022-09-08 21:34:49 -0400 | |
---|---|---|
committer | 2022-09-10 05:47:13 -0400 | |
commit | 72553a083c0dd0d384b7ec922f4e20d357a9001a (patch) | |
tree | 8895445a0e9842437ad0013743b0022b1cbdabf2 /app-emulation/wine-proton | |
parent | xfce-extra/xfce4-windowck-plugin: Fix shebangs for Python scripts (diff) | |
download | gentoo-72553a083c0dd0d384b7ec922f4e20d357a9001a.tar.gz gentoo-72553a083c0dd0d384b7ec922f4e20d357a9001a.tar.bz2 gentoo-72553a083c0dd0d384b7ec922f4e20d357a9001a.zip |
app-emulation/wine-proton: misc ebuild adjustments
Mostly text/comment/style updates plus live support to match what
will be used in wine-staging/vanilla ebuilds rebased on this.
Also restrict tests, it was no-op but makes it more explicit that
they exists and we're not running them.
Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'app-emulation/wine-proton')
-rw-r--r-- | app-emulation/wine-proton/wine-proton-7.0.4.ebuild | 61 |
1 files changed, 38 insertions, 23 deletions
diff --git a/app-emulation/wine-proton/wine-proton-7.0.4.ebuild b/app-emulation/wine-proton/wine-proton-7.0.4.ebuild index b7bb3868a11a..9101a5f62172 100644 --- a/app-emulation/wine-proton/wine-proton-7.0.4.ebuild +++ b/app-emulation/wine-proton/wine-proton-7.0.4.ebuild @@ -12,20 +12,32 @@ WINE_GECKO=2.47.3 WINE_MONO=7.3.0 WINE_PV=$(ver_rs 2 -) +if [[ ${PV} == *9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/ValveSoftware/wine.git" + EGIT_BRANCH="experimental_$(ver_cut 1-2)" +else + SRC_URI="https://github.com/ValveSoftware/wine/archive/refs/tags/proton-wine-${WINE_PV}.tar.gz" + S="${WORKDIR}/${PN}-wine-${WINE_PV}" + KEYWORDS="-* ~amd64 ~x86" +fi + DESCRIPTION="Valve Software's fork of Wine" HOMEPAGE="https://github.com/ValveSoftware/wine/" -SRC_URI="https://github.com/ValveSoftware/wine/archive/refs/tags/proton-wine-${WINE_PV}.tar.gz" -S="${WORKDIR}/${PN}-wine-${WINE_PV}" LICENSE="LGPL-2.1+ BSD-2 IJG MIT ZLIB gsm libpng2 libtiff" SLOT="${PV}" -KEYWORDS="-* ~amd64 ~x86" IUSE=" +abi_x86_32 +abi_x86_64 +alsa crossdev-mingw custom-cflags debug +fontconfig +gecko +gstreamer llvm-libunwind +mono nls openal osmesa perl pulseaudio +sdl selinux +ssl udev udisks +unwind usb v4l +vkd3d +xcomposite xinerama" +# tests are non-trivial to run, can hang easily, don't play well with +# sandbox, and several need real opengl/vulkan or network access +RESTRICT="test" + +# `grep WINE_CHECK_SONAME configure.ac` + if not directly linked WINE_DLOPEN_DEPEND=" dev-libs/gmp:=[${MULTILIB_USEDEP}] dev-libs/libgcrypt:=[${MULTILIB_USEDEP}] @@ -106,25 +118,29 @@ pkg_pretend() { if use crossdev-mingw && [[ ! -v MINGW_BYPASS ]]; then local mingw=-w64-mingw32 for mingw in $(usev abi_x86_64 x86_64${mingw}) $(usev abi_x86_32 i686${mingw}); do - type -P ${mingw}-gcc >/dev/null && continue - eerror "With USE=crossdev-mingw, you must prepare the MinGW toolchain" - eerror "yourself by installing sys-devel/crossdev then running:" - eerror - eerror " crossdev --target ${mingw}" - eerror - eerror "For more information, please see: https://wiki.gentoo.org/wiki/Mingw" - eerror "--> Note that mingw builds are default for ${PN} even without this USE." - die "USE=crossdev-mingw is enabled, but ${mingw}-gcc was not found" + if ! type -P ${mingw}-gcc >/dev/null; then + eerror "With USE=crossdev-mingw, you must prepare the MinGW toolchain" + eerror "yourself by installing sys-devel/crossdev then running:" + eerror + eerror " crossdev --target ${mingw}" + eerror + eerror "For more information, please see: https://wiki.gentoo.org/wiki/Mingw" + eerror "--> Note that mingw builds are default for ${PN} even without this USE." + die "USE=crossdev-mingw is enabled, but ${mingw}-gcc was not found" + fi done fi } src_prepare() { # sanity check, bumping these has a history of oversights - local geckomono="$(sed -En '/^#define (GECKO|MONO)_VER/{s/[^0-9.]//gp}' \ - dlls/appwiz.cpl/addons.c || die)" - [[ ${WINE_GECKO}$'\n'${WINE_MONO} == "${geckomono}" ]] || - die "gecko/mono mismatch, has:" ${geckomono} + local geckomono=$(sed -En '/^#define (GECKO|MONO)_VER/{s/[^0-9.]//gp}' \ + dlls/appwiz.cpl/addons.c || die) + if [[ ${WINE_GECKO}$'\n'${WINE_MONO} != "${geckomono}" ]]; then + local gmfatal= + [[ ${PV} == *9999 ]] && gmfatal=nonfatal + ${gmfatal} die -n "gecko/mono mismatch in ebuild, has: " ${geckomono} " (please file a bug)" + fi default @@ -134,10 +150,10 @@ src_prepare() { # similarly to staging, append to `wine --version` for identification sed -i "s/wine_build[^1]*1/& (Proton-${WINE_PV})/" configure.ac || die - # source has outdated auto-generated files, update like Proton's Makefile + # always update for patches (including user's wrt #432348) eautoreconf tools/make_requests || die # perl - dlls/winevulkan/make_vulkan -x vk.xml || die # python + dlls/winevulkan/make_vulkan -x vk.xml || die # python, needed for proton's } src_configure() { @@ -162,7 +178,6 @@ src_configure() { # ...and disable most options unimportant for games and unused by # Proton rather than expose as volatile USEs with little support - --disable-tests # does not build and is disabled in Proton's Makefile --without-capi --without-cups --without-gphoto @@ -177,13 +192,14 @@ src_configure() { $(use_enable gecko mshtml) $(use_enable mono mscoree) + --disable-tests $(use_with alsa) $(use_with fontconfig) $(use_with gstreamer) $(use_with nls gettext) $(use_with openal) $(use_with osmesa) - --without-oss # media-sound/oss is not packaged + --without-oss # media-sound/oss is not packaged (OSSv4) $(use_with pulseaudio pulse) $(use_with sdl) $(use_with ssl gnutls) @@ -220,7 +236,7 @@ src_configure() { $(usev abi_x86_64 --with-wine64=../build64) TARGETFLAGS=-m32 # for widl ) - # _setup is optional, but use over Wine's auto-detect (+bug 472038) + # _setup is optional, but use over Wine's auto-detect (+#472038) multilib_toolchain_setup x86 fi : "${CROSSCC:=${CROSSCC_x86:-i686-w64-mingw32-gcc}}" @@ -262,8 +278,7 @@ src_install() { use perl || rm "${ED}"${WINE_DATADIR}/man/man1/wine{dump,maker}.1 \ "${ED}"${WINE_PREFIX}/bin/{function_grep.pl,wine{dump,maker}} || die - # create variant wrappers for eselect-wine, quotes are - # enough to prevent bug #615218 if it somehow happens + # create variant wrappers for eselect-wine local bin for bin in "${ED}"${WINE_PREFIX}/bin/*; do make_wrapper "${bin##*/}-${P#wine-}" "${bin#"${ED}"}" |