games/colobot: fix build with Python 3 and restore port

This commit is contained in:
Max Brazhnikov 2020-08-21 19:56:36 +00:00
parent d351bbeabd
commit 50bb641c27
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=545621
8 changed files with 3768 additions and 1 deletions

1
MOVED
View file

@ -15266,7 +15266,6 @@ devel/py-yum-metadata-parser||2020-08-15|Has expired: Uses deprecated version of
devel/rubygem-warden127||2020-08-15|Has expired: No longer needed
dns/py-dnschain||2020-08-15|Has expired: Uses deprecated version of python
dns/py-idnkit2||2020-08-15|Has expired: Uses deprecated version of python
games/colobot||2020-08-15|Has expired: Uses deprecated version of python
games/endgame-singularity||2020-08-15|Has expired: Uses deprecated version of python
games/katawa-shoujo||2020-08-15|Has expired: Uses deprecated version of RenPy
games/pyfa||2020-08-15|Has expired: Uses deprecated version of python

View file

@ -145,6 +145,7 @@
SUBDIR += circuslinux
SUBDIR += cockatrice
SUBDIR += coffeebreak
SUBDIR += colobot
SUBDIR += colorcode
SUBDIR += columns
SUBDIR += concentration

54
games/colobot/Makefile Normal file
View file

@ -0,0 +1,54 @@
# $FreeBSD$
PORTNAME= colobot
DISTVERSIONPREFIX= ${PORTNAME}-gold-
DISTVERSION= 0.1.12
DISTVERSIONSUFFIX= -alpha
PORTREVISION= 5
CATEGORIES= games
MASTER_SITES= https://colobot.info/files/music/:music
DISTFILES= colobot-music_ogg_0.1.12-alpha.tar.gz:music
MAINTAINER= makc@FreeBSD.org
COMMENT= Educational game aiming to teach programming to kids
LICENSE= GPLv3
LICENSE_FILE= ${WRKSRC}/LICENSE.txt
LIB_DEPENDS= libpng.so:graphics/png \
libsndfile.so:audio/libsndfile \
libvorbis.so:audio/libvorbis \
libogg.so:audio/libogg \
libopenal.so:audio/openal-soft \
libphysfs.so:devel/physfs \
libboost_system.so:devel/boost-libs
USES= cmake compiler:c++11-lang gl gettext-runtime \
gettext-tools:build localbase:ldflags openal python:build \
sdl shebangfix
USE_SDL= image2 ttf2
USE_GL= gl glew glu
USE_LDCONFIG= yes
USE_GITHUB= yes
GH_TUPLE= colobot:colobot-data:c467bd9:data
LDFLAGS_i386= -Wl,-znotext
SHEBANG_FILES= data/i18n-tools/scripts/process_translations.py
post-extract:
@${MV} ${WRKDIR}/colobot-data-c467bd9/* ${WRKSRC}/data
@${MV} ${WRKDIR}/*.ogg ${WRKDIR}/LICENSE.txt ${WRKSRC}/data/music/
@${REINPLACE_CMD} 's|$${CMAKE_INSTALL_PREFIX}/games|$${CMAKE_INSTALL_PREFIX}/bin|g' ${WRKSRC}/CMakeLists.txt
@${REINPLACE_CMD} 's|PLATFORM_MACOSX|PLATFORM_MACOSX OR PLATFORM_OTHER|g' ${WRKSRC}/src/CMakeLists.txt
post-patch:
@${REINPLACE_CMD} 's|/usr/local|${LOCALBASE}|g' ${WRKSRC}/cmake/FindGLEW.cmake
@${REINPLACE_CMD} 's|/usr/local|${LOCALBASE}|g' ${WRKSRC}/cmake/FindPhysFS.cmake
@${REINPLACE_CMD} 's|/usr/local|${LOCALBASE}|g' ${WRKSRC}/cmake/FindSDL2.cmake
@${REINPLACE_CMD} 's|/usr/local|${LOCALBASE}|g' ${WRKSRC}/cmake/FindSDL2_image.cmake
@${REINPLACE_CMD} 's|/usr/local|${LOCALBASE}|g' ${WRKSRC}/cmake/FindSDL2_ttf.cmake
@${REINPLACE_CMD} 's|/usr/local|${LOCALBASE}|g' ${WRKSRC}/tools/check-levels.sh
${REINPLACE_CMD} 's|python|${PYTHON_CMD}|' ${WRKSRC}/data/tools/*.sh
.include <bsd.port.mk>

7
games/colobot/distinfo Normal file
View file

@ -0,0 +1,7 @@
TIMESTAMP = 1551719919
SHA256 (colobot-music_ogg_0.1.12-alpha.tar.gz) = 55e89d244f1f63e2467ef71253ca881ee31279f02aac9ac4706ef26c466306e9
SIZE (colobot-music_ogg_0.1.12-alpha.tar.gz) = 55596353
SHA256 (colobot-colobot-colobot-gold-0.1.12-alpha_GH0.tar.gz) = 38e01a6fb8c670203b86e7a100c79ed4ab4a9a4dcc01fd26a6a57f40fa1a8b5c
SIZE (colobot-colobot-colobot-gold-0.1.12-alpha_GH0.tar.gz) = 1468594
SHA256 (colobot-colobot-data-c467bd9_GH0.tar.gz) = 4a6a53ea22970870d05a12ebf56f595d34d765a789ab3b0aae618f2747312c35
SIZE (colobot-colobot-data-c467bd9_GH0.tar.gz) = 54728879

View file

@ -0,0 +1,11 @@
--- data/CMakeLists.txt.orig 2019-02-23 19:01:32 UTC
+++ data/CMakeLists.txt
@@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 2.8)
option(TRANSLATIONS "Enable translations of help and level files" ON)
if(TRANSLATIONS)
- find_package(PythonInterp 2.7 REQUIRED)
+ find_package(PythonInterp REQUIRED)
else()
message(STATUS "Translations disabled; only English files will be installed")
endif()

View file

@ -0,0 +1,11 @@
--- src/object/task/taskgoto.h.orig 2019-10-18 08:14:46 UTC
+++ src/object/task/taskgoto.h
@@ -147,7 +147,7 @@ class CTaskGoto : public CForegroundTask (protected)
int m_bmTotal = 0; // number of points in m_bmPoints
int m_bmIndex = 0; // index in m_bmPoints
Math::Vector m_bmPoints[MAXPOINTS+2];
- char m_bmIter[MAXPOINTS+2] = {};
+ signed char m_bmIter[MAXPOINTS+2] = {};
int m_bmIterCounter = 0;
CObject* m_bmCargoObject = nullptr;
float m_bmFinalMove = 0.0f; // final advance distance

11
games/colobot/pkg-descr Normal file
View file

@ -0,0 +1,11 @@
Colobot is an educational real-time strategy video game featuring 3D graphics.
The objective of the game is to find a planet for colonization by the human race
by establishing a basic infrastructure on the surface and eliminating any alien
life forms endangering the expedition
You can program your units (bots) in a language called CBOT, which is
similar to C++ and Java. Your mission is to find a new planet to live and
survive. You can save the humanity and get programming skills!
WWW: https://colobot.info/

3673
games/colobot/pkg-plist Normal file

File diff suppressed because it is too large Load diff