%define major 23 %define libname %mklibname %{name} %{major} %define develname %mklibname %{name} -d %define majorxx 8 %define libnamexx %mklibname %{name}xx %{majorxx} Name: mpir Version: 3.0.0 Release: %mkrel 7 Summary: Multiprecision integer library derived from GMP License: LGPLv3+ Group: System/Libraries Url: https://github.com/wbhart/mpir Source: https://mpir.org/%{name}-%{version}.tar.bz2 # Enable aarch64 support Patch0: %{name}-aarch64.patch Patch1: 0001-Fix-configure-failures-with-Xcode12.patch # ppc64 assembly has not yet been ported to little endian ExcludeArch: ppc64le BuildRequires: gcc-c++ BuildRequires: m4 BuildRequires: yasm %description MPIR is a library for arbitrary precision arithmetic, operating on signed integers, rational numbers, and floating point numbers. It has a rich set of functions, and the functions have a regular interface. #------------------------------------------------ %package -n %{libname} Summary: Multiprecision integer library derived from GMP Group: System/Libraries %description -n %{libname} MPIR is a library for arbitrary precision arithmetic, operating on signed integers, rational numbers, and floating point numbers. It has a rich set of functions, and the functions have a regular interface. #------------------------------------------------ %package -n %{libnamexx} Summary: Multiprecision integer library derived from GMP Group: System/Libraries %description -n %{libnamexx} MPIR is a library for arbitrary precision arithmetic, operating on signed integers, rational numbers, and floating point numbers. It has a rich set of functions, and the functions have a regular interface. #------------------------------------------------ %package -n %{develname} Summary: Development package for %{name} Group: Development/C++ Requires: %{libname} >= %{version}-%{release} Requires: %{libnamexx} >= %{version}-%{release} Provides: %{name}-devel = %{version}-%{release} Provides: lib%{name}-devel = %{version}-%{release} Provides: %{name}xx-devel = %{version}-%{release} Provides: lib%{name}xx-devel = %{version}-%{release} Requires(pre): info-install Requires(postun): info-install %description -n %{develname} MPIR is an open source multiprecision integer library derived from version 4.2.1 of the GMP. MPIR is a library for arbitrary precision arithmetic, operating on signed integers, rational numbers, and floating point numbers. It has a rich set of functions, and the functions have a regular interface. This subpackage contains libraries and header files for developing applications that want to make use of libmpir. #------------------------------------------------ %prep %autosetup -p1 %build # Use -fwrap due to https://github.com/wbhart/mpir/issues/295 # Use -Wno-implicit-int and -Wno-implicit-function-declaration due to gcc14 export CFLAGS="%{optflags} -fexceptions -Wno-error=return-type -Wno-implicit-int -Wno-implicit-function-declaration -fwrapv" export CXXFLAGS="%{optflags} -fexceptions -Wno-error=return-type -Wno-implicit-int -Wno-implicit-function-declaration -fwrapv" %configure \ --disable-static \ --enable-cxx \ --enable-fat \ --with-yasm=%{_bindir}/yasm %make_build %install %make_install # we don't want these find %{buildroot} -name '*.la' -delete %check export LD_LIBRARY_PATH=$PWD/.libs make check %files -n %{libname} %{_libdir}/libmpir.so.%{major}{,.*} %files -n %{libnamexx} %{_libdir}/libmpirxx.so.%{majorxx}{,.*} %files -n %{develname} %doc COPYING README %{_includedir}/*.h %{_libdir}/libmpir.so %{_libdir}/libmpirxx.so %{_infodir}/mpir.info*.* %changelog * Thu Apr 04 2024 daviddavid <daviddavid> 3.0.0-7.mga10 + Revision: 2054398 - hack around gcc14 build failure adding '-Wno-implicit-int' and '-Wno-implicit-function-declaration' build flags * Tue Nov 15 2022 daviddavid <daviddavid> 3.0.0-6.mga9 + Revision: 1907391 - build with -fwrapv in order to fix: https://github.com/wbhart/mpir/issues/295 + umeabot <umeabot> - Mageia 9 Mass Rebuild * Wed Aug 19 2020 ovitters <ovitters> 3.0.0-5.mga8 + Revision: 1616017 - remove install-info scriptlets, rely on filetrigger instead (mga#27107) * Mon Feb 17 2020 umeabot <umeabot> 3.0.0-4.mga8 + Revision: 1537751 - Mageia 8 Mass Rebuild + wally <wally> - replace deprecated %%configure2_5x * Thu Nov 07 2019 daviddavid <daviddavid> 3.0.0-3.mga8 + Revision: 1458682 - add virtual provide on mpirxx-devel * Sun Sep 23 2018 umeabot <umeabot> 3.0.0-2.mga7 + Revision: 1299625 - Mageia 7 Mass Rebuild * Sun Oct 08 2017 daviddavid <daviddavid> 3.0.0-1.mga7 + Revision: 1170120 - imported package mpir