aboutsummaryrefslogtreecommitdiff
path: root/games/openttd
diff options
context:
space:
mode:
authorAlexey Dokuchaev <danfe@FreeBSD.org>2017-08-03 11:19:24 +0000
committerAlexey Dokuchaev <danfe@FreeBSD.org>2017-08-03 11:19:24 +0000
commit16adc8f350f940d2ae601ed50dc1b6c3d637425c (patch)
tree356f22537af62e6938a459cf10a0e463b9e80d22 /games/openttd
parent53e9876f82b6f893949f26aa83522a7eefe8a647 (diff)
downloadports-16adc8f350f940d2ae601ed50dc1b6c3d637425c.tar.gz
ports-16adc8f350f940d2ae601ed50dc1b6c3d637425c.zip
Update of LLVM components in -head to version 5.0.0 apparently had broken
OpenTTD due to a conflict of ``type'' being defined (differently) and used in both libc++ and the game itself: In file included from /usr/include/c++/v1/math.h:310: /usr/include/c++/v1/limits:234:95: error: member reference base type 'int' is not a structure or union _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type signaling_NaN() _NOEXCEPT {return type(0);} .../openttd-1.7.1/src/3rdparty/squirrel/squirrel/sqobject.h:99:25: note: expanded from macro 'type' #define type(obj) ((obj)._type) Mend the problem by #includ'ing <math.h> prior to Squirrel's (programming language OpenTTD uses internally for scripting). Reported by: pkg-fallout
Notes
Notes: svn path=/head/; revision=447202
Diffstat (limited to 'games/openttd')
-rw-r--r--games/openttd/files/patch-src_3rdparty_squirrel_squirrel_sqvm.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/games/openttd/files/patch-src_3rdparty_squirrel_squirrel_sqvm.cpp b/games/openttd/files/patch-src_3rdparty_squirrel_squirrel_sqvm.cpp
new file mode 100644
index 000000000000..dfff26557701
--- /dev/null
+++ b/games/openttd/files/patch-src_3rdparty_squirrel_squirrel_sqvm.cpp
@@ -0,0 +1,13 @@
+--- src/3rdparty/squirrel/squirrel/sqvm.cpp.orig 2017-06-13 18:34:58 UTC
++++ src/3rdparty/squirrel/squirrel/sqvm.cpp
+@@ -4,9 +4,9 @@
+
+ #include "../../../stdafx.h"
+
++#include <math.h>
+ #include <squirrel.h>
+ #include "sqpcheader.h"
+-#include <math.h>
+ #include "sqopcodes.h"
+ #include "sqfuncproto.h"
+ #include "sqvm.h"