Package: visp
Version: 3.0.1-2
Severity: important
Tags: patch
User: ubuntu-de...@lists.ubuntu.com
Usertags: origin-ubuntu artful ubuntu-patch

Dear maintainers,

When rebuilding visp for the libgsl transition in Ubuntu, we found that the
package FTBFS on i386 with a test failure:

 19/196 Test  #19: testColVector 
.....................................................***Failed    0.01 sec
[...]
regular_sumSquare=3.654335195e+10 ; sse_sumSquare=3.654335195e+10
t_regular=0.1711152792 ms ; t_sse=0.06501948833 ms
Speed-up: 2.631753703X
Problem when computing v.sumSquare()!

  
https://launchpad.net/ubuntu/+source/visp/3.0.1-2build2/+build/13205544/+files/buildlog_ubuntu-artful-i386.visp_3.0.1-2build2_BUILDING.txt.gz

The displayed value for each of the calculations is identical, but the
actual floating point values clearly differ by a quantity greater than the
tolerance.

Floating point is always a bit dodgy on i386, and in this case the problem
with non-IEEE results (whether that's due to a change in gsl or in gcc - I
haven't checked which) is fixed by building with -ffloat-store as in the
attached patch.

It's worth noting that the visp package also FTBFS in Debian already, but
with a different set of failures pointing to SIGILL.  visp appears to be
doing a lot of SSE math, which is not part of the ISA that's guaranteed to
be present for the i386 port in Debian (or in Ubuntu); so while I think this
patch is correct, I do not expect it to fix the Debian build failure on its own.

Hope that helps,
-- 
Steve Langasek                   Give me a lever long enough and a Free OS
Debian Developer                   to set it on, and I can move the world.
Ubuntu Developer                                    http://www.debian.org/
slanga...@ubuntu.com                                     vor...@debian.org
diff -Nru visp-3.0.1/debian/rules visp-3.0.1/debian/rules
--- visp-3.0.1/debian/rules     2017-02-13 08:52:30.000000000 -0800
+++ visp-3.0.1/debian/rules     2017-08-07 11:29:52.000000000 -0700
@@ -16,6 +16,10 @@
   CMAKE_ARCH_FLAGS = -DUSE_DC1394=OFF -DUSE_V4L2=OFF -DUSE_OIS=OFF
 endif
 
+ifeq ($(DEB_HOST_ARCH),i386)
+  CXXFLAGS += -ffloat-store
+endif
+
 # freenect is not available on hurd.
 ifeq ($(DEB_HOST_ARCH_OS),hurd)
   CMAKE_ARCH_FLAGS += -DUSE_LIBFREENECT=OFF
-- 
debian-science-maintainers mailing list
debian-science-maintainers@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/debian-science-maintainers

Reply via email to