From e911d0897c72244cd579a5598ec9113a134d9842 Mon Sep 17 00:00:00 2001 From: Björn Esser Date: Feb 24 2016 20:10:15 +0000 Subject: fix build with gcc 6 --- diff --git a/arprec-2.2.18-fix_gcc6.patch b/arprec-2.2.18-fix_gcc6.patch new file mode 100644 index 0000000..713d284 --- /dev/null +++ b/arprec-2.2.18-fix_gcc6.patch @@ -0,0 +1,12 @@ +Index: arprec-2.2.18/src/write.cpp +=================================================================== +--- arprec-2.2.18.orig/src/write.cpp ++++ arprec-2.2.18/src/write.cpp +@@ -196,6 +196,6 @@ bool mp_real::write(ostream &s, int prec + + string str = to_string(precision, width, expn_width, + fmt, showpos, uppercase, fill); +- return (s << str) != 0; ++ return static_cast(s << str) != 0; + } + diff --git a/arprec.spec b/arprec.spec index 7822dc6..40e0633 100644 --- a/arprec.spec +++ b/arprec.spec @@ -13,7 +13,7 @@ Name: arprec Version: 2.2.18 -Release: 2%{?dist} +Release: 3%{?dist} Summary: Software package for performing arbitrary precision arithmetic %{?el5:Group: System Environment/Libraries} @@ -22,6 +22,9 @@ URL: http://crd.lbl.gov/~dhbailey/mpdist Source0: %{url}/%{name}-%{version}.tar.gz Source1: %{url}/BSD-LBNL-License.doc +# fixes for GCC 6 +Patch0001: arprec-2.2.18-fix_gcc6.patch + %{?el5:BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)} BuildRequires: catdoc BuildRequires: chrpath @@ -122,6 +125,9 @@ series. %prep %setup -q +# Apply patches. +%patch0001 -p 1 -b .gcc6 + # Pull-in upstream's .doc-license. %{__cp} -a %{SOURCE1} . @@ -415,6 +421,9 @@ done %changelog +* Wed Feb 24 2016 Björn Esser - 2.2.18-3 +- fix build with gcc 6 + * Wed Feb 03 2016 Fedora Release Engineering - 2.2.18-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild