diff options
Diffstat (limited to 'games/openomf/files')
-rw-r--r-- | games/openomf/files/patch-CMakeLists.txt | 23 | ||||
-rw-r--r-- | games/openomf/files/patch-src_main.c | 11 | ||||
-rw-r--r-- | games/openomf/files/patch-src_resources_pathmanager.c | 26 |
3 files changed, 13 insertions, 47 deletions
diff --git a/games/openomf/files/patch-CMakeLists.txt b/games/openomf/files/patch-CMakeLists.txt deleted file mode 100644 index 9e046cc0c01e..000000000000 --- a/games/openomf/files/patch-CMakeLists.txt +++ /dev/null @@ -1,23 +0,0 @@ ---- CMakeLists.txt.orig 2016-01-10 17:37:25 UTC -+++ CMakeLists.txt -@@ -67,6 +67,7 @@ ENDIF() - find_package(SDL2) - find_package(enet) - find_package(confuse) -+find_package(Gettext) - - # Check functions and generate platform configuration file - CHECK_SYMBOL_EXISTS(strdup "string.h" HAVE_STD_STRDUP) -@@ -320,10 +321,10 @@ ENDIF() - # Handle module playback libraries - IF(USE_SUBMODULES) - set(CORELIBS ${CORELIBS} dumb) -- set(COREINCS ${COREINCS} ${DUMB_INCLUDE_DIR}) -+ set(COREINCS ${DUMB_INCLUDE_DIR} ${COREINCS} ) - ELSEIF(USE_DUMB) - set(CORELIBS ${CORELIBS} ${DUMB_LIBRARY}) -- set(COREINCS ${COREINCS} ${DUMB_INCLUDE_DIR}) -+ set(COREINCS ${DUMB_INCLUDE_DIR} ${COREINCS}) - ENDIF() - IF(USE_MODPLUG) - set(CORELIBS ${CORELIBS} ${MODPLUG_LIBRARY}) diff --git a/games/openomf/files/patch-src_main.c b/games/openomf/files/patch-src_main.c deleted file mode 100644 index 7a27405be42c..000000000000 --- a/games/openomf/files/patch-src_main.c +++ /dev/null @@ -1,11 +0,0 @@ ---- src/main.c.orig 2016-01-10 17:37:25 UTC -+++ src/main.c -@@ -156,7 +156,7 @@ int main(int argc, char *argv[]) { - INFO("Running on platform: %s", SDL_GetPlatform()); - - #ifndef STANDALONE_SERVER -- if(SDL_InitSubSystem(SDL_INIT_JOYSTICK|SDL_INIT_GAMECONTROLLER|SDL_INIT_HAPTIC)) { -+ if(SDL_InitSubSystem(SDL_INIT_JOYSTICK|SDL_INIT_GAMECONTROLLER)) { - err_msgbox("SDL2 Initialization failed: %s", SDL_GetError()); - goto exit_2; - } diff --git a/games/openomf/files/patch-src_resources_pathmanager.c b/games/openomf/files/patch-src_resources_pathmanager.c index 7e9ec87edaed..365a06c92ef9 100644 --- a/games/openomf/files/patch-src_resources_pathmanager.c +++ b/games/openomf/files/patch-src_resources_pathmanager.c @@ -1,16 +1,16 @@ --- src/resources/pathmanager.c.orig 2016-01-10 17:37:25 UTC +++ src/resources/pathmanager.c -@@ -85,11 +85,11 @@ int pm_init() { - local_path_build(RESOURCE_PATH, bin_base_dir, "resources\\"); - local_path_build(PLUGIN_PATH, bin_base_dir, "plugins\\"); +@@ -133,6 +133,13 @@ int pm_init() { + local_path_build(RESOURCE_PATH, bin_base_dir, "../share/games/openomf/"); + local_path_build(SHADER_PATH, bin_base_dir, "../share/games/openomf/shaders/"); m_ok = 1; -- } else if(!strcasecmp(SDL_GetPlatform(), "Linux")) { -+ } else if(!strcasecmp(SDL_GetPlatform(), "FreeBSD")) { - // on linux, the resources will be in ../share/games/openomf, relative to the binary - // so if openomf is installed to /usr/local/bin, - // the resources will be in /usr/local/share/games/openomf -- local_path_build(RESOURCE_PATH, bin_base_dir, "../share/games/openomf/"); -+ local_path_build(RESOURCE_PATH, %%PREFIX%%, "/share/openomf/"); - local_path_build(PLUGIN_PATH, bin_base_dir, "../lib/openomf/"); - m_ok = 1; - } else if(!strcasecmp(SDL_GetPlatform(), "Mac OS X")) { ++ } else if(strcmp(SDL_GetPlatform(), "FreeBSD") == 0) { ++ // on FreeBSD, the resources will be in ../share/openomf, relative to the binary ++ // so if openomf is installed to %%PREFIX%%/bin, ++ // the resources will be in %%PREFIX%%/share/openomf ++ local_path_build(RESOURCE_PATH, bin_base_dir, "../share/openomf/"); ++ local_path_build(SHADER_PATH, bin_base_dir, "../share/openomf/shaders/"); ++ m_ok = 1; + } else if(strcmp(SDL_GetPlatform(), "Mac OS X") == 0) { + // on OSX, GetBasePath returns the 'Resources' directory + // if run from an app bundle, so we can use this as-is |