diff options
author | Alexey Dokuchaev <danfe@FreeBSD.org> | 2016-05-29 23:02:03 +0800 |
---|---|---|
committer | Alexey Dokuchaev <danfe@FreeBSD.org> | 2016-05-29 23:02:03 +0800 |
commit | e0daea23e8d106b09d57b0ec81279e1e31922eec (patch) | |
tree | 60548fc2264b64455b40d2f280726db0c74ecdf8 /graphics | |
parent | a13742590ab1dc4027433ff31af5dd38f2fc5d18 (diff) | |
download | freebsd-ports-gnome-e0daea23e8d106b09d57b0ec81279e1e31922eec.tar.gz freebsd-ports-gnome-e0daea23e8d106b09d57b0ec81279e1e31922eec.tar.zst freebsd-ports-gnome-e0daea23e8d106b09d57b0ec81279e1e31922eec.zip |
Disable some overloaded math functions for libc++ 3.8.0 and higher, and thus
unbreak the build.
This is because this port defines its own versions of a number of <cmath>
functions, which cause the ambiguity. These functions are only declared in
<cmath> for libc++ 3.8.0 and later, so fix it by disabling the custom
functions for those versions of libc++.
PR: 209652
Submitted by: dim
Diffstat (limited to 'graphics')
-rw-r--r-- | graphics/embree/files/patch-common_math_math.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/graphics/embree/files/patch-common_math_math.h b/graphics/embree/files/patch-common_math_math.h index 1b8109969999..bb1cfc4612b1 100644 --- a/graphics/embree/files/patch-common_math_math.h +++ b/graphics/embree/files/patch-common_math_math.h @@ -1,5 +1,14 @@ --- common/math/math.h.orig 2016-05-20 05:45:13 UTC +++ common/math/math.h +@@ -83,7 +83,7 @@ namespace embree + return _mm_cvtss_f32(c); + } + +-#if !defined(__WIN32__) ++#if !defined(__WIN32__) && (!defined(_LIBCPP_VERSION) || _LIBCPP_VERSION < 3800) + __forceinline float abs ( const float x ) { return ::fabsf(x); } + __forceinline float acos ( const float x ) { return ::acosf (x); } + __forceinline float asin ( const float x ) { return ::asinf (x); } @@ -179,7 +179,7 @@ namespace embree } #endif |