Control: tags -1 patch

Hi!

The attached debdiff contains a patch which fixes the issue for me. I changed
the type for imode inside rounding_mode_struct from long_long_type to its
unsigned counterpart ulong_long_type so that assigning the large unsigned
R-values wouldn't trigger the narrowing-conversion warning anymore:

--- 
gecode-4.4.0.orig/gecode/third-party/boost/numeric/interval/detail/ppc_rounding_control.hpp
+++ 
gecode-4.4.0/gecode/third-party/boost/numeric/interval/detail/ppc_rounding_control.hpp
@@ -24,7 +24,7 @@ namespace interval_lib {
 namespace detail {

 typedef union {
-   ::gecode_boost::long_long_type imode;
+   ::gecode_boost::ulong_long_type imode;
   double dmode;
 } rounding_mode_struct;

Successfully tested on the ppc64 porterbox pizzetti.debian.org. I couldn't
test on plummer.debian.org for ppc64el since the machine is down at the
moment.

Adrian

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaub...@debian.org
`. `'   Freie Universitaet Berlin - glaub...@physik.fu-berlin.de
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
diff -Nru gecode-4.4.0/debian/changelog gecode-4.4.0/debian/changelog
--- gecode-4.4.0/debian/changelog	2015-09-05 23:20:35.000000000 +0300
+++ gecode-4.4.0/debian/changelog	2017-03-19 00:01:25.000000000 +0300
@@ -1,3 +1,12 @@
+gecode (4.4.0-3.1) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * Add ppc_use_ulong-long-type patch to use ulong_long_type inside
+    rounding_mode_struct to fix narrowing conversion issue on all
+    PowerPC targets. (Closes: #858132)
+
+ -- John Paul Adrian Glaubitz <glaub...@physik.fu-berlin.de>  Sat, 18 Mar 2017 22:01:25 +0100
+
 gecode (4.4.0-3) unstable; urgency=medium
 
   * Library transition for GCC 5 (Closes: #791042)
diff -Nru gecode-4.4.0/debian/patches/ppc_use_ulong-long-type gecode-4.4.0/debian/patches/ppc_use_ulong-long-type
--- gecode-4.4.0/debian/patches/ppc_use_ulong-long-type	1970-01-01 03:00:00.000000000 +0300
+++ gecode-4.4.0/debian/patches/ppc_use_ulong-long-type	2017-03-19 00:01:25.000000000 +0300
@@ -0,0 +1,15 @@
+Description: Use ulong_long_type for imode on PowerPC
+Author: John Paul Adrian Glaubitz <glaub...@physik.fu-berlin.de>
+Last-Update: 2017-03-18
+
+--- gecode-4.4.0.orig/gecode/third-party/boost/numeric/interval/detail/ppc_rounding_control.hpp
++++ gecode-4.4.0/gecode/third-party/boost/numeric/interval/detail/ppc_rounding_control.hpp
+@@ -24,7 +24,7 @@ namespace interval_lib {
+ namespace detail {
+ 
+ typedef union {
+-   ::gecode_boost::long_long_type imode;
++   ::gecode_boost::ulong_long_type imode;
+   double dmode;
+ } rounding_mode_struct;
+ 
diff -Nru gecode-4.4.0/debian/patches/series gecode-4.4.0/debian/patches/series
--- gecode-4.4.0/debian/patches/series	2015-04-29 22:47:28.000000000 +0300
+++ gecode-4.4.0/debian/patches/series	2017-03-19 00:01:25.000000000 +0300
@@ -1,2 +1,3 @@
 no-O3
 bison-3-support
+ppc_use_ulong-long-type

Reply via email to