forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
games-board/pouetchess: Fix building with GCC-6
Bug: https://bugs.gentoo.org/show_bug.cgi?id=613428 Package-Manager: Portage-2.3.5, Repoman-2.3.2 Closes: gentoo#4278
- Loading branch information
1 parent
25890eb
commit b6dce8e
Showing
2 changed files
with
19 additions
and
2 deletions.
There are no files selected for viewing
16 changes: 16 additions & 0 deletions
16
games-board/pouetchess/files/pouetchess-0.2.0-gcc6-cmath.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -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); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters