mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 03:30:05 +02:00
biniax2, new recipe (#5552)
This commit is contained in:
59
games-puzzle/biniax2/biniax2-1.30.recipe
Normal file
59
games-puzzle/biniax2/biniax2-1.30.recipe
Normal file
@@ -0,0 +1,59 @@
|
||||
SUMMARY="Logic game with arcade and tactics modes"
|
||||
DESCRIPTION="Biniax-2 is a original and entertaining game. Takes a minute \
|
||||
to learn and gives you hours and hours of gameplay. Discover the different \
|
||||
Biniax-2 faces - for action heroes or careful strategists."
|
||||
HOMEPAGE="http://biniax.com/"
|
||||
COPYRIGHT="1991-2004 Silicon Graphics
|
||||
1997-2006 Sam Lantinga
|
||||
2005-2009 Jordan Tuzsuzov"
|
||||
LICENSE="Zlib"
|
||||
REVISION="1"
|
||||
SOURCE_URI="http://www.tuzsuzov.com/biniax/biniax2-1.30-fullsrc.tar.gz"
|
||||
CHECKSUM_SHA256="2c09f6f0a5fe453a409d990d72a964636ee91ca91daac99f0db861b8f42531bf"
|
||||
SOURCE_DIR=""
|
||||
PATCHES="biniax2-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="!x86_gcc2 x86_64"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
biniax2$secondaryArchSuffix = $portVersion
|
||||
cmd:biniax2$secondaryArchSuffix = $portVersion
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
lib:libSDL_1.2$secondaryArchSuffix
|
||||
lib:libSDL_image_1.2$secondaryArchSuffix
|
||||
lib:libSDL_mixer_1.2$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libSDL_1.2$secondaryArchSuffix
|
||||
devel:libSDL_image_1.2$secondaryArchSuffix
|
||||
devel:libSDL_mixer_1.2$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:make
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PATCH()
|
||||
{
|
||||
sed -i "s|data|$dataDir/biniax2|g" desktop/gfx.c desktop/snd.c
|
||||
}
|
||||
|
||||
BUILD()
|
||||
{
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
mkdir -p $appsDir $dataDir/biniax2
|
||||
mv biniax2 $appsDir/Biniax2
|
||||
cp -rf data/* $dataDir/biniax2
|
||||
rm -f $dataDir/biniax2/Thumbs.db
|
||||
|
||||
addAppDeskbarSymlink $appsDir/Biniax2
|
||||
}
|
||||
42
games-puzzle/biniax2/patches/biniax2-1.30.patchset
Normal file
42
games-puzzle/biniax2/patches/biniax2-1.30.patchset
Normal file
@@ -0,0 +1,42 @@
|
||||
From cc9d495228bfe5b1a3c34f7ec2829764a19d1410 Mon Sep 17 00:00:00 2001
|
||||
From: begasus <begasus@gmail.com>
|
||||
Date: Fri, 1 Jan 2021 13:23:27 +0000
|
||||
Subject: Fix launch from Tracker/Deskbar
|
||||
|
||||
|
||||
diff --git a/biniax.c b/biniax.c
|
||||
old mode 100755
|
||||
new mode 100644
|
||||
index 886b692..9ca0bba
|
||||
--- a/biniax.c
|
||||
+++ b/biniax.c
|
||||
@@ -50,6 +50,11 @@ INCLUDES
|
||||
#include "game.h"
|
||||
#include "lev.h"
|
||||
#include "inc.h"
|
||||
+
|
||||
+#ifdef __HAIKU__
|
||||
+#include <libgen.h>
|
||||
+#include <unistd.h>
|
||||
+#endif
|
||||
|
||||
/* Global instance of GAME structure */
|
||||
BNX_GAME Game;
|
||||
@@ -88,7 +93,13 @@ PROGRAM START
|
||||
******************************************************************************/
|
||||
|
||||
int main( int argc, char *argv[] )
|
||||
-{
|
||||
+{
|
||||
+ char *binpath = realpath(argv[0], NULL);
|
||||
+ if (binpath != NULL) {
|
||||
+ chdir(dirname(binpath));
|
||||
+ free(binpath);
|
||||
+ }
|
||||
+
|
||||
BNX_BOOL bquit = BNX_FALSE;
|
||||
BNX_INT16 enterState = cStateMainMenu;
|
||||
BNX_INT16 nmenu = 0;
|
||||
--
|
||||
2.28.0
|
||||
|
||||
Reference in New Issue
Block a user