--- Begin Message ---
Subject: |
[PATCH] gnu: perf-tools: Patch executable paths |
Date: |
Fri, 5 Aug 2022 11:49:26 -0400 |
* gnu/packages/instrumentation.scm (perf-tools): Add patch phase.
[phases]: Add patch-paths.
---
gnu/packages/instrumentation.scm | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/instrumentation.scm b/gnu/packages/instrumentation.scm
index f52cf11505..95724f976b 100644
--- a/gnu/packages/instrumentation.scm
+++ b/gnu/packages/instrumentation.scm
@@ -308,7 +308,15 @@ (define-public perf-tools
(base32
"1ab735idi0h62yvhzd7822jj3555vygixv4xjrfrdvi8d2hhz6qn"))))
(build-system copy-build-system)
(arguments
- `(#:install-plan
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'patch-paths
+ (lambda _
+ (substitute* '("execsnoop" "killsnoop" "kernel/funcslower")
+ (("/usr/bin/gawk") (which "awk")))
+ (substitute* '"execsnoop"
+ (("/usr/bin/getconf") (which "getconf"))))))
+ #:install-plan
',(append
(map (cut list <> "bin/")
'("disk/bitesize"
--
2.37.1
--- End Message ---
--- Begin Message ---
Subject: |
Re: bug#57008: [PATCH] gnu: perf-tools: Patch executable paths |
Date: |
Wed, 31 Aug 2022 23:05:36 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.1 (gnu/linux) |
Hi Olivier & Mathieu,
Olivier Dion <olivier.dion@polymtl.ca> skribis:
> * gnu/packages/instrumentation.scm (perf-tools): Add patch phase.
> [phases]: Add patch-paths.
[...]
> + (substitute* '("execsnoop" "killsnoop" "kernel/funcslower")
> + (("/usr/bin/gawk") (which "awk")))
> + (substitute* '"execsnoop"
> + (("/usr/bin/getconf") (which "getconf"))))))
I went ahead and applied a modified version of this patch that uses
‘search-input-file’ instead of ‘which’.
Thanks,
Ludo’.
--- End Message ---