diff mbox series

[v2] package/util-linux: add an option to enable irqtop

Message ID 20230117074742.5295-1-yegorslists@googlemail.com
State Accepted
Headers show
Series [v2] package/util-linux: add an option to enable irqtop | expand

Commit Message

Nayab Sayed via buildroot Jan. 17, 2023, 7:47 a.m. UTC
From: Yegor Yefremov <yegorslists@googlemail.com>

irqtop is an IRQ monitoring tool.

Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
---
Changes v1 -> v2:
	- add the missing NCURSES dependency

 package/util-linux/Config.in     | 8 ++++++++
 package/util-linux/util-linux.mk | 1 +
 2 files changed, 9 insertions(+)

Comments

Thomas Petazzoni Jan. 28, 2023, 10:11 p.m. UTC | #1
Hello,

On Tue, 17 Jan 2023 08:47:42 +0100
yegorslists--- via buildroot <buildroot@buildroot.org> wrote:

> From: Yegor Yefremov <yegorslists@googlemail.com>
> 
> irqtop is an IRQ monitoring tool.
> 
> Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
> ---
> Changes v1 -> v2:
> 	- add the missing NCURSES dependency

Applied to master, thanks.

Yann: I read your (very valid) concern about the fact that this patch
is changing the behavior of current configurations (irqtop used to be
built unconditionally if all its prerequisites are met, now it is only
built if BR2_PACKAGE_UTIL_LINUX_IRQTOP=y). However, I think the
breakage is very easy to fix, and we need to find the good balance
between backward compatibility and minimal configuration/footprint by
default. In this case, I believe the best trade-off was to make this
new option default to disabled. Note that I realize this is really an
opinion, and there's no perfect solution here.

Best regards,

Thomas
diff mbox series

Patch

diff --git a/package/util-linux/Config.in b/package/util-linux/Config.in
index 917f1bc2b4..b5d8cad15b 100644
--- a/package/util-linux/Config.in
+++ b/package/util-linux/Config.in
@@ -161,6 +161,14 @@  config BR2_PACKAGE_UTIL_LINUX_IPCS
 	help
 	  Show information on IPC facilities
 
+config BR2_PACKAGE_UTIL_LINUX_IRQTOP
+	bool "irqtop"
+	depends on BR2_USE_MMU # libsmartcols
+	select BR2_PACKAGE_NCURSES
+	select BR2_PACKAGE_UTIL_LINUX_LIBSMARTCOLS
+	help
+	  Show information on IRQs
+
 config BR2_PACKAGE_UTIL_LINUX_KILL
 	bool "kill"
 	help
diff --git a/package/util-linux/util-linux.mk b/package/util-linux/util-linux.mk
index b53b94ec31..87ec3c19d7 100644
--- a/package/util-linux/util-linux.mk
+++ b/package/util-linux/util-linux.mk
@@ -136,6 +136,7 @@  UTIL_LINUX_CONF_OPTS += \
 	$(if $(BR2_PACKAGE_UTIL_LINUX_IPCMK),--enable-ipcmk,--disable-ipcmk) \
 	$(if $(BR2_PACKAGE_UTIL_LINUX_IPCRM),--enable-ipcrm,--disable-ipcrm) \
 	$(if $(BR2_PACKAGE_UTIL_LINUX_IPCS),--enable-ipcs,--disable-ipcs) \
+	$(if $(BR2_PACKAGE_UTIL_LINUX_IRQTOP),--enable-irqtop,--disable-irqtop) \
 	$(if $(BR2_PACKAGE_UTIL_LINUX_KILL),--enable-kill,--disable-kill) \
 	$(if $(BR2_PACKAGE_UTIL_LINUX_LAST),--enable-last,--disable-last) \
 	$(if $(BR2_PACKAGE_UTIL_LINUX_LIBBLKID),--enable-libblkid,--disable-libblkid) \