From 513731bef526b75d30714e36c444a29c0093c654 Mon Sep 17 00:00:00 2001 From: blinxen Date: Mon, 3 Jul 2023 22:01:34 +0200 Subject: [PATCH] Initial package --- .gitignore | 2 + README.md | 3 -- gix-trace-fix-metadata.diff | 13 +++++ rust-gix-trace.spec | 98 +++++++++++++++++++++++++++++++++++++ rust2rpm.conf | 2 + sources | 1 + 6 files changed, 116 insertions(+), 3 deletions(-) create mode 100644 .gitignore delete mode 100644 README.md create mode 100644 gix-trace-fix-metadata.diff create mode 100644 rust-gix-trace.spec create mode 100644 rust2rpm.conf create mode 100644 sources diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..3e2178c --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +/gix-trace-0.1.1.crate +/gix-trace-0.1.2.crate diff --git a/README.md b/README.md deleted file mode 100644 index e3fac13..0000000 --- a/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# rust-gix-trace - -The rust-gix-trace package diff --git a/gix-trace-fix-metadata.diff b/gix-trace-fix-metadata.diff new file mode 100644 index 0000000..ac53068 --- /dev/null +++ b/gix-trace-fix-metadata.diff @@ -0,0 +1,13 @@ +--- gix-trace-0.1.1/Cargo.toml 1970-01-01T00:00:01+00:00 ++++ gix-trace-0.1.1/Cargo.toml 2023-06-28T16:05:24.252314+00:00 +@@ -31,10 +31,6 @@ + test = false + doctest = false + +-[dependencies.document-features] +-version = "0.2.0" +-optional = true +- + [dependencies.tracing-core] + version = "0.1.31" + optional = true diff --git a/rust-gix-trace.spec b/rust-gix-trace.spec new file mode 100644 index 0000000..d272163 --- /dev/null +++ b/rust-gix-trace.spec @@ -0,0 +1,98 @@ +# Generated by rust2rpm 24 +%bcond_without check +%global debug_package %{nil} + +%global crate gix-trace + +Name: rust-gix-trace +Version: 0.1.2 +Release: %autorelease +Summary: Minimal tracing support for gitoxide that can be turned off to zero cost + +# Upstream license specification: MIT/Apache-2.0 +License: MIT OR Apache-2.0 +URL: https://crates.io/crates/gix-trace +Source: %{crates_source} +# Manually created patch for downstream crate metadata changes +# * Documentation feature is not needed for fedora +Patch: gix-trace-fix-metadata.diff + +BuildRequires: cargo-rpm-macros >= 24 + +%global _description %{expand: +A crate to provide minimal `tracing` support that can be turned off to +zero cost.} + +%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}/LICENSE-APACHE +%license %{crate_instdir}/LICENSE-MIT +%doc %{crate_instdir}/CHANGELOG.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}+tracing-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+tracing-devel %{_description} + +This package contains library source intended for building other packages which +use the "tracing" feature of the "%{crate}" crate. + +%files -n %{name}+tracing-devel +%ghost %{crate_instdir}/Cargo.toml + +%package -n %{name}+tracing-detail-devel +Summary: %{summary} +BuildArch: noarch + +%description -n %{name}+tracing-detail-devel %{_description} + +This package contains library source intended for building other packages which +use the "tracing-detail" feature of the "%{crate}" crate. + +%files -n %{name}+tracing-detail-devel +%ghost %{crate_instdir}/Cargo.toml + +%prep +%autosetup -n %{crate}-%{version_no_tilde} -p1 +%cargo_prep + +%generate_buildrequires +%cargo_generate_buildrequires + +%build +%cargo_build + +%install +%cargo_install + +%if %{with check} +%check +%cargo_test +%endif + +%changelog +%autochangelog diff --git a/rust2rpm.conf b/rust2rpm.conf new file mode 100644 index 0000000..d2d530e --- /dev/null +++ b/rust2rpm.conf @@ -0,0 +1,2 @@ +[DEFAULT] +summary = Minimal tracing support for gitoxide that can be turned off to zero cost diff --git a/sources b/sources new file mode 100644 index 0000000..cb49930 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (gix-trace-0.1.2.crate) = 6527fc785bb481bca94edd55f012c57c7b35387615ff20b418b012302ed687eed7e2d3b50a884863f3b1bf58ac627559c09c86389585b96178deadb030e24fd5