mirror of
https://github.com/yann64/haikuports.git
synced 2026-03-19 01:46:00 +01:00
gltron: new recipe (#8562)
* gltron: new recipe
* gltron: replace config.{guess,sub} patch with autoreconf -fi
This commit is contained in:
77
games-action/gltron/gltron-0.70.recipe
Normal file
77
games-action/gltron/gltron-0.70.recipe
Normal file
@@ -0,0 +1,77 @@
|
||||
SUMMARY="A 3D lightcycle game using OpenGL"
|
||||
DESCRIPTION="gltron was inspired by the film tron - actually, more by all the games that where \
|
||||
inspired by the film tron :-) It's a game for one to four players, the objective is not to drive \
|
||||
into a wall."
|
||||
HOMEPAGE="http://gltron.org/"
|
||||
COPYRIGHT="1999 Andreas Umbach"
|
||||
LICENSE="GNU GPL v2"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://sourceforge.net/projects/gltron/files/gltron-source/$portVersion/gltron-$portVersion-source.tar.gz"
|
||||
CHECKSUM_SHA256="e0c8ebb41a18a1f8d7302a9c2cb466f5b1dd63e9a9966c769075e6b6bdad8bb0"
|
||||
PATCHES="gltron-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="all"
|
||||
|
||||
PROVIDES="
|
||||
gltron = $portVersion
|
||||
app:GLtron
|
||||
"
|
||||
REQUIRES="
|
||||
haiku
|
||||
lib:libgl
|
||||
lib:libmikmod
|
||||
lib:libogg
|
||||
lib:libpng16
|
||||
lib:libSDL_1.2
|
||||
lib:libSDL_net_1.2
|
||||
lib:libSDL_sound_1.0
|
||||
lib:libsmpeg_0.4
|
||||
lib:libvorbis
|
||||
lib:libvorbisfile
|
||||
lib:libz
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku_devel
|
||||
devel:libgl
|
||||
devel:libglu # needed by SDL
|
||||
devel:libmikmod
|
||||
devel:libogg
|
||||
devel:libpng16
|
||||
devel:libSDL_1.2
|
||||
devel:libSDL_net_1.2
|
||||
devel:libSDL_sound_1.0
|
||||
devel:libsmpeg_0.4
|
||||
devel:libvorbis
|
||||
devel:libvorbisfile
|
||||
devel:libz
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:aclocal
|
||||
cmd:autoreconf
|
||||
cmd:gcc
|
||||
cmd:g++
|
||||
cmd:make
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
touch AUTHORS NEWS
|
||||
autoreconf -fi
|
||||
runConfigure --omit-dirs "binDir dataRootDir docDir" ./configure \
|
||||
--bindir=$appsDir \
|
||||
--enable-network \
|
||||
--with-preferences-dir="`finddir B_USER_SETTINGS_DIRECTORY`" \
|
||||
--disable-warn
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install-strip
|
||||
|
||||
mv $appsDir/gltron $appsDir/GLtron
|
||||
|
||||
# TODO: add icon and other resources
|
||||
addAppDeskbarSymlink $appsDir/GLtron
|
||||
}
|
||||
101
games-action/gltron/patches/gltron-0.70.patchset
Normal file
101
games-action/gltron/patches/gltron-0.70.patchset
Normal file
@@ -0,0 +1,101 @@
|
||||
From 35ab8a765c73b70cd09e0af717aba448ae5a258d Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Joachim=20Mairb=C3=B6ck?= <j.mairboeck@gmail.com>
|
||||
Date: Fri, 5 May 2023 17:54:39 +0200
|
||||
Subject: fix build (constness and linking order)
|
||||
|
||||
|
||||
diff --git a/Makefile.am b/Makefile.am
|
||||
index 858c5f7..bc666d6 100644
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -12,13 +12,13 @@ gltron_LDADD = \
|
||||
src/video/libvideo.a \
|
||||
src/configuration/libconfiguration.a \
|
||||
src/base/libbase.a \
|
||||
- src/filesystem/libfilesystem.a \
|
||||
nebu/input/libinput.a \
|
||||
nebu/audio/libaudio.a \
|
||||
nebu/video/libvideo.a \
|
||||
nebu/scripting/libscripting.a \
|
||||
nebu/filesystem/libfilesystem.a \
|
||||
nebu/base/libbase.a \
|
||||
+ src/filesystem/libfilesystem.a \
|
||||
lua/src/liblua.a \
|
||||
lua/src/lib/liblualib.a
|
||||
|
||||
diff --git a/nebu/scripting/scripting.c b/nebu/scripting/scripting.c
|
||||
index e26bc77..0fa39c0 100644
|
||||
--- a/nebu/scripting/scripting.c
|
||||
+++ b/nebu/scripting/scripting.c
|
||||
@@ -169,16 +169,16 @@ int scripting_CopyStringResult(char *s, int len) {
|
||||
return status;
|
||||
}
|
||||
|
||||
-void scripting_RunFile(char *name) {
|
||||
+void scripting_RunFile(const char *name) {
|
||||
lua_dofile(L, name);
|
||||
}
|
||||
|
||||
-void scripting_Run(char *command) {
|
||||
+void scripting_Run(const char *command) {
|
||||
/* fprintf(stderr, "[command] %s\n", command); */
|
||||
lua_dostring(L, command);
|
||||
}
|
||||
|
||||
-void scripting_RunFormat(char *format, ... ) {
|
||||
+void scripting_RunFormat(const char *format, ... ) {
|
||||
char buf[4096];
|
||||
va_list ap;
|
||||
va_start(ap, format);
|
||||
--
|
||||
2.37.3
|
||||
|
||||
|
||||
From a99e603eaf8d5d08d96be5bf18f60bd7b7d264d5 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Joachim=20Mairb=C3=B6ck?= <j.mairboeck@gmail.com>
|
||||
Date: Sun, 30 Apr 2023 19:56:49 +0200
|
||||
Subject: use proper settings file name for Haiku
|
||||
|
||||
|
||||
diff --git a/src/include/game/gltron.h b/src/include/game/gltron.h
|
||||
index c66d31f..34978b7 100644
|
||||
--- a/src/include/game/gltron.h
|
||||
+++ b/src/include/game/gltron.h
|
||||
@@ -30,6 +30,11 @@
|
||||
#define RC_NAME "gltronPrefs.txt"
|
||||
#endif
|
||||
|
||||
+#ifdef __HAIKU__ /* Haiku */
|
||||
+#undef RC_NAME
|
||||
+#define RC_NAME "GLtron settings"
|
||||
+#endif
|
||||
+
|
||||
/* the engine */
|
||||
#include "Nebu.h"
|
||||
|
||||
--
|
||||
2.37.3
|
||||
|
||||
|
||||
From 0fe379ad906fb31da3751ea8e34ed5f7bd161927 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Joachim=20Mairb=C3=B6ck?= <j.mairboeck@gmail.com>
|
||||
Date: Fri, 5 May 2023 18:06:17 +0200
|
||||
Subject: remove comments from Makefile.am to fix automake
|
||||
|
||||
|
||||
diff --git a/nebu/scripting/Makefile.am b/nebu/scripting/Makefile.am
|
||||
index b4a9e9b..76c90f6 100644
|
||||
--- a/nebu/scripting/Makefile.am
|
||||
+++ b/nebu/scripting/Makefile.am
|
||||
@@ -6,8 +6,6 @@ libscripting_a_SOURCES= \
|
||||
libscripting_a_LIBADD= \
|
||||
$(top_builddir)/lua/src/liblua.a \
|
||||
$(top_builddir)/lua/src/lib/liblualib.a
|
||||
- # @top_srcdir@/lua/src/liblua.a \
|
||||
- # @top_srcdir@/lua/src/lib/liblualib.a
|
||||
|
||||
AM_CFLAGS = \
|
||||
-I$(top_srcdir)/nebu/include/base \
|
||||
--
|
||||
2.37.3
|
||||
|
||||
Reference in New Issue
Block a user