aboutsummaryrefslogtreecommitdiff
path: root/games
diff options
context:
space:
mode:
authorDmitry Marakasov <amdmi3@FreeBSD.org>2014-08-05 00:18:17 +0000
committerDmitry Marakasov <amdmi3@FreeBSD.org>2014-08-05 00:18:17 +0000
commit4ed90952f0eb006100c14e7232c857499778961a (patch)
tree20164041d68e70c76fb2114f4a3ffa3f72fa436f /games
parentaf05658457b4e7d5cd06cb89e3b3caeed0c796eb (diff)
downloadports-4ed90952f0eb006100c14e7232c857499778961a.tar.gz
ports-4ed90952f0eb006100c14e7232c857499778961a.zip
Notes
Diffstat (limited to 'games')
-rw-r--r--games/Makefile1
-rw-r--r--games/openspades/Makefile52
-rw-r--r--games/openspades/distinfo4
-rw-r--r--games/openspades/files/patch-CMakeLists.txt8
-rw-r--r--games/openspades/files/patch-Sources__CMakeLists.txt15
-rw-r--r--games/openspades/files/patch-Sources__Core__ConcurrentDispatch.cpp20
-rw-r--r--games/openspades/files/patch-Sources__Draw__SWFeatureLevel.h10
-rw-r--r--games/openspades/pkg-descr7
-rw-r--r--games/openspades/pkg-plist32
9 files changed, 149 insertions, 0 deletions
diff --git a/games/Makefile b/games/Makefile
index c43db0b7af3e..0254267848fc 100644
--- a/games/Makefile
+++ b/games/Makefile
@@ -681,6 +681,7 @@
SUBDIR += openpref
SUBDIR += opensfx
SUBDIR += opensonic
+ SUBDIR += openspades
SUBDIR += openssn
SUBDIR += opensurge
SUBDIR += openttd
diff --git a/games/openspades/Makefile b/games/openspades/Makefile
new file mode 100644
index 000000000000..bbfe8fdbd51f
--- /dev/null
+++ b/games/openspades/Makefile
@@ -0,0 +1,52 @@
+# Created by: Dmitry Marakasov <amdmi3@FreeBSD.org>
+# $FreeBSD$
+
+PORTNAME= openspades
+PORTVERSION= 0.0.12
+CATEGORIES= games
+MASTER_SITES= http://yvt.jp/files/programs/osppaks/:data
+DISTFILES= ${DISTNAME}${EXTRACT_SUFX} DevPaks27.zip:data
+
+MAINTAINER= amdmi3@FreeBSD.org
+COMMENT= Compatible client of Ace of Spades
+
+LICENSE= GPLv3
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+BUILD_DEPENDS= convert:${PORTSDIR}/graphics/ImageMagick # for building icons
+LIB_DEPENDS= libcurl.so:${PORTSDIR}/ftp/curl \
+ libGLEW.so:${PORTSDIR}/graphics/glew
+
+USE_GITHUB= yes
+GH_ACCOUNT= yvt
+GH_TAGNAME= v${PORTVERSION}
+GH_COMMIT= 6a310d8
+
+USES= compiler:c++11-lib cmake desktop-file-utils
+CMAKE_ARGS= -DOPENSPADES_RESOURCES=OFF \
+ -DOPENSPADES_INSTALL_MAN="man/man6" \
+ -DOPENSPADES_INSTALL_BINARY="bin" \
+ -DOPENSPADES_INSTALL_RESOURCES="${DATADIR_REL}"
+USE_SDL= sdl2 image2
+USE_GL= gl
+INSTALLS_ICONS= yes
+
+PORTDOCS= *
+PORTDATA= *
+
+OPTIONS_DEFINE= DOCS
+
+.include <bsd.port.pre.mk>
+
+.if ${OSVERSION} < 1000000
+BROKEN= doesn't build on pre-10.x
+.endif
+
+post-extract:
+ @${MKDIR} ${WRKSRC}/Resources/DevPak
+ @${MV} ${WRKDIR}/*.pak ${WRKSRC}/Resources/DevPak/
+
+post-patch:
+ @${REINPLACE_CMD} -e 's|Xext|${LOCALBASE}/lib/lib&.so|' ${WRKSRC}/Sources/CMakeLists.txt
+
+.include <bsd.port.post.mk>
diff --git a/games/openspades/distinfo b/games/openspades/distinfo
new file mode 100644
index 000000000000..3f2d03861086
--- /dev/null
+++ b/games/openspades/distinfo
@@ -0,0 +1,4 @@
+SHA256 (openspades-0.0.12.tar.gz) = fdd4becc27f5f75b8796a9392c965924b6f1b2822b7314107aaa63743c731072
+SIZE (openspades-0.0.12.tar.gz) = 1984663
+SHA256 (DevPaks27.zip) = 668b62d3770f407447e6f45df28928f66a7fe3440c541788f66583f31ae5c717
+SIZE (DevPaks27.zip) = 19597524
diff --git a/games/openspades/files/patch-CMakeLists.txt b/games/openspades/files/patch-CMakeLists.txt
new file mode 100644
index 000000000000..9370b7769f15
--- /dev/null
+++ b/games/openspades/files/patch-CMakeLists.txt
@@ -0,0 +1,8 @@
+--- CMakeLists.txt.orig 2014-06-23 15:55:03.000000000 +0400
++++ CMakeLists.txt 2014-07-30 23:27:27.655286901 +0400
+@@ -1,5 +1,4 @@
+ cmake_minimum_required(VERSION 2.8)
+-set(CMAKE_INSTALL_PREFIX "/usr/local")
+ project(OpenSpades)
+
+ set(OpenSpades_VERSION_MAJOR 0)
diff --git a/games/openspades/files/patch-Sources__CMakeLists.txt b/games/openspades/files/patch-Sources__CMakeLists.txt
new file mode 100644
index 000000000000..ec1023ccd2ac
--- /dev/null
+++ b/games/openspades/files/patch-Sources__CMakeLists.txt
@@ -0,0 +1,15 @@
+--- Sources/CMakeLists.txt.orig 2014-06-23 15:55:03.000000000 +0400
++++ Sources/CMakeLists.txt 2014-07-30 23:09:36.981184077 +0400
+@@ -24,9 +24,9 @@
+ add_subdirectory(AngelScript/projects/cmake_addons)
+ set(ANGELSCRIPT_LIBS Angelscript Angelscript_addons)
+
+-include_directories(".")
+-include_directories("json/include")
+-include_directories("ENet/include")
++include_directories(BEFORE ".")
++include_directories(BEFORE "json/include")
++include_directories(BEFORE "ENet/include")
+
+ if(WIN32)
+ if(MINGW) # = gcc, can someone confirm that this works?
diff --git a/games/openspades/files/patch-Sources__Core__ConcurrentDispatch.cpp b/games/openspades/files/patch-Sources__Core__ConcurrentDispatch.cpp
new file mode 100644
index 000000000000..7b40b64c4a48
--- /dev/null
+++ b/games/openspades/files/patch-Sources__Core__ConcurrentDispatch.cpp
@@ -0,0 +1,20 @@
+--- Sources/Core/ConcurrentDispatch.cpp.orig 2014-06-23 15:55:03.000000000 +0400
++++ Sources/Core/ConcurrentDispatch.cpp 2014-07-30 23:05:09.324201495 +0400
+@@ -38,7 +38,7 @@
+ #ifndef _MSC_VER
+ #include <unistd.h>
+ #endif
+-#if defined(__GNUC__)
++#if defined(__linux__)
+ #include <sys/sysinfo.h>
+ #endif
+ #endif
+@@ -67,7 +67,7 @@
+ if(count < 1) { count = 1; }
+ }
+ return count;
+-#elif defined(__GNUC__)
++#elif defined(__linux__)
+ return get_nprocs();
+ #else
+ return sysconf(_SC_NPROCESSORS_ONLN);
diff --git a/games/openspades/files/patch-Sources__Draw__SWFeatureLevel.h b/games/openspades/files/patch-Sources__Draw__SWFeatureLevel.h
new file mode 100644
index 000000000000..945062da9b71
--- /dev/null
+++ b/games/openspades/files/patch-Sources__Draw__SWFeatureLevel.h
@@ -0,0 +1,10 @@
+--- Sources/Draw/SWFeatureLevel.h.orig 2014-06-23 15:55:03.000000000 +0400
++++ Sources/Draw/SWFeatureLevel.h 2014-07-31 00:18:47.036897321 +0400
+@@ -55,6 +55,7 @@
+ #endif
+
+ #include <algorithm>
++#include <cmath>
+ #include <Core/ConcurrentDispatch.h>
+ #include <Core/Debug.h>
+
diff --git a/games/openspades/pkg-descr b/games/openspades/pkg-descr
new file mode 100644
index 000000000000..f704e74b2cd7
--- /dev/null
+++ b/games/openspades/pkg-descr
@@ -0,0 +1,7 @@
+OpenSpades is a compatible client of Ace of Spades 0.75.
+
+* Can connect to a vanilla/pyspades/pysnip server.
+* Uses OpenGL/AL for better visuals.
+* Open source, and cross platform.
+
+WWW: http://www.openspades.org/
diff --git a/games/openspades/pkg-plist b/games/openspades/pkg-plist
new file mode 100644
index 000000000000..b875fa702206
--- /dev/null
+++ b/games/openspades/pkg-plist
@@ -0,0 +1,32 @@
+bin/openspades
+man/man6/openspades.6.gz
+share/applications/openspades.desktop
+share/icons/hicolor/128x128/apps/openspades.png
+share/icons/hicolor/16x16/apps/openspades.png
+share/icons/hicolor/24x24/apps/openspades.png
+share/icons/hicolor/256x256/apps/openspades.png
+share/icons/hicolor/32x32/apps/openspades.png
+share/icons/hicolor/48x48/apps/openspades.png
+share/icons/hicolor/64x64/apps/openspades.png
+share/icons/hicolor/96x96/apps/openspades.png
+share/menu/openspades
+share/pixmaps/openspades.xpm
+@dirrmtry share/icons/hicolor/128x128/apps
+@dirrmtry share/icons/hicolor/128x128
+@dirrmtry share/icons/hicolor/16x16/apps
+@dirrmtry share/icons/hicolor/16x16
+@dirrmtry share/icons/hicolor/24x24/apps
+@dirrmtry share/icons/hicolor/24x24
+@dirrmtry share/icons/hicolor/256x256/apps
+@dirrmtry share/icons/hicolor/256x256
+@dirrmtry share/icons/hicolor/32x32/apps
+@dirrmtry share/icons/hicolor/32x32
+@dirrmtry share/icons/hicolor/48x48/apps
+@dirrmtry share/icons/hicolor/48x48
+@dirrmtry share/icons/hicolor/64x64/apps
+@dirrmtry share/icons/hicolor/64x64
+@dirrmtry share/icons/hicolor/96x96/apps
+@dirrmtry share/icons/hicolor/96x96
+@dirrmtry share/icons/hicolor
+@dirrmtry share/icons
+@dirrmtry share/menu