Blame SPECS/qatlib.spec

a0b995
# SPDX-License-Identifier: MIT
a0b995
0207a3
%global libqat_soversion  3
a0b995
%global libusdm_soversion 0
a0b995
Name:             qatlib
0207a3
Version:          22.07.0
6afffe
Release:          1%{?dist}
a0b995
Summary:          Intel QuickAssist user space library
a0b995
# The entire source code is released under BSD.
a0b995
# For a breakdown of inbound licenses see the INSTALL file.
a0b995
License:          BSD and (BSD or GPLv2)
a0b995
URL:              https://github.com/intel/%{name}
a0b995
Source0:          https://github.com/intel/%{name}/archive/%{version}/%{name}-%{version}.tar.gz
0207a3
BuildRequires:    systemd gcc make autoconf automake libtool systemd-devel openssl-devel zlib-devel yasm
a0b995
Requires(pre):    shadow-utils
0207a3
Recommends:       qatlib-service
a0b995
# https://bugzilla.redhat.com/show_bug.cgi?id=1897661
a0b995
ExcludeArch:      %{arm} aarch64 %{power64} s390x i686
a0b995
a0b995
%description
a0b995
Intel QuickAssist Technology (Intel QAT) provides hardware acceleration
a0b995
for offloading security, authentication and compression services from the
a0b995
CPU, thus significantly increasing the performance and efficiency of
a0b995
standard platform solutions.
a0b995
a0b995
Its services include symmetric encryption and authentication,
a0b995
asymmetric encryption, digital signatures, RSA, DH and ECC, and
a0b995
lossless data compression.
a0b995
a0b995
This package provides user space libraries that allow access to
a0b995
Intel QuickAssist devices and expose the Intel QuickAssist APIs.
a0b995
a0b995
%package       devel
a0b995
Summary:       Headers and libraries to build applications that use qatlib
a0b995
Requires:      %{name}%{?_isa} = %{version}-%{release}
a0b995
a0b995
%description   devel
a0b995
This package contains headers and libraries required to build applications
a0b995
that use the Intel QuickAssist APIs.
a0b995
6afffe
%package       tests
6afffe
Summary:       Sample applications that use qatlib
6afffe
Requires:      %{name}%{?_isa} = %{version}-%{release}
6afffe
6afffe
%description   tests
6afffe
This package contains sample applications that use the Intel QuickAssists APIs.
6afffe
0207a3
%package       service
0207a3
Summary:       A daemon for qatlib resources management
0207a3
Requires:      %{name}%{?_isa} = %{version}-%{release}
0207a3
%{?systemd_requires}
0207a3
0207a3
%description   service
0207a3
This package contains a daemon that manages QAT resources for the Intel
0207a3
QuickAssist Technology user space library (qatlib).
0207a3
a0b995
%prep
a0b995
%autosetup
a0b995
a0b995
%build
a0b995
autoreconf -vif
a0b995
%configure
a0b995
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
a0b995
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
a0b995
sed -i -e 's! -shared ! -Wl,--as-needed\0!g' libtool
a0b995
%make_build
a0b995
a0b995
%install
a0b995
%make_install
6afffe
make DESTDIR=%{buildroot} samples-install
039e00
rm %{buildroot}/%{_libdir}/libqat.la
039e00
rm %{buildroot}/%{_libdir}/libusdm.la
0207a3
rm %{buildroot}/%{_libdir}/libqat.a
0207a3
rm %{buildroot}/%{_libdir}/libusdm.a
a0b995
a0b995
%pre
a0b995
getent group qat >/dev/null || groupadd -r qat
a0b995
exit 0
a0b995
0207a3
%post          service
a0b995
%systemd_post qat.service
a0b995
0207a3
%preun         service
a0b995
%systemd_preun qat.service
a0b995
0207a3
%postun        service
a0b995
%systemd_postun_with_restart qat.service
a0b995
a0b995
%files
039e00
%doc INSTALL README.md
a0b995
%license LICENSE*
a0b995
%{_libdir}/libqat.so.%{libqat_soversion}*
a0b995
%{_libdir}/libusdm.so.%{libusdm_soversion}*
a0b995
a0b995
%files         devel
a0b995
%{_libdir}/libqat.so
a0b995
%{_libdir}/libusdm.so
a0b995
%{_includedir}/qat
a0b995
6afffe
%files         tests
0207a3
%doc quickassist/lookaside/access_layer/src/sample_code/README.txt
6afffe
%attr(0754,-,qat) %{_bindir}/cpa_sample_code
6afffe
%attr(0754,-,qat) %{_bindir}/dc_dp_sample
6afffe
%attr(0754,-,qat) %{_bindir}/dc_stateless_sample
6afffe
%attr(0754,-,qat) %{_bindir}/dc_stateless_multi_op_sample
6afffe
%attr(0754,-,qat) %{_bindir}/algchaining_sample
6afffe
%attr(0754,-,qat) %{_bindir}/ccm_sample
6afffe
%attr(0754,-,qat) %{_bindir}/cipher_sample
6afffe
%attr(0754,-,qat) %{_bindir}/gcm_sample
6afffe
%attr(0754,-,qat) %{_bindir}/hash_file_sample
6afffe
%attr(0754,-,qat) %{_bindir}/hash_sample
6afffe
%attr(0754,-,qat) %{_bindir}/ipsec_sample
6afffe
%attr(0754,-,qat) %{_bindir}/ssl_sample
6afffe
%attr(0754,-,qat) %{_bindir}/sym_dp_sample
6afffe
%attr(0754,-,qat) %{_bindir}/dh_sample
6afffe
%attr(0754,-,qat) %{_bindir}/eddsa_sample
6afffe
%attr(0754,-,qat) %{_bindir}/prime_sample
6afffe
%attr(0754,-,qat) %{_bindir}/hkdf_sample
6afffe
%attr(0754,-,qat) %{_bindir}/ec_montedwds_sample
6afffe
%{_datadir}/qat/calgary
6afffe
%{_datadir}/qat/calgary32
6afffe
%{_datadir}/qat/canterbury
6afffe
0207a3
%files         service
0207a3
%{_sbindir}/qatmgr
0207a3
%{_sbindir}/qat_init.sh
0207a3
%{_unitdir}/qat.service
0207a3
%{_mandir}/man8/qatmgr.8*
0207a3
%{_mandir}/man8/qat_init.sh.8*
0207a3
a0b995
%changelog
0207a3
* Fri Jul 22 2022 Vladis Dronov <vdronov@redhat.com> - 22.07.0-1
0207a3
- Update to qatlib 22.07 (bz 2040743)
0207a3
- Moved qat.service to separate rpm
0207a3
6afffe
* Thu Nov 11 2021 Vladis Dronov <vdronov@redhat.com> - 21.11.0-1
6afffe
- Update to qatlib 21.11 (bz 1960303)
6afffe
- Add qatlib-tests package
6afffe
- Add OSCI testing harness
6afffe
039e00
* Fri Aug 27 2021 Vladis Dronov <vdronov@redhat.com> - 21.05.0-2
039e00
- Add documentation files to the main package
039e00
039e00
* Tue Jun  8 2021 Vladis Dronov <vdronov@redhat.com> - 21.05.0-1
039e00
- Update to qatlib 21.05 (bz 1920237)
039e00
a0b995
* Tue Feb  9 2021 Vladis Dronov <vdronov@redhat.com> - 20.10.0-3
a0b995
- Add OSCI testing harness (bz 1907482)
a0b995
a0b995
* Mon Dec 14 2020 Giovanni Cabiddu <giovanni.cabiddu@intel.com> - 20.10.0-2
a0b995
- Add ExcludeArch i686
a0b995
a0b995
* Mon Nov 16 2020 Giovanni Cabiddu <giovanni.cabiddu@intel.com> - 20.10.0-1
a0b995
- Update to qatlib 20.10
a0b995
- Fixes to spec to address comments from Fedora review
a0b995
a0b995
* Mon Aug 10 2020 Mateusz Polrola <mateuszx.potrola@intel.com> - 20.08.0-1
a0b995
- Initial version of the package