Skip to content

Commit

Permalink
games-sports/torcs: Fix building with GCC-6
Browse files Browse the repository at this point in the history
Bug: https://bugs.gentoo.org/show_bug.cgi?id=594670
Package-Manager: Portage-2.3.6, Repoman-2.3.2
Closes: gentoo#4780
  • Loading branch information
Peter-Levine authored and SoapGentoo committed Jun 2, 2017
1 parent ac2efef commit 1b99de5
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 3 deletions.
11 changes: 11 additions & 0 deletions games-sports/torcs/files/torcs-1.3.6-gcc6.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
--- a/src/drivers/olethros/geometry.cpp
+++ b/src/drivers/olethros/geometry.cpp
@@ -27,6 +27,8 @@
#ifdef WIN32
#include <float.h>
#define isnan _isnan
+#elif __cplusplus >= 201103L
+using std::isnan;
#endif


3 changes: 2 additions & 1 deletion games-sports/torcs/torcs-1.3.6-r1.ebuild
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 1999-2016 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

EAPI=6
Expand Down Expand Up @@ -33,6 +33,7 @@ PATCHES=(
"${FILESDIR}"/${P}-flags.patch
"${FILESDIR}"/${P}-format.patch
"${FILESDIR}"/${P}-noXmuXt.patch
"${FILESDIR}"/${P}-gcc6.patch
)

src_prepare() {
Expand Down
5 changes: 3 additions & 2 deletions games-sports/torcs/torcs-1.3.6.ebuild
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 1999-2015 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

EAPI=5
Expand Down Expand Up @@ -33,7 +33,8 @@ src_prepare() {
"${FILESDIR}"/${P}-as-needed.patch \
"${FILESDIR}"/${P}-flags.patch \
"${FILESDIR}"/${P}-format.patch \
"${FILESDIR}"/${P}-noXmuXt.patch
"${FILESDIR}"/${P}-noXmuXt.patch \
"${FILESDIR}"/${P}-gcc6.patch
eautoreconf
ecvs_clean
}
Expand Down

0 comments on commit 1b99de5

Please sign in to comment.