commit:     8ae0fab62da1dd7066b966b431a65218a4865e6f
Author:     Matt Jolly <kangie <AT> gentoo <DOT> org>
AuthorDate: Wed Apr 16 02:16:58 2025 +0000
Commit:     Matt Jolly <kangie <AT> gentoo <DOT> org>
CommitDate: Wed Apr 16 05:52:27 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8ae0fab6

games-strategy/freeciv: add 3.2.0_beta2; USE=svg

The `svg` USE enables support for SVG flags in clients that support
it, currently Qt6. This USE is ignored if that client is not selected
as it will intstall superfluous SVG files.

Signed-off-by: Matt Jolly <kangie <AT> gentoo.org>

 games-strategy/freeciv/Manifest                    |  1 +
 ...eciv-9999.ebuild => freeciv-3.2.0_beta2.ebuild} | 37 +++++-----------------
 games-strategy/freeciv/freeciv-9999.ebuild         |  4 ++-
 3 files changed, 12 insertions(+), 30 deletions(-)

diff --git a/games-strategy/freeciv/Manifest b/games-strategy/freeciv/Manifest
index a346f0bd3ebe..819c32e35706 100644
--- a/games-strategy/freeciv/Manifest
+++ b/games-strategy/freeciv/Manifest
@@ -1,2 +1,3 @@
 DIST freeciv-3.1.3.tar.gz 127913563 BLAKE2B 
d6ab211ccda9f6795dbcf395f3a1b06372ce2c5147e92398c4d1eceddd3346ef9debddded79ce3b85209cf25323f262a99f56204ca58b660dccd7333d7611214
 SHA512 
c8528d1576d810820de3934ced2b6d34eefa9a848117916f7234ba5447aad52df71aba6bedfdd1f42e62e8fe7477a0a04a799f93c54343a3ba886747face4eeb
 DIST freeciv-3.1.4.tar.gz 128914453 BLAKE2B 
60a371692e74434e8f8a0311b3c4732cb4a0199ea426f06eaac87d0f5982239f9bec069441f5897921907edafe6e5ab4492dd525b606eaeb3a4de1976d6c5766
 SHA512 
1a94861e4298e6fa81347a5625ae5d9fea1f2ee0195265a8b53a1c2255d1b02010140d3f48fc3474ae4aa188db16f12b84b7a112d37e2ed7bd474f250a50a97a
+DIST freeciv-3.2.0_beta2.tar.gz 142029035 BLAKE2B 
f1a04574ae9d33a8dd4d642a4e4eb74902986ecb518dd2a15e5ebcccd69c4163fc41f999821cda41e4653a12f2cb805423392318e4a2884c9cf70636a31e25c9
 SHA512 
8261ebdf828c4995706729f7b0469441dce7e234c1db62b3bf3ad106c6327b02b3ac5559082a794fcd444935c86af9934ad6083d07e74c8e66932f3a84876179

diff --git a/games-strategy/freeciv/freeciv-9999.ebuild 
b/games-strategy/freeciv/freeciv-3.2.0_beta2.ebuild
similarity index 85%
copy from games-strategy/freeciv/freeciv-9999.ebuild
copy to games-strategy/freeciv/freeciv-3.2.0_beta2.ebuild
index 35366b1f4070..a62e7ec5bef5 100644
--- a/games-strategy/freeciv/freeciv-9999.ebuild
+++ b/games-strategy/freeciv/freeciv-3.2.0_beta2.ebuild
@@ -25,14 +25,12 @@ fi
 
 LICENSE="GPL-2+"
 SLOT="0"
-IUSE="authentication dedicated gtk3 gtk4 json mapimg mariadb modpack nls odbc 
qt6"
-IUSE+=" readline rule-editor sdl +sdl3 +server +sound sqlite +system-lua 
web-server"
+IUSE="dedicated gtk3 gtk4 json mapimg modpack nls qt6"
+IUSE+=" readline rule-editor sdl +sdl3 +server +sound svg +system-lua 
web-server"
 
 REQUIRED_USE="
-       authentication? ( || ( mariadb odbc sqlite ) )
        !dedicated? ( || ( gtk3 gtk4 qt6 sdl sdl3 ) )
        dedicated? ( !gtk3 !gtk4 !mapimg !nls !qt6 !sdl !sdl3 !sound )
-       modpack? ( sqlite )
        sound? ( || ( sdl3 sdl ) )
        system-lua? ( ${LUA_REQUIRED_USE} )
 "
