Blame SPECS/xxhash.spec

3568d3
Name:		xxhash
3568d3
Version:	0.8.1
3568d3
Release:	3%{?dist}
3568d3
Summary:	Extremely fast hash algorithm
3568d3
3568d3
#		The source for the library (xxhash.c and xxhash.h) is BSD
3568d3
#		The source for the command line tool (xxhsum.c) is GPLv2+
3568d3
License:	BSD and GPLv2+
3568d3
URL:		http://www.xxhash.com/
3568d3
Source0:	https://github.com/Cyan4973/xxHash/archive/v%{version}/%{name}-%{version}.tar.gz
3568d3
3568d3
BuildRequires:	make
3568d3
BuildRequires:	gcc
3568d3
BuildRequires:	doxygen
3568d3
3568d3
Patch0:		1-fix-man-page-installation.patch
3568d3
3568d3
%description
3568d3
xxHash is an Extremely fast Hash algorithm, running at RAM speed
3568d3
limits. It successfully completes the SMHasher test suite which
3568d3
evaluates collision, dispersion and randomness qualities of hash
3568d3
functions. Code is highly portable, and hashes are identical on all
3568d3
platforms (little / big endian).
3568d3
3568d3
%package libs
3568d3
Summary:	Extremely fast hash algorithm - library
3568d3
License:	BSD
3568d3
3568d3
%description libs
3568d3
xxHash is an Extremely fast Hash algorithm, running at RAM speed
3568d3
limits. It successfully completes the SMHasher test suite which
3568d3
evaluates collision, dispersion and randomness qualities of hash
3568d3
functions. Code is highly portable, and hashes are identical on all
3568d3
platforms (little / big endian).
3568d3
3568d3
%package devel
3568d3
Summary:	Extremely fast hash algorithm - development files
3568d3
License:	BSD
3568d3
Requires:	%{name}-libs%{?_isa} = %{version}-%{release}
3568d3
# By setting XXH_INLINE_ALL, xxhash may be used as a header-only library.
3568d3
# Dependent packages that use xxhash this way must BR this virtual Provide:
3568d3
Provides:	%{name}-static = %{version}-%{release}
3568d3
3568d3
%description devel
3568d3
Development files for the xxhash library
3568d3
3568d3
%package doc
3568d3
Summary:	Extremely fast hash algorithm - documentation files
3568d3
License:	BSD
3568d3
BuildArch:	noarch
3568d3
3568d3
%description doc
3568d3
Documentation files for the xxhash library
3568d3
3568d3
%prep
3568d3
%setup -q -n xxHash-%{version}
3568d3
%patch0 -p1
3568d3
3568d3
%build
3568d3
# Enable runtime detection of sse2/avx2/avx512 on intel architectures
3568d3
%ifarch %{ix86} x86_64
3568d3
%global dispatch 1
3568d3
%else
3568d3
%global dispatch 0
3568d3
%endif
3568d3
3568d3
%make_build MOREFLAGS="%{__global_cflags} %{?__global_ldflags}" \
3568d3
	    DISPATCH=%{dispatch}
3568d3
doxygen
3568d3
3568d3
%install
3568d3
%make_install PREFIX=%{_prefix} LIBDIR=%{_libdir}
3568d3
rm %{buildroot}/%{_libdir}/libxxhash.a
3568d3
3568d3
%check
3568d3
make check
3568d3
make test-xxhsum-c
3568d3
3568d3
%ldconfig_scriptlets libs
3568d3
3568d3
%files
3568d3
%{_bindir}/xxh*sum
3568d3
%{_mandir}/man1/xxh*sum.1*
3568d3
%license cli/COPYING
3568d3
%doc cli/README.md
3568d3
3568d3
%files libs
3568d3
%{_libdir}/libxxhash.so.*
3568d3
%license LICENSE
3568d3
%doc README.md
3568d3
3568d3
%files devel
3568d3
%{_includedir}/xxhash.h
3568d3
%{_includedir}/xxh3.h
3568d3
%{_libdir}/libxxhash.so
3568d3
%{_libdir}/pkgconfig/libxxhash.pc
3568d3
3568d3
%files doc
3568d3
%doc doxygen/html
3568d3
3568d3
%changelog
3568d3
* Mon Jul 18 2022 Vladis Dronov <vdronov@redhat.com> - 0.8.1-3
3568d3
- Fix broken manpages (upstream commit 836f4e735cf3)
3568d3
- Add OSCI testing harness
3568d3
3568d3
* Fri Jun 17 2022 Vladis Dronov <vdronov@redhat.com> - 0.8.1-1
3568d3
- Packaging of xxhash v0.8.1 for CS and RHEL copied from Fedora 36