bpftune: 0-unstable-2025-03-20 → 0.4-2 (#483359)

This commit is contained in:
Sandro
2026-02-12 15:07:06 +00:00
committed by GitHub
2 changed files with 10 additions and 10 deletions
+4 -1
View File
@@ -22,6 +22,9 @@ in
config = lib.mkIf cfg.enable {
systemd.packages = [ cfg.package ];
systemd.services.bpftune.wantedBy = [ "multi-user.target" ];
systemd.services.bpftune = {
wantedBy = [ "multi-user.target" ];
path = [ pkgs.kmod ]; # bpftune calls modprobe
};
};
}
+6 -9
View File
@@ -9,29 +9,27 @@
libcap,
libnl,
nixosTests,
unstableGitUpdater,
nix-update-script,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "bpftune";
version = "0-unstable-2025-03-20";
version = "0.4-2";
src = fetchFromGitHub {
owner = "oracle";
repo = "bpftune";
rev = "8c6a3ffc09265bd44ed89b75c400ef97959d1aff";
hash = "sha256-TQ8WaGvMcvyeZC4B9gSjJ2k5NOxpTaV4n7Qi36aA78Q=";
tag = finalAttrs.version;
hash = "sha256-clfR2nZKB9ztfUEw+znr9/Rdefv4K+mTeRCSBLIBmVY=";
};
postPatch = ''
# otherwise shrink rpath would drop $out/lib from rpath
substituteInPlace src/Makefile \
--replace-fail /sbin /bin \
--replace-fail /sbin /bin \
--replace-fail ldconfig true
substituteInPlace src/bpftune.service \
--replace-fail /usr/sbin/bpftune "$out/bin/bpftune"
substituteInPlace src/libbpftune.c \
--replace-fail /lib/modules /run/booted-system/kernel-modules/lib/modules
'';
nativeBuildInputs = [
@@ -56,7 +54,6 @@ stdenv.mkDerivation (finalAttrs: {
];
hardeningDisable = [
"stackprotector"
"zerocallusedregs"
];
@@ -64,7 +61,7 @@ stdenv.mkDerivation (finalAttrs: {
tests = {
inherit (nixosTests) bpftune;
};
updateScript = unstableGitUpdater { };
updateScript = nix-update-script { };
};
enableParallelBuilding = true;