summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /games-fps/qudos
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'games-fps/qudos')
-rw-r--r--games-fps/qudos/Manifest2
-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.xml11
-rw-r--r--games-fps/qudos/qudos-0.40.1.ebuild188
5 files changed, 223 insertions, 0 deletions
diff --git a/games-fps/qudos/Manifest b/games-fps/qudos/Manifest
new file mode 100644
index 000000000000..4c5257af06dc
--- /dev/null
+++ b/games-fps/qudos/Manifest
@@ -0,0 +1,2 @@
+DIST QuDos-0.40.1-src.tar.bz2 2031636 SHA256 90d8dbbbe4e006b4233b9c8c20bc3da5c240dde8fdf17ccf43ca533d296aa21a SHA512 97b9c6bac0d09c060ab33174604deb2781f0ebdc48b00bd0bc402523fb04cdf84edd8abc18507bba8c7e616f6d460a1de6debc96ec39bb5562b20a7f06eea734 WHIRLPOOL 623456b47dfefc389ceadf267369221c2a89a934597fbc5e951c9728d6947a982525884803cfae6a59ede682c637bfba2f97f0c3e2c98579fce63dfe71161fca
+DIST QuDos-0.40.1.pk3 5253128 SHA256 c02e0df50785d5b360ec5435e2fd3d31b337f28f676b7af141a8e2664f518f1c SHA512 69d1e752c32e763f0452f41856fbb9833676dfd27337633c65666b47be13db48be7ad6f81054b180a3fdc43d3952f3bbe632df12fa0a8e86be14c48c2d8daec5 WHIRLPOOL 33d54cadce0d5d3fd4353838dcd9719443f3fc01f5bb859f80aae105389990c62cc8ee5576eb81098ccce5320d7591b9c955f9e82c61461ec217e01034a939d4
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..0dd51f0c44b4
--- /dev/null
+++ b/games-fps/qudos/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>games</herd>
+ <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>
+</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..2253492f7ad9
--- /dev/null
+++ b/games-fps/qudos/qudos-0.40.1.ebuild
@@ -0,0 +1,188 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+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="http://qudos.quakedev.com/"
+SRC_URI="http://qudos.quakedev.com/linux/${MY_PN}/engines/QuDos/${FILE_STEM}.tar.bz2
+ http://qudos.quakedev.com/linux/${MY_PN}/engines/QuDos/${PK3_FILE}"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="alsa cdinstall debug dedicated demo dga ipv6 joystick mods opengl qmax oss sdl textures"
+
+UIDEPEND="alsa? ( media-libs/alsa-lib )
+ opengl? (
+ virtual/opengl
+ virtual/glu )
+ sdl? ( media-libs/libsdl )
+ virtual/jpeg
+ media-libs/libogg
+ media-libs/libpng
+ media-libs/libvorbis
+ sys-libs/zlib
+ x11-libs/libX11
+ x11-libs/libXext
+ x11-libs/libXxf86dga
+ x11-libs/libXxf86vm"
+RDEPEND="${UIDEPEND}
+ cdinstall? ( games-fps/quake2-data )
+ demo? ( games-fps/quake2-demodata )
+ textures? ( games-fps/quake2-textures )"
+DEPEND="${UIDEPEND}"
+
+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"
+ [[ -z "${snd_drv}" ]] && use alsa && snd_drv="alsa"
+ # 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
+ if [[ "${snd_drv}" = "alsa" ]] ; then
+ ewarn "The ALSA sound driver for this game is incomplete."
+ # OSS is the default sound driver in the Makefile
+ ewarn "The 'oss' USE flag is recommended instead."
+ echo
+ fi
+ fi
+}
+
+src_unpack() {
+ unpack "${FILE_STEM}.tar.bz2"
+}
+
+src_prepare() {
+ rm docs/gnu.txt
+
+ # Change default sound driver and its location
+ sed -i src/client/snd_dma.c \
+ -e "s:\"oss\":\"${snd_drv}\":" \
+ -e "s:\"\./snd:\"$(games_get_libdir)/${PN}/snd:" \
+ || die "sed snd_dma.c failed"
+
+ sed -i \
+ -e 's:jpeg_mem_src:qudos_jpeg_mem_src:g' \
+ src/ref_gl/gl_image.c || die
+
+ has_version '>=sys-libs/zlib-1.2.5.1-r1' && \
+ sed -i -e '1i#define OF(x) x' src/qcommon/unzip/ioapi.h
+
+ epatch \
+ "${FILESDIR}"/${P}-libpng15.patch \
+ "${FILESDIR}"/${P}-gnusource.patch
+}
+
+src_compile() {
+ yesno() { use $1 && echo YES || echo NO ; }
+
+ local client="YES"
+ default_client || client="NO"
+
+ local type="release"
+ use debug && type="debug"
+
+ emake -j1 \
+ BUILD_QUAKE2="${client}" \
+ BUILD_DEDICATED=$(yesno dedicated) \
+ BUILD_GLX=$(yesno opengl) \
+ BUILD_SDLGL=$(yesno sdl) \
+ BUILD_ALSA_SND=$(yesno alsa) \
+ 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
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+
+ if use demo && ! has_version "games-fps/quake2-demodata[symlink]" ; then
+ ewarn "To play the Quake 2 demo,"
+ ewarn "emerge games-fps/quake2-demodata with the 'symlink' USE flag."
+ echo
+ fi
+}