Blob Blame History Raw
Summary: High performance compressor optimized for binary data
Name: blosc
Version: 1.14.4
Release: 1%{?dist}
License: MIT
Source: https://github.com/Blosc/c-blosc/archive/v%{version}/blosc-%{version}.tar.gz

URL:  https://github.com/Blosc/c-blosc
BuildRequires: gcc
BuildRequires: gcc-c++
BuildRequires: cmake
BuildRequires: lz4-devel
BuildRequires: snappy-devel
BuildRequires: zlib-devel
BuildRequires: libzstd-devel

%description
Blosc is a compression library designed to transmit data to the processor
cache faster than the traditional non-compressed memory fetch.
Compression ratios are not very high, but the decompression is very fast.
Blosc is meant not only to reduce the size of large datasets on-disk or
in-memory, but also to accelerate memory-bound computations.

%package devel
Summary: Header files and libraries for Blosc development
Requires: %{name}%{?_isa} = %{version}-%{release}

%description devel
The blosc-devel package contains the header files and libraries needed
to develop programs that use the blosc meta-compressor.

%package bench
Summary: Benchmark for the Blosc compressor
Requires: %{name} = %{version}-%{release}
Requires: python3-matplotlib

%description bench
The blosc-bench package contains a benchmark suite which evaluates
the performance of Blosc, and compares it with memcpy.

%prep
%autosetup -n c-%{name}-%{version} -p1
rm -r internal-complibs/snappy* internal-complibs/zlib*

# Fix rpath issue
sed -i '1i  set\(CMAKE_SKIP_RPATH true\)' bench/CMakeLists.txt

# Fix cmake detection of pthreads
sed -i '1i  set\(CMAKE_POSITION_INDEPENDENT_CODE TRUE\)' CMakeLists.txt

# https://github.com/Blosc/c-blosc/issues/190
sed -i 's|lib/pkgconfig|%{_lib}/pkgconfig|' CMakeLists.txt

# Add python shebang and permission
sed -i '1i  #!/usr/bin/python3' bench/plot-speeds.py

%build
# Use the proper library path and SSE2 instruction on 64bits systems
%cmake \
%ifarch x86_64
    %{?_cmake_lib_suffix64} \
%endif
    -DCMAKE_BUILD_TYPE:STRING="Debug" \
    -DCMAKE_C_FLAGS:STRING="%{optflags}" \
    -DCMAKE_INSTALL_PREFIX=%{_prefix} \
    -DBUILD_STATIC:BOOL=OFF \
    -DPREFER_EXTERNAL_LZ4:BOOL=ON \
    -DTEST_INCLUDE_BENCH_SUITE:BOOL=OFF \
    -DPREFER_EXTERNAL_SNAPPY:BOOL=ON \
    -DPREFER_EXTERNAL_ZLIB:BOOL=ON \
    -DPREFER_EXTERNAL_ZSTD:BOOL=ON \
    .

# Parallel build failed
make VERBOSE=1 #{?_smp_mflags}

%check
LD_LIBRARY_PATH=%{buildroot}%{_libdir} make test VERBOSE=1

%install
%make_install

