From 58364bfb9698e38416849988459c7e3318396210 Mon Sep 17 00:00:00 2001 From: Josh Stone Date: Mon, 12 Nov 2018 18:03:52 -0800 Subject: [PATCH] Adapt to new packaging --- rust-object.spec | 92 +++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 75 insertions(+), 17 deletions(-) diff --git a/rust-object.spec b/rust-object.spec index 29bfa0f..547eec2 100644 --- a/rust-object.spec +++ b/rust-object.spec @@ -6,7 +6,7 @@ Name: rust-%{crate} Version: 0.10.0 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Unified interface for parsing object file formats # Upstream license specification: Apache-2.0/MIT @@ -20,28 +20,89 @@ Patch0: object-fix-metadata.diff ExclusiveArch: %{rust_arches} BuildRequires: rust-packaging -# [dependencies] -BuildRequires: (crate(flate2) >= 1.0.0 with crate(flate2) < 2.0.0) -BuildRequires: ((crate(goblin) >= 0.0.17 with crate(goblin) < 0.0.18) with crate(goblin/endian_fd) with crate(goblin/elf32) with crate(goblin/elf64) with crate(goblin/mach32) with crate(goblin/mach64) with crate(goblin/pe32) with crate(goblin/pe64) with crate(goblin/archive)) +BuildRequires: (crate(flate2/default) >= 1.0.0 with crate(flate2/default) < 2.0.0) +BuildRequires: (crate(goblin/archive) >= 0.0.17 with crate(goblin/archive) < 0.0.18) +BuildRequires: (crate(goblin/elf32) >= 0.0.17 with crate(goblin/elf32) < 0.0.18) +BuildRequires: (crate(goblin/elf64) >= 0.0.17 with crate(goblin/elf64) < 0.0.18) +BuildRequires: (crate(goblin/endian_fd) >= 0.0.17 with crate(goblin/endian_fd) < 0.0.18) +BuildRequires: (crate(goblin/mach32) >= 0.0.17 with crate(goblin/mach32) < 0.0.18) +BuildRequires: (crate(goblin/mach64) >= 0.0.17 with crate(goblin/mach64) < 0.0.18) +BuildRequires: (crate(goblin/pe32) >= 0.0.17 with crate(goblin/pe32) < 0.0.18) +BuildRequires: (crate(goblin/pe64) >= 0.0.17 with crate(goblin/pe64) < 0.0.18) +BuildRequires: (crate(goblin/std) >= 0.0.17 with crate(goblin/std) < 0.0.18) BuildRequires: (crate(scroll) >= 0.9.0 with crate(scroll) < 0.10.0) BuildRequires: (crate(uuid) >= 0.6.0 with crate(uuid) < 0.7.0) %if %{with check} -# [dev-dependencies] -BuildRequires: (crate(memmap) >= 0.6.0 with crate(memmap) < 0.7.0) +BuildRequires: (crate(memmap/default) >= 0.6.0 with crate(memmap/default) < 0.7.0) %endif -%description -%{summary}. +%global _description \ +A unified interface for parsing object file formats. + +%description %{_description} %package devel Summary: %{summary} BuildArch: noarch -%description devel -A unified interface for parsing object file formats. +%description devel %{_description} + +This package contains library source intended for building other packages +which use "%{crate}" crate. + +%files devel +%license LICENSE-APACHE LICENSE-MIT +%doc README.md +%{cargo_registry}/%{crate}-%{version}/ +%exclude %{cargo_registry}/%{crate}-%{version}/coverage + +%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 "default" feature of "%{crate}" crate. + +%files -n %{name}+default-devel +%ghost %{cargo_registry}/%{crate}-%{version}/Cargo.toml + +%package -n %{name}+compression-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+compression-devel %{_description} This package contains library source intended for building other packages -which use %{crate} from crates.io. +which use "compression" feature of "%{crate}" crate. + +%files -n %{name}+compression-devel +%ghost %{cargo_registry}/%{crate}-%{version}/Cargo.toml + +%package -n %{name}+flate2-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+flate2-devel %{_description} + +This package contains library source intended for building other packages +which use "flate2" feature of "%{crate}" crate. + +%files -n %{name}+flate2-devel +%ghost %{cargo_registry}/%{crate}-%{version}/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 "std" feature of "%{crate}" crate. + +%files -n %{name}+std-devel +%ghost %{cargo_registry}/%{crate}-%{version}/Cargo.toml %prep %autosetup -n %{crate}-%{version} -p1 @@ -58,13 +119,10 @@ which use %{crate} from crates.io. %cargo_test %endif -%files devel -%license LICENSE-APACHE LICENSE-MIT -%doc README.md -%{cargo_registry}/%{crate}-%{version}/ -%exclude %{cargo_registry}/%{crate}-%{version}/coverage - %changelog +* Tue Nov 13 2018 Josh Stone - 0.10.0-2 +- Adapt to new packaging + * Tue Oct 02 2018 Josh Stone - 0.10.0-1 - Update to 0.10.0