# Generated by rust2rpm 28 %bcond check 1 %global debug_package %{nil} %global crate dos-date-time Name: rust-dos-date-time Version: 0.2.0 Release: %autorelease Summary: MS-DOS date and time library License: Apache-2.0 OR MIT URL: https://crates.io/crates/dos-date-time Source: %{crates_source} # Manually created patch for downstream crate metadata changes # * Exclude README.md so we don’t have to add its CC-BY-4.0 license (which is # allowed for documentation) to the License field in the spec file. Also # exclude the CC-BY-4.0 license text, since it is no longer needed. Both are # still distributed in the source RPM, which is fine. Patch: dos-date-time-fix-metadata.diff BuildRequires: cargo-rpm-macros >= 24 %global _description %{expand: An MS-DOS date and time library.} %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}/LICENSES/Apache-2.0.txt %license %{crate_instdir}/LICENSES/MIT.txt %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}+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}+jiff-devel Summary: %{summary} BuildArch: noarch %description -n %{name}+jiff-devel %{_description} This package contains library source intended for building other packages which use the "jiff" feature of the "%{crate}" crate. %files -n %{name}+jiff-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 %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