summaryrefslogtreecommitdiff
path: root/games-fps/qudos
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /games-fps/qudos
reinit the tree, so we can have metadata
Diffstat (limited to 'games-fps/qudos')
-rw-r--r--games-fps/qudos/Manifest8
-rw-r--r--games-fps/qudos/files/qudos-0.40.1-gnusource.patch12
-rw-r--r--games-fps/qudos/files/qudos-0.40.1-libpng15.patch10
-rw-r--r--games-fps/qudos/metadata.xml17
-rw-r--r--games-fps/qudos/qudos-0.40.1.ebuild174
5 files changed, 221 insertions, 0 deletions
diff --git a/games-fps/qudos/Manifest b/games-fps/qudos/Manifest
new file mode 100644
index 000000000000..e72dd0cf5098
--- /dev/null
+++ b/games-fps/qudos/Manifest
@@ -0,0 +1,8 @@
+AUX qudos-0.40.1-gnusource.patch 338 SHA256 f4c33cce1e154ebb4ba8406d2da2da1964b170919eaf57b4eba2c1babf8de382 SHA512 6e6411e0d6a4c48a82f70cc83eb64eb8b86a15f0ffa552007cb5af6a8d0f718527f6acbcdb80393b45344e133f52ee366cf7923423afae25b3c6ab10829dae98 WHIRLPOOL ad757265ad6ca23258f64904ede8d3dbe9fba6038983f9b0c3843f7d19021cc869f9a41964a204ae23a936a4bf8c4b7e5cf7143c83e3af55080232c54a8624dd
+AUX qudos-0.40.1-libpng15.patch 205 SHA256 7364352d723d8f237a0340508a752894d1c51e43cb668e4b60cebd958dd6c97c SHA512 4a2ccb3566f0d3126910b48c024fc5b9d40fe471ca73ce043bc8c8339d2a08f124b921e622bdee05ed007861f4b816941307184bfcbdb8281eca02733b289f70 WHIRLPOOL 3b09dcbf9be708a8cd9a61ec300b2c554dc79be29d549ee84afe86a0f644a34e725aaf7490cc3e96791bf450ea16524aaa5d16f92280815ee1ba40415bb62719
+DIST QuDos-0.40.1-src.tar.bz2 2031636 SHA256 90d8dbbbe4e006b4233b9c8c20bc3da5c240dde8fdf17ccf43ca533d296aa21a SHA512 97b9c6bac0d09c060ab33174604deb2781f0ebdc48b00bd0bc402523fb04cdf84edd8abc18507bba8c7e616f6d460a1de6debc96ec39bb5562b20a7f06eea734 WHIRLPOOL 623456b47dfefc389ceadf267369221c2a89a934597fbc5e951c9728d6947a982525884803cfae6a59ede682c637bfba2f97f0c3e2c98579fce63dfe71161fca
+DIST QuDos-0.40.1.pk3 4210489 SHA256 c6f4dec4b0499b7b9d311d0d2a438358a205d4203eeee1b49f5695e5e14859ca SHA512 19c3c6b3d17cbd9642320d8eb7a83d667afeafd0ee5eb818e9f07be71e2ab69182474c1f529ecbcfcfa59590bafedb0de3c70dfff10e4bc7a6e07a1546f27d4b WHIRLPOOL 53d571d352f2f184fad9fcefd45a77e4d703e3338b5ec4baa77d0f46fb669d95164a2fa33dd80cb7083c40dd86da54cf4a0bea6e5d5dbb9253c3c9b53a44f86c
+EBUILD qudos-0.40.1.ebuild 4100 SHA256 a7b9ad30dce548d385ea3b58eafc74e9a618791424bcf4a8345fd31da25e882f SHA512 af3b10b7fc9ea21978a6f69a743a7ec62bd57ef3a85e12dcdfd51c0f783a2758d3b709045269a2503dac72adf3388037d06e8760b2c22b18f11f83bbd2fdb2a1 WHIRLPOOL a2b5516efda691934e2b3154ee58be7894086390c838964f034968e41ad7412e48e80edd6eedee64883980d87ba752e16942ae3416da0ec5a18d12eb26f4a4b4
+MISC ChangeLog 3581 SHA256 44955fb6334083700e188a568860b4d7a368b94a50db5332f7f02f732888d410 SHA512 17cb2f6bb09cb1c7016814289c1e4fc07976fb736e5124a699515beceb79b0122f7f51ecb41246169e724348a8201e572f2f0ebd9149bc761cc07b6a8dc26e66 WHIRLPOOL 89a2bdca999ab088c58a4ca4c1a3b4d952c76ea7db04da7cb19eb30b4cbab957f464e2eb0fc35bb867bffb792048744801e746da1a864549e389940cb5cb76d3
+MISC ChangeLog-2015 2386 SHA256 95a2683b783e3765903bb76a4c2abc5ee6db13938e5dcb26cfa31b383edab27d SHA512 bf9d5f8e15616f7379ca3ed513048b0cda28403615b4e6e36f86f1ed435d684b00ac23e36eb518c07fee8c1fb6fdd6dccf61e5e9477f22abd1701a6dd80acee8 WHIRLPOOL 97a824f0a6b26d0ea36182ce5e1817964689294a63759c6149274be86037f403e693c78ac98ed1e033a2f7918c27413bec09212114b2c3ce92a080e65fd7b3d0
+MISC metadata.xml 665 SHA256 8837ecd6764ee918a6cf6c83f5695551f5578a287e787290182a087d6b04bc69 SHA512 c96f5c164edea2f535115ca1fdd9ff39755f2be2a3f8846eb91d22e6d12f6e0e589e6d7e97a69d0afc65464df62390117296a27bb7b4b2e8da79735b206e5966 WHIRLPOOL f0aef32a9bbc0e25fdc3355a95056ff6661cc4703f8b5c164ede1402cd5561b49f362686a56411c290e8c6f68c92862fb18db95c0d5989c372b693138f7b9200
diff --git a/games-fps/qudos/files/qudos-0.40.1-gnusource.patch b/games-fps/qudos/files/qudos-0.40.1-gnusource.patch
new file mode 100644
index 000000000000..dd2113b0c3bb
--- /dev/null
+++ b/games-fps/qudos/files/qudos-0.40.1-gnusource.patch
@@ -0,0 +1,12 @@
+--- src/unix/qsh_unix.c.orig 2011-10-22 17:46:37.665993357 -0500
++++ src/unix/qsh_unix.c 2011-10-22 17:46:40.965972209 -0500
+@@ -17,6 +17,9 @@
+ * Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ */
++#if !defined(_GNU_SOURCE)
++ #define _GNU_SOURCE
++#endif
+ #include <sys/types.h>
+ #include <sys/stat.h>
+ #include <sys/time.h>
diff --git a/games-fps/qudos/files/qudos-0.40.1-libpng15.patch b/games-fps/qudos/files/qudos-0.40.1-libpng15.patch
new file mode 100644
index 000000000000..ecf9de9370e9
--- /dev/null
+++ b/games-fps/qudos/files/qudos-0.40.1-libpng15.patch
@@ -0,0 +1,10 @@
+--- src/ref_gl/gl_local.h
++++ src/ref_gl/gl_local.h
+@@ -29,6 +29,7 @@
+ #include <GL/glu.h>
+ #include <GL/glext.h>
+
++#include <zlib.h> /* Z_DEFAULT_COMPRESSION */
+ #include <png.h>
+ #include <jpeglib.h>
+
diff --git a/games-fps/qudos/metadata.xml b/games-fps/qudos/metadata.xml
new file mode 100644
index 000000000000..114138906332
--- /dev/null
+++ b/games-fps/qudos/metadata.xml
@@ -0,0 +1,17 @@
+<?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>
+ <use>
+ <flag name="demo">Install the demo files (quake2-demodata) and configure for use</flag>
+ <flag name="mods">Build support for the quake2 mission packs</flag>
+ <flag name="qmax">Build the pretty version (quake max)</flag>
+ <flag name="textures">Install the enhanced textures (quake2-textures)</flag>
+ </use>
+ <upstream>
+ <remote-id type="github">ZwS/qudos</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/games-fps/qudos/qudos-0.40.1.ebuild b/games-fps/qudos/qudos-0.40.1.ebuild
new file mode 100644
index 000000000000..27988248d7dd
--- /dev/null
+++ b/games-fps/qudos/qudos-0.40.1.ebuild
@@ -0,0 +1,174 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=5
+inherit eutils toolchain-funcs games
+
+FILE_STEM="QuDos-${PV}-src"
+PK3_FILE="QuDos-${PV}.pk3"
+MY_PN="quake2"
+
+DESCRIPTION="Enhanced Quake 2 engine"
+HOMEPAGE="https://github.com/ZwS/qudos"
+SRC_URI="mirror://gentoo/${FILE_STEM}.tar.bz2
+ https://github.com/ZwS/qudos/raw/master/quake2/baseq2/qudos.pk3 -> ${PK3_FILE}"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="cdinstall debug dedicated demo dga ipv6 joystick mods opengl qmax oss sdl textures"
+
+DEPEND="opengl? (
+ virtual/opengl
+ virtual/glu )
+ sdl? ( media-libs/libsdl[joystick?,opengl,sound,video]
+ virtual/opengl
+ virtual/glu )
+ virtual/jpeg:0
+ media-libs/libogg
+ media-libs/libpng:0
+ media-libs/libvorbis
+ sys-libs/zlib
+ x11-libs/libX11
+ x11-libs/libXext
+ x11-libs/libXxf86dga
+ x11-libs/libXxf86vm"
+RDEPEND="${DEPEND}
+ cdinstall? ( games-fps/quake2-data )
+ demo? ( games-fps/quake2-demodata[symlink] )
+ textures? ( games-fps/quake2-textures )"
+
+S=${WORKDIR}/${FILE_STEM}
+dir=${GAMES_DATADIR}/${MY_PN}
+
+default_client() {
+ if use opengl || use sdl || ! use dedicated ; then
+ # Build default client
+ return 0
+ fi
+ return 1
+}
+
+pkg_setup() {
+ games_pkg_setup
+
+ if ! use qmax && $( use opengl || use sdl ) ; then
+ elog "The 'qmax' graphical improvements are recommended."
+ echo
+ fi
+
+ if use debug ; then
+ ewarn "The 'debug' USE flag may cause compilation to fail with:"
+ ewarn
+ ewarn "src/qcommon/cmd.c:364: warning: dereferencing type-punned"
+ ewarn "pointer will break strict-aliasing rules."
+ echo
+ fi
+
+ # Determine the default sound driver, in order of preference
+ # snd_drv is not a local variable
+ snd_drv=""
+ [[ -z "${snd_drv}" ]] && use oss && snd_drv="oss"
+ [[ -z "${snd_drv}" ]] && use sdl && snd_drv="sdl"
+ # Default if nothing else chosen
+ [[ -z "${snd_drv}" ]] && snd_drv="oss"
+
+ if default_client ; then
+ elog "Selected the ${snd_drv} sound driver as the default."
+ echo
+ fi
+}
+
+src_unpack() {
+ unpack "${FILE_STEM}.tar.bz2"
+}
+
+src_prepare() {
+ rm docs/gnu.txt
+
+ # Change default sound driver and its location
+ sed -i \
+ -e "s:\"oss\":\"${snd_drv}\":" \
+ -e "s:\"\./snd:\"$(games_get_libdir)/${PN}/snd:" \
+ src/client/snd_dma.c || die
+
+ sed -i \
+ -e 's:jpeg_mem_src:qudos_jpeg_mem_src:g' \
+ src/ref_gl/gl_image.c || die
+
+ if has_version '>=sys-libs/zlib-1.2.5.1-r1' ; then
+ sed -i \
+ -e '1i#define OF(x) x' \
+ src/qcommon/unzip/ioapi.h || die
+ fi
+ sed -i -e '106,119 s/CFL/LED/' Makefile || die
+
+ epatch \
+ "${FILESDIR}"/${P}-libpng15.patch \
+ "${FILESDIR}"/${P}-gnusource.patch
+}
+
+src_compile() {
+ yesno() { usex $1 YES NO; }
+
+ local client="YES"
+ default_client || client="NO"
+
+ local type="release"
+ use debug && type="debug"
+
+ emake \
+ BUILD_QUAKE2="${client}" \
+ BUILD_DEDICATED=$(yesno dedicated) \
+ BUILD_GLX=$(yesno opengl) \
+ BUILD_SDLGL=$(yesno sdl) \
+ BUILD_ALSA_SND=NO \
+ BUILD_SDL_SND=$(yesno sdl) \
+ BUILD_OSS_SND=$(yesno oss) \
+ WITH_XMMS=NO \
+ WITH_DGA_MOUSE=$(yesno dga) \
+ WITH_JOYSTICK=$(yesno joystick) \
+ TYPE="${type}" \
+ DATADIR="${dir}" \
+ LOCALBASE=/usr \
+ LIBDIR="$(games_get_libdir)"/${PN} \
+ WITH_QMAX=$(yesno qmax) \
+ BUILD_3ZB2=$(yesno mods) \
+ BUILD_CTF=$(yesno mods) \
+ BUILD_JABOT=$(yesno mods) \
+ BUILD_ROGUE=$(yesno mods) \
+ BUILD_XATRIX=$(yesno mods) \
+ BUILD_ZAERO=$(yesno mods) \
+ WITH_BOTS=$(yesno mods) \
+ HAVE_IPV6=$(yesno ipv6) \
+ CC="$(tc-getCC)" \
+ WITH_X86_ASM=NO \
+ WITH_DATADIR=YES \
+ WITH_LIBDIR=YES \
+ BUILD_DEBUG_DIR=release \
+ BUILD_RELEASE_DIR=release
+}
+
+src_install() {
+ if default_client ; then
+ newgamesbin ${MY_PN}/QuDos ${PN}
+ # Change from gif to png in next version?
+ newicon docs/q2_orig/quake2.gif ${PN}.gif
+ make_desktop_entry ${PN} "QuDos" ${PN}.gif
+ fi
+
+ if use dedicated ; then
+ newgamesbin ${MY_PN}/QuDos-ded ${PN}-ded
+ fi
+
+ insinto "$(games_get_libdir)"/${PN}
+ doins -r ${MY_PN}/*
+ rm "${D}/$(games_get_libdir)"/${PN}/QuDos
+
+ insinto "$(games_get_libdir)"/${PN}/baseq2
+ newins "${DISTDIR}/${PK3_FILE}" qudos.pk3
+
+ dodoc $(find docs -name \*.txt) docs/q2_orig/README*
+
+ prepgamesdirs
+}