install -p bench/plot-speeds.py* -Dt %{buildroot}/%{_pkgdocdir}/bench/
install -pm 0644 bench/*.c %{buildroot}/%{_pkgdocdir}/bench

install -p bench/bench -D %{buildroot}/%{_bindir}/%{name}-bench
install -p bench/plot-speeds.py %{buildroot}/%{_bindir}/%{name}-plot-times

%files
%exclude %{_pkgdocdir}/bench/
%license LICENSES/*
%doc README.md ANNOUNCE.rst RELEASE_NOTES.rst README_HEADER.rst README_THREADED.rst
%{_libdir}/libblosc.so.1*

%files devel
%{_libdir}/libblosc.so
%{_libdir}/pkgconfig/blosc.pc
%{_includedir}/blosc.h
%{_includedir}/blosc-export.h

%files bench
%{_pkgdocdir}/bench/*.c
%{_bindir}/%{name}-bench
%{_bindir}/%{name}-plot-times


%changelog
* Mon Nov 12 2018 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.14.4-1
- Update to latest version (#1609768)

* Thu Jul 19 2018 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.14.3-1
- Update to latest version
- Drop obsolete ldconfig invocations

* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.13.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild

* Thu Jan 25 2018 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.13.3-1
- Update to latest version (#1536731)

* Thu Jan 18 2018 Jan Beran <jberan@redhat.com> - 1.13.1-1
* New version using Python 3

* Wed Aug 02 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.11.3-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild

* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.11.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild

* Sat Mar 11 2017 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.11.3-1
- Update to latest version
- Build against external zstd
- A pkgconfig file is now provided

* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.11.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild

* Mon Nov 07 2016 Than Ngo <than@redhat.com> - 1.11.1-2
- Fix the bigendian issue which causes build failure in PyTables (bz#1379123)

* Sun Nov  6 2016 Orion Poplawski <orion@cora.nwra.com> - 1.11.1-1
- Update to 1.11.1 (#1361777)
- Run cmake in %%build

* Mon Sep 26 2016 Dominik Mierzejewski <rpm@greysector.net> - 1.10.1-2
- rebuilt for matplotlib-2.0.0

* Thu Jul 28 2016 Zbigniew Jędrzejewski-Szmek <zbyszek@bupkis> - 1.10.1-1
- Update to latest version (#1323008)

* Thu Jul 14 2016 Thibault North <tnorth@fedoraproject.org> - 1.9.3-1
- Update to 1.9.3 (#1211599)
- Remove 32-bits test patch now integrated

* Mon May 16 2016 Orion Poplawski <orion@cora.nwra.com> - 1.9.0-1
- Update to 1.9.0 (#1211599)
- Update URL
- Disable parallel build
- Run all tests
- Ship license files

* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.6.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild

* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.6.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild

* Wed May  6 2015 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.6.1-1
- Update to 1.6.1 (#1211599)

* Mon Apr 20 2015 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.5.4-1
- Update to 1.5.4 (#1211599)

* Tue Jan 06 2015 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.5.2-1
- Update to 1.5.2 (#1115808)

* Fri Aug 15 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.3.5-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild

* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.3.5-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild

* Sat Mar 22 2014 Thibault North <tnorth@fedoraproject.org> - 1.3.5-1
- Update to 1.3.5

* Fri Mar 21 2014 Thibault North <tnorth@fedoraproject.org> - 1.3.4-1
- Update to 1.3.4

* Tue Jan 07 2014 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.3.0-1.rc2
- Attempt to package new version

* Tue Oct 22 2013 Thibault North <tnorth@fedoraproject.org> - 1.2.3-9
- Fix flags and bench compilation

* Mon Oct 21 2013 Thibault North <tnorth@fedoraproject.org> - 1.2.3-8
- Fix docdir for F<20 and remove sse flag

* Mon Oct 21 2013 Thibault North <tnorth@fedoraproject.org> - 1.2.3-7
- Use install instead of cp, more fixes

* Mon Oct 21 2013 Thibault North <tnorth@fedoraproject.org> - 1.2.3-6
- Fixes

* Mon Oct 21 2013 Thibault North <tnorth@fedoraproject.org> - 1.2.3-5
- Use pkgdocdir, various fixes.

* Mon Oct 21 2013 Thibault North <tnorth@fedoraproject.org> - 1.2.3-4
- Fix docdir, add blosc-bench subpackage

* Fri Oct 18 2013 Thibault North <tnorth@fedoraproject.org> - 1.2.3-3
- Fixes (thanks Zbigniew Jędrzejewski-Szmek)

* Wed Oct 16 2013 Thibault North <tnorth@fedoraproject.org> - 1.2.3-2
- Various fixes

* Fri Sep 20 2013 Thibault North <tnorth@fedoraproject.org> - 1.2.3-1
- Sync upstream

* Fri Mar 22 2013 Thibault North <tnorth@fedoraproject.org> - 1.1.6-1
- Initial package