Blame SPECS/qatlib.spec

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