lgeneral, remove older (broken build) recipe (#8979)

This commit is contained in:
Schrijvers Luc
2023-07-06 09:36:08 +02:00
committed by GitHub
parent 9851f0f30d
commit 2e35f4f24a
2 changed files with 0 additions and 157 deletions

View File

@@ -1,68 +0,0 @@
SUMMARY="A turn-based strategy engine"
DESCRIPTION="LGeneral is a turn-based strategy engine heavily inspired by Panzer General. \
You play single scenarios or whole campaigns turn by turn against a human \
player or the AI. Entrenchment, rugged defense, defensive fire, surprise \
contacts, surrender, unit supply, weather influence, reinforcements and other \
implementations contribute to the tactical and strategic depth of the game."
HOMEPAGE="http://lgames.sourceforge.net/"
COPYRIGHT="2000, 2001 Michael Speck, Leo Savernik, Peter Ivanyi"
LICENSE="GNU GPL v2"
REVISION="3"
SOURCE_URI="http://downloads.sourceforge.net/project/lgeneral/lgeneral/lgeneral-1.2.3.tar.gz"
CHECKSUM_SHA256="55d17bb173c956c705b94bc8a6399d5311b3ec82c9f1821a97fe9ec45da0d9a1"
SOURCE_URI_2="http://prdownloads.sourceforge.net/lgeneral/pg-data.tar.gz"
CHECKSUM_SHA256_2="cc6fa5d263d1d5824d706517958b1bb09b405ba0ed21e63e4a4d38e2727d7a04"
PATCHES="lgeneral-1.2.3.patchset"
ARCHITECTURES="?all x86_gcc2"
PROVIDES="
lgeneral = $portVersion
cmd:lgc_pg = $portVersion
cmd:lged = $portVersion
cmd:lgeneral = $portVersion
cmd:ltrextract = $portVersion
cmd:shptool = $portVersion
"
REQUIRES="
haiku
lib:libSDL_1.2
lib:libSDL_mixer_1.2
lib:libSDL_net_1.2
"
BUILD_REQUIRES="
haiku_devel
devel:libintl
devel:libSDL_1.2
devel:libSDL_mixer_1.2
devel:libSDL_net_1.2
"
BUILD_PREREQUIRES="
cmd:gcc
cmd:ld
cmd:libtoolize
cmd:make
"
BUILD()
{
libtoolize --force --copy --install
runConfigure ./configure --disable-nls
mkdir -p pg-data
cp ../../sources-2/pg-data/* ./pg-data/
make $jobArgs
}
INSTALL()
{
make install
rm -rf $dataDir/applications
rm -rf $dataDir/icons
$binDir/lgc-pg -s ./pg-data
addAppDeskbarSymlink $binDir/lgeneral LGeneral
}

View File

@@ -1,89 +0,0 @@
From a7b2bc562fb3a4403fefc4061b8730f27bade615 Mon Sep 17 00:00:00 2001
From: Markus Himmel <markus@himmel-villmar.de>
Date: Mon, 12 Jan 2015 20:01:38 +0000
Subject: [PATCH 1/2] applying patch lgeneral-1.2.3.patch
---
configure | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/configure b/configure
index 846e301..e6073fd 100755
--- a/configure
+++ b/configure
@@ -5314,7 +5314,7 @@ if test "${ac_cv_lib_m_main+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
-LIBS="-lm $LIBS"
+LIBS="$LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
@@ -5368,7 +5368,7 @@ if test $ac_cv_lib_m_main = yes; then
#define HAVE_LIBM 1
_ACEOF
- LIBS="-lm $LIBS"
+ LIBS="$LIBS"
else
{ { echo "$as_me:$LINENO: error: maths library is needed" >&5
--
1.8.3.4
From b29a7822ee12df83585548077267afe2be0c78e1 Mon Sep 17 00:00:00 2001
From: Markus Himmel <markus@himmel-villmar.de>
Date: Wed, 14 Jan 2015 20:15:41 +0000
Subject: [PATCH 2/2] Move main config
---
src/config.c | 19 +++++++++++++++++--
1 file changed, 17 insertions(+), 2 deletions(-)
diff --git a/src/config.c b/src/config.c
index 5baa759..b44e162 100644
--- a/src/config.c
+++ b/src/config.c
@@ -22,6 +22,13 @@
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
+
+#ifdef __HAIKU__
+#include <SupportDefs.h>
+#include <FindDirectory.h>
+#include <fs_info.h>
+#endif
+
#include "sdl.h"
#include "config.h"
#include "parser.h"
@@ -32,13 +39,21 @@ Config config;
/* check if config directory exists; if not create it and set config_dir */
void check_config_dir_name()
{
+ size_t length;
struct stat info;
#ifndef INSTALLDIR
/* if no installation store config to current directory not home */
sprintf( config.dir_name, "." );
-#else
+#elif __HAIKU__
+ find_directory(B_USER_SETTINGS_DIRECTORY, dev_for_path("/boot"), false,
+ config.dir_name, sizeof(config.dir_name) - 1);
+ length = strlen(config.dir_name);
+ snprintf(config.dir_name + length, sizeof(config.dir_name) - (1 + length),
+ "/LGames");
+ fprintf( stderr, "HAIKU: Config path is %s\n", config.dir_name);
+#else
sprintf( config.dir_name, "%s/.lgames", getenv( "HOME" ) );
-#endif
+#endif
if ( stat( config.dir_name, &info ) != 0 ) {
int res;
--
1.8.3.4