# Copyright Verizon Media. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. # Force special prefix for Vespa %define _prefix /opt/vespa-deps # Only strip debug info %global _find_debuginfo_opts -g # Version %define ver_major 4 %define ver_minor 1 %define ver_patch 0 %define ver_release 3 Summary : mpfr compiled for vespa Name : vespa-mpfr Version : %{ver_major}.%{ver_minor}.%{ver_patch} Release : %{ver_release}%{?dist} Group : Development/Tools License : LGPLv3+ and GPLv3+ and GFDL URL : http://www.mpfr.org/ Source0 : https://www.mpfr.org/mpfr-4.1.0/mpfr-4.1.0.tar.bz2 %if 0%{?el7} %define _devtoolset_enable /opt/rh/devtoolset-9/enable BuildRequires: devtoolset-9-gcc %endif %if 0%{?el8} %define _devtoolset_enable /opt/rh/gcc-toolset-9/enable BuildRequires: gcc-toolset-9-gcc %endif %if 0%{?fedora} BuildRequires: gcc %endif BuildRequires: make BuildRequires: vespa-gmp Requires: vespa-gmp %description mpfr compiled for vespa The MPFR library is a C library for multiple-precision floating-point computations with "correct rounding". The MPFR is efficient and also 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). MPFR is based on the GMP multiple-precision library. %prep %setup -n mpfr-%{version} %build %if 0%{?_devtoolset_enable:1} source %{_devtoolset_enable} || true %endif export LD_RUN_PATH=%{_libdir} CFLAGS='-g -O2 ' ./configure --with-gmp-include=%{_prefix}/include --with-gmp-lib=%{_libdir} --enable-static=no --prefix=%{_prefix} --libdir=%{_libdir} make %{?_smp_mflags} %install %if 0%{?_devtoolset_enable:1} source %{_devtoolset_enable} || true %endif export LD_RUN_PATH=%{_libdir} make install DESTDIR=$RPM_BUILD_ROOT rm -f $RPM_BUILD_ROOT%{_infodir}/dir %files %{_libdir} %{_includedir} %{_infodir} %{_prefix}/share/doc %changelog