diff --git a/rust-url.spec b/rust-url.spec index 6c54097..7db301e 100644 --- a/rust-url.spec +++ b/rust-url.spec @@ -1,5 +1,5 @@ # Generated by rust2rpm -# Tests are run in infrastructure +# * Tests are run in infrastructure %bcond_with check %global debug_package %{nil} @@ -7,44 +7,136 @@ Name: rust-%{crate} Version: 1.7.1 -Release: 4%{?dist} +Release: 5%{?dist} Summary: URL library for Rust, based on the WHATWG URL Standard +# Upstream license specification: MIT/Apache-2.0 License: MIT or ASL 2.0 URL: https://crates.io/crates/url Source0: https://crates.io/api/v1/crates/%{crate}/%{version}/download#/%{crate}-%{version}.crate +# Initial patched metadata +# * Exclude CI files, https://github.com/servo/rust-url/pull/467 +Patch0: url-fix-metadata.diff ExclusiveArch: %{rust_arches} BuildRequires: rust-packaging -# [dependencies] -BuildRequires: (crate(encoding) >= 0.2.0 with crate(encoding) < 0.3.0) -BuildRequires: (crate(heapsize) >= 0.4.1 with crate(heapsize) < 0.5.0) -BuildRequires: (crate(idna) >= 0.1.0 with crate(idna) < 0.2.0) -BuildRequires: (crate(matches) >= 0.1.0 with crate(matches) < 0.2.0) -BuildRequires: (crate(percent-encoding) >= 1.0.0 with crate(percent-encoding) < 2.0.0) -BuildRequires: (crate(rustc-serialize) >= 0.3.0 with crate(rustc-serialize) < 0.4.0) -BuildRequires: (crate(serde) >= 0.6.1 with crate(serde) < 0.9.0) +BuildRequires: (crate(encoding/default) >= 0.2.0 with crate(encoding/default) < 0.3.0) +BuildRequires: (crate(heapsize/default) >= 0.4.1 with crate(heapsize/default) < 0.5.0) +BuildRequires: (crate(idna/default) >= 0.1.0 with crate(idna/default) < 0.2.0) +BuildRequires: (crate(matches/default) >= 0.1.0 with crate(matches/default) < 0.2.0) +BuildRequires: (crate(percent-encoding/default) >= 1.0.0 with crate(percent-encoding/default) < 2.0.0) +BuildRequires: (crate(rustc-serialize/default) >= 0.3.0 with crate(rustc-serialize/default) < 0.4.0) +BuildRequires: (crate(serde/default) >= 0.6.1 with crate(serde/default) < 0.9.0) %if %{with check} -# [dev-dependencies] -BuildRequires: (crate(bencher) >= 0.1.0 with crate(bencher) < 0.2.0) -BuildRequires: (crate(rustc-serialize) >= 0.3.0 with crate(rustc-serialize) < 0.4.0) -BuildRequires: (crate(rustc-test) >= 0.3.0 with crate(rustc-test) < 0.4.0) -BuildRequires: (crate(serde_json) >= 0.6.1 with crate(serde_json) < 0.9.0) +BuildRequires: (crate(bencher/default) >= 0.1.0 with crate(bencher/default) < 0.2.0) +BuildRequires: (crate(rustc-serialize/default) >= 0.3.0 with crate(rustc-serialize/default) < 0.4.0) +BuildRequires: (crate(rustc-test/default) >= 0.3.0 with crate(rustc-test/default) < 0.4.0) +BuildRequires: (crate(serde_json/default) >= 0.6.1 with crate(serde_json/default) < 0.9.0) %endif -%description -%{summary}. +%global _description \ +URL library for Rust, based on the WHATWG URL Standard. + +%description %{_description} %package devel Summary: %{summary} BuildArch: noarch -%description devel -URL library for Rust, based on the WHATWG URL Standard. +%description devel %{_description} + +This package contains library source intended for building other packages +which use "%{crate}" crate. + +%files devel +%license LICENSE-MIT LICENSE-APACHE +%doc README.md UPGRADING.md +%{cargo_registry}/%{crate}-%{version}/ + +%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}+encoding-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+encoding-devel %{_description} + +This package contains library source intended for building other packages +which use "encoding" feature of "%{crate}" crate. + +%files -n %{name}+encoding-devel +%ghost %{cargo_registry}/%{crate}-%{version}/Cargo.toml + +%package -n %{name}+heap_size-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+heap_size-devel %{_description} This package contains library source intended for building other packages -which use %{crate} from crates.io. +which use "heap_size" feature of "%{crate}" crate. + +%files -n %{name}+heap_size-devel +%ghost %{cargo_registry}/%{crate}-%{version}/Cargo.toml + +%package -n %{name}+heapsize-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+heapsize-devel %{_description} + +This package contains library source intended for building other packages +which use "heapsize" feature of "%{crate}" crate. + +%files -n %{name}+heapsize-devel +%ghost %{cargo_registry}/%{crate}-%{version}/Cargo.toml + +%package -n %{name}+query_encoding-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+query_encoding-devel %{_description} + +This package contains library source intended for building other packages +which use "query_encoding" feature of "%{crate}" crate. + +%files -n %{name}+query_encoding-devel +%ghost %{cargo_registry}/%{crate}-%{version}/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 "rustc-serialize" feature of "%{crate}" crate. + +%files -n %{name}+rustc-serialize-devel +%ghost %{cargo_registry}/%{crate}-%{version}/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 "serde" feature of "%{crate}" crate. + +%files -n %{name}+serde-devel +%ghost %{cargo_registry}/%{crate}-%{version}/Cargo.toml %prep %autosetup -n %{crate}-%{version} -p1 @@ -61,13 +153,10 @@ which use %{crate} from crates.io. %cargo_test %endif -%files devel -%license LICENSE-MIT LICENSE-APACHE -%doc README.md UPGRADING.md -%{cargo_registry}/%{crate}-%{version}/ -%exclude %{cargo_registry}/%{crate}-%{version}/{appveyor.yml,docs} - %changelog +* Sat Nov 03 2018 Igor Gnatenko - 1.7.1-5 +- Adapt to new packaging + * Sat Jul 28 2018 Igor Gnatenko - 1.7.1-4 - Rebuild to trigger tests diff --git a/url-fix-metadata.diff b/url-fix-metadata.diff new file mode 100644 index 0000000..ccc5332 --- /dev/null +++ b/url-fix-metadata.diff @@ -0,0 +1,10 @@ +--- url-1.7.1/Cargo.toml 1970-01-01T01:00:00+01:00 ++++ url-1.7.1/Cargo.toml 2018-11-03T15:06:59.972822+01:00 +@@ -21,6 +21,7 @@ + categories = ["parser-implementations", "web-programming", "encoding"] + license = "MIT/Apache-2.0" + repository = "https://github.com/servo/rust-url" ++exclude = ["/docs/*", "/.travis.yml", "/appveyor.yml"] + [package.metadata.docs.rs] + features = ["query_encoding"] +