summaryrefslogtreecommitdiff
path: root/games-board/pouetchess/files/pouetchess-0.2.0-gcc6-cmath.patch
diff options
context:
space:
mode:
Diffstat (limited to 'games-board/pouetchess/files/pouetchess-0.2.0-gcc6-cmath.patch')
-rw-r--r--games-board/pouetchess/files/pouetchess-0.2.0-gcc6-cmath.patch16
1 files changed, 16 insertions, 0 deletions
diff --git a/games-board/pouetchess/files/pouetchess-0.2.0-gcc6-cmath.patch b/games-board/pouetchess/files/pouetchess-0.2.0-gcc6-cmath.patch
new file mode 100644
index 000000000000..4853eee81e1d
--- /dev/null
+++ b/games-board/pouetchess/files/pouetchess-0.2.0-gcc6-cmath.patch
@@ -0,0 +1,16 @@
+--- pouetchess_src_0.2.0/src/sxmlgui/MathUtils.h.old 2006-05-26 21:22:57.000000000 -0400
++++ pouetchess_src_0.2.0/src/sxmlgui/MathUtils.h 2017-03-21 18:01:15.569181229 -0400
+@@ -27,10 +27,13 @@
+ return (x < min) ? min : (x > max) ? max : x;
+ }
+
++// Not used anywhere and conflicts with C++11 std::round(float)
++#if __cplusplus < 201103L
+ inline int round(float f)
+ {
+ return int(f + 0.5f);
+ }
++#endif
+
+ inline float getNextRandom(){
+ return (float)rand()/(RAND_MAX + 1);