From 289c050e52b5971c0862441af8bfbf605e9da330 Mon Sep 17 00:00:00 2001 From: madomado Date: Mon, 30 Oct 2023 14:37:52 +0800 Subject: [PATCH] fix: bandwhich ouch oxipng rnote youki --- .../bandwhich-fix-metadata-auto.diff | 8 +-- anda/rust/bandwhich/rust-bandwhich.spec | 11 ++-- anda/rust/ouch/rust-ouch.spec | 3 + anda/rust/rnote/rnote.spec | 2 +- anda/rust/youki/anda.hcl | 2 +- anda/rust/youki/rust-youki.spec | 58 +++++++++++++++++++ anda/rust/youki/update.rhai | 2 +- 7 files changed, 73 insertions(+), 13 deletions(-) create mode 100644 anda/rust/youki/rust-youki.spec diff --git a/anda/rust/bandwhich/bandwhich-fix-metadata-auto.diff b/anda/rust/bandwhich/bandwhich-fix-metadata-auto.diff index f9fdd38559..60d3c3b77a 100644 --- a/anda/rust/bandwhich/bandwhich-fix-metadata-auto.diff +++ b/anda/rust/bandwhich/bandwhich-fix-metadata-auto.diff @@ -1,6 +1,6 @@ ---- bandwhich-0.21.0/Cargo.toml 1970-01-01T00:00:01+00:00 -+++ bandwhich-0.21.0/Cargo.toml 2023-09-21T07:50:16.506970+00:00 -@@ -104,17 +104,3 @@ +--- bandwhich-0.21.1/Cargo.toml 1970-01-01T00:00:01+00:00 ++++ bandwhich-0.21.1/Cargo.toml 2023-10-30T06:12:20.956389+00:00 +@@ -119,17 +119,3 @@ [target."cfg(target_os=\"linux\")".dependencies.procfs] version = "0.15.1" @@ -14,7 +14,7 @@ -version = "1.0.75" - -[target."cfg(target_os=\"windows\")".build-dependencies.http_req] --version = "0.9.3" +-version = "0.10.0" - -[target."cfg(target_os=\"windows\")".build-dependencies.zip] -version = "0.6.6" diff --git a/anda/rust/bandwhich/rust-bandwhich.spec b/anda/rust/bandwhich/rust-bandwhich.spec index d544953d23..62599af63c 100644 --- a/anda/rust/bandwhich/rust-bandwhich.spec +++ b/anda/rust/bandwhich/rust-bandwhich.spec @@ -1,20 +1,20 @@ -# Generated by rust2rpm 24 +# Generated by rust2rpm 25 #bcond_without check %global crate bandwhich Name: rust-bandwhich Version: 0.21.1 -Release: 1%{?dist} +Release: %autorelease Summary: Display current network utilization by process, connection and remote IP/hostname License: MIT URL: https://crates.io/crates/bandwhich Source: %{crates_source} -# Automatically generated patch to strip foreign dependencies +# Automatically generated patch to strip dependencies and normalize metadata Patch: bandwhich-fix-metadata-auto.diff -BuildRequires: anda-srpm-macros rust-packaging >= 23 +BuildRequires: anda-srpm-macros cargo-rpm-macros >= 24 %global _description %{expand: Display current network utilization by process, connection and remote @@ -38,7 +38,7 @@ License: MIT %{_bindir}/bandwhich %prep -%autosetup -n %{crate}-%{version_no_tilde} -p1 +%autosetup -n %{crate}-%{version} -p1 %cargo_prep_online %build @@ -48,7 +48,6 @@ License: MIT %install %cargo_install -rm %{buildroot}/.cargo -rf %if %{with check} %check diff --git a/anda/rust/ouch/rust-ouch.spec b/anda/rust/ouch/rust-ouch.spec index 56af757c0b..2b90b52648 100644 --- a/anda/rust/ouch/rust-ouch.spec +++ b/anda/rust/ouch/rust-ouch.spec @@ -11,6 +11,9 @@ Summary: Command-line utility for easily compressing and decompressing fi License: MIT URL: https://crates.io/crates/ouch Source: %{crates_source} +# Automatically generated patch to strip foreign dependencies +Patch: ouch-fix-metadata-auto.diff + BuildRequires: anda-srpm-macros rust-packaging >= 21 %global _description %{expand: diff --git a/anda/rust/rnote/rnote.spec b/anda/rust/rnote/rnote.spec index c8f607256b..71067b48ce 100644 --- a/anda/rust/rnote/rnote.spec +++ b/anda/rust/rnote/rnote.spec @@ -6,7 +6,7 @@ License: GPL-3.0 URL: https://github.com/flxzt/rnote Source0: %{url}/archive/refs/tags/v%version.tar.gz Requires: gtk4 -BuildRequires: cargo meson cmake libappstream-glib gcc-c++ pkgconfig(alsa) alsa-lib clang-devel python desktop-file-utils +BuildRequires: cargo meson cmake libappstream-glib gcc-c++ pkgconfig(alsa) alsa-lib clang-devel python BuildRequires: pkgconfig(glib-2.0) >= 2.66 BuildRequires: pkgconfig(gtk4) >= 4.7 BuildRequires: pkgconfig(libadwaita-1) >= 1.2 diff --git a/anda/rust/youki/anda.hcl b/anda/rust/youki/anda.hcl index 400560e42f..57d84ec6d5 100644 --- a/anda/rust/youki/anda.hcl +++ b/anda/rust/youki/anda.hcl @@ -1,6 +1,6 @@ project pkg { rpm { - spec = "youki.spec" + spec = "rust-youki.spec" // enable_scm = true diff --git a/anda/rust/youki/rust-youki.spec b/anda/rust/youki/rust-youki.spec new file mode 100644 index 0000000000..03ddf728ec --- /dev/null +++ b/anda/rust/youki/rust-youki.spec @@ -0,0 +1,58 @@ +# Generated by rust2rpm 25 +#bcond_without check + +%global crate youki + +Name: rust-youki +Version: 0.3.0 +Release: %autorelease +Summary: Container runtime written in Rust + +License: None +URL: https://crates.io/crates/youki +Source: %{crates_source} + +BuildRequires: anda-srpm-macros cargo-rpm-macros >= 24 +BuildRequires: pkg-config +BuildRequires: systemd-devel +BuildRequires: dbus-devel +BuildRequires: libseccomp-devel +BuildRequires: elfutils-libelf-devel +BuildRequires: binutils + +%global _description %{expand: +A container runtime written in Rust.} + +%description %{_description} + +%package -n %{crate} +Summary: %{summary} +License: Apache-2.0 + +%description -n %{crate} %{_description} + +%files -n %{crate} +%license LICENSE +%license LICENSE.dependencies +%doc README.md +%{_bindir}/youki + +%prep +%autosetup -n %{crate}-%{version} -p1 +%cargo_prep_online + +%build +%cargo_build +%{cargo_license_summary} +%{cargo_license} > LICENSE.dependencies + +%install +%cargo_install + +%if %{with check} +%check +%cargo_test +%endif + +%changelog +%autochangelog diff --git a/anda/rust/youki/update.rhai b/anda/rust/youki/update.rhai index 1a65ed0082..628c1b1619 100644 --- a/anda/rust/youki/update.rhai +++ b/anda/rust/youki/update.rhai @@ -1 +1 @@ -rpm.version(gh("containers/youki")); +rpm.version(crates("youki"));