linuxPackages_latest.perf: fix python shebangs on 6.3+

Without the change `perf` build fails as:

    sh: line 1: pmu-events/metric_test.py: cannot execute: required file not found
    make[3]: *** [pmu-events/Build:32: pmu-events/metric_test.log] Error 1

Full build log: https://hydra.nixos.org/log/mp5a0fr1jhw3rvkp8azbh5xh0g1cjqhj-perf-linux-6.3.drv
This commit is contained in:
Sergei Trofimovich 2023-04-25 07:30:18 +01:00
parent e2e676d8cd
commit e205b43f47

View file

@ -64,6 +64,10 @@ stdenv.mkDerivation {
# Linux scripts
patchShebangs scripts
'' + lib.optionalString (lib.versionAtLeast kernel.version "6.3") ''
# perf-specific scripts
patchShebangs tools/perf/pmu-events
'' + ''
cd tools/perf
for x in util/build-id.c util/dso.c; do