summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--games-strategy/spring/files/gcc.patch11
-rw-r--r--games-strategy/spring/files/no_gml.patch13
-rw-r--r--games-strategy/spring/files/no_headless.patch10
-rw-r--r--games-strategy/spring/files/spring.pngbin0 -> 139208 bytes
-rw-r--r--games-strategy/spring/spring-0.82.7.1-r1.ebuild96
5 files changed, 130 insertions, 0 deletions
diff --git a/games-strategy/spring/files/gcc.patch b/games-strategy/spring/files/gcc.patch
new file mode 100644
index 0000000..fa20686
--- /dev/null
+++ b/games-strategy/spring/files/gcc.patch
@@ -0,0 +1,11 @@
+diff -Naur spring_original/rts/lib/lobby/Connection.h spring_patched/rts/lib/lobby/Connection.h
+--- spring_original/rts/lib/lobby/Connection.h 2010-10-15 23:08:24.000000000 +0300
++++ spring_patched/rts/lib/lobby/Connection.h 2010-12-13 00:06:25.000000000 +0200
+@@ -7,6 +7,7 @@
+ #include <boost/asio/deadline_timer.hpp>
+ #include <boost/asio/ip/tcp.hpp>
+ #include <string>
++#include <list>
+
+ struct ClientStatus
+ {
diff --git a/games-strategy/spring/files/no_gml.patch b/games-strategy/spring/files/no_gml.patch
new file mode 100644
index 0000000..15dbf3f
--- /dev/null
+++ b/games-strategy/spring/files/no_gml.patch
@@ -0,0 +1,13 @@
+diff --git a/rts/builds/CMakeLists.txt b/rts/builds/CMakeLists.txt
+index ef85210..c830d9a 100644
+--- a/rts/builds/CMakeLists.txt
++++ b/rts/builds/CMakeLists.txt
+@@ -34,7 +34,7 @@ endmacro (CreateEngineBuildInstallTarget targetName)
+
+ if (NOT HEADLESS_SYSTEM)
+ Add_Subdirectory(default)
+- Add_Subdirectory(GML)
++ #Add_Subdirectory(GML)
+ endif (NOT HEADLESS_SYSTEM)
+
+ Add_Subdirectory(DS)
diff --git a/games-strategy/spring/files/no_headless.patch b/games-strategy/spring/files/no_headless.patch
new file mode 100644
index 0000000..002ac13
--- /dev/null
+++ b/games-strategy/spring/files/no_headless.patch
@@ -0,0 +1,10 @@
+diff --git a/rts/builds/CMakeLists.txt b/rts/builds/CMakeLists.txt
+index ef85210..05d51cc 100644
+--- a/rts/builds/CMakeLists.txt
++++ b/rts/builds/CMakeLists.txt
+@@ -38,4 +38,4 @@ if (NOT HEADLESS_SYSTEM)
+ endif (NOT HEADLESS_SYSTEM)
+
+ Add_Subdirectory(DS)
+-Add_Subdirectory(HL)
++#Add_Subdirectory(HL)
diff --git a/games-strategy/spring/files/spring.png b/games-strategy/spring/files/spring.png
new file mode 100644
index 0000000..0e75470
--- /dev/null
+++ b/games-strategy/spring/files/spring.png
Binary files differ
diff --git a/games-strategy/spring/spring-0.82.7.1-r1.ebuild b/games-strategy/spring/spring-0.82.7.1-r1.ebuild
new file mode 100644
index 0000000..6704e0c
--- /dev/null
+++ b/games-strategy/spring/spring-0.82.7.1-r1.ebuild
@@ -0,0 +1,96 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI=2
+
+inherit cmake-utils eutils fdo-mime flag-o-matic games
+
+DESCRIPTION="a 3D multiplayer real time strategy game engine"
+HOMEPAGE="http://springrts.com"
+SRC_URI="mirror://sourceforge/springrts/${PF/-/_}_src.tar.lzma"
+S="${WORKDIR}/${PF/-/_}"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~x86 ~amd64"
+IUSE="debug java custom-cflags gml headless"
+RESTRICT="nomirror"
+
+RDEPEND="
+ >=dev-libs/boost-1.35
+ media-libs/devil[jpeg,png,opengl]
+ >=media-libs/freetype-2.0.0
+ >=media-libs/glew-1.4
+ >=media-libs/libsdl-1.2.0[X,opengl]
+ media-libs/openal
+ sys-libs/zlib
+ virtual/glu
+ virtual/opengl
+ java? ( virtual/jdk )
+"
+
+DEPEND="${RDEPEND}
+ >=sys-devel/gcc-4.1
+ app-arch/p7zip
+ >=dev-util/cmake-2.6.0
+"
+### gcc 4.4 dependency is bad, but 4.3 causes desync problems
+
+### where to place content files which change each spring release (as opposed to mods, ota-content which go somewhere else)
+VERSION_DATADIR="${GAMES_DATADIR}/${PN}"
+
+src_prepare() {
+ if ! use gml ; then
+ epatch "${FILESDIR}/no_gml.patch"
+ fi
+
+
+ if ! use headless ; then
+ epatch "${FILESDIR}/no_headless.patch"
+ fi
+ cd AI/Skirmish
+ git clone git://github.com/Tarendai/Shard.git
+ cd ../..
+}
+
+src_configure() {
+ if ! use custom-cflags ; then
+ strip-flags
+ else
+ mycmakeargs="${mycmakeargs} -DMARCH_FLAG=$(get-flag march)"
+ fi
+
+ if ! use java ; then
+ mycmakeargs="${mycmakeargs} -DAIINTERFACES=NATIVE"
+ fi
+
+ LIBDIR="$(games_get_libdir)"
+ mycmakeargs="${mycmakeargs} -DCMAKE_INSTALL_PREFIX=/usr -DBINDIR=${GAMES_BINDIR#/usr/} -DLIBDIR=${LIBDIR#/usr/} -DDATADIR=${VERSION_DATADIR#/usr/}"
+ if use debug ; then
+ CMAKE_BUILD_TYPE="DEBUG"
+ else
+ CMAKE_BUILD_TYPE="RELEASE"
+ fi
+
+ cmake-utils_src_configure
+}
+
+src_compile () {
+ cmake-utils_src_compile
+}
+
+src_install () {
+ cmake-utils_src_install
+
+ prepgamesdirs
+
+ if use custom-cflags ; then
+ ewarn "You decided to use custom CFLAGS. This may be save, or it may cause your computer to desync more or less often. If you experience desyncs, disable it before doing any bugreport. If you don't know what you are doing, *disable custom-cflags*."
+ fi
+}
+
+pkg_postinst() {
+ fdo-mime_mime_database_update
+ games_pkg_postinst
+}