forked from google/snappy
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
git clean -xdf git submodule sync --recursive git submodule update --init --recursive git submodule foreach git checkout -- . tar zcvf ../snappy_1.2.0.orig.tar.gz --exclude=.git . debuild -uc -us cp snappy.spec ../snappy_1.2.0-1.spec cp ../*snappy*1.2.0*.{gz,xz,spec,dsc} /osc/home\:alvistack/google-snappy-1.2.0/ rm -rf ../*snappy*1.2.0*.* See google#178 Signed-off-by: Wong Hoi Sing Edison <hswong3i@pantarei-design.com>
- Loading branch information
Showing
14 changed files
with
303 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
prefix=@CMAKE_INSTALL_PREFIX@ | ||
exec_prefix=${prefix} | ||
libdir=@CMAKE_INSTALL_LIBDIR@ | ||
includedir=${prefix}/include | ||
|
||
Name: @PROJECT_NAME@ | ||
Description: A fast compression/decompression library | ||
Version: @PROJECT_VERSION@ | ||
Libs: -L${libdir} -lsnappy | ||
Cflags: -I${includedir} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
*.substvars | ||
*debhelper* | ||
.debhelper | ||
autoreconf.* | ||
files | ||
tmp | ||
|
||
libsnappy-dev | ||
libsnappy1v5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
snappy (100:1.2.0-1) UNRELEASED; urgency=medium | ||
|
||
* https://github.com/google/snappy/releases/tag/1.2.0 | ||
|
||
-- Wong Hoi Sing Edison <hswong3i@pantarei-design.com> Sat, 06 Apr 2024 11:21:20 +0900 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
Source: snappy | ||
Section: libs | ||
Priority: optional | ||
Standards-Version: 4.5.0 | ||
Maintainer: Wong Hoi Sing Edison <hswong3i@pantarei-design.com> | ||
Homepage: https://github.com/google/snappy | ||
Vcs-Browser: https://github.com/alvistack/google-snappy | ||
Vcs-Git: https://github.com/alvistack/google-snappy.git | ||
Build-Depends: | ||
debhelper, | ||
debhelper-compat (= 10), | ||
cmake, | ||
liblz4-dev, | ||
liblzo2-dev, | ||
pkg-config, | ||
zlib1g-dev, | ||
|
||
Package: libsnappy1v5 | ||
Section: libs | ||
Architecture: amd64 | ||
Description: Fast compression/decompression library | ||
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. | ||
Pre-Depends: | ||
${misc:Pre-Depends}, | ||
Depends: | ||
${shlibs:Depends}, | ||
${misc:Depends}, | ||
Conflicts: | ||
libsnappy1, | ||
|
||
Package: libsnappy-dev | ||
Section: libdevel | ||
Architecture: amd64 | ||
Description: Fast compression/decompression library (development files) | ||
This package contains the development files required to build programs | ||
against Snappy. | ||
Depends: | ||
${misc:Depends}, | ||
libsnappy1v5 (= ${source:Version}), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ | ||
|
||
Files: debian/* | ||
Copyright: 2024 Wong Hoi Sing Edison <hswong3i@pantarei-design.com> | ||
License: Apache-2.0 | ||
|
||
License: Apache-2.0 | ||
Licensed under the Apache License, Version 2.0 (the "License"); | ||
you may not use this file except in compliance with the License. | ||
You may obtain a copy of the License at | ||
. | ||
http://www.apache.org/licenses/LICENSE-2.0 | ||
. | ||
Unless required by applicable law or agreed to in writing, software | ||
distributed under the License is distributed on an "AS IS" BASIS, | ||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
See the License for the specific language governing permissions and | ||
limitations under the License. | ||
. | ||
The complete text of the Apache version 2.0 license | ||
can be found in "/usr/share/common-licenses/Apache-2.0". |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
usr/include/* | ||
usr/lib/*/*.a | ||
usr/lib/*/*.so | ||
usr/lib/*/cmake/* | ||
usr/lib/*/pkgconfig/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
libsnappy-dev: initial-upload-closes-no-bugs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
usr/lib/*/*.so.* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
libsnappy1v5: initial-upload-closes-no-bugs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
#!/usr/bin/make -f | ||
|
||
SHELL := /bin/bash | ||
|
||
override_dh_autoreconf: | ||
|
||
override_dh_auto_configure: | ||
mkdir -p build | ||
pushd build && \ | ||
cmake \ | ||
.. \ | ||
-DBUILD_SHARED_LIBS=ON \ | ||
-DCMAKE_BUILD_TYPE=Release \ | ||
-DCMAKE_INSTALL_LIBDIR=/usr/lib/${DEB_HOST_MULTIARCH} \ | ||
-DCMAKE_INSTALL_PREFIX=/usr \ | ||
-DSNAPPY_BUILD_BENCHMARKS=OFF \ | ||
-DSNAPPY_BUILD_TESTS=OFF && \ | ||
popd | ||
|
||
override_dh_auto_build: | ||
pushd build && \ | ||
cmake \ | ||
--build . \ | ||
--parallel 10 \ | ||
--config Release && \ | ||
popd | ||
|
||
override_dh_auto_install: | ||
pushd build && \ | ||
export DESTDIR=../debian/tmp && \ | ||
cmake \ | ||
--install . && \ | ||
popd | ||
|
||
override_dh_auto_test: | ||
|
||
override_dh_auto_clean: | ||
|
||
%: | ||
dh $@ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
3.0 (quilt) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
snappy source: file-without-copyright-information | ||
snappy source: no-debian-changes | ||
snappy source: not-binnmuable-any-depends-any | ||
snappy source: weak-library-dev-dependency |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,133 @@ | ||
# Copyright 2024 Wong Hoi Sing Edison <hswong3i@pantarei-design.com> | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
%global debug_package %{nil} | ||
|
||
%global source_date_epoch_from_changelog 0 | ||
|
||
Name: snappy | ||
Epoch: 100 | ||
Version: 1.2.0 | ||
Release: 1%{?dist} | ||
Summary: Fast compression/decompression library | ||
License: BSD-3-Clause | ||
URL: https://github.com/google/snappy/tags | ||
Source0: %{name}_%{version}.orig.tar.gz | ||
BuildRequires: cmake | ||
BuildRequires: gcc-c++ | ||
BuildRequires: lz4-devel | ||
BuildRequires: lzo-devel | ||
BuildRequires: pkgconfig | ||
BuildRequires: zlib-devel | ||
|
||
%description | ||
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. | ||
|
||
%prep | ||
%autosetup -T -c -n %{name}_%{version}-%{release} | ||
tar -zx -f %{S:0} --strip-components=1 -C . | ||
|
||
%build | ||
mkdir -p build | ||
pushd build && \ | ||
cmake \ | ||
.. \ | ||
-DBUILD_SHARED_LIBS=ON \ | ||
-DCMAKE_BUILD_TYPE=Release \ | ||
-DCMAKE_INSTALL_LIBDIR=%{_libdir} \ | ||
-DCMAKE_INSTALL_PREFIX=%{_prefix} \ | ||
-DSNAPPY_BUILD_BENCHMARKS=OFF \ | ||
-DSNAPPY_BUILD_TESTS=OFF && \ | ||
popd | ||
pushd build && \ | ||
cmake \ | ||
--build . \ | ||
--parallel 10 \ | ||
--config Release && \ | ||
popd | ||
|
||
%install | ||
pushd build && \ | ||
export DESTDIR=%{buildroot} && \ | ||
cmake \ | ||
--install . && \ | ||
popd | ||
|
||
%if 0%{?suse_version} > 1500 || 0%{?sle_version} > 150000 | ||
%package -n libsnappy1 | ||
Summary: Fast compression/decompression library | ||
|
||
%description -n libsnappy1 | ||
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. | ||
|
||
%package -n snappy-devel | ||
Summary: Fast compression/decompression library (development files) | ||
Requires: libsnappy1 = %{epoch}:%{version}-%{release} | ||
Requires: pkgconfig | ||
|
||
%description -n snappy-devel | ||
This package contains the development files required to build programs | ||
against Snappy. | ||
|
||
%post -n libsnappy1 -p /sbin/ldconfig | ||
%postun -n libsnappy1 -p /sbin/ldconfig | ||
|
||
%files | ||
%license COPYING | ||
|
||
%files -n libsnappy1 | ||
%{_libdir}/*.so.* | ||
|
||
%files -n snappy-devel | ||
%dir %{_libdir}/cmake/Snappy/ | ||
%{_includedir}/* | ||
%{_libdir}/*.a | ||
%{_libdir}/*.so | ||
%{_libdir}/cmake/Snappy/* | ||
%{_libdir}/pkgconfig/* | ||
%endif | ||
|
||
%if !(0%{?suse_version} > 1500) && !(0%{?sle_version} > 150000) | ||
%package -n snappy-devel | ||
Summary: Fast compression/decompression library (development files) | ||
Requires: snappy = %{epoch}:%{version}-%{release} | ||
Requires: pkgconfig | ||
|
||
%description -n snappy-devel | ||
This package contains the development files required to build programs | ||
against Snappy. | ||
|
||
%post -p /sbin/ldconfig | ||
%postun -p /sbin/ldconfig | ||
|
||
%files | ||
%license COPYING | ||
%{_libdir}/*.so.* | ||
|
||
%files -n snappy-devel | ||
%dir %{_libdir}/cmake/Snappy/ | ||
%{_includedir}/* | ||
%{_libdir}/*.a | ||
%{_libdir}/*.so | ||
%{_libdir}/cmake/Snappy/* | ||
%{_libdir}/pkgconfig/* | ||
%endif | ||
|
||
%changelog |