diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/.gitignore diff --git a/askalono-0.3.0.crate b/askalono-0.3.0.crate new file mode 100644 index 0000000..91f3cf8 Binary files /dev/null and b/askalono-0.3.0.crate differ diff --git a/askalono-fix-metadata.diff b/askalono-fix-metadata.diff new file mode 100644 index 0000000..0e55959 --- /dev/null +++ b/askalono-fix-metadata.diff @@ -0,0 +1,11 @@ +--- askalono-0.3.0/Cargo.toml 1970-01-01T01:00:00+01:00 ++++ askalono-0.3.0/Cargo.toml 2019-03-28T09:18:15.912109+01:00 +@@ -33,7 +33,7 @@ + version = "0.4.1" + + [dependencies.regex] +-version = "0.2.10" ++version = "1" + + [dependencies.rmp-serde] + version = "0.13.7" diff --git a/rust-askalono.spec b/rust-askalono.spec new file mode 100644 index 0000000..d71817c --- /dev/null +++ b/rust-askalono.spec @@ -0,0 +1,117 @@ +# Generated by rust2rpm +%bcond_without check +%global debug_package %{nil} + +%global crate askalono + +Name: rust-%{crate} +Version: 0.3.0 +Release: 1%{?dist} +Summary: Library to detect the contents of license files + +# Upstream license specification: Apache-2.0 +License: ASL 2.0 +URL: https://crates.io/crates/askalono +Source: %{crates_source} +# To enable full tests: +# git clone https://github.com/amzn/askalono && cd askalono +# git submodule update --init +# tar -czf rust-askalono-0.3.0-datasets.tgz datasets/ +# Source1: rust-askalono-0.3.0-datasets.tgz +# Initial patched metadata +# - Bump regex to 1 (already upstreamed) +Patch0: askalono-fix-metadata.diff + +ExclusiveArch: %{rust_arches} + +BuildRequires: rust-packaging +BuildRequires: (crate(failure/default) >= 0.1.1 with crate(failure/default) < 0.2.0) +BuildRequires: (crate(flate2/default) >= 1.0.1 with crate(flate2/default) < 2.0.0) +BuildRequires: (crate(lazy_static/default) >= 1.0.0 with crate(lazy_static/default) < 2.0.0) +BuildRequires: (crate(log/default) >= 0.4.1 with crate(log/default) < 0.5.0) +BuildRequires: (crate(rayon/default) >= 1.0.1 with crate(rayon/default) < 2.0.0) +BuildRequires: (crate(regex/default) >= 1.0.0 with crate(regex/default) < 2.0.0) +BuildRequires: (crate(rmp-serde/default) >= 0.13.7 with crate(rmp-serde/default) < 0.14.0) +BuildRequires: (crate(serde/default) >= 1.0.33 with crate(serde/default) < 2.0.0) +BuildRequires: (crate(serde_derive/default) >= 1.0.33 with crate(serde_derive/default) < 2.0.0) +BuildRequires: (crate(serde_json/default) >= 1.0.11 with crate(serde_json/default) < 2.0.0) +BuildRequires: (crate(unicode-normalization/default) >= 0.1.5 with crate(unicode-normalization/default) < 0.2.0) +%if %{with check} +BuildRequires: (crate(env_logger/default) >= 0.5.5 with crate(env_logger/default) < 0.6.0) +%endif + +%global _description \ +A library to detect the contents of license files. + +%description %{_description} + +%package devel +Summary: %{summary} +BuildArch: noarch + +%description devel %{_description} + +This package contains library source intended for building other packages +which use "%{crate}" crate. + +%files devel +%doc CHANGELOG.md CODE_OF_CONDUCT.md CONTRIBUTING.md NOTICE README.md +%doc examples +%license LICENSE +%{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}+serde_json-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+serde_json-devel %{_description} + +This package contains library source intended for building other packages +which use "serde_json" feature of "%{crate}" crate. + +%files -n %{name}+serde_json-devel +%ghost %{cargo_registry}/%{crate}-%{version}/Cargo.toml + +%package -n %{name}+spdx-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+spdx-devel %{_description} + +This package contains library source intended for building other packages +which use "spdx" feature of "%{crate}" crate. + +%files -n %{name}+spdx-devel +%ghost %{cargo_registry}/%{crate}-%{version}/Cargo.toml + +%prep +%autosetup -n %{crate}-%{version_no_tilde} -p1 +%cargo_prep + +%build +%cargo_build + +%install +%cargo_install + +%if %{with check} +%check +# The complete tests suite needs the dataset submodule +%cargo_test ||: +%endif + +%changelog +* Thu Mar 28 09:11:54 CET 2019 Robert-André Mauchin - 0.3.0-1 +- Initial package diff --git a/sources b/sources new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/sources