5

There is a convenient Linux kernel makefile target "make deb-pkg" to build kernel, modules, headers as .deb. Then I can install/remove via dpkg command.

However, for perf compilation, there is only build source package option. I wonder if there is a way to build perf as installable.deb as well?

Patrick
  • 259
  • 1
  • 5

2 Answers2

3

see the patch "kbuild: Build linux-tools package with 'make deb-pkg'". Or latest you could use this patch "RFC: builddeb: add linux-tools package with perf"However, those patch was not integrated into kernel source.

0

You can use these patches and apply them to the vanilla linux kernel. These patches are more recent than what was posted above. This will build linux-tools-*.deb packages. I've recently tested on the following versions:

  • linux-5.17.3 and linux-5.19.13
  • On linux-6.2.8 version, because libtraceevent was removed from the kernel, you'll have to remove the dpkg-shlibdeps $tools_dest/usr/bin/* $tools_dest/usr/lib64/traceevent/plugins/* line from the patch.
cojocar
  • 101
  • 2