Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
cookbook
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
redox-os
cookbook
Commits
58e53a1a
Commit
58e53a1a
authored
6 years ago
by
Nagy Tibor
Browse files
Options
Downloads
Patches
Plain Diff
openttd: Relibc fixes
parent
0c47839c
No related branches found
No related tags found
1 merge request
!186
openttd: Relibc fixes
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
recipes/openttd/01_redox.patch
+35
-77
35 additions, 77 deletions
recipes/openttd/01_redox.patch
with
35 additions
and
77 deletions
recipes/openttd/01_redox.patch
+
35
−
77
View file @
58e53a1a
diff --git a/config.lib b/config.lib
index bc2224f..54290b1 100644
--- a/config.lib
+++ b/config.lib
diff -rupNw source-original/config.lib source/config.lib
--- source-original/config.lib 2018-11-23 19:25:11.000000000 +0100
+++ source/config.lib 2018-11-23 21:37:19.956620161 +0100
@@ -1486,7 +1486,7 @@
make_cflags_and_ldflags() {
# Special CXXFlags for HOST
CXXFLAGS="$CXXFLAGS"
...
...
@@ -20,61 +19,9 @@ index bc2224f..54290b1 100644
fi
if [ "$os" != "CYGWIN" ] && [ "$os" != "HAIKU" ] && [ "$os" != "MINGW" ] && [ "$os" != "DOS" ] && [ "$os" != "WINCE" ]; then
diff --git a/src/os/unix/crashlog_unix.cpp b/src/os/unix/crashlog_unix.cpp
index 47de057..07a3b74 100644
--- a/src/os/unix/crashlog_unix.cpp
+++ b/src/os/unix/crashlog_unix.cpp
@@ -17,7 +17,7 @@
#include <errno.h>
#include <signal.h>
-#include <sys/utsname.h>
+//#include <sys/utsname.h>
#if defined(__GLIBC__)
/* Execinfo (and thus making stacktraces) is a GNU extension */
@@ -42,22 +42,22 @@
class CrashLogUnix : public CrashLog {
/* virtual */ char *LogOSVersion(char *buffer, const char *last) const
{
- struct utsname name;
- if (uname(&name) < 0) {
+ //struct utsname name;
+ //if (uname(&name) < 0) {
return buffer + seprintf(buffer, last, "Could not get OS version: %s\n", strerror(errno));
- }
-
- return buffer + seprintf(buffer, last,
- "Operating system:\n"
- " Name: %s\n"
- " Release: %s\n"
- " Version: %s\n"
- " Machine: %s\n",
- name.sysname,
- name.release,
- name.version,
- name.machine
- );
+ //}
+
+ //return buffer + seprintf(buffer, last,
+ // "Operating system:\n"
+ // " Name: %s\n"
+ // " Release: %s\n"
+ // " Version: %s\n"
+ // " Machine: %s\n",
+ // name.sysname,
+ // name.release,
+ // name.version,
+ // name.machine
+ //);
}
/* virtual */ char *LogError(char *buffer, const char *last, const char *message) const
diff --git a/src/os/unix/unix.cpp b/src/os/unix/unix.cpp
index d7c2304..ed3c706 100644
--- a/src/os/unix/unix.cpp
+++ b/src/os/unix/unix.cpp
diff -rupNw source-original/src/os/unix/unix.cpp source/src/os/unix/unix.cpp
--- source-original/src/os/unix/unix.cpp 2018-11-23 19:25:12.000000000 +0100
+++ source/src/os/unix/unix.cpp 2018-11-23 21:37:19.956620161 +0100
@@ -28,7 +28,7 @@
#ifdef __APPLE__
#include <sys/mount.h>
...
...
@@ -84,11 +31,10 @@ index d7c2304..ed3c706 100644
#endif
#if defined(OPENBSD) || defined(__NetBSD__) || defined(__FreeBSD__)
diff --git a/src/rev.cpp.in b/src/rev.cpp.in
index b6bddea..499ec09 100644
--- a/src/rev.cpp.in
+++ b/src/rev.cpp.in
@@ -57,7 +57,7 @@
const char _openttd_build_date[] = __DATE__ " " __TIME__;
diff -rupNw source-original/src/rev.cpp.in source/src/rev.cpp.in
--- source-original/src/rev.cpp.in 2018-11-23 19:25:12.000000000 +0100
+++ source/src/rev.cpp.in 2018-11-23 21:37:19.956620161 +0100
@@ -57,7 +57,7 @@
const char _openttd_build_date[] = __DAT
* (compiling from sources without any version control software)
* and 2 is for modified revision.
*/
...
...
@@ -97,16 +43,28 @@ index b6bddea..499ec09 100644
/**
* The NewGRF revision of OTTD:
diff --git a/src/stringfilter.cpp b/src/stringfilter.cpp
index 6045c19..6fc3f99 100644
--- a/src/stringfilter.cpp
+++ b/src/stringfilter.cpp
@@ -113,7 +113,7 @@
void StringFilter::AddLine(const char *str)
const WordState *end = this->word_index.End();
for (WordState *it = this->word_index.Begin(); it != end; ++it) {
if (!it->match) {
- if ((match_case ? strstr(str, it->start) : strcasestr(str, it->start)) != NULL) {
+ if ((match_case ? strstr(str, it->start) : strstr(str, it->start)) != NULL) {
it->match = true;
this->word_matches++;
}
diff -rupNw source-original/src/stdafx.h source/src/stdafx.h
--- source-original/src/stdafx.h 2018-11-23 19:25:12.000000000 +0100
+++ source/src/stdafx.h 2018-11-23 19:49:25.000000000 +0100
@@ -12,6 +12,9 @@
#ifndef STDAFX_H
#define STDAFX_H
+#include <strings.h>
+#include <alloca.h>
+
#if defined(__APPLE__)
#include "os/macosx/osx_stdafx.h"
#endif /* __APPLE__ */
diff -rupNw source-original/src/string.cpp source/src/string.cpp
--- source-original/src/string.cpp 2018-11-23 19:25:12.000000000 +0100
+++ source/src/string.cpp 2018-11-23 20:01:10.000000000 +0100
@@ -528,7 +528,7 @@
size_t Utf8TrimString(char *s, size_t ma
return length;
}
-#ifdef DEFINE_STRCASESTR
+#if 0
char *strcasestr(const char *haystack, const char *needle)
{
size_t hay_len = strlen(haystack);
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment