commit:     643377b8784df7e5deec1ba73dd5297eebb3e952
Author:     Samuel Bauer <samuel.bauer <AT> yahoo <DOT> fr>
AuthorDate: Sun May 30 19:20:45 2021 +0000
Commit:     Samuel Bauer <samuel.bauer <AT> yahoo <DOT> fr>
CommitDate: Sun May 30 19:20:45 2021 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=643377b8

games-emulation/yuzu: compatibility list: add flag

Signed-off-by: Samuel Bauer <samuel.bauer <AT> yahoo.fr>

 games-emulation/yuzu/metadata.xml     | 5 +++--
 games-emulation/yuzu/yuzu-9999.ebuild | 9 ++++++---
 2 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/games-emulation/yuzu/metadata.xml 
b/games-emulation/yuzu/metadata.xml
index ac55d48f0..3974ff3d6 100644
--- a/games-emulation/yuzu/metadata.xml
+++ b/games-emulation/yuzu/metadata.xml
@@ -2,12 +2,13 @@
 <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd";>
 <pkgmetadata>
 <maintainer type="person">
-       <name>Samuel Bauer</name>
-       <email>samuel.ba...@yahoo.fr</email>
+       <name>mazes-80</name>
+       <email>mazes...@github.com</email>
 </maintainer>
 <use>
        <flag name="boxcat">Enable the Boxcat service, a yuzu high-level 
implementation of BCAT</flag>
        <flag name="cubeb">Enables the cubeb audio backend</flag>
+       <flag name="compatibility-list">Downloads the latest compatibility 
list</flag>
        <flag name="discord">Enables Discord Rich Presence</flag>
        <flag name="webengine">Use QtWebEngine for web applet 
implementation</flag>
        <flag name="webservice">Enable web services (telemetry, etc.)</flag>

diff --git a/games-emulation/yuzu/yuzu-9999.ebuild 
b/games-emulation/yuzu/yuzu-9999.ebuild
index ce3240a30..e7a2452f4 100644
--- a/games-emulation/yuzu/yuzu-9999.ebuild
+++ b/games-emulation/yuzu/yuzu-9999.ebuild
@@ -18,7 +18,7 @@ EGIT_SUBMODULES=( '*' '-ffmpeg' '-inih' '-libressl' '-libusb' 
'-libzip' '-opus'
 LICENSE="GPL-3"
 SLOT="0"
 KEYWORDS=""
-IUSE="+boxcat +cubeb discord +qt5 sdl webengine +webservice"
+IUSE="+boxcat +compatibility-list +cubeb discord +qt5 sdl webengine 
+webservice"
 
 DEPEND="
        discord? ( >=dev-libs/rapidjson-1.1.0 )
@@ -58,7 +58,7 @@ src_unpack() {
        git-r3_src_unpack
 
        # Do not fetch via sources because this file always changes
-       curl https://api.yuzu-emu.org/gamedb/ > "${S}"/compatibility_list.json
+       use compatibility-list && curl https://api.yuzu-emu.org/gamedb/ > 
"${S}"/compatibility_list.json
 }
 
 src_prepare() {
@@ -107,6 +107,7 @@ src_prepare() {
 src_configure() {
        local -a mycmakeargs=(
                -DBUILD_SHARED_LIBS=OFF
+               -DENABLE_COMPATIBILITY_LIST_DOWNLOAD=$(usex compatibility-list)
                -DENABLE_CUBEB=$(usex cubeb)
                -DENABLE_QT=$(usex qt5)
                -DENABLE_QT_TRANSLATION=$(usex qt5)
@@ -120,5 +121,7 @@ src_configure() {
        cmake_src_configure
 
        # This would be better in src_unpack but it would be unlinked
-       mv "${S}"/compatibility_list.json 
"${BUILD_DIR}"/dist/compatibility_list/ || die
+       if use compatibility-list; then
+               mv "${S}"/compatibility_list.json 
"${BUILD_DIR}"/dist/compatibility_list/ || die
+       fi
 }

Reply via email to