diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2018-04-14 01:05:40 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2018-04-14 01:05:40 +0100 |
commit | 76cba73c47c8694e74377004634daca18f2d9c08 (patch) | |
tree | 468603ebdc189bcfae77696162761b3be936baea /media-libs/glm/files/glm-0.9.8.5-gcc7_tests.patch | |
parent | 6957f5c65b02bba533954eabc0b62f5de36be206 (diff) |
gentoo resync : 14.04.2018
Diffstat (limited to 'media-libs/glm/files/glm-0.9.8.5-gcc7_tests.patch')
-rw-r--r-- | media-libs/glm/files/glm-0.9.8.5-gcc7_tests.patch | 70 |
1 files changed, 70 insertions, 0 deletions
diff --git a/media-libs/glm/files/glm-0.9.8.5-gcc7_tests.patch b/media-libs/glm/files/glm-0.9.8.5-gcc7_tests.patch new file mode 100644 index 000000000000..d7744aed5551 --- /dev/null +++ b/media-libs/glm/files/glm-0.9.8.5-gcc7_tests.patch @@ -0,0 +1,70 @@ +Bug: https://bugs.gentoo.org/638312 +Upstream commit: https://github.com/g-truc/glm/commit/e37cf6e47fa4305c82845103b17af58f6cfe23db + +From e37cf6e47fa4305c82845103b17af58f6cfe23db Mon Sep 17 00:00:00 2001 +From: Christophe Riccio <christophe.riccio@unity3d.com> +Date: Thu, 17 Aug 2017 00:08:37 +0200 +Subject: [PATCH] Fixed GCC 7.1.0 failing tests #666 + +--- + test/core/core_type_mat2x4.cpp | 4 +++- + test/core/core_type_mat3x4.cpp | 4 +++- + test/core/core_type_mat4x4.cpp | 3 ++- + 3 files changed, 8 insertions(+), 3 deletions(-) + +diff --git a/test/core/core_type_mat2x4.cpp b/test/core/core_type_mat2x4.cpp +index 17afebf91..eea3e46f4 100644 +--- a/test/core/core_type_mat2x4.cpp ++++ b/test/core/core_type_mat2x4.cpp +@@ -1,3 +1,5 @@ ++#include <glm/gtc/epsilon.hpp> ++#include <glm/gtc/constants.hpp> + #include <glm/vector_relational.hpp> + #include <glm/mat2x2.hpp> + #include <glm/mat2x3.hpp> +@@ -83,7 +85,7 @@ namespace cast + glm::mat2x4 Identity(1.0f); + + for(glm::length_t i = 0, length = B.length(); i < length; ++i) +- Error += glm::all(glm::equal(B[i], Identity[i])) ? 0 : 1; ++ Error += glm::all(glm::epsilonEqual(B[i], Identity[i], glm::epsilon<float>())) ? 0 : 1; + + return Error; + } +diff --git a/test/core/core_type_mat3x4.cpp b/test/core/core_type_mat3x4.cpp +index e3b78d31b..74a45d87a 100644 +--- a/test/core/core_type_mat3x4.cpp ++++ b/test/core/core_type_mat3x4.cpp +@@ -1,3 +1,5 @@ ++#include <glm/gtc/epsilon.hpp> ++#include <glm/gtc/constants.hpp> + #include <glm/vector_relational.hpp> + #include <glm/mat2x2.hpp> + #include <glm/mat2x3.hpp> +@@ -87,7 +89,7 @@ namespace cast + glm::mat3x4 Identity(1.0f); + + for(glm::length_t i = 0, length = B.length(); i < length; ++i) +- Error += glm::all(glm::equal(B[i], Identity[i])) ? 0 : 1; ++ Error += glm::all(glm::epsilonEqual(B[i], Identity[i], glm::epsilon<float>())) ? 0 : 1; + + return Error; + } +diff --git a/test/core/core_type_mat4x4.cpp b/test/core/core_type_mat4x4.cpp +index 3966c2b7f..fd2aca8b4 100644 +--- a/test/core/core_type_mat4x4.cpp ++++ b/test/core/core_type_mat4x4.cpp +@@ -1,3 +1,4 @@ ++#include <glm/gtc/constants.hpp> + #include <glm/gtc/epsilon.hpp> + #include <glm/matrix.hpp> + #include <glm/mat2x2.hpp> +@@ -263,7 +264,7 @@ namespace cast + glm::mat4x4 Identity(1.0f); + + for(glm::length_t i = 0, length = B.length(); i < length; ++i) +- Error += glm::all(glm::equal(B[i], Identity[i])) ? 0 : 1; ++ Error += glm::all(glm::epsilonEqual(B[i], Identity[i], glm::epsilon<float>())) ? 0 : 1; + + return Error; + } |