@@ -42,6 +40,7 @@ RDEPEND="
        app-arch/xz-utils
        app-arch/zstd:=
        dev-build/libtool
+       dev-db/sqlite:3
        dev-libs/icu:=
        net-misc/curl
        sys-libs/zlib
@@ -76,13 +75,6 @@ RDEPEND="
        )
        json? ( dev-libs/jansson:= )
        readline? ( sys-libs/readline:= )
-       mariadb? ( || (
-               dev-db/mariadb:*
-               dev-db/mariadb-connector-c
-               )
-       )
-       odbc? ( dev-db/unixODBC )
-       sqlite? ( dev-db/sqlite:3 )
        system-lua? (
                ${LUA_DEPS}
        )
@@ -99,6 +91,7 @@ BDEPEND="
 
 pkg_setup() {
        use system-lua && lua-single_pkg_setup
+       use svg && use !qt6 && einfo "SVG flags only supported in qt6 client, 
ignoring"
 }
 
 src_prepare() {
@@ -143,6 +136,7 @@ src_configure() {
                freeciv_enable_ui gtk4
                freeciv_enable_ui qt6 qt
                use qt6 && emesonargs+=( -Dqtver=qt6 )
+               use qt6 && emesonargs+=( $(meson_use svg svgflags) )
        else
                if use modpack ; then
                        myfcmp+=( cli )
@@ -155,19 +149,6 @@ src_configure() {
                -Dfcmp=$(IFS=, ; echo "${myfcmp[*]}")
        )
 
-       if use authentication; then
-               local myfcdb=()
-               use sqlite && myfcdb+=( sqlite3 )
-               use mariadb && myfcdb+=( mariadb )
-               use odbc && myfcdb+=( odbc )
-               emesonargs+=(
-                       -Dfcdb=$(IFS=, ; echo "${myfcdb[*]}")
-               )
-       else
-               # If we don't want authentication
-               emesonargs+=( -Dfcdb="" )
-       fi
-
        if use sound; then
                # We can only select one, prefer the newer SDL3
                if use sdl3 ; then
@@ -242,13 +223,11 @@ src_install() {
 pkg_postinst() {
        xdg_pkg_postinst
 
-       if [[ -z ${REPLACING_VERSIONS} ]] && use authentication; then
+       if [[ -z ${REPLACING_VERSIONS} ]]; then
                einfo "There are a number of supported authentication backends."
                einfo "sqlite3 is the default, however dedicated servers may 
wish to"
-               einfo "use another supported backend. Additional configuration 
is required,"
-               einfo "to do so, even if the relevant USE was selected at build 
time."
-               einfo "please consult the documentation for instructions on 
configuring"
-               einfo "freeciv for a particular backend:"
+               einfo "use another supported backend; please consult the 
documentation"
+               einfo "to configure freeciv for a particular backend:"
                einfo 
"https://github.com/freeciv/freeciv/blob/main/doc/README.fcdb";
        fi
 }

diff --git a/games-strategy/freeciv/freeciv-9999.ebuild 
b/games-strategy/freeciv/freeciv-9999.ebuild
index 35366b1f4070..65c349c37342 100644
--- a/games-strategy/freeciv/freeciv-9999.ebuild
+++ b/games-strategy/freeciv/freeciv-9999.ebuild
@@ -26,7 +26,7 @@ fi
 LICENSE="GPL-2+"
 SLOT="0"
 IUSE="authentication dedicated gtk3 gtk4 json mapimg mariadb modpack nls odbc 
qt6"
-IUSE+=" readline rule-editor sdl +sdl3 +server +sound sqlite +system-lua 
web-server"
+IUSE+=" readline rule-editor sdl +sdl3 +server +sound sqlite svg +system-lua 
web-server"
 
 REQUIRED_USE="
        authentication? ( || ( mariadb odbc sqlite ) )
@@ -99,6 +99,7 @@ BDEPEND="
 
 pkg_setup() {
        use system-lua && lua-single_pkg_setup
+       use svg && use !qt6 && einfo "SVG flags only supported in qt6 client, 
ignoring"
 }
 
 src_prepare() {
@@ -143,6 +144,7 @@ src_configure() {
                freeciv_enable_ui gtk4
                freeciv_enable_ui qt6 qt
                use qt6 && emesonargs+=( -Dqtver=qt6 )
+               use qt6 && emesonargs+=( $(meson_use svg svgflags) )
        else
                if use modpack ; then
                        myfcmp+=( cli )

Reply via email to