diff --git a/games-fps/yamagi-quake2/patches/yamagi_quake2-7.41.patchset b/games-fps/yamagi-quake2/patches/yamagi_quake2-7.41.patchset deleted file mode 100644 index 3ccaa04af..000000000 --- a/games-fps/yamagi-quake2/patches/yamagi_quake2-7.41.patchset +++ /dev/null @@ -1,128 +0,0 @@ -From 50932c734a5d0489bb3d8bc49095e9f4f34ac51f Mon Sep 17 00:00:00 2001 -From: Sergei Reznikov -Date: Tue, 9 Oct 2018 16:48:35 +0300 -Subject: Add Haiku support - - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index f38d575..7541fe0 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -132,6 +132,8 @@ endif() - # General linker flags. - if(${CMAKE_SYSTEM_NAME} MATCHES "Windows") - list(APPEND yquake2LinkerFlags "-lm -static-libgcc") -+elseif(${CMAKE_SYSTEM_NAME} MATCHES "Haiku") -+ list(APPEND yquake2LinkerFlags "-lnetwork") - else() - list(APPEND yquake2LinkerFlags "-lm -rdynamic") - endif() -diff --git a/src/backends/unix/main.c b/src/backends/unix/main.c -index 1201e1f..7ee797a 100644 ---- a/src/backends/unix/main.c -+++ b/src/backends/unix/main.c -@@ -85,6 +85,8 @@ main(int argc, char **argv) - } - } - -+#ifndef __HAIKU__ -+ - /* Prevent running Quake II as root. Only very mad - minded or stupid people even think about it. :) */ - if (getuid() == 0) -@@ -106,12 +108,13 @@ main(int argc, char **argv) - - return 1; - } -+#endif - - // enforce C locale - setenv("LC_ALL", "C", 1); - - /// Do not delay reads on stdin -- fcntl(fileno(stdin), F_SETFL, fcntl(fileno(stdin), F_GETFL, NULL) | FNDELAY); -+ fcntl(fileno(stdin), F_SETFL, fcntl(fileno(stdin), F_GETFL, NULL) | O_NDELAY); - - // Initialize the game. - // Never returns. -diff --git a/src/backends/unix/system.c b/src/backends/unix/system.c -index 0554598..7769a42 100644 ---- a/src/backends/unix/system.c -+++ b/src/backends/unix/system.c -@@ -62,7 +62,7 @@ Sys_Error(char *error, ...) - char string[1024]; - - /* change stdin to non blocking */ -- fcntl(0, F_SETFL, fcntl(0, F_GETFL, 0) & ~FNDELAY); -+ fcntl(0, F_SETFL, fcntl(0, F_GETFL, 0) & ~O_NDELAY); - - #ifndef DEDICATED_ONLY - CL_Shutdown(); -@@ -91,7 +91,7 @@ Sys_Quit(void) - } - - Qcommon_Shutdown(); -- fcntl(0, F_SETFL, fcntl(0, F_GETFL, 0) & ~FNDELAY); -+ fcntl(0, F_SETFL, fcntl(0, F_GETFL, 0) & ~O_NDELAY); - - printf("------------------------------------\n"); - -diff --git a/src/client/input/sdl.c b/src/client/input/sdl.c -index a2e6f18..9397d97 100644 ---- a/src/client/input/sdl.c -+++ b/src/client/input/sdl.c -@@ -1239,9 +1239,9 @@ IN_Init(void) - SDL_StartTextInput(); - - /* Joystick init */ -- if (!SDL_WasInit(SDL_INIT_GAMECONTROLLER | SDL_INIT_HAPTIC)) -+ if (!SDL_WasInit(SDL_INIT_GAMECONTROLLER)) - { -- if (SDL_Init(SDL_INIT_GAMECONTROLLER | SDL_INIT_HAPTIC) == -1) -+ if (SDL_Init(SDL_INIT_GAMECONTROLLER) == -1) - { - Com_Printf ("Couldn't init SDL joystick: %s.\n", SDL_GetError ()); - } --- -2.19.1 - -From 7cf68509bfbd20fe3fa84f0598973e8558c28742 Mon Sep 17 00:00:00 2001 -From: Nikolay0054 -Date: Sat, 3 Nov 2018 14:10:59 +0500 -Subject: [PATCH] fix find path - ---- - src/backends/generic/misc.c | 11 +++++++++++ - 1 file changed, 11 insertions(+) - -diff --git a/src/backends/generic/misc.c b/src/backends/generic/misc.c -index 973a2cba..11832be0 100644 ---- a/src/backends/generic/misc.c -+++ b/src/backends/generic/misc.c -@@ -45,6 +45,10 @@ - #include // _NSGetExecutablePath - #endif - -+#ifdef __HAIKU__ -+#include // find_path() -+#endif -+ - #ifndef PATH_MAX - // this is mostly for windows. windows has a MAX_PATH = 260 #define, but allows - // longer paths anyway.. this might not be the maximum allowed length, but is -@@ -119,6 +123,13 @@ static void SetExecutablePath(char* exePath) - // TODO: realpath() ? - // TODO: no idea what this is if the executable is in an app bundle - -+#elif defined(__HAIKU__) -+ -+ if(find_path(B_APP_IMAGE_SYMBOL, B_FIND_PATH_IMAGE_PATH, NULL, exePath, PATH_MAX) != B_OK) -+ { -+ exePath[0] = '\0'; -+ } -+ - #else - - // Several platforms (for example OpenBSD) donn't provide a --- -2.19.1 diff --git a/games-fps/yamagi-quake2/patches/yamagi_quake2-7.45.patchset b/games-fps/yamagi-quake2/patches/yamagi_quake2-7.45.patchset new file mode 100644 index 000000000..2393a3a1e --- /dev/null +++ b/games-fps/yamagi-quake2/patches/yamagi_quake2-7.45.patchset @@ -0,0 +1,47 @@ +From aa6d604aca37c95a2a5927122c5c0b4893e8eb0c Mon Sep 17 00:00:00 2001 +From: Sergei Reznikov +Date: Tue, 9 Oct 2018 16:48:35 +0300 +Subject: Add Haiku support + + +diff --git a/src/backends/unix/system.c b/src/backends/unix/system.c +index c4bd90f..ca48738 100644 +--- a/src/backends/unix/system.c ++++ b/src/backends/unix/system.c +@@ -68,7 +68,7 @@ Sys_Error(char *error, ...) + char string[1024]; + + /* change stdin to non blocking */ +- fcntl(0, F_SETFL, fcntl(0, F_GETFL, 0) & ~FNDELAY); ++ fcntl(0, F_SETFL, fcntl(0, F_GETFL, 0) & ~O_NDELAY); + + #ifndef DEDICATED_ONLY + CL_Shutdown(); +@@ -97,7 +97,7 @@ Sys_Quit(void) + } + + Qcommon_Shutdown(); +- fcntl(0, F_SETFL, fcntl(0, F_GETFL, 0) & ~FNDELAY); ++ fcntl(0, F_SETFL, fcntl(0, F_GETFL, 0) & ~O_NDELAY); + + printf("------------------------------------\n"); + +diff --git a/src/client/input/sdl.c b/src/client/input/sdl.c +index 051505b..f05da4e 100644 +--- a/src/client/input/sdl.c ++++ b/src/client/input/sdl.c +@@ -1374,9 +1374,9 @@ IN_Init(void) + SDL_StartTextInput(); + + /* Joystick init */ +- if (!SDL_WasInit(SDL_INIT_GAMECONTROLLER | SDL_INIT_HAPTIC)) ++ if (!SDL_WasInit(SDL_INIT_GAMECONTROLLER)) + { +- if (SDL_Init(SDL_INIT_GAMECONTROLLER | SDL_INIT_HAPTIC) == -1) ++ if (SDL_Init(SDL_INIT_GAMECONTROLLER) == -1) + { + Com_Printf ("Couldn't init SDL joystick: %s.\n", SDL_GetError ()); + } +-- +2.28.0 + diff --git a/games-fps/yamagi-quake2/yamagi_quake2-7.41.recipe b/games-fps/yamagi-quake2/yamagi_quake2-7.45.recipe similarity index 97% rename from games-fps/yamagi-quake2/yamagi_quake2-7.41.recipe rename to games-fps/yamagi-quake2/yamagi_quake2-7.45.recipe index a56d80ae5..88482c080 100644 --- a/games-fps/yamagi-quake2/yamagi_quake2-7.41.recipe +++ b/games-fps/yamagi-quake2/yamagi_quake2-7.45.recipe @@ -28,9 +28,9 @@ code is fully 64 bit clean and highly portable." HOMEPAGE="https://www.yamagi.org/quake2/" COPYRIGHT="OpenArena Team" LICENSE="GNU GPL v2" -REVISION="2" +REVISION="1" SOURCE_URI="https://deponie.yamagi.org/quake2/quake2-$portVersion.tar.xz" -CHECKSUM_SHA256="7ae543fac9e8a74ecd706ac0fa0f94098912aa5aafcb33f1c2c3f57b48011364" +CHECKSUM_SHA256="c7524567bf1aa6045f25619bea6e4fd9066284b3fb81863b581fb44f4f47ff65" SOURCE_DIR="quake2-$portVersion" PATCHES="yamagi_quake2-$portVersion.patchset" ADDITIONAL_FILES="yamagi_quake2.rdef.in"