-
-
Save abel0b/b1881e41b9e1c4b16d84e5e083c38a13 to your computer and use it in GitHub Desktop.
apt install flex bison | |
git clone https://github.com/microsoft/WSL2-Linux-Kernel --depth 1 | |
cd WSL2-Linux-Kernel/tools/perf | |
make -j8 | |
sudo cp perf /usr/local/bin |
Downgraded to Python 3.10.13 and it also worked.
Downgraded to Python 3.10.13 and it also worked.
Ty, worked
what about WSL1 ?
Why do you even use it?
What about this one?
In file included from /home/vaqxai/perf-install/perf-6.9.0/tools/perf/util/evsel.c:43:
/home/vaqxai/perf-install/perf-6.9.0/tools/perf/util/trace-event.h:152:62: error: operator '&&' has no right operand
152 | #if defined(LIBTRACEEVENT_VERSION) && LIBTRACEEVENT_VERSION >= MAKE_LIBTRACEEVENT_VERSION(1, 5, 0)
| ^~
error: command '/usr/bin/gcc' failed with exit code 1
What about this one?
In file included from /home/vaqxai/perf-install/perf-6.9.0/tools/perf/util/evsel.c:43: /home/vaqxai/perf-install/perf-6.9.0/tools/perf/util/trace-event.h:152:62: error: operator '&&' has no right operand 152 | #if defined(LIBTRACEEVENT_VERSION) && LIBTRACEEVENT_VERSION >= MAKE_LIBTRACEEVENT_VERSION(1, 5, 0) | ^~ error: command '/usr/bin/gcc' failed with exit code 1
I delete ./util/debug.c:31 and it works for me.
What about this one?
In file included from /home/vaqxai/perf-install/perf-6.9.0/tools/perf/util/evsel.c:43: /home/vaqxai/perf-install/perf-6.9.0/tools/perf/util/trace-event.h:152:62: error: operator '&&' has no right operand 152 | #if defined(LIBTRACEEVENT_VERSION) && LIBTRACEEVENT_VERSION >= MAKE_LIBTRACEEVENT_VERSION(1, 5, 0) | ^~ error: command '/usr/bin/gcc' failed with exit code 1
I delete ./util/debug.c:31 and it works for me.
didn't work for me
Also missing libpfm4-dev libtraceevent-dev pkg-config
With sudo apt install libpfm4-dev libtraceevent-dev pkg-config
the compilation error issue get solved.
With
sudo apt install libpfm4-dev libtraceevent-dev pkg-config
the compilation error issue get solved.
Had the same issue as crucinal1, and that solution worked.
With
sudo apt install libpfm4-dev libtraceevent-dev pkg-config
the compilation error issue get solved.
Thanks, that works.
For people seeing errors, try make -j8 WERROR=0
, as the kernel automatically turns warning into errors. This stops that behaviour.
What about this one?
In file included from /home/vaqxai/perf-install/perf-6.9.0/tools/perf/util/evsel.c:43: /home/vaqxai/perf-install/perf-6.9.0/tools/perf/util/trace-event.h:152:62: error: operator '&&' has no right operand 152 | #if defined(LIBTRACEEVENT_VERSION) && LIBTRACEEVENT_VERSION >= MAKE_LIBTRACEEVENT_VERSION(1, 5, 0) | ^~ error: command '/usr/bin/gcc' failed with exit code 1
apt install pkg-config
and it works for me
What about this one?
In file included from /home/vaqxai/perf-install/perf-6.9.0/tools/perf/util/evsel.c:43: /home/vaqxai/perf-install/perf-6.9.0/tools/perf/util/trace-event.h:152:62: error: operator '&&' has no right operand 152 | #if defined(LIBTRACEEVENT_VERSION) && LIBTRACEEVENT_VERSION >= MAKE_LIBTRACEEVENT_VERSION(1, 5, 0) | ^~ error: command '/usr/bin/gcc' failed with exit code 1
apt install
pkg-config
and it works for me
finally it work, thank you
I'm getting
Makefile.config:1144: *** ERROR: libtraceevent is missing. Please install libtraceevent-dev/libtraceevent-devel or build with NO_LIBTRACEEVENT=1. Stop.
Unfortunately.....
$ sudo apt install libtraceevent-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package libtraceevent-dev
For anyone else who gets this, looking at the page for libtraceevent suggests that the issue is probably because I am still on Ubuntu 2020.04 LTS (Focal). The oldest they have is for 2022 Jammy. How quickly time has flown...
The latest LTS release is 2024.04 LTS (Noble). I'll post back here if upgrading doesn't fix this issue.
Edit: Installing 2024.04 LTS fixed the issue.
perf record
, perf report
work beautifully
yes, python 3.10.12 is ok, but 3.11 will broken