summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Linimon <linimon@FreeBSD.org>2018-11-05 20:31:46 +0000
committerMark Linimon <linimon@FreeBSD.org>2018-11-05 20:31:46 +0000
commit4ffa3a21d79e13da20d9dbb4a990e21d1992b07e (patch)
tree8d7b2a7be3d1b335a84dabec186aeb4e9d6c78ce
parentThis port requires USES=compiler:c++11-lang, since it links with (diff)
Fails with base GCC, needs to have USES=compiler:c++11-lang.
Additionally, a fix for isnan() being not detected. Also, add USES=gl. PR: 232680 Submitted by: Piotr Kubaj Approved by: maintainer
-rw-r--r--games/torcs/Makefile3
-rw-r--r--games/torcs/files/patch-src_drivers_olethros_geometry.cpp11
2 files changed, 13 insertions, 1 deletions
diff --git a/games/torcs/Makefile b/games/torcs/Makefile
index 15b6bea7407f..0c86514a80f6 100644
--- a/games/torcs/Makefile
+++ b/games/torcs/Makefile
@@ -19,7 +19,8 @@ RUN_DEPENDS= bash:shells/bash
MAKE_JOBS_UNSAFE= yes
-USES= compiler:c++11-lang cpe gmake openal:al,alut shebangfix tar:bzip2
+USES= compiler:c++11-lang cpe gl gmake openal:al,alut shebangfix \
+ tar:bzip2
CPE_VENDOR= bernhard_wymann
SHEBANG_FILES= src/tools/accc/accc.in src/tools/nfsperf/nfsperf.in \
src/tools/texmapper/texmapper.in src/tools/nfs2ac/nfs2ac.in \
diff --git a/games/torcs/files/patch-src_drivers_olethros_geometry.cpp b/games/torcs/files/patch-src_drivers_olethros_geometry.cpp
new file mode 100644
index 000000000000..7be690b87c55
--- /dev/null
+++ b/games/torcs/files/patch-src_drivers_olethros_geometry.cpp
@@ -0,0 +1,11 @@
+--- src/drivers/olethros/geometry.cpp.orig 2018-10-25 14:35:19 UTC
++++ src/drivers/olethros/geometry.cpp
+@@ -370,7 +370,7 @@ void EstimateSphere (std::vector<Vector> P, Parametric
+ }
+ delta_total += delta;
+ }
+- if (isnan(r)) {
++ if (std::isnan(r)) {
+ for (i=0; i<d; i++) {
+ center[i] = ((*(sphere->C))[i] - mean[i]) / scale;
+ }