SHA256
3
0
forked from pool/mpfr
mpfr/mpfr.spec
Richard Biener 29e86add7c - Add mpfr-4.0.1-cummulative-patch.patch. Fixes
* A subtraction of two numbers of the same sign or addition of two
    numbers of different signs can be rounded incorrectly (and the
    ternary value can be incorrect) when one of the two inputs is
    reused as the output (destination) and all these MPFR numbers
    have exactly GMP_NUMB_BITS bits of precision (typically, 32 bits
    on 32-bit machines, 64 bits on 64-bit machines).
  * The mpfr_fma and mpfr_fms functions can behave incorrectly in case
    of internal overflow or underflow.
  * The result of the mpfr_sqr function can be rounded incorrectly
    in a rare case near underflow when the destination has exactly
    GMP_NUMB_BITS bits of precision (typically, 32 bits on 32-bit
    machines, 64 bits on 64-bit machines) and the input has at most
    GMP_NUMB_BITS bits of precision.
  * The behavior and documentation of the mpfr_get_str function are
    inconsistent concerning the minimum precision (this is related to
    the change of the minimum precision from 2 to 1 in MPFR 4.0.0). The
    get_str patch fixes this issue in the following way: the value 1
    can now be provided for n (4th argument of mpfr_get_str); if n = 0,
    then the number of significant digits in the output string can now
    be 1, as already implied by the documentation (but the code was
    increasing it to 2).
  * The mpfr_cmp_q function can behave incorrectly when the rational
    (mpq_t) number has a null denominator.
  * The mpfr_inp_str and mpfr_out_str functions might behave
    incorrectly when the stream is a null pointer: the stream is
    replaced by stdin and stdout, respectively. This behavior is
    useless, not documented (thus incorrect in case a null pointer
    would have a special meaning), and not consistent with other
    input/output functions.

OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/mpfr?expand=0&rev=51
2018-05-02 09:02:53 +00:00

111 lines
3.4 KiB
RPMSpec

#
# spec file for package mpfr
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Name: mpfr
Version: 4.0.1
Release: 0
Summary: The GNU multiple-precision floating-point library
License: LGPL-3.0+
Group: Development/Libraries/C and C++
Url: http://www.mpfr.org/
Source0: http://www.mpfr.org/mpfr-%{version}/mpfr-%{version}.tar.bz2
Source1: http://www.mpfr.org/mpfr-%{version}/mpfr-%{version}.tar.bz2.asc
Source2: %{name}.keyring
Source3: baselibs.conf
Patch: mpfr-4.0.1-cummulative-patch.patch
BuildRequires: gmp-devel
BuildRequires: pkgconfig
%description
The MPFR library is a C library for multiple-precision floating-point
computations with exact rounding (also called correct rounding). It is
based on the GMP multiple-precision library.
The main goal of MPFR is to provide a library for multiple-precision
floating-point computation which is both efficient and has a
well-defined semantics. It copies the good ideas from the ANSI/IEEE-754
standard for double-precision floating-point arithmetic (53-bit
mantissa).
%package -n libmpfr6
Summary: The GNU multiple-precision floating-point shared library
Group: Development/Libraries/C and C++
%description -n libmpfr6
The MPFR library is a C library for multiple-precision floating-point
computations with exact rounding (also called correct rounding). It is
based on the GMP multiple-precision library.
%package devel
Summary: Development files for the GNU multiple-precision floating-point library
Group: Development/Libraries/C and C++
Requires: gmp-devel
Requires: libmpfr6 = %{version}
Requires(pre): %{install_info_prereq}
%description devel
Development files for the GNU multiple-precision floating-point library.
The MPFR library is a C library for multiple-precision floating-point
computations with exact rounding (also called correct rounding). It is
based on the GMP multiple-precision library.
%prep
%setup -q
%patch -p1
%build
%configure \
%ifarch %{sparc} hppa
--disable-thread-safe \
%else
--enable-thread-safe \
%endif
--enable-shared \
--disable-static \
--docdir=%{_docdir}/%{name}
make %{?_smp_mflags}
%check
make check %{?_smp_mflags}
%install
%make_install
find %{buildroot} -type f -name "*.la" -delete -print
%post -n libmpfr6 -p /sbin/ldconfig
%post devel
%install_info --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz
%postun -n libmpfr6 -p /sbin/ldconfig
%postun devel
%install_info_delete --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz
%files -n libmpfr6
%{_libdir}/libmpfr.so.6*
%files devel
%doc %{_docdir}/mpfr
%{_infodir}/mpfr.info%{ext_info}
%{_libdir}/libmpfr.so
%{_includedir}/mpf2mpfr.h
%{_includedir}/mpfr.h
%{_libdir}/pkgconfig/mpfr.pc
%changelog