2023-04-06 19:50:18 +08:00
|
|
|
# TODO - this may belong in /lib and not /usr/lib
|
|
|
|
|
2023-04-16 23:46:34 +08:00
|
|
|
# Many (most?) distributions put install-info in /{,usr/}sbin
|
|
|
|
# YJL defines this macro to /usr/bin/install-info
|
|
|
|
# so define it to be in /sbin/ if not defined.
|
|
|
|
%if %{!?insinfo:1}%{?insinfo:0}
|
|
|
|
%global insinfo /sbin/install-info
|
|
|
|
%endif
|
2023-04-06 19:50:18 +08:00
|
|
|
|
2023-04-16 23:46:34 +08:00
|
|
|
%global tarname mpc
|
2023-04-06 19:50:18 +08:00
|
|
|
|
2023-04-16 23:46:34 +08:00
|
|
|
Name: lib%{tarname}
|
|
|
|
Version: 1.3.1
|
|
|
|
Release: %{?repo}0.rc2%{?dist}
|
|
|
|
Summary: Complex floating point library
|
|
|
|
|
|
|
|
Group: System Environment/Libraries
|
|
|
|
License: LGPLv3
|
|
|
|
URL: https://directory.fsf.org/wiki/Mpc
|
|
|
|
Source0: https://ftp.gnu.org/gnu/mpc/%{tarname}-%{version}.tar.gz
|
|
|
|
|
|
|
|
BuildRequires: gmp-devel
|
|
|
|
BuildRequires: mpfr-devel
|
2023-04-06 19:50:18 +08:00
|
|
|
|
|
|
|
%description
|
|
|
|
MPC is a C library for the arithmetic of complex numbers with arbitrarily
|
|
|
|
high precision and correct rounding of the result. It extends the
|
|
|
|
principles of the IEEE-754 standard for fixed precision real floating
|
|
|
|
point numbers to complex numbers, providing well-defined semantics for
|
|
|
|
every operation. At the same time, speed of operation at high precision
|
|
|
|
is a major design goal.
|
|
|
|
|
|
|
|
%package devel
|
2023-04-16 23:46:34 +08:00
|
|
|
Summary: Development files for libmpc
|
|
|
|
Group: Development/Libraries
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
2023-04-06 19:50:18 +08:00
|
|
|
|
|
|
|
%description devel
|
|
|
|
This package contains the files necessary to compile software that
|
2023-04-16 23:46:34 +08:00
|
|
|
links against the libmpc library.
|
2023-04-06 19:50:18 +08:00
|
|
|
|
|
|
|
%prep
|
2023-04-16 23:46:34 +08:00
|
|
|
%setup -n %{tarname}-%{version}
|
2023-04-06 19:50:18 +08:00
|
|
|
|
|
|
|
%build
|
|
|
|
%configure --disable-static
|
|
|
|
make %{?_smp_mflags}
|
|
|
|
make html
|
|
|
|
|
|
|
|
%check
|
|
|
|
make check > %{name}-make.check.log 2>&1
|
|
|
|
|
|
|
|
%install
|
|
|
|
make install DESTDIR=%{buildroot}
|
|
|
|
|
|
|
|
%post -p /sbin/ldconfig
|
|
|
|
%postun -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%post devel
|
2023-04-16 23:46:34 +08:00
|
|
|
%{insinfo} %{_infodir}/mpc.info %{_infodir}/dir ||:
|
2023-04-06 19:50:18 +08:00
|
|
|
|
|
|
|
%preun devel
|
|
|
|
if [ $1 = 0 ]; then
|
2023-04-16 23:46:34 +08:00
|
|
|
%{insinfo} --delete %{_infodir}/mpc.info %{_infodir}/dir ||:
|
2023-04-06 19:50:18 +08:00
|
|
|
fi
|
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root,-)
|
|
|
|
%attr(0755,root,root) %{_libdir}/libmpc.so.3.3.1
|
|
|
|
%{_libdir}/libmpc.so.3
|
|
|
|
%license COPYING.LESSER
|
|
|
|
%doc AUTHORS COPYING.LESSER NEWS README TODO
|
|
|
|
%doc %{name}-make.check.log
|
|
|
|
|
|
|
|
%files devel
|
|
|
|
%defattr(-,root,root,-)
|
|
|
|
%attr(0644,root,root) %{_includedir}/mpc.h
|
|
|
|
%{_libdir}/libmpc.so
|
|
|
|
%attr(0644,root,root) %{_infodir}/mpc.info*
|
|
|
|
%exclude %{_infodir}/dir
|
2023-04-16 23:46:34 +08:00
|
|
|
%license COPYING.LESSER
|
2023-04-17 01:32:02 +08:00
|
|
|
%doc COPYING.LESSER doc/mpc.html
|
2023-04-06 19:50:18 +08:00
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
2023-04-16 23:46:34 +08:00
|
|
|
* Sun Apr 16 2023 Michael A. Peters <anymouseprophet@gmail.com> - 1.3.1-0.rc2
|
|
|
|
- Use %%insinfo macro
|
|
|
|
|
2023-04-06 19:50:18 +08:00
|
|
|
* Thu Apr 06 2023 Michael A. Peters <anymouseprophet@gmail.com> - 1.3.1-0.rc1
|
|
|
|
- Initial spec file for YJL (RPM bootstrapping LFS/BLFS 11.3)
|