WIP recipe for Ur-Quan Masters

Not working (fails to link libnetwork despite trying to add it in
several places), and I got bored with their custom buildsystem. Feel
free to improve.
This commit is contained in:
Adrien Destugues
2014-01-16 22:12:56 +01:00
parent 7bfe0c3ccc
commit 848ebd0ffd
2 changed files with 174 additions and 0 deletions

View File

@@ -0,0 +1,100 @@
From 45ee17169b5ca4ebb52661725d3e0bb9f1377a4c Mon Sep 17 00:00:00 2001
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
Date: Wed, 15 Jan 2014 23:08:17 +0100
Subject: Add pre-configured config.state file.
This avoids the build script asking questions using an interactive menu.
diff --git a/config.state b/config.state
new file mode 100644
index 0000000..01b69f6
--- /dev/null
+++ b/config.state
@@ -0,0 +1,14 @@
+CHOICE_debug_VALUE='nodebug'
+CHOICE_graphics_VALUE='opengl'
+CHOICE_sound_VALUE='mixsdl'
+CHOICE_mikmod_VALUE='external'
+CHOICE_ovcodec_VALUE='standard'
+CHOICE_netplay_VALUE='ipv4'
+CHOICE_joystick_VALUE='enabled'
+CHOICE_ioformat_VALUE='stdio_zip'
+CHOICE_accel_VALUE='asm'
+CHOICE_threadlib_VALUE='pthread'
+INPUT_install_prefix_VALUE='PREFIX_HERE'
+INPUT_install_bindir_VALUE='$prefix/bin'
+INPUT_install_libdir_VALUE='$prefix/lib'
+INPUT_install_sharedir_VALUE='$prefix/share'
--
1.8.3.4
From 3833a4d67d17c88f0ca5d042134a2f77e97475cb Mon Sep 17 00:00:00 2001
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
Date: Wed, 15 Jan 2014 23:08:55 +0100
Subject: Make buildsystem aware of Haiku.
diff --git a/build/unix/config_functions b/build/unix/config_functions
index 4f017f1..7c4aa5a 100644
--- a/build/unix/config_functions
+++ b/build/unix/config_functions
@@ -1060,6 +1060,8 @@ set_host_system() {
HOST_SYSTEM="ARMV5" ;;
[Gg][Cc][Cc][Ee])
HOST_SYSTEM="GCCE" ;;
+ [Hh][Aa][Ii][Kk][Uu])
+ HOST_SYSTEM="Haiku" ;;
*)
build_message "Warning: host type '$BUILD_HOST' unknown. Using defaults."
;;
diff --git a/build/unix/config_proginfo_host b/build/unix/config_proginfo_host
index 6e0466c..d95c6c9 100644
--- a/build/unix/config_proginfo_host
+++ b/build/unix/config_proginfo_host
@@ -299,7 +299,7 @@ case "$HOST_SYSTEM" in
LIB_pthread_LDFLAGS="$(pthread-config --ldflags)"
LIB_pthread_VERSION="$(pthread-config --version)"
;;
- WINSCW|ARMV5|GCCE)
+ WINSCW|ARMV5|GCCE|Haiku)
LIB_pthread_DETECT="true"
;;
*)
@@ -321,6 +321,11 @@ case "$HOST_SYSTEM" in
ARMV5|WINSCW|GCCE)
LIB_netlibs_DETECT="false"
;;
+ Haiku)
+ LIB_netlibs_CFLAGS=""
+ LIB_netlibs_LDFLAGS="-lnetwork"
+ LIB_netlibs_VERSION=""
+ ;;
esac
--
1.8.3.4
From 0cf24463ad192a871fc103821b477cf49bc91306 Mon Sep 17 00:00:00 2001
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
Date: Wed, 15 Jan 2014 23:09:08 +0100
Subject: Add missing include for use of select().
diff --git a/src/libs/network/netmanager/netmanager_bsd.c b/src/libs/network/netmanager/netmanager_bsd.c
index 29159f8..4390eb8 100644
--- a/src/libs/network/netmanager/netmanager_bsd.c
+++ b/src/libs/network/netmanager/netmanager_bsd.c
@@ -30,6 +30,7 @@
#include <errno.h>
#include <stdlib.h>
#include <string.h>
+#include <sys/select.h>
#include "netmanager_common.ci"
#include "ndindex.ci"
--
1.8.3.4

View File

@@ -0,0 +1,74 @@
SUMMARY="a port of Star Control II for modern personal computers and operating systems"
DESCRIPTION="
The project started in August 2002, when Toys For Bob released the partially
ported sources of Star Control 2 3DO version to the fan community. Our goal is
to port this wonderful game to current personal computers and operating systems.
It is and will remain 100% free of charge, and anyone can contribute to the
project and thus help make it even better. For more information, look at our
info page.
"
HOMEPAGE="http://sc2.sourceforge.net/"
SRC_URI="http://prdownloads.sourceforge.net/sc2/uqm-0.7.0-source.tgz"
CHECKSUM_MD5="f9018ea0493d7dac6a9e1006b00af7df"
REVISION="1"
ARCHITECTURES="!x86 ?x86_64"
if [ $effectiveTargetArchitecture != x86_gcc2 ]; then
# x86_gcc2 is fine as primary target architecture as long as we're building
# for a different secondary architecture.
ARCHITECTURES="$ARCHITECTURES !x86_gcc2"
fi
SECONDARY_ARCHITECTURES="x86"
#PATCHES="vcmi-0.94.patchset"
PROVIDES="
uqm$secondaryArchSuffix = $portVersion
"
REQUIRES="
haiku$secondaryArchSuffix >= $haikuVersion
lib:libSDL_1.2$secondaryArchSuffix
lib:libsdl_image$secondaryArchSuffix
lib:libz$secondaryArchSuffix
lib:libpng$secondaryArchSuffix
lib:libvorbisfile$secondaryArchSuffix
lib:libogg$secondaryArchSuffix
lib:libmikmod$secondaryArchSuffix
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel >= $haikuVersion
devel:libSDL$secondaryArchSuffix
devel:libsdl_image$secondaryArchSuffix
devel:libz$secondaryArchSuffix
devel:libz$secondaryArchSuffix
devel:libpng$secondaryArchSuffix
devel:libvorbisfile$secondaryArchSuffix
devel:libogg$secondaryArchSuffix
devel:libmikmod$secondaryArchSuffix
devel:libglu$secondaryArchSuffix
"
BUILD_PREREQUIRES="
cmd:gcc$secondaryArchSuffix
cmd:as$secondaryArchSuffix
cmd:sed
cmd:make
cmd:tr
cmd:pkg_config$secondaryArchSuffix
"
PATCHES="uqm-$portVersion.patchset"
BUILD()
{
sed -i -e"s!PREFIX_HERE!$prefix!" config.state
./build.sh uqm reprocess_config
./build.sh uqm
}
INSTALL()
{
./build.sh uqm install
}
COPYRIGHT="2005-2013 VCMI Team"
LICENSE="GNU GPL v2"