396 lines
12 KiB
RPMSpec
396 lines
12 KiB
RPMSpec
# Generated by rust2rpm 28
|
|
%bcond check 1
|
|
%global debug_package %{nil}
|
|
|
|
%global crate zip
|
|
|
|
Name: rust-zip
|
|
Version: 8.1.0
|
|
Release: %autorelease
|
|
Summary: Library to support the reading and writing of zip files
|
|
|
|
License: MIT
|
|
URL: https://crates.io/crates/zip
|
|
Source: %{crates_source}
|
|
# * A copy of the GitHub source archive for zip-rs/zip2, with everything but the
|
|
# test/data/ subdirectory removed, and additionally, from which test files
|
|
# with known license issues have been removed. Fortunately, no removed test
|
|
# files are required for any of the tests that are present in the published
|
|
# crates.
|
|
Source10: zip2-%{version}-filtered.tar.gz
|
|
# * Script used to generate Source11: ./get_test_data.sh %%{version}
|
|
Source11: get_test_data.sh
|
|
# Automatically generated patch to strip dependencies and normalize metadata
|
|
Patch: zip-fix-metadata-auto.diff
|
|
# Manually created patch for downstream crate metadata changes
|
|
# * Drop unused benchmark-only / example-only dev-dependencies
|
|
# * Patch out the nt-time features; rust-nt-time not yet packaged
|
|
# * Patch out the deflate-flate2-zlib-ng-compat feature, which requires
|
|
# flate2/zlib-ng-compat, not packaged.
|
|
Patch: zip-fix-metadata.diff
|
|
# * Downstream-only: patch out tests that would need omitted test files to
|
|
# compile
|
|
Patch10: zip-6.0.0-omitted-test-files.patch
|
|
|
|
BuildRequires: cargo-rpm-macros >= 24
|
|
|
|
%global _description %{expand:
|
|
Library to support the reading and writing of zip files.}
|
|
|
|
%description %{_description}
|
|
|
|
%package devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "%{crate}" crate.
|
|
|
|
%files devel
|
|
%license %{crate_instdir}/LICENSE
|
|
%doc %{crate_instdir}/CHANGELOG.md
|
|
%doc %{crate_instdir}/CODE_OF_CONDUCT.md
|
|
%doc %{crate_instdir}/CONTRIBUTING.md
|
|
%doc %{crate_instdir}/README.md
|
|
%doc %{crate_instdir}/SECURITY.md
|
|
%{crate_instdir}/
|
|
%exclude %{crate_instdir}/cliff.toml
|
|
%exclude %{crate_instdir}/pull_request_template.md
|
|
%exclude %{crate_instdir}/release-plz.toml
|
|
|
|
%package -n %{name}+default-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+default-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "default" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+default-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+_arbitrary-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+_arbitrary-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "_arbitrary" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+_arbitrary-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+_bzip2_any-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+_bzip2_any-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "_bzip2_any" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+_bzip2_any-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+_deflate-any-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+_deflate-any-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "_deflate-any" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+_deflate-any-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+aes-crypto-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+aes-crypto-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "aes-crypto" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+aes-crypto-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+bitstream-io-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+bitstream-io-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "bitstream-io" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+bitstream-io-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+bzip2-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+bzip2-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "bzip2" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+bzip2-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+bzip2-rs-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+bzip2-rs-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "bzip2-rs" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+bzip2-rs-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+chrono-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+chrono-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "chrono" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+chrono-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+deflate-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+deflate-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "deflate" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+deflate-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+deflate-flate2-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+deflate-flate2-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "deflate-flate2" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+deflate-flate2-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+deflate-flate2-zlib-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+deflate-flate2-zlib-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "deflate-flate2-zlib" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+deflate-flate2-zlib-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+deflate-flate2-zlib-ng-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+deflate-flate2-zlib-ng-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "deflate-flate2-zlib-ng" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+deflate-flate2-zlib-ng-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+deflate-flate2-zlib-rs-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+deflate-flate2-zlib-rs-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "deflate-flate2-zlib-rs" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+deflate-flate2-zlib-rs-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+deflate-zopfli-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+deflate-zopfli-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "deflate-zopfli" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+deflate-zopfli-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+deflate64-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+deflate64-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "deflate64" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+deflate64-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+deprecated-time-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+deprecated-time-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "deprecated-time" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+deprecated-time-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+getrandom-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+getrandom-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "getrandom" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+getrandom-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+jiff-02-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+jiff-02-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "jiff-02" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+jiff-02-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+legacy-zip-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+legacy-zip-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "legacy-zip" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+legacy-zip-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+lzma-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+lzma-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "lzma" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+lzma-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+ppmd-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+ppmd-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "ppmd" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+ppmd-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+time-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+time-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "time" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+time-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+unreserved-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+unreserved-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "unreserved" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+unreserved-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+xz-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+xz-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "xz" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+xz-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%package -n %{name}+zstd-devel
|
|
Summary: %{summary}
|
|
BuildArch: noarch
|
|
|
|
%description -n %{name}+zstd-devel %{_description}
|
|
|
|
This package contains library source intended for building other packages which
|
|
use the "zstd" feature of the "%{crate}" crate.
|
|
|
|
%files -n %{name}+zstd-devel
|
|
%ghost %{crate_instdir}/Cargo.toml
|
|
|
|
%prep
|
|
%autosetup -n %{crate}-%{version} -p1
|
|
%cargo_prep
|
|
|
|
%generate_buildrequires
|
|
%cargo_generate_buildrequires -a
|
|
|
|
%build
|
|
%cargo_build -a
|
|
|
|
%install
|
|
%cargo_install -a
|
|
|
|
%if %{with check}
|
|
%check
|
|
# Extract test data (only) from the GitHub archive
|
|
tar -xzvf '%{SOURCE10}' --strip-components=1 'zip2-%{version}/tests/data/'
|
|
%cargo_test -a
|
|
%endif
|
|
|
|
%changelog
|
|
%autochangelog
|