summaryrefslogtreecommitdiff
path: root/games-fps/quake3
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /games-fps/quake3
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'games-fps/quake3')
-rw-r--r--games-fps/quake3/Manifest5
-rw-r--r--games-fps/quake3/files/quake3-1.36-bots.patch20
-rw-r--r--games-fps/quake3/metadata.xml26
-rw-r--r--games-fps/quake3/quake3-1.36-r1.ebuild122
-rw-r--r--games-fps/quake3/quake3-9999.ebuild137
5 files changed, 310 insertions, 0 deletions
diff --git a/games-fps/quake3/Manifest b/games-fps/quake3/Manifest
new file mode 100644
index 000000000000..e6ee7ca4c809
--- /dev/null
+++ b/games-fps/quake3/Manifest
@@ -0,0 +1,5 @@
+AUX quake3-1.36-bots.patch 499 BLAKE2B d8f9f0df531519e2ca96584ab728a18929f5a27891ec6c5c24e34a705c458205f020e4fa509ec8e66571aad16e21f26fbc45a8e3abc44585469aa589fc191288 SHA512 75d0659a07902cd78153792353796e77ce1baf7545da370d88f37accca090bee9b94d7447bfa0d284fb98769c94ee434cf7baa6fe9f457018d00dd6431eecba0
+DIST ioquake3-1.36.tar.bz2 3503058 BLAKE2B f5688bc66f19eeeb0cc925208ac4f8a95905f4a2a9be6380f408d354d466020135e0944abc1344e81a9f67aeb714111af2d0f968c2c2eab6138f1a55b2db7191 SHA512 fdd8e0ab56966cdc614eff45ab478b87255cfb1b50ba10b3141bcfcc569fc620d281de93333d39119b2d7b43aac3900ecf826a0459fc89bb2f57e30ae2425645
+EBUILD quake3-1.36-r1.ebuild 3013 BLAKE2B 19680c247cc7fb09143118f8190ad387f800e3da789bbef509a8e632fa1dd1bd7fef763bc37fab62af99d6d7b6f22345c5c07f3ecc2a559c9a275a6c01d24b3e SHA512 b20cd53c7dacab10a6948ef1f88dd0c3218d6b156b3b81e4f33a6700abc22e7ee5bf6e4a751ab1bf70f93c3d1fe398600f14cfeb754389cf342ab29600b83179
+EBUILD quake3-9999.ebuild 3537 BLAKE2B a9e2d29981768255e2d532c66baa4e6fb13bf9040c4bd88c2f2d9c545d920165975c5120843bfc93f08cb62d16c473cc90b1ab76568cb426e9cf0d137ec811b2 SHA512 aebd3073b92f3d8878697cca0c7183f7f4f5eca8b9e111dbe80649648d2db951dfd2071247aaaf7912822643d5f6a4649cd5f3d0515989f5f2475bc821368ca9
+MISC metadata.xml 1286 BLAKE2B b6b6ec5139fe9f86f102a52bec57df55a0228ff70cb958cdd5af84c332ddd9e7b78f2e334874d70429f857dcd6e9eb8cd5e843d509b19438040d572b1a3218a8 SHA512 6a82390bc52e5995c1ff12e001cb6d54d70366b618c71107e0c79c5b03c9717b6e7426e221ac499126ea0ea870c75bdfe40418e04a2f3c4241ac5e0b99dd22b9
diff --git a/games-fps/quake3/files/quake3-1.36-bots.patch b/games-fps/quake3/files/quake3-1.36-bots.patch
new file mode 100644
index 000000000000..31d2f2041c6f
--- /dev/null
+++ b/games-fps/quake3/files/quake3-1.36-bots.patch
@@ -0,0 +1,20 @@
+--- code/botlib/l_script.c.orig 2009-11-02 20:29:23.000000000 +0100
++++ code/botlib/l_script.c 2009-11-02 22:21:40.000000000 +0100
+@@ -1118,7 +1118,7 @@
+ {
+ if (*string == '\"')
+ {
+- strcpy(string, string+1);
++ memmove(string, string+1, strlen(string));
+ } //end if
+ if (string[strlen(string)-1] == '\"')
+ {
+@@ -1135,7 +1135,7 @@
+ {
+ if (*string == '\'')
+ {
+- strcpy(string, string+1);
++ memmove(string, string+1, strlen(string));
+ } //end if
+ if (string[strlen(string)-1] == '\'')
+ {
diff --git a/games-fps/quake3/metadata.xml b/games-fps/quake3/metadata.xml
new file mode 100644
index 000000000000..c62fb568e143
--- /dev/null
+++ b/games-fps/quake3/metadata.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>games@gentoo.org</email>
+ <name>Gentoo Games Project</name>
+ </maintainer>
+ <longdescription>
+Quake III Arena is the third installment of the extremely popular and
+successful Quake series by id software. The game was released by id
+software for both Windows and Linux. The Linux version of the game was
+maintained and sold by the now defunct Loki Entertainment. The powerful
+Quake III engine is the basis for many other commercial games, as id's
+major source of revenue is licensing their game engines. The engine
+allows for user-contributed modifications to be made, allowing the game
+to be extensible and expandable. This game is commercial software, and
+requires the data from a retail copy of the game to play. If you're
+interested in checking out the technology behind Quake III, then
+"emerge quake3-demo" to get the playable demo.
+</longdescription>
+ <use>
+ <flag name="mumble">Adds player-location (positional audio) support to VoIP</flag>
+ <flag name="teamarena">Adds support for Team Arena expansion pack</flag>
+ <flag name="voice">Adds VoIP support</flag>
+ </use>
+</pkgmetadata>
diff --git a/games-fps/quake3/quake3-1.36-r1.ebuild b/games-fps/quake3/quake3-1.36-r1.ebuild
new file mode 100644
index 000000000000..d2ce233ab185
--- /dev/null
+++ b/games-fps/quake3/quake3-1.36-r1.ebuild
@@ -0,0 +1,122 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+inherit eutils flag-o-matic toolchain-funcs games
+
+MY_PN="ioquake3"
+MY_PV="${PV}"
+MY_P="${MY_PN}-${MY_PV}"
+
+DESCRIPTION="Quake III Arena - 3rd installment of the classic id 3D first-person shooter"
+HOMEPAGE="https://ioquake3.org/"
+SRC_URI="https://ioquake3.org/files/${MY_PV}/${MY_P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~x86-fbsd"
+# "smp" is omitted, because currently it does not work.
+IUSE="dedicated opengl teamarena +openal curl vorbis voice mumble"
+
+UIDEPEND="virtual/opengl
+ media-libs/libsdl[sound,video,joystick,X,opengl]
+ openal? ( media-libs/openal )
+ vorbis? (
+ media-libs/libogg
+ media-libs/libvorbis
+ )
+ voice? ( media-libs/speex )
+ curl? ( net-misc/curl )"
+DEPEND="opengl? ( ${UIDEPEND} )
+ !dedicated? ( ${UIDEPEND} )"
+UIRDEPEND="voice? ( mumble? ( media-sound/mumble ) )"
+RDEPEND="${DEPEND}
+ opengl? ( ${UIRDEPEND} )
+ !dedicated? ( ${UIRDEPEND} )
+ games-fps/quake3-data
+ teamarena? ( games-fps/quake3-teamarena )"
+
+S="${WORKDIR}/${MY_P}"
+
+my_arch() {
+ case "${ARCH}" in
+ x86) echo "i386" ;;
+ amd64) echo "x86_64" ;;
+ *) tc-arch-kernel ;;
+ esac
+}
+
+my_platform() {
+ usex kernel_linux linux freebsd
+}
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-bots.patch
+ einfo "Fixing libspeex linking..."
+ sed -i -e 's/\(-lspeex\)/\1 -lspeexdsp/' Makefile || die
+}
+
+src_compile() {
+
+ buildit() { use $1 && echo 1 || echo 0 ; }
+
+ # This is the easiest way to pass CPPFLAGS to the build system, which
+ # are otherwise ignored.
+ append-flags ${CPPFLAGS}
+
+ # OPTIMIZE is disabled in favor of CFLAGS.
+ #
+ # TODO: BUILD_CLIENT_SMP=$(buildit smp)
+ emake \
+ ARCH="$(my_arch)" \
+ V=1 \
+ BUILD_CLIENT=$(( $(buildit opengl) | $(buildit !dedicated) )) \
+ BUILD_GAME_QVM=0 \
+ BUILD_GAME_SO=0 \
+ BUILD_SERVER=$(buildit dedicated) \
+ DEFAULT_BASEDIR="${GAMES_DATADIR}/${PN}" \
+ GENERATE_DEPENDENCIES=0 \
+ OPTIMIZE="" \
+ PLATFORM="$(my_platform)" \
+ USE_CODEC_VORBIS=$(buildit vorbis) \
+ USE_CURL=$(buildit curl) \
+ USE_CURL_DLOPEN=0 \
+ USE_INTERNAL_SPEEX=0 \
+ USE_INTERNAL_ZLIB=0 \
+ USE_LOCAL_HEADERS=0 \
+ USE_MUMBLE=$(buildit mumble) \
+ USE_OPENAL=$(buildit openal) \
+ USE_OPENAL_DLOPEN=0 \
+ USE_VOIP=$(buildit voice)
+}
+
+src_install() {
+ dodoc BUGS ChangeLog id-readme.txt md4-readme.txt NOTTODO README TODO
+ if use voice ; then
+ dodoc voip-readme.txt
+ fi
+
+ if use opengl || ! use dedicated ; then
+ doicon misc/quake3.svg
+ make_desktop_entry quake3 "Quake III Arena"
+ fi
+
+ cd build/release-$(my_platform)-$(my_arch) || die
+ local exe target
+ for exe in {ioquake3,ioquake3-smp,ioq3ded}.$(my_arch) ; do
+ if [[ -x ${exe} ]] ; then
+ target=${exe%.*}
+ newgamesbin ${exe} ${target}
+ dosym ${target} "${GAMES_BINDIR}/${target/io}"
+ fi
+ done
+
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+
+ ewarn "The source version of Quake III Arena will not work with PunkBuster."
+ ewarn "If you need PB support, then use the games-fps/quake3-bin package."
+}
diff --git a/games-fps/quake3/quake3-9999.ebuild b/games-fps/quake3/quake3-9999.ebuild
new file mode 100644
index 000000000000..a5273e1ac571
--- /dev/null
+++ b/games-fps/quake3/quake3-9999.ebuild
@@ -0,0 +1,137 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+# quake3-9999 -> latest git
+# quake3-9999.REV -> use git REV
+# quake3-VER_alphaREV -> git snapshot REV for version VER
+# quake3-VER -> normal quake release
+
+EAPI=5
+inherit eutils flag-o-matic toolchain-funcs games
+[[ "${PV}" == 9999* ]] && inherit git-r3
+
+MY_PN="ioquake3"
+MY_PV="${PV}"
+MY_P="${MY_PN}-${MY_PV}"
+
+DESCRIPTION="Quake III Arena - 3rd installment of the classic id 3D first-person shooter"
+HOMEPAGE="https://ioquake3.org/"
+[[ "${PV}" != 9999* ]] && SRC_URI="https://ioquake3.org/files/${MY_PV}/${MY_P}.tar.bz2"
+EGIT_REPO_URI="https://github.com/ioquake/ioq3.git"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS=""
+# "smp" is omitted, because currently it does not work.
+IUSE="dedicated opengl teamarena +openal curl vorbis voice mumble"
+
+UIDEPEND="virtual/opengl
+ media-libs/libsdl[sound,video,joystick,X,opengl]
+ virtual/jpeg:0
+ openal? ( media-libs/openal )
+ vorbis? (
+ media-libs/libogg
+ media-libs/libvorbis
+ )
+ voice? ( media-libs/speex )
+ curl? ( net-misc/curl )"
+DEPEND="opengl? ( ${UIDEPEND} )
+ !dedicated? ( ${UIDEPEND} )"
+UIRDEPEND="voice? ( mumble? ( media-sound/mumble ) )"
+RDEPEND="${DEPEND}
+ opengl? ( ${UIRDEPEND} )
+ !dedicated? ( ${UIRDEPEND} )
+ games-fps/quake3-data
+ teamarena? ( games-fps/quake3-teamarena )"
+
+if [[ "${PV}" != 9999* ]] ; then
+ S="${WORKDIR}/${MY_P}"
+fi
+
+my_arch() {
+ case "${ARCH}" in
+ x86) echo "i386" ;;
+ amd64) echo "x86_64" ;;
+ *) tc-arch-kernel ;;
+ esac
+}
+
+my_platform() {
+ usex kernel_linux linux freebsd
+}
+
+src_compile() {
+
+ buildit() { use $1 && echo 1 || echo 0 ; }
+
+ # This is the easiest way to pass CPPFLAGS to the build system, which
+ # are otherwise ignored.
+ append-flags ${CPPFLAGS}
+
+ # Workaround for used zlib macro, wrt bug #449510
+ append-flags -DOF=_Z_OF
+
+ # OPTIMIZE is disabled in favor of CFLAGS.
+ #
+ # TODO: BUILD_CLIENT_SMP=$(buildit smp)
+ emake \
+ ARCH="$(my_arch)" \
+ V=1 \
+ BUILD_CLIENT=$(( $(buildit opengl) | $(buildit !dedicated) )) \
+ BUILD_GAME_QVM=0 \
+ BUILD_GAME_SO=0 \
+ BUILD_SERVER=$(buildit dedicated) \
+ DEFAULT_BASEDIR="${GAMES_DATADIR}/${PN}" \
+ FULLBINEXT="" \
+ GENERATE_DEPENDENCIES=0 \
+ OPTIMIZE="" \
+ PLATFORM="$(my_platform)" \
+ USE_CODEC_VORBIS=$(buildit vorbis) \
+ USE_CURL=$(buildit curl) \
+ USE_CURL_DLOPEN=0 \
+ USE_INTERNAL_JPEG=0 \
+ USE_INTERNAL_SPEEX=0 \
+ USE_INTERNAL_ZLIB=0 \
+ USE_LOCAL_HEADERS=0 \
+ USE_MUMBLE=$(buildit mumble) \
+ USE_OPENAL=$(buildit openal) \
+ USE_OPENAL_DLOPEN=0 \
+ USE_VOIP=$(buildit voice)
+}
+
+src_install() {
+ dodoc BUGS ChangeLog id-readme.txt md4-readme.txt NOTTODO README.md TODO voip-readme.txt
+ if use voice ; then
+ dodoc voip-readme.txt
+ fi
+
+ if use opengl || ! use dedicated ; then
+ doicon misc/quake3.svg
+ make_desktop_entry quake3 "Quake III Arena"
+ #use smp && make_desktop_entry quake3-smp "Quake III Arena (SMP)"
+ fi
+
+ cd build/release-$(my_platform)-$(my_arch) || die
+ local exe
+ for exe in ioquake3 ioquake3-smp ioq3ded ; do
+ if [[ -x ${exe} ]] ; then
+ dogamesbin ${exe}
+ dosym ${exe} "${GAMES_BINDIR}/${exe/io}"
+ fi
+ done
+
+ # Install renderer libraries, wrt bug #449510
+ # this should be done through 'dogameslib', but
+ # for this some files need to be patched
+ exeinto "${GAMES_DATADIR}/${PN}"
+ doexe renderer*.so
+
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+
+ ewarn "The source version of Quake III Arena will not work with PunkBuster."
+ ewarn "If you need PB support, then use the games-fps/quake3-bin package."
+}