From 15f586da51d6f3b627b19fb949644b23f7c674e1 Mon Sep 17 00:00:00 2001 From: Michel Lind Date: Fri, 29 Dec 2023 15:58:55 -0600 Subject: [PATCH] Update to 0.22.0 Signed-off-by: Michel Lind --- .gitignore | 1 + libbpf-cargo-fix-finding-libbpf-rs.diff | 2 +- rust-libbpf-cargo.spec | 14 ++++++++++---- rust2rpm.conf | 7 ------- rust2rpm.toml | 3 +++ sources | 2 +- 6 files changed, 16 insertions(+), 13 deletions(-) delete mode 100644 rust2rpm.conf create mode 100644 rust2rpm.toml diff --git a/.gitignore b/.gitignore index 44d0dd8..38393fd 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ /libbpf-cargo-0.10.0.crate /libbpf-cargo-0.13.1.crate /libbpf-cargo-0.21.2.crate +/libbpf-cargo-0.22.0.crate diff --git a/libbpf-cargo-fix-finding-libbpf-rs.diff b/libbpf-cargo-fix-finding-libbpf-rs.diff index 0a71bd8..e3d528b 100644 --- a/libbpf-cargo-fix-finding-libbpf-rs.diff +++ b/libbpf-cargo-fix-finding-libbpf-rs.diff @@ -12,7 +12,7 @@ - .parent() - .expect("failed to get parent of libbpf-cargo directory") - .join("libbpf-rs") -+ Path::new("/usr/share/cargo/registry/libbpf-rs-0.21.2") ++ Path::new("/usr/share/cargo/registry/libbpf-rs-0.22.0") .canonicalize() .expect("failed to canonicalize libbpf-rs") } diff --git a/rust-libbpf-cargo.spec b/rust-libbpf-cargo.spec index b377bb2..527bee9 100644 --- a/rust-libbpf-cargo.spec +++ b/rust-libbpf-cargo.spec @@ -1,10 +1,10 @@ -# Generated by rust2rpm 24 +# Generated by rust2rpm 25 %bcond_without check %global crate libbpf-cargo Name: rust-libbpf-cargo -Version: 0.21.2 +Version: 0.22.0 Release: %autorelease Summary: Cargo plugin to build bpf programs @@ -15,7 +15,7 @@ Source: %{crates_source} # fix to point to /usr/share/cargo/registry Patch: libbpf-cargo-fix-finding-libbpf-rs.diff -BuildRequires: rust-packaging >= 21 +BuildRequires: cargo-rpm-macros >= 24 %global _description %{expand: Cargo plugin to build bpf programs.} @@ -24,6 +24,9 @@ Cargo plugin to build bpf programs.} %package -n %{crate} Summary: %{summary} +# FIXME: paste output of %%cargo_license_summary here +License: # FIXME +# LICENSE.dependencies contains a full license breakdown %description -n %{crate} %{_description} @@ -31,6 +34,7 @@ Summary: %{summary} %license LICENSE %license LICENSE.BSD-2-Clause %license LICENSE.LGPL-2.1 +%license LICENSE.dependencies %doc CHANGELOG.md %doc README.md %{_bindir}/cargo-libbpf @@ -79,7 +83,7 @@ use the "novendor" feature of the "%{crate}" crate. %ghost %{crate_instdir}/Cargo.toml %prep -%autosetup -n %{crate}-%{version_no_tilde} -p1 +%autosetup -n %{crate}-%{version} -p1 %cargo_prep %generate_buildrequires @@ -89,6 +93,8 @@ echo 'rustfmt' %build %cargo_build +%{cargo_license_summary} +%{cargo_license} > LICENSE.dependencies %install %cargo_install diff --git a/rust2rpm.conf b/rust2rpm.conf deleted file mode 100644 index 7e2b391..0000000 --- a/rust2rpm.conf +++ /dev/null @@ -1,7 +0,0 @@ -[DEFAULT] -buildrequires = - clang - rustfmt -lib.requires = - clang - rustfmt diff --git a/rust2rpm.toml b/rust2rpm.toml new file mode 100644 index 0000000..dec1df8 --- /dev/null +++ b/rust2rpm.toml @@ -0,0 +1,3 @@ +[requires] +build = ["clang", "rustfmt"] +lib = ["clang", "rustfmt"] diff --git a/sources b/sources index f7edabb..450d41c 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (libbpf-cargo-0.21.2.crate) = 8cc6e1e9f159fdc619621fe21960d6c634a978b14a203fdbad5b8615e31e871f68f85ad43521625235bf312f03804de633d7d45d0056b58288e612d6794f5db3 +SHA512 (libbpf-cargo-0.22.0.crate) = e06d45e543ceca3b8893f435cf22fb2112b93269dde75a2d7757366db3f3b76cff83ec6afd55ee767a54cc5f034cb62b2f5a90939a356231c16df1927243f026