]> git.draconx.ca Git - gentoo-draconx.git/commitdiff
Add ioquake3 1.36.
authorNick Bowler <nbowler@draconx.ca>
Wed, 16 Dec 2009 20:31:26 +0000 (15:31 -0500)
committerNick Bowler <nbowler@draconx.ca>
Wed, 16 Dec 2009 20:31:26 +0000 (15:31 -0500)
https://bugs.gentoo.org/show_bug.cgi?id=222005

games-fps/quake3/Manifest [new file with mode: 0644]
games-fps/quake3/quake3-1.36.ebuild [new file with mode: 0644]

diff --git a/games-fps/quake3/Manifest b/games-fps/quake3/Manifest
new file mode 100644 (file)
index 0000000..2a70ee3
--- /dev/null
@@ -0,0 +1,2 @@
+DIST ioquake3-1.36.tar.bz2 3503058 RMD160 af9f65bbde2fe5531fa371ec6d2023126a523293 SHA1 0f92891e2b174253d02f666fd22e147c886089b4 SHA256 79b10b92e9e586748a67089ac871646fe8144004d3ab4a55158348bc38d74821
+EBUILD quake3-1.36.ebuild 3346 RMD160 c6d6af6f96e8c29d33a8e94001d6e1c4f15a48a2 SHA1 0b4af84bf61cd31b9c64a559fb2590a1cab2ae8f SHA256 886eba14992202294e4f035f83f6f9b43ea987550a9b77d000ee9494efaaccb5
diff --git a/games-fps/quake3/quake3-1.36.ebuild b/games-fps/quake3/quake3-1.36.ebuild
new file mode 100644 (file)
index 0000000..50c4855
--- /dev/null
@@ -0,0 +1,135 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit eutils games toolchain-funcs
+[[ "${PV}" == 9999* ]] && inherit subversion
+
+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="http://ioquake3.org/"
+[[ "${PV}" != 9999* ]] && SRC_URI="http://ioquake3.org/files/${MY_PV}/${MY_P}.tar.bz2"
+ESVN_REPO_URI="svn://svn.icculus.org/quake3/trunk"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86 ~x86-fbsd"
+# 'smp' doesn't currently work on Linux
+IUSE="dedicated opengl teamarena +openal curl vorbis voice mumble"
+
+# FIXME Add to UIDEPEND once USE_INTERNAL_SPEEX is 0
+#      voice? ( media-libs/speex )
+UIDEPEND="
+       virtual/opengl
+       media-libs/libsdl[joystick,opengl,video,X]
+       openal? ( media-libs/openal )
+       !openal? ( media-libs/libsdl[audio] )
+       vorbis? (
+               media-libs/libogg
+               media-libs/libvorbis
+       )
+       curl? ( net-misc/curl )
+"
+DEPEND="
+       opengl? ( ${UIDEPEND} )
+       !dedicated? ( ${UIDEPEND} )
+"
+RDEPEND="
+       ${DEPEND}
+       opengl? ( voice? ( mumble? ( media-sound/mumble ) ) )
+       !dedicated? ( voice? ( mumble? ( media-sound/mumble ) ) )
+       games-fps/quake3-data
+       teamarena? ( games-fps/quake3-teamarena )
+"
+
+if [[ "${PV}" == 9999* ]] ; then
+       S="${WORKDIR}/trunk"
+else
+       S="${WORKDIR}/${MY_P}"
+fi
+
+my_arch() {
+       case "${ARCH}" in
+               x86)    echo "i386" ;;
+               amd64)  echo "x86_64" ;;
+               *)      tc-arch-kernel ;;
+       esac
+}
+
+my_platform() {
+       case "${ARCH}" in
+               amd64|ppc|x86)  echo "linux" ;;
+               x86-fbsd)       echo "freebsd" ;; # Should be tested
+       esac
+}
+
+src_compile() {
+
+       buildit() {
+               use $1 && echo 1 || echo 0
+       }
+
+       # FIXME Set USE_INTERNAL_SPEEX=0 once it works with media-libs/speex
+       # FIXME Add BUILD_CLIENT_SMP once smp support works
+       # FIXME Add FULLBINEXT (currently only in SVN)
+       ARCH="$(my_arch)" \
+       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 \
+       PLATFORM="$(my_platform)" \
+       USE_CODEC_VORBIS=$(buildit vorbis) \
+       USE_CURL=$(buildit curl) \
+       USE_CURL_DLOPEN=0 \
+       USE_INTERNAL_SPEEX=1 \
+       USE_INTERNAL_ZLIB=0 \
+       USE_LOCAL_HEADERS=0 \
+       USE_MUMBLE=$(buildit mumble) \
+       USE_OPENAL=$(buildit openal) \
+       USE_OPENAL_DLOPEN=0 \
+       USE_VOIP=$(buildit voice) \
+       emake || die "emake failed"
+}
+
+src_install() {
+       dodoc id-readme.txt TODO README BUGS ChangeLog md4-readme.txt || die "dodoc"
+       if use voice ; then
+               dodoc voip-readme.txt || die "dodoc"
+       fi
+
+       if use opengl || ! use dedicated ; then
+               doicon misc/quake3.svg || die "doicon"
+               #if use smp; then
+               #       make_desktop_entry quake3-smp "Quake III Arena"
+               #else
+                       make_desktop_entry quake3 "Quake III Arena"
+               #fi
+       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} || die "newgamesbin ${target}"
+                       dosym ${target} "${GAMES_BINDIR}/${target/io}" || die "dosym ${target}"
+               fi
+       done
+
+       prepgamesdirs
+}
+
+pkg_postinst() {
+       games_pkg_postinst
+
+       elog
+       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."
+}