2012-11-30 10:09:29 +00:00
|
|
|
#
|
|
|
|
# spec file for package snappy
|
|
|
|
#
|
2015-07-29 10:05:15 +00:00
|
|
|
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
|
2012-11-30 10:09:29 +00:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2015-07-29 10:05:15 +00:00
|
|
|
|
2013-08-15 12:50:54 +00:00
|
|
|
%define lib_name libsnappy1
|
2012-11-30 10:09:29 +00:00
|
|
|
Name: snappy
|
2015-07-29 11:03:33 +00:00
|
|
|
Version: 1.1.3
|
2013-08-15 12:50:54 +00:00
|
|
|
Release: 0
|
|
|
|
Summary: A fast compressor/decompressor library
|
2013-08-22 15:40:34 +00:00
|
|
|
License: BSD-3-Clause
|
2012-11-30 10:09:29 +00:00
|
|
|
Group: Development/Libraries/C and C++
|
2015-07-29 11:03:33 +00:00
|
|
|
Url: https://github.com/google/snappy/
|
|
|
|
Source0: https://github.com/google/snappy/archive/%{version}.tar.gz
|
2015-07-29 10:05:15 +00:00
|
|
|
Source99: baselibs.conf
|
2015-07-29 11:03:33 +00:00
|
|
|
BuildRequires: autoconf
|
|
|
|
BuildRequires: automake
|
2013-08-15 12:50:54 +00:00
|
|
|
BuildRequires: gcc-c++
|
2015-07-29 11:03:33 +00:00
|
|
|
BuildRequires: libtool
|
2013-08-15 12:50:54 +00:00
|
|
|
BuildRequires: lzo-devel
|
2015-07-29 11:03:33 +00:00
|
|
|
BuildRequires: pkgconfig
|
2013-08-15 12:50:54 +00:00
|
|
|
BuildRequires: zlib-devel
|
2015-07-29 11:03:33 +00:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2013-08-15 12:50:54 +00:00
|
|
|
|
2012-11-30 10:09:29 +00:00
|
|
|
%description
|
2013-08-15 12:50:54 +00:00
|
|
|
Snappy is a compression/decompression library. It does not aim for maximum
|
|
|
|
compression, or compatibility with any other compression library; instead, it
|
|
|
|
aims for very high speeds and reasonable compression. For instance, compared to
|
|
|
|
the fastest mode of zlib, Snappy is an order of magnitude faster for most
|
|
|
|
inputs, but the resulting compressed files are anywhere from 20% to 100%
|
|
|
|
bigger. On a single core of a Core i7 processor in 64-bit mode, Snappy
|
2015-07-29 11:03:33 +00:00
|
|
|
compresses at about 250 MB/sec or more and decompresses at about
|
2012-11-30 10:09:29 +00:00
|
|
|
500 MB/sec or more.
|
|
|
|
|
|
|
|
%package -n %{lib_name}
|
|
|
|
Summary: Shared library from snappy
|
2013-08-15 12:50:54 +00:00
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
|
2012-11-30 10:09:29 +00:00
|
|
|
%description -n %{lib_name}
|
2015-07-29 11:03:33 +00:00
|
|
|
Snappy is a compression/decompression library. It does not aim for maximum compression,
|
|
|
|
or compatibility with any other compression library; instead, it aims for very high
|
|
|
|
speeds and reasonable compression. For instance, compared to the fastest mode of zlib,
|
|
|
|
Snappy is an order of magnitude faster for most inputs, but the resulting compressed
|
|
|
|
files are anywhere from 20% to 100% bigger. On a single core of a Core i7 processor
|
|
|
|
in 64-bit mode, Snappy compresses at about 250 MB/sec or more and decompresses at about
|
2012-11-30 10:09:29 +00:00
|
|
|
500 MB/sec or more.
|
|
|
|
|
|
|
|
This package holds the shared library of snappy.
|
|
|
|
|
|
|
|
%package devel
|
|
|
|
Summary: Development files for snappy
|
2013-08-15 12:50:54 +00:00
|
|
|
Group: Development/Libraries/C and C++
|
2015-07-29 11:03:33 +00:00
|
|
|
Requires: %{lib_name} = %{version}
|
2013-08-15 12:50:54 +00:00
|
|
|
|
2012-11-30 10:09:29 +00:00
|
|
|
%description devel
|
2013-08-15 12:50:54 +00:00
|
|
|
Snappy is a compression/decompression library. It does not aim for maximum
|
|
|
|
compression, or compatibility with any other compression library; instead, it
|
|
|
|
aims for very high speeds and reasonable compression. For instance, compared to
|
|
|
|
the fastest mode of zlib, Snappy is an order of magnitude faster for most
|
|
|
|
inputs, but the resulting compressed files are anywhere from 20% to 100%
|
|
|
|
bigger. On a single core of a Core i7 processor in 64-bit mode, Snappy
|
2015-07-29 11:03:33 +00:00
|
|
|
compresses at about 250 MB/sec or more and decompresses at about
|
2012-11-30 10:09:29 +00:00
|
|
|
500 MB/sec or more.
|
|
|
|
|
|
|
|
This package holds the development files for snappy.
|
|
|
|
|
|
|
|
%prep
|
2013-08-15 12:50:54 +00:00
|
|
|
%setup -q
|
2012-11-30 10:09:29 +00:00
|
|
|
|
|
|
|
%build
|
2015-07-29 11:03:33 +00:00
|
|
|
autoreconf -fvi
|
2013-08-15 12:50:54 +00:00
|
|
|
# mvyskocil: disable assertions to improve a speed a bit in microbenchmarks and hopefully in real-world use as well
|
|
|
|
# http://code.google.com/p/snappy/issues/detail?id=40
|
|
|
|
%configure CXXFLAGS="%{optflags} -DNDEBUG" \
|
|
|
|
--with-pic \
|
|
|
|
--disable-static \
|
|
|
|
--docdir=%{_defaultdocdir}/%{name}
|
|
|
|
|
2015-07-29 11:03:33 +00:00
|
|
|
make %{?_smp_mflags}
|
2012-11-30 10:09:29 +00:00
|
|
|
|
|
|
|
%install
|
2015-07-29 11:03:33 +00:00
|
|
|
make DESTDIR=%{buildroot} install %{?_smp_mflags}
|
|
|
|
find %{buildroot} -type f -name "*.la" -delete -print
|
2013-08-15 12:50:54 +00:00
|
|
|
rm %{buildroot}/%{_defaultdocdir}/%{name}/INSTALL
|
2012-11-30 10:09:29 +00:00
|
|
|
|
|
|
|
%check
|
2015-07-29 11:03:33 +00:00
|
|
|
make %{?_smp_mflags} check
|
2012-11-30 10:09:29 +00:00
|
|
|
|
|
|
|
%post -n %{lib_name} -p /sbin/ldconfig
|
2015-07-29 11:03:33 +00:00
|
|
|
|
2012-11-30 10:09:29 +00:00
|
|
|
%postun -n %{lib_name} -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%files -n %{lib_name}
|
|
|
|
%defattr(-,root,root,-)
|
2013-08-15 12:50:54 +00:00
|
|
|
%doc %{_defaultdocdir}/%{name}/COPYING
|
2012-11-30 10:09:29 +00:00
|
|
|
%{_libdir}/libsnappy.so.*
|
|
|
|
|
|
|
|
%files devel
|
|
|
|
%defattr(-,root,root,-)
|
|
|
|
%{_includedir}/snappy*.h
|
|
|
|
%{_libdir}/libsnappy.so
|
|
|
|
%doc %{_defaultdocdir}/%{name}
|
2013-08-15 12:50:54 +00:00
|
|
|
%exclude %{_defaultdocdir}/%{name}/COPYING
|
2012-11-30 10:09:29 +00:00
|
|
|
|
|
|
|
%changelog
|