# Copyright 1999-2023 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 inherit desktop flag-o-matic toolchain-funcs xdg-utils DESCRIPTION="Hollywood tactical shooter based on the ioquake3 engine" HOMEPAGE="https://urbanterror.info https://github.com/mickael9/ioq3" if [[ ${PV} == *9999 ]]; then inherit git-r3 EGIT_REPO_URI="https://github.com/mickael9/ioq3.git" EGIT_BRANCH="urt" else COMMIT_ID="c988f7669bd70b59beb384563d4c8304062ae011" SRC_URI="https://github.com/mickael9/ioq3/archive/${COMMIT_ID}.tar.gz -> ${P}.tar.gz" S="${WORKDIR}/ioq3-${COMMIT_ID}" KEYWORDS="~amd64 ~x86" fi LICENSE="GPL-2" SLOT="0" IUSE="+altgamma +client +curl debug mumble openal +opus server +skeetshootmod voip vorbis" REQUIRED_USE=" || ( client server ) voip? ( opus ) " DOCS=( ChangeLog README.md README.ioq3.md md4-readme.txt ) PATCHES=( "${FILESDIR}"/${PN}-4.3.4_p20211208-respect-flags.patch ) RDEPEND=" client? ( media-libs/libsdl2[X,sound,joystick,opengl,video] mumble? ( net-voip/mumble:= ) openal? ( media-libs/openal:= ) opus? ( media-libs/opusfile ) vorbis? ( media-libs/libvorbis ) ) curl? ( net-misc/curl ) ~games-fps/urbanterror-data-4.3.4 sys-libs/zlib:=[minizip] virtual/jpeg:0 x11-libs/libX11 x11-libs/libXxf86vm " DEPEND="${RDEPEND}" pkg_pretend() { if use client; then if ! use openal && ! use opus && ! use vorbis; then ewarn ewarn "No sound implementation selected. Enable 'openal', 'opus' or 'vorbis' USE flag to get sound!" fi fi } src_configure() { tc-export CC default } src_compile() { # Workaround for used zlib macro, which got renamed in Gentoo # wrt bug #449510 has_version "