summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Ospald <hasufell@gentoo.org>2013-01-18 19:08:13 +0000
committerJulian Ospald <hasufell@gentoo.org>2013-01-18 19:08:13 +0000
commit9131622dc07554b64225016c4b0e61242bca6ed8 (patch)
tree369b6f82ebf78eb45d633463a8c08f5c31c95316 /games-fps
parentFix for CVE-2013-1364, and upstream bug #ZBX-6097. Bumps 1.8.16 and 2.0.4-r1. (diff)
downloadhistorical-9131622dc07554b64225016c4b0e61242bca6ed8.tar.gz
historical-9131622dc07554b64225016c4b0e61242bca6ed8.tar.bz2
historical-9131622dc07554b64225016c4b0e61242bca6ed8.zip
unbundle libRocket, revbump for safety
Package-Manager: portage-2.2.0_alpha153/cvs/Linux x86_64 Manifest-Sign-Key: 0xE73C35B3
Diffstat (limited to 'games-fps')
-rw-r--r--games-fps/warsow/ChangeLog10
-rw-r--r--games-fps/warsow/Manifest19
-rw-r--r--games-fps/warsow/files/warsow-1.02-build.patch66
-rw-r--r--games-fps/warsow/warsow-1.02-r1.ebuild179
4 files changed, 248 insertions, 26 deletions
diff --git a/games-fps/warsow/ChangeLog b/games-fps/warsow/ChangeLog
index 77658703bbf1..6b975ac3acf2 100644
--- a/games-fps/warsow/ChangeLog
+++ b/games-fps/warsow/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for games-fps/warsow
-# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/games-fps/warsow/ChangeLog,v 1.47 2012/12/27 02:24:48 hasufell Exp $
+# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/games-fps/warsow/ChangeLog,v 1.48 2013/01/18 19:08:09 hasufell Exp $
+
+*warsow-1.02-r1 (18 Jan 2013)
+
+ 18 Jan 2013; Julian Ospald <hasufell@gentoo.org> +warsow-1.02-r1.ebuild,
+ files/warsow-1.02-build.patch:
+ unbundle libRocket, revbump for safety
27 Dec 2012; Julian Ospald <hasufell@gentoo.org> warsow-1.02.ebuild,
files/warsow-1.02-build.patch:
diff --git a/games-fps/warsow/Manifest b/games-fps/warsow/Manifest
index ed083d8316d8..a090dd1f3858 100644
--- a/games-fps/warsow/Manifest
+++ b/games-fps/warsow/Manifest
@@ -3,7 +3,7 @@ Hash: SHA256
AUX warsow-1.0-build.patch 16346 SHA256 626f23dc9c99eec2d1e1760e9247eb81079569ea139c165cb3ec908235e3aee7 SHA512 50131166cbd4ea39e9d77936d47ee9ca602f78f37f4f0351c188528deaebee1312b757ec4703b20a104cd23dbb5b68a948af774d67da07d1dac671c752bee4cf WHIRLPOOL 866797b10d0513269e72d2e71cda2d4860c8ca90322a426232dbcbd00cde68350a56ac484dacf350de11263ef329c5632dab5f8d0d8b08795191d6ac671ebe51
AUX warsow-1.0-pic.patch 377 SHA256 300c220fb833424be66da460ad4ac1ef6c61cde0dc5b76e1e8e0b75f5ece3782 SHA512 1f712dbf83c3bca6a2f0424f2250133a23903da86c9045d0917ef5a18b311f6485af6cd5afc1bbcc8b47ff0e0f880154fc17f978c2e7400b6edb4b2ba33b2e18 WHIRLPOOL 536ddb836e09c15d0a3e5645066042164a556d608022c9892a82cd56552a489d6d424909878fe89ddf035a1a604d9ba4a73eabe563c6de51f44ccec1f9b7d854
-AUX warsow-1.02-build.patch 17194 SHA256 e7d7beb3cc375538619290e6abeea26966eafff1eb06458464a87ca63c26b28c SHA512 483a99d76c74561e056334e95ef70b210912fff06da508de422b003c6bffdb0decb68a2f25a5e0ca5ca492bb5ac229b84a33ab6e4ca2dcb87cef0304b7859b1a WHIRLPOOL 5941cd2e9085f62d29c25b4dd55e1f9b6679c13e8e7e7119011ef6d9426405da19c0c95d93805cc934d85aaed9fbf65cf2758676a7d9d4db9001e66cc8660c50
+AUX warsow-1.02-build.patch 18235 SHA256 2651eac7e51e8fabe2782870ab9126f7767e16627c43a5f610d88be714298629 SHA512 85ccd72d70106ec086c5ac84377d1b7c5026b1b98487c104fa88e5a4d5fdbd0b851b98c9c936f925f22e63ce726a453fecd3368946437dbba3623e2f36388c22 WHIRLPOOL 648fbeb9fdef1c37e7bd5cd71c36d82e6243fa7bd9c54ac4c7dc3b98514eb997b97c4103a47d8d4ac32120487d41e69c4e34a830b860600f07ce34d30ea8d61b
AUX warsow-1.02-pic.patch 377 SHA256 300c220fb833424be66da460ad4ac1ef6c61cde0dc5b76e1e8e0b75f5ece3782 SHA512 1f712dbf83c3bca6a2f0424f2250133a23903da86c9045d0917ef5a18b311f6485af6cd5afc1bbcc8b47ff0e0f880154fc17f978c2e7400b6edb4b2ba33b2e18 WHIRLPOOL 536ddb836e09c15d0a3e5645066042164a556d608022c9892a82cd56552a489d6d424909878fe89ddf035a1a604d9ba4a73eabe563c6de51f44ccec1f9b7d854
DIST warsow.png 1692 SHA256 086968e72271b248ef32609ed1818ff9f5c355297b1eee3cbee9e41f4e18a954 SHA512 76476fd6f624b4043405fbddeaa0fa46338b96bf46a9b64434940d9a84738a20c25243ef1316048159698b6a70b3e0f26218da3332203a93944312e77ba22c8f WHIRLPOOL 94b7c77641d5a8f581de4eb0e4e91b71f25347248a6aa6c1160e8fefda92951daa3fbbf04aee4920fc9b53fb07872d3fb7d870d4207d13844e07afa51c93e85b
DIST warsow_1.02_sdk.tar.gz 56541955 SHA256 bec1f0ec26c39defad393578b28eb955504f054599142b096773c28889cabb2c SHA512 d62399baa13341bc87863d123a9d852ec688d0aa279eb626b8c95bda28b7ac1d602c7571e02dfda7dd8ea83a231cd8c3310a0126c1235968291e9e700679fbca WHIRLPOOL 7c44fb252b95b400e829c752c58a4d715b695d56f7e9b35504be9c1e1566c513f101090f7bbe0eabba5aef11ff3f320106fe7ce1d4b7b17e7368979b0b193621
@@ -11,17 +11,18 @@ DIST warsow_1.02_update.zip 20582996 SHA256 23efd46590be99140b836125335dc973f606
DIST warsow_1.0_sdk.tar.gz 56525636 SHA256 2e394b5c50ad206723a59636ab93448f69d8602e710ab334451badf746870e22 SHA512 dee6591fb5ed7150e3e18db20b18366777dbacd4a465074eb3c978a04b7df5140e8a7817a5248542af06d2a6eb972ad986690f16e57ac08f753cccb2470d7bfe WHIRLPOOL e30772b49f37dede19d54e129cc1ca05bf9f01c9a10f372c9c420ceba25514c6a928c12ba61e140efc5ea8d46cbd6db403ca03aee215964173662127b9dbfd59
DIST warsow_1.0_unified.tar.gz 518459004 SHA256 f933d251de4c92b6107d4db1eef5326baf4873d32a6e2f1c3daae14bc92e85ec SHA512 78706093fb4b8684893d9b497fd10f1ce3ef096b68bbf7d36ed2bc775fa649738f0153a723b2788ef6a54d30826ec96bc36899d2e5c230bf09022b98cc105aad WHIRLPOOL efdffd7f358c704a6c08eb1d8c91543db3b76805edba775f88570debfa1b4a9ac64772958831fff7d0be4d72f2d29abbb7610d115e92cdb0fd897a8e31b1059c
EBUILD warsow-1.0.ebuild 3376 SHA256 aa2331fdad71c190d031933e36b6e8c2f20ec9b546d56dfafce8f20449f1633f SHA512 7e06adc5c0159468726b395d3254104df630226dae37a67b3705629b874c6e934649fad096be036fee1735a9521ce891fe9bce91ba22b66f96bcf67aa31e8248 WHIRLPOOL 154a349864122c0122c0f4ea124c9a23f75d5d1e45678c704d7b8c766426de139ffce509d278e898cbff3a4b629165c89ee3f88ef91f2e0f0955b782d5fccefe
+EBUILD warsow-1.02-r1.ebuild 3779 SHA256 6b9f8bb527d3138b698124f741d7789beb10955eadd82980d3eacc4c8137718e SHA512 a064a966d8669996d31aeed383f340297dca81df5a2f92e03d4208b66082c211f6eb2b1c1ef70ba40e7b8eaad1a968c4e4533a7c1629a6bb2fdc812d45c1326c WHIRLPOOL cf2bf2707dab6ddf1048d8eb80684a423f8dac62443538b536b76bb895a859d579c2bcc17d5ef1af3340a67b5de1d6a55043d808fc75e9f74aca42a054591e87
EBUILD warsow-1.02.ebuild 3718 SHA256 d7fdb02d5c5c0d7f875dcac52f05da2155631263bf3ac1163110e52ca6251465 SHA512 c72410e495e4fbef639b5c1ce757e600bed80f64b86b5054aebf29de2f99ee671b91f5fa0589c7c3549c62c8ba31793c5cd384170ae9d482428a5435f699bf84 WHIRLPOOL ad6f43f9968a8a9600edcbb08bb4e162a13a706c003c9fe8a44229f5fafc5108ef8d74b7317fd8b834de5895c34daa9798b93c6ad156eda798745f9e21e893c5
-MISC ChangeLog 6853 SHA256 93d2ad491b7179c031c1f033603918f74a8cea49334f94a12788d9fbdddaa828 SHA512 eb30648874ab6a097090dce1896e3d6a367716fa6b3dbfec295528ddd9f868fde6bdbc8c0fe4c94abb163bb407f9131bdf885cde245735e5c1f6b421272d7ec0 WHIRLPOOL 69985bcfd5a2e247df75ee827089ffe5812158da8593f2f4ee6c91d5e43c1f676afdb13aefd8297c8170bb9d9117410c6baa60a5eab9b3b190d416fc59b511f5
+MISC ChangeLog 7034 SHA256 dbfbae21ed9e63a1acfd2f8a01b01ff0da7aaa95428982bfa8d1e480d1d7ed04 SHA512 89262d715880f683265904d2347b5b4974ad31cd966d1da2fa356b4f6b6b4fc346aadbbceada3fc6a92073f68ee506cee58ee3f28d164f77ac505319f2da9ca8 WHIRLPOOL c9f119aa35dd0e023b6687e036dd320c117e1cceb1a8283b828412c3a6c20f46954545a2287f1e0aba39214cb2307a299267ddbdaeb87310776254e5c9efa7b5
MISC metadata.xml 347 SHA256 016dbabb997c28f241f054760d9b81b1c43f5161de6d53936a2ebeb78bccdbea SHA512 34e3d6eae3b4665eac573b096d83a2841aee4488cc1a237e54e6e12c0c7ad8caefbbde6b563d1421c9d68cf7fb2b6c2446dfeddb1390971a7630b5efa494cb77 WHIRLPOOL 9d4cbde23eacc798cb4f1ac0c504963d349619229a5c2e926d8fc1348b1fefc53e999cc21e0be0cdca58affd1bfd4a275ae633709af78ca3dc808431fa365db3
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.19 (GNU/Linux)
-iQEcBAEBCAAGBQJQ27F0AAoJEFpvPKfnPDWzMMAH/361S97pmLN0H/SyfifrDs97
-TgPT4JAdzofWIy6OCI2LpQAIeVL8wPjBPOrSeCkXXqYzmX4wHRiwJGTXQk5XdISB
-VF4bwMsjtf6C4VNFMwaiGdRdffFqn5uVvzXmEnEYuTid/aoAo2VhegLPk95V5u2y
-J6qUvFHtZoh1iZmRxMFtp62LY/J9LWjomaETWRbk1Q/b6mShRCzPNmkTODX8mggF
-FRAwhQ9HjEssNnS1G9FG7RsmmRCvw/MWPDUWG2kqo6YtpYS/LgfGdxjZvIRutBg4
-bPDA8pQP84XAvbfNO/qu9XI95sDJNJa/0U2mrX3mdHYUuaIdu0PAi8g3gy7Krcw=
-=XG6z
+iQEcBAEBCAAGBQJQ+Z2dAAoJEFpvPKfnPDWzLgwIALQT3nd94mPeu39F3oEYs/O7
+vyzBhN1NMceoEbo11DISwiuocCbVeFOFpjilh3zO2F8P7g7OjeJ/tww8ujpHixIJ
+iM1Yqj1UNdts0h1iuloEXz3fHYkBPsrLoBVI0YBAj+Qj9rWVg5vJMVydxMFJgzSK
+BFf/FdHmZSO5t0kyYcsi+Ao6YWc3zo9bRChASydPFziFiVjV9mrUD5+kLLzap7UO
+Oytlu8e3lYUJLitiMYUYl8DJnu6kd3S7yC/BhYvBu9SDoPwTSdNSnSJbkUT1sDXU
+EesjjupTouIRv6JqoWlfng2VwnytZ4NlyGtTaDAsx/4NFVIHHB1xVqbk9Gf+9NQ=
+=jCjO
-----END PGP SIGNATURE-----
diff --git a/games-fps/warsow/files/warsow-1.02-build.patch b/games-fps/warsow/files/warsow-1.02-build.patch
index ed73860fd4e9..b08376a8cc44 100644
--- a/games-fps/warsow/files/warsow-1.02-build.patch
+++ b/games-fps/warsow/files/warsow-1.02-build.patch
@@ -13,10 +13,13 @@ g) address parallel make issues
--- source/Makefile
+++ source/Makefile
-@@ -30,6 +30,13 @@
+@@ -30,6 +30,16 @@
# Build Warsow client without server capabilities?
BUILD_THIN_CLIENT?=NO
++# use system libRocket
++SYSTEM_LIBS=NO
++
+# enable verbosity
+V=NO
+
@@ -27,7 +30,7 @@ g) address parallel make issues
###########################################################
ifeq ($(USE_MINGW),YES)
-@@ -50,10 +57,10 @@
+@@ -50,10 +60,10 @@
else
CC?=gcc
CXX?=g++
@@ -42,7 +45,7 @@ g) address parallel make issues
# this nice line comes from the linux kernel makefile
BASE_ARCH:=$(shell uname -m | sed -e s/i.86/i386/ -e s/sun4u/sparc/ -e s/sparc64/sparc/ -e s/arm.*/arm/ -e s/sa110/arm/ -e s/alpha/axp/)
-@@ -62,7 +69,7 @@
+@@ -62,7 +72,7 @@
ifeq ($(OS),FreeBSD)
ARCH?=freebsd_$(BASE_ARCH)
else
@@ -51,7 +54,7 @@ g) address parallel make issues
endif
SHARED_LIBRARY_EXTENSION=so
-@@ -72,7 +79,7 @@
+@@ -72,7 +82,7 @@
ifeq ($(DEBUG_BUILD), YES)
BINDIR=debug
@@ -60,7 +63,32 @@ g) address parallel make issues
else
BINDIR=release
endif
-@@ -195,9 +202,9 @@
+@@ -118,15 +128,22 @@
+ LIBROCKET_INC=$(LIBROCKET_DIR)/Include
+ LIBROCKET_LIB=$(LIBROCKET_DIR)/lib/libRocketWSW.a
+
+-CFLAGS_ROCKET=-DSTATIC_LIB -I$(LIBROCKET_INC) -I$(ANGELSCRIPT_INC)
++CFLAGS_ROCKET=-I$(ANGELSCRIPT_INC)
+ # add the base of ui to inclusions
+ CFLAGS_ROCKET+=-Iui
+
+ # static link to custombuilt lib
+-LDFLAGS_ROCKET=-L$(LIBROCKET_DIR)/lib -lRocketWSW -lfreetype
++LDFLAGS_ROCKET=
+ # dynamic link to 'official' build
+ # LDFLAGS_ROCKET=-L$(LIBROCKET_DIR)/Build -lRocketCore -lRocketControls -lfreetype
+
++ifneq ($(SYSTEM_LIBS),YES)
++CFLAGS_ROCKET += -DSTATIC_LIB -I$(LIBROCKET_INC)
++LDFLAGS_ROCKET=-L$(LIBROCKET_DIR)/lib -lRocketWSW -lfreetype
++else
++LDFLAGS_ROCKET = -lRocketCore -lRocketControls
++endif
++
+ ###########################################################
+
+ ####################### MINGW ######################
+@@ -195,9 +212,9 @@
LOCALBASE?=/usr/local
X11BASE?=/usr/X11R6
@@ -73,7 +101,7 @@ g) address parallel make issues
ifeq ($(DEBUG_BUILD),YES)
CFLAGS_COMMON+=$(CFLAGS_DEBUG)
else
-@@ -209,18 +216,18 @@
+@@ -209,18 +226,18 @@
CFLAGS_MODULE=-DPIC -fPIC
CFLAGS_TV_SERVER=-DDEDICATED_ONLY -DTV_SERVER_ONLY -DC_ONLY -DTV_MODULE_HARD_LINKED
@@ -97,7 +125,7 @@ g) address parallel make issues
endif
ifeq ($(ARCH),x86_64)
-@@ -298,12 +305,19 @@
+@@ -298,12 +315,19 @@
######################################################################################################
# Helper functions
######################################################################################################
@@ -120,7 +148,7 @@ g) address parallel make issues
DO_CC_CLIENT=$(DO_CC) $(CFLAGS_CLIENT)
DO_CC_DED=$(DO_CC) $(CFLAGS_DED)
-@@ -505,17 +519,17 @@
+@@ -505,17 +529,17 @@
all: client openal qf ded cgame game ui irc cin angelwrap tv_server
@@ -141,14 +169,22 @@ g) address parallel make issues
clean: clean-msg clean-depend clean-client clean-openal clean-qf clean-ded clean-cgame clean-game clean-ui clean-librocket clean-irc clean-cin clean-angelwrap clean-tv_server
-@@ -611,13 +625,14 @@
+@@ -609,7 +633,14 @@
+ @echo "> *********************************************************"
+ @echo "> * Building ui"
@echo "> *********************************************************"
++
++ifneq ($(SYSTEM_LIBS),YES)
compile-ui: $(OBJS_UI_ROCKET) $(LIBROCKET_LIB)
- link-ui: $(BINDIR)/basewsw $(BINDIR)/basewsw/ui_$(ARCH).$(SHARED_LIBRARY_EXTENSION)
+$(BINDIR)/basewsw/ui_$(ARCH).$(SHARED_LIBRARY_EXTENSION): $(LIBROCKET_LIB)
++else
++compile-ui: $(OBJS_UI_ROCKET)
++endif
++
+ link-ui: $(BINDIR)/basewsw $(BINDIR)/basewsw/ui_$(ARCH).$(SHARED_LIBRARY_EXTENSION)
clean-ui:
@echo " > Removing ui objects" && \
- $(RM) $(OBJS_UI_ROCKET)
+@@ -617,7 +648,7 @@
$(LIBROCKET_LIB):
@echo "> * Building Rocket library"
@@ -157,7 +193,7 @@ g) address parallel make issues
@echo "> * Done building RocketCore library."
@echo "> *********************************************************"
@echo "> * Continuing ui building..."
-@@ -656,7 +671,6 @@
+@@ -656,7 +687,6 @@
@echo "> *********************************************************"
@echo "> * Building angelwrap"
@echo "> *********************************************************"
@@ -165,7 +201,7 @@ g) address parallel make issues
$(ANGELSCRIPT_INC)/angelscript.h:
@echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
@echo "!!!"
-@@ -668,7 +682,7 @@
+@@ -668,7 +698,7 @@
$(ANGELSCRIPT_LIB): $(ANGELSCRIPT_INC)/angelscript.h
@echo "> * Building Angelscript library first"
@@ -174,7 +210,7 @@ g) address parallel make issues
@echo "> * Done building angelscript library."
@echo "> *********************************************************"
@echo "> * Continuing angelwrap building..."
-@@ -702,69 +716,69 @@
+@@ -702,69 +732,69 @@
# DED
########
$(BINDIR)/$(SERVER_EXE): $(OBJS_DED)
@@ -268,7 +304,7 @@ g) address parallel make issues
######################################################################################################
# Meta Rules
-@@ -776,229 +790,229 @@
+@@ -776,229 +806,229 @@
# CLIENT
########
$(BUILDDIR)/client/%.o: qcommon/%.c
diff --git a/games-fps/warsow/warsow-1.02-r1.ebuild b/games-fps/warsow/warsow-1.02-r1.ebuild
new file mode 100644
index 000000000000..ee1adca6affd
--- /dev/null
+++ b/games-fps/warsow/warsow-1.02-r1.ebuild
@@ -0,0 +1,179 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/games-fps/warsow/warsow-1.02-r1.ebuild,v 1.1 2013/01/18 19:08:09 hasufell Exp $
+
+EAPI=4
+inherit eutils check-reqs gnome2-utils games
+
+MY_P=${PN}_${PV}
+DESCRIPTION="Multiplayer FPS based on the QFusion engine (evolved from Quake 2)"
+HOMEPAGE="http://www.warsow.net/"
+SRC_URI="http://funpark.warsow-esport.net/~${PN}/1.0/${PN}_1.0_unified.tar.gz
+ http://funpark.warsow-esport.net/~${PN}/${PV}/${MY_P}_sdk.tar.gz
+ http://funpark.warsow-esport.net/~${PN}/${PV}/${MY_P}_update.zip
+ mirror://gentoo/${PN}.png"
+
+LICENSE="GPL-2 warsow"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="+angelscript debug dedicated irc openal server"
+
+RDEPEND=">=dev-libs/libRocket-1.2.1_p20130110
+ media-libs/freetype
+ net-misc/curl
+ sys-libs/zlib
+ !dedicated? (
+ media-libs/libpng:0
+ media-libs/libsdl
+ media-libs/libtheora
+ media-libs/libvorbis
+ x11-libs/libX11
+ x11-libs/libXinerama
+ x11-libs/libXrandr
+ x11-libs/libXxf86dga
+ x11-libs/libXxf86vm
+ virtual/jpeg
+ virtual/opengl
+ openal? ( media-libs/openal )
+ )"
+DEPEND="${RDEPEND}
+ app-arch/unzip
+ x11-misc/makedepend
+ !dedicated? (
+ x11-proto/xineramaproto
+ x11-proto/xf86dgaproto
+ x11-proto/xf86vidmodeproto
+ )
+ openal? ( virtual/pkgconfig )"
+
+S=${WORKDIR}/${MY_P}_sdk/source
+S_U=${WORKDIR}/${PN}_1.0
+S_UPDATE=${WORKDIR}/${MY_P}_update
+
+CHECKREQS_DISK_BUILD="1G"
+CHECKREQS_DISK_USR="500M"
+
+src_unpack() {
+ unpack ${PN}_1.0_unified.tar.gz ${MY_P}_sdk.tar.gz
+ mkdir "${S_UPDATE}" || die
+ cd "${S_UPDATE}" || die
+ unpack ${MY_P}_update.zip
+}
+
+src_prepare() {
+ sed -i \
+ -e "/fs_basepath =/ s:\.:${GAMES_DATADIR}/${PN}:" \
+ qcommon/files.c \
+ || die "sed files.c failed"
+
+ sed -i \
+ -e "s:q_jpeg_mem_src:_&:" \
+ ref_gl/r_image.c || die "sed r_image.c failed"
+
+ rm -r "${S_U}"/docs/old* || die
+
+ cd "${WORKDIR}"/${MY_P}_sdk || die
+ epatch "${FILESDIR}"/${P}-build.patch \
+ "${FILESDIR}"/${P}-pic.patch
+ epatch_user
+}
+
+src_compile() {
+ yesno() { use ${1} && echo YES || echo NO ; }
+
+ use angelscript &&
+ emake -C ../libsrcs/angelscript/angelSVN/sdk/angelscript/projects/gnuc
+
+ local arch
+ if use amd64 ; then
+ arch=x86_64
+ elif use x86 ; then
+ arch=i386
+ fi
+
+ local myconf
+ if use dedicated ; then
+ myconf=(
+ BUILD_CLIENT=NO
+ BUILD_IRC=NO
+ BUILD_SND_OPENAL=NO
+ BUILD_SND_QF=NO
+ BUILD_CIN=NO
+ BUILD_SERVER=YES
+ BUILD_TV_SERVER=YES
+ )
+ else
+ myconf=(
+ BUILD_CLIENT=YES
+ BUILD_IRC=$(yesno irc)
+ BUILD_SND_OPENAL=$(yesno openal)
+ BUILD_SND_QF=YES
+ BUILD_CIN=YES
+ BUILD_SERVER=$(yesno server)
+ BUILD_TV_SERVER=$(yesno server)
+ )
+ fi
+
+ emake \
+ V=YES \
+ SYSTEM_LIBS=YES \
+ BASE_ARCH=${arch} \
+ BINDIR=lib \
+ BUILD_ANGELWRAP=$(yesno angelscript) \
+ DEBUG_BUILD=$(yesno debug) \
+ ${myconf[@]}
+}
+
+src_install() {
+ cd lib
+
+ if ! use dedicated ; then
+ newgamesbin ${PN}.* ${PN}
+ doicon -s 48 "${DISTDIR}"/${PN}.png
+ make_desktop_entry ${PN} Warsow
+ fi
+
+ if use dedicated || use server ; then
+ newgamesbin wsw_server.* ${PN}-ded
+ newgamesbin wswtv_server.* ${PN}-tv
+ fi
+
+ exeinto "$(games_get_libdir)"/${PN}
+ doexe */*.so
+
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r "${S_U}"/basewsw
+ doins -r "${S_UPDATE}"/basewsw
+
+ local so
+ for so in basewsw/*.so ; do
+ dosym "$(games_get_libdir)"/${PN}/${so##*/} \
+ "${GAMES_DATADIR}"/${PN}/${so}
+ done
+
+ if [[ -e libs ]] ; then
+ dodir "${GAMES_DATADIR}"/${PN}/libs
+ for so in libs/*.so ; do
+ dosym "$(games_get_libdir)"/${PN}/${so##*/} \
+ "${GAMES_DATADIR}"/${PN}/${so}
+ done
+ fi
+
+ dodoc "${S_U}"/docs/*
+ dodoc "${S_UPDATE}"/docs/*
+ prepgamesdirs
+}
+
+pkg_preinst() {
+ games_pkg_preinst
+ gnome2_icon_savelist
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+ gnome2_icon_cache_update
+}
+
+pkg_postrm() {
+ gnome2_icon_cache_update
+}