Import games/odamex.
``` Odamex is a free, cross-platform modification of the Doom engine that allows players to easily join servers dedicated to playing Doom online. ``` OK solene@, thanks!
This commit is contained in:
parent
0755fdadb0
commit
52eafd1fa2
53
games/odamex/Makefile
Normal file
53
games/odamex/Makefile
Normal file
@ -0,0 +1,53 @@
|
||||
# $OpenBSD: Makefile,v 1.1.1.1 2020/10/05 21:07:37 edd Exp $
|
||||
|
||||
COMMENT = online multiplayer doom
|
||||
|
||||
V = 0.8.3
|
||||
DISTNAME = odamex-src-${V}
|
||||
PKGNAME = odamex-${V}
|
||||
|
||||
CATEGORIES = games
|
||||
HOMEPAGE = https://odamex.net/
|
||||
MAINTAINER = Edd Barrett <edd@openbsd.org>
|
||||
|
||||
# GPLv2
|
||||
PERMIT_PACKAGE = Yes
|
||||
|
||||
WANTLIB += ${COMPILER_LIBCXX} ICE SDL2 SDL2_mixer SM X11 Xext
|
||||
WANTLIB += c execinfo m miniupnpc png portmidi wx_baseu-3.0 wx_baseu_net-3.0
|
||||
WANTLIB += wx_baseu_xml-3.0 wx_gtk3u_adv-3.0 wx_gtk3u_core-3.0
|
||||
WANTLIB += wx_gtk3u_html-3.0 wx_gtk3u_qa-3.0 wx_gtk3u_xrc-3.0
|
||||
WANTLIB += z
|
||||
|
||||
MASTER_SITES = ${MASTER_SITE_SOURCEFORGE:=odamex/}
|
||||
EXTRACT_SUFX = .tar.bz2
|
||||
|
||||
COMPILER = base-clang ports-gcc base-gcc
|
||||
|
||||
MODULES = devel/cmake
|
||||
|
||||
CONFIGURE_ARGS += -DCMAKE_CXX_FLAGS=-I${LOCALBASE}/include
|
||||
|
||||
LIB_DEPENDS = devel/libexecinfo \
|
||||
x11/wxWidgets \
|
||||
audio/portmidi \
|
||||
graphics/png \
|
||||
devel/sdl2-mixer \
|
||||
net/miniupnp/miniupnpc
|
||||
|
||||
NO_TEST = Yes
|
||||
|
||||
pre-build:
|
||||
${SUBST_CMD} ${WRKSRC}/CMakeLists.txt
|
||||
${SUBST_CMD} ${WRKSRC}/server/CMakeLists.txt
|
||||
|
||||
EXAMPLES_DIR = ${PREFIX}/share/examples/odamex
|
||||
post-install:
|
||||
mv ${PREFIX}/share/odamex/config-samples ${EXAMPLES_DIR}
|
||||
chown -r ${shareown}:${sharegrp} ${EXAMPLES_DIR}
|
||||
|
||||
# Fix MS-DOS line endings.
|
||||
pre-patch:
|
||||
@cd ${WRKSRC} && perl -i -pe 's/\r$$//' CMakeLists.txt
|
||||
|
||||
.include <bsd.port.mk>
|
2
games/odamex/distinfo
Normal file
2
games/odamex/distinfo
Normal file
@ -0,0 +1,2 @@
|
||||
SHA256 (odamex-src-0.8.3.tar.bz2) = 3M/SMwPXQlCLvs8SQIpVVTkGc5GSzfPy1tXi8HWP+eY=
|
||||
SIZE (odamex-src-0.8.3.tar.bz2) = 8532510
|
34
games/odamex/patches/patch-CMakeLists_txt
Normal file
34
games/odamex/patches/patch-CMakeLists_txt
Normal file
@ -0,0 +1,34 @@
|
||||
$OpenBSD: patch-CMakeLists_txt,v 1.1.1.1 2020/10/05 21:07:37 edd Exp $
|
||||
|
||||
INSTALL_PREFIX needs to be set to find executables and wads.
|
||||
|
||||
Don't use the bundled miniupnpc.
|
||||
|
||||
Index: CMakeLists.txt
|
||||
--- CMakeLists.txt.orig
|
||||
+++ CMakeLists.txt
|
||||
@@ -10,6 +10,7 @@ set(CMAKE_INSTALL_BINDIR "bin")
|
||||
set(CMAKE_INSTALL_DATADIR "share")
|
||||
include(GNUInstallDirs OPTIONAL)
|
||||
|
||||
+add_definitions(-DINSTALL_PREFIX="${PREFIX}")
|
||||
add_definitions(-DINSTALL_BINDIR="${CMAKE_INSTALL_BINDIR}")
|
||||
add_definitions(-DINSTALL_DATADIR="${CMAKE_INSTALL_DATADIR}")
|
||||
|
||||
@@ -149,16 +150,6 @@ set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/module
|
||||
# git describe
|
||||
include(GetGitRevisionDescription)
|
||||
git_describe(GIT_DESCRIBE --tags --always)
|
||||
-
|
||||
-# MiniUPnPc
|
||||
-if (USE_MINIUPNP)
|
||||
- set(UPNPC_BUILD_STATIC ON CACHE INTERNAL "" FORCE)
|
||||
- set(UPNPC_BUILD_SHARED OFF CACHE INTERNAL "" FORCE)
|
||||
- set(UPNPC_BUILD_TESTS OFF CACHE INTERNAL "" FORCE)
|
||||
- set(UPNPC_INSTALL OFF CACHE INTERNAL "" FORCE)
|
||||
- mark_as_advanced(FORCE UPNPC_INSTALL)
|
||||
- add_subdirectory(libraries/libminiupnpc)
|
||||
-endif()
|
||||
|
||||
# Subdirectories for Odamex projects
|
||||
if(BUILD_CLIENT)
|
14
games/odamex/patches/patch-client_CMakeLists_txt
Normal file
14
games/odamex/patches/patch-client_CMakeLists_txt
Normal file
@ -0,0 +1,14 @@
|
||||
$OpenBSD: patch-client_CMakeLists_txt,v 1.1.1.1 2020/10/05 21:07:37 edd Exp $
|
||||
|
||||
Index: client/CMakeLists.txt
|
||||
--- client/CMakeLists.txt.orig
|
||||
+++ client/CMakeLists.txt
|
||||
@@ -234,7 +234,7 @@ if(SDL_VERSION)
|
||||
endif()
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
- target_link_libraries(odamex rt)
|
||||
+ target_link_libraries(odamex execinfo)
|
||||
if(X11_FOUND)
|
||||
target_link_libraries(odamex X11)
|
||||
endif()
|
15
games/odamex/patches/patch-odalpapi_net_io_cpp
Normal file
15
games/odamex/patches/patch-odalpapi_net_io_cpp
Normal file
@ -0,0 +1,15 @@
|
||||
$OpenBSD: patch-odalpapi_net_io_cpp,v 1.1.1.1 2020/10/05 21:07:37 edd Exp $
|
||||
|
||||
AI_ALL isn't defined on OpenBSD.
|
||||
|
||||
Index: odalpapi/net_io.cpp
|
||||
--- odalpapi/net_io.cpp.orig
|
||||
+++ odalpapi/net_io.cpp
|
||||
@@ -182,7 +182,6 @@ void BufferedSocket::SetRemoteAddress(const string& Ad
|
||||
addrinfo* result = NULL;
|
||||
|
||||
memset(&hints, 0, sizeof(struct addrinfo));
|
||||
- hints.ai_flags = AI_ALL;
|
||||
hints.ai_family = PF_INET;
|
||||
|
||||
if((getaddrinfo(Address.c_str(), NULL, &hints, &result)) != 0)
|
56
games/odamex/patches/patch-server_CMakeLists_txt
Normal file
56
games/odamex/patches/patch-server_CMakeLists_txt
Normal file
@ -0,0 +1,56 @@
|
||||
$OpenBSD: patch-server_CMakeLists_txt,v 1.1.1.1 2020/10/05 21:07:37 edd Exp $
|
||||
|
||||
Don't use the bundled miniupnpc.
|
||||
|
||||
Index: server/CMakeLists.txt
|
||||
--- server/CMakeLists.txt.orig
|
||||
+++ server/CMakeLists.txt
|
||||
@@ -33,12 +33,6 @@ set(JSONCPP_DIR ../libraries/jsoncpp)
|
||||
file(GLOB JSONCPP_HEADERS ${JSONCPP_DIR}/json/*.h)
|
||||
set(JSONCPP_SOURCE ${JSONCPP_DIR}/jsoncpp.cpp)
|
||||
|
||||
-# MiniUPnPc
|
||||
-if (USE_MINIUPNP)
|
||||
- set(MINIUPNPC_DIR ../libraries/libminiupnpc)
|
||||
- set(MINIUPNPC_STATIC_LIBRARIES upnpc-static)
|
||||
-endif()
|
||||
-
|
||||
# git describe
|
||||
set_source_files_properties(${COMMON_DIR}/version.cpp PROPERTIES COMPILE_FLAGS -DGIT_DESCRIBE=\\"${GIT_DESCRIBE}\\")
|
||||
|
||||
@@ -59,7 +53,7 @@ include_directories(${JSONCPP_DIR} ${COMMON_DIR} ${SER
|
||||
|
||||
# Include miniupnpc if we want it
|
||||
if (USE_MINIUPNP)
|
||||
- include_directories(${MINIUPNPC_DIR})
|
||||
+ include_directories(${LOCALBASE}/include/miniupnpc)
|
||||
endif()
|
||||
|
||||
# Set up FHS installation path
|
||||
@@ -67,6 +61,8 @@ if(NOT APPLE AND NOT WIN32)
|
||||
add_definitions(-DINSTALL_PREFIX="${CMAKE_INSTALL_PREFIX}")
|
||||
endif()
|
||||
|
||||
+link_directories(${LOCALBASE}/lib)
|
||||
+
|
||||
add_executable(odasrv
|
||||
${JSONCPP_SOURCE} ${JSONCPP_HEADERS}
|
||||
${COMMON_SOURCES} ${COMMON_HEADERS}
|
||||
@@ -74,7 +70,7 @@ add_executable(odasrv
|
||||
${SERVER_WIN32_HEADERS} ${SERVER_WIN32_RESOURCES})
|
||||
|
||||
if (USE_MINIUPNP)
|
||||
- target_link_libraries(odasrv ${MINIUPNPC_STATIC_LIBRARIES})
|
||||
+ target_link_libraries(odasrv miniupnpc)
|
||||
endif()
|
||||
|
||||
if(WIN32)
|
||||
@@ -87,7 +83,7 @@ elseif(UNIX)
|
||||
endif()
|
||||
|
||||
if(UNIX AND NOT APPLE)
|
||||
- target_link_libraries(odasrv rt)
|
||||
+ target_link_libraries(odasrv execinfo)
|
||||
endif()
|
||||
|
||||
if(APPLE)
|
2
games/odamex/pkg/DESCR
Normal file
2
games/odamex/pkg/DESCR
Normal file
@ -0,0 +1,2 @@
|
||||
Odamex is a free, cross-platform modification of the Doom engine that allows
|
||||
players to easily join servers dedicated to playing Doom online.
|
29
games/odamex/pkg/PLIST
Normal file
29
games/odamex/pkg/PLIST
Normal file
@ -0,0 +1,29 @@
|
||||
@comment $OpenBSD: PLIST,v 1.1.1.1 2020/10/05 21:07:37 edd Exp $
|
||||
@bin bin/odalaunch
|
||||
@bin bin/odamast
|
||||
@bin bin/odamex
|
||||
@bin bin/odasrv
|
||||
share/doc/pkg-readmes/${PKGSTEM}
|
||||
share/examples/odamex/
|
||||
share/examples/odamex/coop-doom.cfg
|
||||
share/examples/odamex/coop-masterlevels.cfg
|
||||
share/examples/odamex/coop-modern.cfg
|
||||
share/examples/odamex/coop-zdoom.cfg
|
||||
share/examples/odamex/ctf-doom.cfg
|
||||
share/examples/odamex/ctf-pub.cfg
|
||||
share/examples/odamex/ctf-wdl.cfg
|
||||
share/examples/odamex/dm-doom.cfg
|
||||
share/examples/odamex/dm-modern.cfg
|
||||
share/examples/odamex/dm-zdoom.cfg
|
||||
share/examples/odamex/duel-altdeath.cfg
|
||||
share/examples/odamex/duel-ddl.cfg
|
||||
share/examples/odamex/duel-doom.cfg
|
||||
share/examples/odamex/duel-zddl.cfg
|
||||
share/examples/odamex/duel-zdoom.cfg
|
||||
share/examples/odamex/tdm-doom.cfg
|
||||
share/examples/odamex/tdm-modern.cfg
|
||||
share/examples/odamex/tdm-zdoom.cfg
|
||||
share/odamex/
|
||||
@comment share/odamex/LICENSE
|
||||
@comment share/odamex/README
|
||||
share/odamex/odamex.wad
|
10
games/odamex/pkg/README
Normal file
10
games/odamex/pkg/README
Normal file
@ -0,0 +1,10 @@
|
||||
$OpenBSD: README,v 1.1.1.1 2020/10/05 21:07:37 edd Exp $
|
||||
|
||||
+-------------------------------------------------------------------------------
|
||||
| Running ${PKGSTEM} on OpenBSD
|
||||
+-------------------------------------------------------------------------------
|
||||
|
||||
To use odamex you will need to put WAD files in ${PREFIX}/share/doom.
|
||||
|
||||
Alternatively you can run odamex from within a directory containing WADs, or
|
||||
you can specify a path using DOOMWADDIR or DOOMWADPATH in your environment.
|
Loading…
x
Reference in New Issue
Block a user