diff options
author | Alyssa Ross <hi@alyssa.is> | 2023-03-18 18:50:14 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2023-03-19 09:57:57 +0000 |
commit | 916dba8790619ad3002ab489a32f44070e44152d (patch) | |
tree | 46bd32ff3bc6fba5e2aa0bdfbacc8c934206e37f /pkgs/os-specific/linux/bpftools | |
parent | 25610316d9685aac7465def38a9d729764cb0fc5 (diff) |
bpftools: 5.19.12 -> 6.2; sync with linuxHeaders
bpftools used to use the same version and sources as linux_latest, but this was changed in f12d2f016b6 ("bpftools: decouple version from linux_latest"), because it caused too many rebuilds. Since then, it has languished. It came to my attention because bpftool btf dump seems to be completely broken on recent kernels. So, since it's a package that really needs to be kept up to date to be compatible with the latest kernels, let's couple it to linuxHeaders instead. linuxHeaders updates already have to go through staging, so we won't suffer from extra rebuilds like we did when it was coupled to the latest kernel directly, which goes straight to master.
Diffstat (limited to 'pkgs/os-specific/linux/bpftools')
-rw-r--r-- | pkgs/os-specific/linux/bpftools/default.nix | 9 | ||||
-rw-r--r-- | pkgs/os-specific/linux/bpftools/strip-binary-name.patch | 15 |
2 files changed, 2 insertions, 22 deletions
diff --git a/pkgs/os-specific/linux/bpftools/default.nix b/pkgs/os-specific/linux/bpftools/default.nix index 287ad9d42264b..ef89ae4040637 100644 --- a/pkgs/os-specific/linux/bpftools/default.nix +++ b/pkgs/os-specific/linux/bpftools/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchurl +{ lib, stdenv, linuxHeaders , libopcodes, libopcodes_2_38 , libbfd, libbfd_2_38 , elfutils, readline @@ -8,15 +8,10 @@ stdenv.mkDerivation rec { pname = "bpftools"; - version = "5.19.12"; - src = fetchurl { - url = "mirror://kernel/linux/kernel/v5.x/linux-${version}.tar.xz"; - sha256 = "sha256-xDalSMcxLOb8WjRyy+rYle749ShB++fHH9jki9/isLo="; - }; + inherit (linuxHeaders) version src; patches = [ - ./strip-binary-name.patch # fix unknown type name '__vector128' on ppc64le ./include-asm-types-for-ppc64le.patch ]; diff --git a/pkgs/os-specific/linux/bpftools/strip-binary-name.patch b/pkgs/os-specific/linux/bpftools/strip-binary-name.patch deleted file mode 100644 index 623e90963bd9b..0000000000000 --- a/pkgs/os-specific/linux/bpftools/strip-binary-name.patch +++ /dev/null @@ -1,15 +0,0 @@ -Strip path to the binary from prints. - -I see no sense in including the full path in outputs like bpftool --version -Especially as argv[0] may not include it, based on calling via $PATH or not. ---- a/tools/bpf/bpftool/main.c -+++ b/tools/bpf/bpftool/main.c -@@ -443 +443,7 @@ -- bin_name = argv[0]; -+ /* Strip the path if any. */ -+ const char *bin_name_slash = strrchr(argv[0], '/'); -+ if (bin_name_slash) { -+ bin_name = bin_name_slash + 1; -+ } else { -+ bin_name = argv[0]; -+ } |