nocnokneo pushed to ceres-solver (f21). "Add upstream patch to fix failing unit test small_blas_test"

notifications at fedoraproject.org notifications at fedoraproject.org
Sat Apr 11 04:01:55 UTC 2015


>From c05e954b093454de9723b8cadbd79c3f8f10d080 Mon Sep 17 00:00:00 2001
From: Taylor Braun-Jones <taylor.braun-jones at ge.com>
Date: Fri, 3 Apr 2015 02:21:08 -0400
Subject: Add upstream patch to fix failing unit test small_blas_test


diff --git a/0002-Increase-tolerance-in-small_blas-test-for-Cygwin.patch b/0002-Increase-tolerance-in-small_blas-test-for-Cygwin.patch
new file mode 100644
index 0000000..2678ed4
--- /dev/null
+++ b/0002-Increase-tolerance-in-small_blas-test-for-Cygwin.patch
@@ -0,0 +1,32 @@
+From 99f953d5d97c7e6366879643a6e391bffb5cdf54 Mon Sep 17 00:00:00 2001
+From: Alex Stewart <alexs.mac at gmail.com>
+Date: Mon, 30 Mar 2015 19:54:26 +0100
+Subject: [PATCH] Increase tolerance in small_blas test for Cygwin.
+
+- Previous tolerance of 2.0 * std::numeric_limits<double>::epsilon()
+  was too tight for Cygwin, worked on all other known platforms.
+
+Change-Id: Ia79ad8961272dbb608d8e8ddd3f6d52e5f0735f4
+
+Conflicts:
+	internal/ceres/small_blas_test.cc
+---
+ internal/ceres/small_blas_test.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/internal/ceres/small_blas_test.cc b/internal/ceres/small_blas_test.cc
+index b8b5bc5..5efceb5 100644
+--- a/internal/ceres/small_blas_test.cc
++++ b/internal/ceres/small_blas_test.cc
+@@ -37,7 +37,7 @@ namespace ceres {
+ namespace internal {
+ 
+ TEST(BLAS, MatrixMatrixMultiply) {
+-  const double kTolerance = 1e-16;
++  const double kTolerance = 3.0 * std::numeric_limits<double>::epsilon();;
+   const int kRowA = 3;
+   const int kColA = 5;
+   Matrix A(kRowA, kColA);
+-- 
+1.8.3.1
+
diff --git a/ceres-solver.spec b/ceres-solver.spec
index ae2cfdc..6385c6d 100644
--- a/ceres-solver.spec
+++ b/ceres-solver.spec
@@ -15,6 +15,7 @@ Source0:        http://%{name}.org/%{name}-%{version}.tar.gz
 # Cherry-pick upstream fix for linker error.
 # https://groups.google.com/d/msg/ceres-solver/58m1efsZZCc/OS8sYjbkEm4J
 Patch1:         0001-Add-SuiteSparse-link-dependency-for-compressed_col_s.patch
+Patch2:         0002-Increase-tolerance-in-small_blas-test-for-Cygwin.patch
 
 %if (0%{?rhel} == 06)
 BuildRequires:  cmake28 >= 2.8.0
@@ -86,6 +87,7 @@ developing applications that use %{name}.
 %prep
 %setup -q
 %patch1 -p1
+%patch2 -p1
 
 %build
 mkdir build
@@ -131,6 +133,9 @@ CTEST_OUTPUT_ON_FAILURE=1 make -C build test
 
 
 %changelog
+* Fri Apr  3 2015 Taylor Braun-Jones <taylor.braun-jones at ge.com> - 1.10.0-3
+- Add upstream patch to fix failing unit test small_blas_test.
+
 * Thu Mar 12 2015 Taylor Braun-Jones <taylor.braun-jones at ge.com> - 1.10.0-3
 - Incorporate package review suggestions from Alex Stewart, Christopher Meng,
   and Rich Mattes.
-- 
cgit v0.10.2


	http://pkgs.fedoraproject.org/cgit/ceres-solver.git/commit/?h=f21&id=c05e954b093454de9723b8cadbd79c3f8f10d080


More information about the scm-commits mailing list