# Generated by rust2rpm 27 %bcond check 1 # prevent library files from being installed %global cargo_install_lib 0 %global crate threecpio Name: rust-threecpio Version: 0.11.0 Release: %autorelease Summary: Manage initrd cpio archives License: ISC URL: https://crates.io/crates/threecpio Source: %{crates_source} BuildRequires: cargo-rpm-macros >= 26 BuildRequires: /usr/bin/asciidoctor BuildRequires: lz4 BuildRequires: lzma %global _description %{expand: Manage initrd cpio archives.} %description %{_description} %package -n 3cpio Summary: %{summary} # ISC # MIT # MIT OR Apache-2.0 License: ISC AND MIT AND (MIT OR Apache-2.0) # LICENSE.dependencies contains a full license breakdown %description -n 3cpio %{_description} %files -n 3cpio %license LICENSE %license LICENSE.dependencies %doc NEWS.md %doc README.md %{_bindir}/3cpio %{_mandir}/man1/3cpio.1* %prep %autosetup -n %{crate}-%{version} -p1 %cargo_prep %generate_buildrequires %cargo_generate_buildrequires %build %cargo_build %{cargo_license_summary} %{cargo_license} > LICENSE.dependencies asciidoctor -b manpage man/3cpio.1.adoc %install %cargo_install install -p -m 0644 -D -t '%{buildroot}%{_mandir}/man1' man/3cpio.1 %if %{with check} %check # * Hard-coded mode and gid in test_file_from_line_location_block_device are # nonportable: https://github.com/bdrung/3cpio/issues/28 # * Test test_file_from_line_location_character_device requires /dev/console, # which does not exist in the mock chroot. %{cargo_test -- -- %{shrink: --skip test_file_from_line_location_block_device --skip test_file_from_line_location_character_device }} %endif %changelog %autochangelog