reaction: port patch for aarch64-linux nftables compat

This patch is merged upstream and can be reverted on the next update.

Fetchpatch does not work against framagit.org, which is why I vendored
the patch instead.
This commit is contained in:
Martin Weinelt
2026-05-28 01:42:39 +02:00
parent d961402c8f
commit 1a7b7c7ddf
3 changed files with 45 additions and 1 deletions
@@ -0,0 +1,33 @@
From 94fafae651077be5e7a6dfd29fc06327a2f218ed Mon Sep 17 00:00:00 2001
From: ppom <reaction@ppom.me>
Date: Thu, 28 May 2026 12:00:00 +0200
Subject: [PATCH] nftables: fix compilation on aarch64-linux
---
plugins/reaction-plugin-nftables/src/nft.rs | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/plugins/reaction-plugin-nftables/src/nft.rs b/plugins/reaction-plugin-nftables/src/nft.rs
index c234f77..2ac49df 100644
--- a/plugins/reaction-plugin-nftables/src/nft.rs
+++ b/plugins/reaction-plugin-nftables/src/nft.rs
@@ -1,5 +1,6 @@
use std::{
ffi::{CStr, CString},
+ os::raw::c_char,
thread,
};
@@ -71,7 +72,7 @@ struct NftCommand {
ret: oneshot::Sender<Result<String, String>>,
}
-fn to_rust_string(c_ptr: *const i8) -> Option<String> {
+fn to_rust_string(c_ptr: *const c_char) -> Option<String> {
if c_ptr.is_null() {
None
} else {
--
GitLab
+6
View File
@@ -4,6 +4,7 @@
callPackage,
rustPlatform,
fetchFromGitLab,
fetchpatch,
versionCheckHook,
installShellFiles,
@@ -23,6 +24,11 @@ rustPlatform.buildRustPackage (finalAttrs: {
hash = "sha256-Y6scgbcwhg56SQ1DefNtdja+n89Gc5bJUHKHKn2EYwQ=";
};
patches = [
# nftables: fix compilation on aarch64-linux; remove in 2.4.1
./nftables-aarch64-linux-compat.patch
];
cargoHash = "sha256-NAcMpASvphAqjBjbAPWLG5qZbSgdaFC3GvU25exCS3g=";
nativeBuildInputs = [ installShellFiles ];
+6 -1
View File
@@ -12,7 +12,12 @@
rustPlatform.buildRustPackage (
{
pname = name;
inherit (reaction) version src cargoHash;
inherit (reaction)
version
src
patches
cargoHash
;
buildAndTestSubdir = "plugins/${name}";
meta = {