Files
haikuports/games-strategy/ja2_stracciatella/patches/ja2_stracciatella-0.15.1.patchset
2017-06-17 11:37:00 -04:00

88 lines
2.4 KiB
Plaintext

From 5893be972ebe1896ae3d5ab9c8882e050b7028e7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Zolt=C3=A1n=20Mizsei?= <zmizsei@extrowerk.com>
Date: Wed, 7 Jun 2017 07:54:07 +0200
Subject: [PATCH] PATCH: LC_ALL not defined on Haiku
---
sgp/SGP.cc | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/sgp/SGP.cc b/sgp/SGP.cc
index 7b9b710..aa1be0a 100644
--- a/sgp/SGP.cc
+++ b/sgp/SGP.cc
@@ -313,6 +313,12 @@ static BOOLEAN ParseParameters(int argc, char* const argv[],
int main(int argc, char* argv[])
try
{
+
+#if defined(__HAIKU__)
+ /*LC_ALL not defined on Haiku, an JA needs to set it to "C" */
+ setenv("LC_ALL","C",1);
+#endif
+
std::string exeFolder = FileMan::getParentPath(argv[0], true);
#if defined BROKEN_SWPRINTF
--
2.12.2
From d612275101c558e8380c57e2029fac9b835f7e47 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Zolt=C3=A1n=20Mizsei?= <zmizsei@extrowerk.com>
Date: Wed, 7 Jun 2017 07:57:36 +0200
Subject: [PATCH] PATCH: dirent dirty fix
---
sgp/FileMan.cc | 3 +++
1 file changed, 3 insertions(+)
diff --git a/sgp/FileMan.cc b/sgp/FileMan.cc
index 0b607c2..3260d19 100644
--- a/sgp/FileMan.cc
+++ b/sgp/FileMan.cc
@@ -539,6 +539,8 @@ bool FileMan::findObjectCaseInsensitive(const char *directory, const char *name,
}
}
}
+#ifndef __HAIKU__
+/* FIXME: dirty hack to eliminate dirent stuff*/
else
{
// name contains only file, no directories
@@ -561,6 +563,7 @@ bool FileMan::findObjectCaseInsensitive(const char *directory, const char *name,
closedir(d);
}
}
+#endif /*__HAIKU__*/
// LOG_INFO("XXXXX Looking for %s/[ %s ] : %s\n", directory, name, result ? "success" : "failure");
return result;
--
2.12.2
From 2c6099a9cbea2d6341565bf220e62c5028939a7e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Zolt=C3=A1n=20Mizsei?= <zmizsei@extrowerk.com>
Date: Wed, 7 Jun 2017 17:57:57 +0200
Subject: [PATCH] Patch: Haiku config file location
---
sgp/FileMan.cc | 2 ++
1 file changed, 2 insertions(+)
diff --git a/sgp/FileMan.cc b/sgp/FileMan.cc
index 3260d19..f21c8c0 100644
--- a/sgp/FileMan.cc
+++ b/sgp/FileMan.cc
@@ -111,6 +111,8 @@ std::string FileMan::findConfigFolderAndSwitchIntoIt()
#ifdef _WIN32
std::string configFolderPath = FileMan::joinPaths(home, "JA2");
+#elif defined(__HAIKU__)
+ std::string configFolderPath = FileMan::joinPaths(home, "config/settings/ja2");
#else
std::string configFolderPath = FileMan::joinPaths(home, ".ja2");
#endif
--
2.12.2