Blob Blame History Raw
# Generated by rust2rpm 26
%bcond_without check
%global debug_package %{nil}

%global crate chrono

Name:           rust-chrono
Version:        0.4.35
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 dependencies and normalize metadata
Patch:          chrono-fix-metadata-auto.diff
# Manually created patch for downstream crate metadata changes
# * remove WASM- and Windows-specific features
Patch:          chrono-fix-metadata.diff

BuildRequires:  cargo-rpm-macros >= 24

%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}+now-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+now-devel %{_description}

This package contains library source intended for building other packages which
use the "now" feature of the "%{crate}" crate.

%files       -n %{name}+now-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}+rkyv-16-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+rkyv-16-devel %{_description}

This package contains library source intended for building other packages which
use the "rkyv-16" feature of the "%{crate}" crate.

%files       -n %{name}+rkyv-16-devel
%ghost %{crate_instdir}/Cargo.toml

%package     -n %{name}+rkyv-32-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+rkyv-32-devel %{_description}

This package contains library source intended for building other packages which
use the "rkyv-32" feature of the "%{crate}" crate.

%files       -n %{name}+rkyv-32-devel
%ghost %{crate_instdir}/Cargo.toml

%package     -n %{name}+rkyv-64-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+rkyv-64-devel %{_description}

This package contains library source intended for building other packages which
use the "rkyv-64" feature of the "%{crate}" crate.

%files       -n %{name}+rkyv-64-devel
%ghost %{crate_instdir}/Cargo.toml

%package     -n %{name}+rkyv-validation-devel
Summary:        %{summary}
BuildArch:      noarch

%description -n %{name}+rkyv-validation-devel %{_description}

This package contains library source intended for building other packages which
use the "rkyv-validation" feature of the "%{crate}" crate.

%files       -n %{name}+rkyv-validation-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}+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} -p1
%cargo_prep

%generate_buildrequires
%cargo_generate_buildrequires

%build
%cargo_build

%install
%cargo_install

%if %{with check}
%check
%cargo_test
%endif

%changelog
%autochangelog