You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
rust-chrono/rust-chrono.spec

234 lines
6.4 KiB

# Generated by rust2rpm 24
%bcond_without check
%global debug_package %{nil}
%global crate chrono
Name: rust-chrono
Version: 0.4.27
Release: %autorelease
Summary: Date and time library for Rust
License: MIT OR Apache-2.0
URL: https://crates.io/crates/chrono
Source: %{crates_source}
# Automatically generated patch to strip foreign dependencies
Patch: chrono-fix-metadata-auto.diff
# Manually created patch for downstream crate metadata changes
# * remove WASM- and doc-specific features
# * drop unused, benchmark-only criterion dev-dependency to speed up builds
Patch: chrono-fix-metadata.diff
BuildRequires: rust-packaging >= 21
%global _description %{expand:
Date and time library for Rust.}
%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.txt
%doc %{crate_instdir}/CHANGELOG.md
%doc %{crate_instdir}/README.md
%{crate_instdir}/
%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}+alloc-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+alloc-devel %{_description}
This package contains library source intended for building other packages which
use the "alloc" feature of the "%{crate}" crate.
%files -n %{name}+alloc-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}+clock-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+clock-devel %{_description}
This package contains library source intended for building other packages which
use the "clock" feature of the "%{crate}" crate.
%files -n %{name}+clock-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+iana-time-zone-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+iana-time-zone-devel %{_description}
This package contains library source intended for building other packages which
use the "iana-time-zone" feature of the "%{crate}" crate.
%files -n %{name}+iana-time-zone-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+libc-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+libc-devel %{_description}
This package contains library source intended for building other packages which
use the "libc" feature of the "%{crate}" crate.
%files -n %{name}+libc-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+oldtime-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+oldtime-devel %{_description}
This package contains library source intended for building other packages which
use the "oldtime" feature of the "%{crate}" crate.
%files -n %{name}+oldtime-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+pure-rust-locales-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+pure-rust-locales-devel %{_description}
This package contains library source intended for building other packages which
use the "pure-rust-locales" feature of the "%{crate}" crate.
%files -n %{name}+pure-rust-locales-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+rkyv-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+rkyv-devel %{_description}
This package contains library source intended for building other packages which
use the "rkyv" feature of the "%{crate}" crate.
%files -n %{name}+rkyv-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+rustc-serialize-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+rustc-serialize-devel %{_description}
This package contains library source intended for building other packages which
use the "rustc-serialize" feature of the "%{crate}" crate.
%files -n %{name}+rustc-serialize-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+serde-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+serde-devel %{_description}
This package contains library source intended for building other packages which
use the "serde" feature of the "%{crate}" crate.
%files -n %{name}+serde-devel
%ghost %{crate_instdir}/Cargo.toml
%package -n %{name}+std-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+std-devel %{_description}
This package contains library source intended for building other packages which
use the "std" feature of the "%{crate}" crate.
%files -n %{name}+std-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}+unstable-locales-devel
Summary: %{summary}
BuildArch: noarch
%description -n %{name}+unstable-locales-devel %{_description}
This package contains library source intended for building other packages which
use the "unstable-locales" feature of the "%{crate}" crate.
%files -n %{name}+unstable-locales-devel
%ghost %{crate_instdir}/Cargo.toml
%prep
%autosetup -n %{crate}-%{version_no_tilde} -p1
%cargo_prep
%generate_buildrequires
%cargo_generate_buildrequires -a
%build
%cargo_build -a
%install
%cargo_install -a
%if %{with check}
%check
# * skip a test that hard-codes 64-bit arch-specific type sizes:
# https://github.com/chronotope/chrono/issues/1234
%cargo_test -a -- -- --skip format::strftime::tests::test_type_sizes
%endif
%changelog
%autochangelog