summaryrefslogtreecommitdiff
path: root/Ports/halflife/patches/0001-Build-Add-SerenityOS-to-list-of-compatible-systems.patch
diff options
context:
space:
mode:
Diffstat (limited to 'Ports/halflife/patches/0001-Build-Add-SerenityOS-to-list-of-compatible-systems.patch')
-rw-r--r--Ports/halflife/patches/0001-Build-Add-SerenityOS-to-list-of-compatible-systems.patch55
1 files changed, 55 insertions, 0 deletions
diff --git a/Ports/halflife/patches/0001-Build-Add-SerenityOS-to-list-of-compatible-systems.patch b/Ports/halflife/patches/0001-Build-Add-SerenityOS-to-list-of-compatible-systems.patch
new file mode 100644
index 0000000000..2d33ffc573
--- /dev/null
+++ b/Ports/halflife/patches/0001-Build-Add-SerenityOS-to-list-of-compatible-systems.patch
@@ -0,0 +1,55 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Jesse Buhagiar <jooster669@gmail.com>
+Date: Sun, 2 Jan 2022 00:10:53 +1100
+Subject: [PATCH] Build: Add SerenityOS to list of compatible systems
+
+This is required by the build system to spit out a library with
+the correct name/platform.
+---
+ public/build.h | 4 ++++
+ scripts/waifulib/library_naming.py | 3 +++
+ 2 files changed, 7 insertions(+)
+
+diff --git a/public/build.h b/public/build.h
+index 3692cf1..5b6bcc3 100644
+--- a/public/build.h
++++ b/public/build.h
+@@ -75,6 +75,7 @@ For more information, please refer to <http://unlicense.org/>
+ #undef XASH_RISCV_DOUBLEFP
+ #undef XASH_RISCV_SINGLEFP
+ #undef XASH_RISCV_SOFTFP
++#undef XASH_SERENITY
+ #undef XASH_WIN32
+ #undef XASH_WIN64
+ #undef XASH_X86
+@@ -126,6 +127,9 @@ For more information, please refer to <http://unlicense.org/>
+ #elif defined __HAIKU__
+ #define XASH_HAIKU 1
+ #define XASH_POSIX 1
++#elif defined __serenity__
++ #define XASH_SERENITY 1
++ #define XASH_POSIX 1
+ #else
+ #error "Place your operating system name here! If this is a mistake, try to fix conditions above and report a bug"
+ #endif
+diff --git a/scripts/waifulib/library_naming.py b/scripts/waifulib/library_naming.py
+index a392906..44ade2f 100644
+--- a/scripts/waifulib/library_naming.py
++++ b/scripts/waifulib/library_naming.py
+@@ -57,6 +57,7 @@ DEFINES = [
+ 'XASH_RISCV_DOUBLEFP',
+ 'XASH_RISCV_SINGLEFP',
+ 'XASH_RISCV_SOFTFP',
++'XASH_SERENITY',
+ 'XASH_WIN32',
+ 'XASH_WIN64',
+ 'XASH_X86',
+@@ -89,6 +90,8 @@ def configure(conf):
+ buildos = "dos4gw" # unused, just in case
+ elif conf.env.XASH_HAIKU:
+ buildos = "haiku"
++ elif conf.env.XASH_SERENITY:
++ buildos = "serenityos"
+ else:
+ conf.fatal("Place your operating system name in build.h and library_naming.py!\n"
+ "If this is a mistake, try to fix conditions above and report a bug")