All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 0/4] introduce the rtla package and its dependencies
@ 2023-01-30 14:46 Maxime Chevallier via buildroot
  2023-01-30 14:46 ` [Buildroot] [PATCH 1/4] package/libtraceevent: new package Maxime Chevallier via buildroot
                   ` (3 more replies)
  0 siblings, 4 replies; 15+ messages in thread
From: Maxime Chevallier via buildroot @ 2023-01-30 14:46 UTC (permalink / raw)
  To: buildroot
  Cc: Pierre Floury, Giulio Benetti, Thomas Petazzoni, Maxime Chevallier

The RTLA (RealTime Linux Analysis) tool is an interface to the osnoise
and timerlat tracers from ftrace, allowing to benchmark and investigate
the sources of latencies introduced by the hardware and the kernel.

It has dependencies on libtraceevent and libtracefs, which used to be
part of the trace-cmd package.

This series introduces one package per library, the rtla tool itself,
and also bumps the trace-cmd version so that it uses the now-external
libraries.

Maxime Chevallier (4):
  package/libtraceevent: new package
  package/libtracefs: new package
  package/linux-tools: add rtla
  package/trace-cmd: bump to 3.1.5

 DEVELOPERS                                |  5 ++++
 package/Config.in                         |  2 ++
 package/libtraceevent/Config.in           |  9 ++++++
 package/libtraceevent/libtraceevent.mk    | 33 +++++++++++++++++++++
 package/libtracefs/Config.in              |  6 ++++
 package/libtracefs/libtracefs.mk          | 35 +++++++++++++++++++++++
 package/linux-tools/Config.in             | 10 +++++++
 package/linux-tools/linux-tool-rtla.mk.in | 32 +++++++++++++++++++++
 package/trace-cmd/Config.in               |  2 ++
 package/trace-cmd/trace-cmd.hash          |  2 +-
 package/trace-cmd/trace-cmd.mk            |  6 ++--
 11 files changed, 139 insertions(+), 3 deletions(-)
 create mode 100644 package/libtraceevent/Config.in
 create mode 100644 package/libtraceevent/libtraceevent.mk
 create mode 100644 package/libtracefs/Config.in
 create mode 100644 package/libtracefs/libtracefs.mk
 create mode 100644 package/linux-tools/linux-tool-rtla.mk.in

-- 
2.39.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 15+ messages in thread

* [Buildroot] [PATCH 1/4] package/libtraceevent: new package
  2023-01-30 14:46 [Buildroot] [PATCH 0/4] introduce the rtla package and its dependencies Maxime Chevallier via buildroot
@ 2023-01-30 14:46 ` Maxime Chevallier via buildroot
  2023-05-14 14:01   ` Yann E. MORIN
  2023-01-30 14:46 ` [Buildroot] [PATCH 2/4] package/libtracefs: " Maxime Chevallier via buildroot
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 15+ messages in thread
From: Maxime Chevallier via buildroot @ 2023-01-30 14:46 UTC (permalink / raw)
  To: buildroot
  Cc: Pierre Floury, Giulio Benetti, Thomas Petazzoni, Maxime Chevallier

Introduce the libtraceevent library, that used to be bundled with the
trace-cmd tool. This library is now used by several tools and libraries
such as trace-cmd, libtracefs and rtla.

This package tries to install libraries in /usr/local/lib by default,
hence the redefinition of the "prefix" variable, so that the library
gets installed in "/usr/lib" instead.

The same applies to the pkgconfig handling of the proved Makefile, which
installs the .pc files in the /usr/local area by default, hence the
redefinition of the pkgconfig_dir to either the correct directory within the
staging area, or to empty value for the target to avoid installing the .pc
in that case.

Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
---
 DEVELOPERS                             |  3 +++
 package/Config.in                      |  1 +
 package/libtraceevent/Config.in        |  9 +++++++
 package/libtraceevent/libtraceevent.mk | 33 ++++++++++++++++++++++++++
 4 files changed, 46 insertions(+)
 create mode 100644 package/libtraceevent/Config.in
 create mode 100644 package/libtraceevent/libtraceevent.mk

diff --git a/DEVELOPERS b/DEVELOPERS
index 706ee80ece..fcf05e0aa0 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -2106,6 +2106,9 @@ F:	package/postgresql/
 F:	package/protozero/
 F:	package/timescaledb/
 
+N:	Maxime Chevallier <maxime.chevallier@bootlin.com>
+F:	package/libtraceevent/
+
 N:	Michael Durrant <mdurrant@arcturusnetworks.com>
 F:	board/arcturus/
 F:	configs/arcturus_ucp1020_defconfig
diff --git a/package/Config.in b/package/Config.in
index 83fddf316f..2f0e6dcb18 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -117,6 +117,7 @@ menu "Debugging, profiling and benchmark"
 	source "package/kyua/Config.in"
 	source "package/latencytop/Config.in"
 	source "package/libbpf/Config.in"
+	source "package/libtraceevent/Config.in"
 	source "package/lmbench/Config.in"
 	source "package/lsof/Config.in"
 	source "package/ltp-testsuite/Config.in"
diff --git a/package/libtraceevent/Config.in b/package/libtraceevent/Config.in
new file mode 100644
index 0000000000..d351e3b4de
--- /dev/null
+++ b/package/libtraceevent/Config.in
@@ -0,0 +1,9 @@
+config BR2_PACKAGE_LIBTRACEEVENT
+	bool "libtraceevent"
+	help
+	  libtraceevent is a library that interfaces with the ftrace
+	  subsystem in the linux kernel.
+	  It used to be bundled directly in the trace-cmd
+	  tool, but it was eventually extracted so that it can be used
+	  by multiple other tools and libraries, such as libtracefs and
+	  rtla.
diff --git a/package/libtraceevent/libtraceevent.mk b/package/libtraceevent/libtraceevent.mk
new file mode 100644
index 0000000000..0125023508
--- /dev/null
+++ b/package/libtraceevent/libtraceevent.mk
@@ -0,0 +1,33 @@
+################################################################################
+#
+# libtraceevent
+#
+################################################################################
+
+LIBTRACEEVENT_VERSION = 1.7.1
+LIBTRACEEVENT_SITE = https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git/snapshot
+LIBTRACEEVENT_INSTALL_STAGING = YES
+LIBTRACEEVENT_LICENSE = GPL-2.0, LGPL-2.1
+LIBTRACEEVENT_LICENSE_FILES = LICENSES/GPL-2.0 LICENSES/LGPL-2.1
+
+define LIBTRACEEVENT_BUILD_CMDS
+	$(TARGET_MAKE_ENV) $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)
+endef
+
+define LIBTRACEEVENT_INSTALL_STAGING_CMDS
+	$(TARGET_MAKE_ENV) $(MAKE1) -C $(@D) $(TARGET_CONFIGURE_OPTS) \
+	DESTDIR=$(STAGING_DIR) \
+	pkgconfig_dir="/usr/lib/pkgconfig" \
+	prefix="/usr" \
+	install
+endef
+
+define LIBTRACEEVENT_INSTALL_TARGET_CMDS
+	$(TARGET_MAKE_ENV) $(MAKE1) -C $(@D) $(TARGET_CONFIGURE_OPTS) \
+	DESTDIR=$(TARGET_DIR) \
+	pkgconfig_dir="" \
+	prefix="/usr" \
+	install
+endef
+
+$(eval $(generic-package))
-- 
2.39.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [Buildroot] [PATCH 2/4] package/libtracefs: new package
  2023-01-30 14:46 [Buildroot] [PATCH 0/4] introduce the rtla package and its dependencies Maxime Chevallier via buildroot
  2023-01-30 14:46 ` [Buildroot] [PATCH 1/4] package/libtraceevent: new package Maxime Chevallier via buildroot
@ 2023-01-30 14:46 ` Maxime Chevallier via buildroot
  2023-05-14 14:02   ` Yann E. MORIN
  2023-01-30 14:46 ` [Buildroot] [PATCH 3/4] package/linux-tools: add rtla Maxime Chevallier via buildroot
  2023-01-30 14:46 ` [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5 Maxime Chevallier via buildroot
  3 siblings, 1 reply; 15+ messages in thread
From: Maxime Chevallier via buildroot @ 2023-01-30 14:46 UTC (permalink / raw)
  To: buildroot
  Cc: Pierre Floury, Giulio Benetti, Thomas Petazzoni, Maxime Chevallier

Introduce the libtracefs library, that used to be bundled with the
trace-cmd tool. This library is now used by several tools and libraries
such as trace-cmd and rtla, and is used as an interface to the ftrace
kernel subsystem through tracefs.

This package tries to install libraries in /usr/local/lib by default,
hence the redefinition of the "prefix" variable, so that the library
gets installed in "/usr/lib" instead.

The same applies to the pkgconfig handling of the proved Makefile, which
installs the .pc files in the /usr/local area by default, hence the
redefinition of the pkgconfig_dir to either the correct directory within the
staging area, or to empty value for the target to avoid installing the .pc
in that case.

Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
---
 DEVELOPERS                       |  1 +
 package/Config.in                |  1 +
 package/libtracefs/Config.in     |  6 ++++++
 package/libtracefs/libtracefs.mk | 35 ++++++++++++++++++++++++++++++++
 4 files changed, 43 insertions(+)
 create mode 100644 package/libtracefs/Config.in
 create mode 100644 package/libtracefs/libtracefs.mk

diff --git a/DEVELOPERS b/DEVELOPERS
index fcf05e0aa0..fe7194f817 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -2108,6 +2108,7 @@ F:	package/timescaledb/
 
 N:	Maxime Chevallier <maxime.chevallier@bootlin.com>
 F:	package/libtraceevent/
+F:	package/libtracefs
 
 N:	Michael Durrant <mdurrant@arcturusnetworks.com>
 F:	board/arcturus/
diff --git a/package/Config.in b/package/Config.in
index 2f0e6dcb18..47e59374e2 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -118,6 +118,7 @@ menu "Debugging, profiling and benchmark"
 	source "package/latencytop/Config.in"
 	source "package/libbpf/Config.in"
 	source "package/libtraceevent/Config.in"
+	source "package/libtracefs/Config.in"
 	source "package/lmbench/Config.in"
 	source "package/lsof/Config.in"
 	source "package/ltp-testsuite/Config.in"
diff --git a/package/libtracefs/Config.in b/package/libtracefs/Config.in
new file mode 100644
index 0000000000..92ce0986df
--- /dev/null
+++ b/package/libtracefs/Config.in
@@ -0,0 +1,6 @@
+config BR2_PACKAGE_LIBTRACEFS
+	bool "libtracefs"
+	select BR2_PACKAGE_LIBTRACEEVENT
+	help
+	  libtracefs is used to easily interface with the ftrace
+	  interface through the tracefs virtual filesystem.
diff --git a/package/libtracefs/libtracefs.mk b/package/libtracefs/libtracefs.mk
new file mode 100644
index 0000000000..4ee6e38105
--- /dev/null
+++ b/package/libtracefs/libtracefs.mk
@@ -0,0 +1,35 @@
+################################################################################
+#
+# libtracefs
+#
+################################################################################
+
+LIBTRACEFS_VERSION = 1.6.4
+LIBTRACEFS_SITE = https://git.kernel.org/pub/scm/libs/libtrace/libtracefs.git/snapshot
+LIBTRACEFS_INSTALL_STAGING = YES
+LIBTRACEFS_LICENSE = GPL-2.0, LGPL-2.1
+LIBTRACEFS_LICENSE_FILES = LICENSES/GPL-2.0 LICENSES/LGPL-2.1
+
+LIBTRACEFS_DEPENDENCIES = host-pkgconf libtraceevent
+
+define LIBTRACEFS_BUILD_CMDS
+	$(TARGET_MAKE_ENV) $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D)
+endef
+
+define LIBTRACEFS_INSTALL_STAGING_CMDS
+	$(TARGET_MAKE_ENV) $(MAKE1) -C $(@D) $(TARGET_CONFIGURE_OPTS) \
+	DESTDIR=$(STAGING_DIR) \
+	pkgconfig_dir="/usr/lib/pkgconfig" \
+	prefix="/usr" \
+	install
+endef
+
+define LIBTRACEFS_INSTALL_TARGET_CMDS
+	$(TARGET_MAKE_ENV) $(MAKE1) -C $(@D) $(TARGET_CONFIGURE_OPTS) \
+	DESTDIR=$(TARGET_DIR) \
+	pkgconfig_dir="" \
+	prefix="/usr" \
+	install
+endef
+
+$(eval $(generic-package))
-- 
2.39.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [Buildroot] [PATCH 3/4] package/linux-tools: add rtla
  2023-01-30 14:46 [Buildroot] [PATCH 0/4] introduce the rtla package and its dependencies Maxime Chevallier via buildroot
  2023-01-30 14:46 ` [Buildroot] [PATCH 1/4] package/libtraceevent: new package Maxime Chevallier via buildroot
  2023-01-30 14:46 ` [Buildroot] [PATCH 2/4] package/libtracefs: " Maxime Chevallier via buildroot
@ 2023-01-30 14:46 ` Maxime Chevallier via buildroot
  2023-05-14 14:06   ` Yann E. MORIN
  2023-01-30 14:46 ` [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5 Maxime Chevallier via buildroot
  3 siblings, 1 reply; 15+ messages in thread
From: Maxime Chevallier via buildroot @ 2023-01-30 14:46 UTC (permalink / raw)
  To: buildroot
  Cc: Pierre Floury, Giulio Benetti, Thomas Petazzoni, Maxime Chevallier

The RealTime Linux Analysis tool includes a set of commands that relies
on the osnoise and timerlat tracers from the ftrace kernel subsystem,
allowing to analyze the lantency sources coming from the hardware and
the kernel itself.

This tool was introduced in v5.17, and relies on libtracefs and
libtraceevent, although libtraceevent itself is already a dependency for
libtracefs.

Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
---
 DEVELOPERS                                |  1 +
 package/linux-tools/Config.in             | 10 +++++++
 package/linux-tools/linux-tool-rtla.mk.in | 32 +++++++++++++++++++++++
 3 files changed, 43 insertions(+)
 create mode 100644 package/linux-tools/linux-tool-rtla.mk.in

diff --git a/DEVELOPERS b/DEVELOPERS
index fe7194f817..8f459c796a 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -2109,6 +2109,7 @@ F:	package/timescaledb/
 N:	Maxime Chevallier <maxime.chevallier@bootlin.com>
 F:	package/libtraceevent/
 F:	package/libtracefs
+F:	package/linux-tools/linux-tool-rtla.mk.in
 
 N:	Michael Durrant <mdurrant@arcturusnetworks.com>
 F:	board/arcturus/
diff --git a/package/linux-tools/Config.in b/package/linux-tools/Config.in
index 8a0b6d5802..186392b816 100644
--- a/package/linux-tools/Config.in
+++ b/package/linux-tools/Config.in
@@ -102,6 +102,16 @@ config BR2_PACKAGE_LINUX_TOOLS_PERF_NEEDS_HOST_PYTHON3
 
 endif
 
+config BR2_PACKAGE_LINUX_TOOLS_RTLA
+	bool "rtla"
+	select BR2_PACKAGE_LINUX_TOOLS
+	select BR2_PACKAGE_LIBTRACEFS
+	help
+	  Linux 5.17 and later has 2 new tracers, osnoise and timerlat.
+	  There tracers allow performing latency analysis, for which
+	  the rtla tool provides wrapper commands to visualize and
+	  extrace latency traces and reports.
+
 config BR2_PACKAGE_LINUX_TOOLS_SELFTESTS
 	bool"selftests"
 	depends on BR2_PACKAGE_BUSYBOX_SHOW_OTHERS # bash
diff --git a/package/linux-tools/linux-tool-rtla.mk.in b/package/linux-tools/linux-tool-rtla.mk.in
new file mode 100644
index 0000000000..a736e3b785
--- /dev/null
+++ b/package/linux-tools/linux-tool-rtla.mk.in
@@ -0,0 +1,32 @@
+################################################################################
+#
+# rtla
+#
+################################################################################
+
+LINUX_TOOLS += rtla
+
+RTLA_DEPENDENCIES = host-pkgconf libtracefs
+RTLA_MAKE_OPTS = $(LINUX_MAKE_FLAGS) \
+	CC=$(TARGET_CC) \
+	LDFLAGS="$(TARGET_LDFLAGS)" \
+	PKG_CONFIG_PATH=$(STAGING_DIR)/usr/lib/pkgconfig
+
+define RTLA_BUILD_CMDS
+	$(Q)if ! grep install $(LINUX_DIR)/tools/tracing/rtla/Makefile >/dev/null 2>&1 ; then \
+		echo "Your kernel version is too old and does not implement the rtla tool." ; \
+		echo "At least kernel 5.17 must be used." ; \
+		exit 1 ; \
+	fi
+
+	$(TARGET_MAKE_ENV) \
+	$(MAKE) $(RTLA_MAKE_OPTS) \
+	-C $(LINUX_DIR)/tools/tracing rtla
+endef
+
+define RTLA_INSTALL_TARGET_CMDS
+	$(TARGET_MAKE_ENV) $(MAKE) -C $(LINUX_DIR)/tools/tracing \
+	$(RTLA_MAKE_OPTS) \
+	DESTDIR=$(TARGET_DIR) \
+	rtla_install
+endef
-- 
2.39.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5
  2023-01-30 14:46 [Buildroot] [PATCH 0/4] introduce the rtla package and its dependencies Maxime Chevallier via buildroot
                   ` (2 preceding siblings ...)
  2023-01-30 14:46 ` [Buildroot] [PATCH 3/4] package/linux-tools: add rtla Maxime Chevallier via buildroot
@ 2023-01-30 14:46 ` Maxime Chevallier via buildroot
  2023-01-30 23:12   ` Giulio Benetti
  3 siblings, 1 reply; 15+ messages in thread
From: Maxime Chevallier via buildroot @ 2023-01-30 14:46 UTC (permalink / raw)
  To: buildroot
  Cc: Pierre Floury, Giulio Benetti, Thomas Petazzoni, Maxime Chevallier

trace-cmd's dependencies 'libtracefs' and 'libtraceevent' were split
into dedicated projects, maintained outside of trace-cmd.

This release, on top of bumping the version, adds this new dependencies.

Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
---
 package/trace-cmd/Config.in      | 2 ++
 package/trace-cmd/trace-cmd.hash | 2 +-
 package/trace-cmd/trace-cmd.mk   | 6 ++++--
 3 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/package/trace-cmd/Config.in b/package/trace-cmd/Config.in
index 2d0accd7ae..00b9ebbd9a 100644
--- a/package/trace-cmd/Config.in
+++ b/package/trace-cmd/Config.in
@@ -4,6 +4,8 @@ config BR2_PACKAGE_TRACE_CMD
 	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
 	depends on BR2_USE_MMU # fork()
 	depends on !BR2_STATIC_LIBS # dlopen()
+	select BR2_PACKAGE_LIBTRACEEVENT
+	select BR2_PACKAGE_LIBTRACEFS
 	help
 	  Command line reader for ftrace.
 
diff --git a/package/trace-cmd/trace-cmd.hash b/package/trace-cmd/trace-cmd.hash
index 4d39e4d5ea..c0c20dc317 100644
--- a/package/trace-cmd/trace-cmd.hash
+++ b/package/trace-cmd/trace-cmd.hash
@@ -1,5 +1,5 @@
 # Locally computed
-sha256  a74d9ade2633b88d0ad199360d51996427e23f4835594133e456cd6e3bd3a651  trace-cmd-v2.9.7.tar.gz
+sha256  9af1ea00e312d03639470e126fa9c786789f03c16df93a57c0bc90eeffbc7d50  trace-cmd-v3.1.5.tar.gz
 sha256  b1d04b850c1c7471b0f0896f6c6f0fcfc9f07e2dd183a5f5826af269fe9e88fb  COPYING
 sha256  70f297763149e72306919c924e164f83041d5e512868d4c8c1826c171b3e49f9  COPYING.LIB
 sha256  f6b78c087c3ebdf0f3c13415070dd480a3f35d8fc76f3d02180a407c1c812f79  LICENSES/GPL-2.0
diff --git a/package/trace-cmd/trace-cmd.mk b/package/trace-cmd/trace-cmd.mk
index 52bb99036c..049ec12925 100644
--- a/package/trace-cmd/trace-cmd.mk
+++ b/package/trace-cmd/trace-cmd.mk
@@ -4,14 +4,14 @@
 #
 ################################################################################
 
-TRACE_CMD_VERSION = 2.9.7
+TRACE_CMD_VERSION = 3.1.5
 TRACE_CMD_SOURCE = trace-cmd-v$(TRACE_CMD_VERSION).tar.gz
 TRACE_CMD_SITE = \
 	https://git.kernel.org/pub/scm/utils/trace-cmd/trace-cmd.git/snapshot
 TRACE_CMD_LICENSE = GPL-2.0, LGPL-2.1
 TRACE_CMD_LICENSE_FILES = COPYING COPYING.LIB LICENSES/GPL-2.0 LICENSES/LGPL-2.1
 
-TRACE_CMD_DEPENDENCIES = host-pkgconf
+TRACE_CMD_DEPENDENCIES = host-pkgconf libtracefs libtraceevent
 TRACE_CMD_MAKE_OPTS = prefix=/usr etcdir=/etc
 
 ifeq ($(BR2_PACKAGE_AUDIT),y)
@@ -34,6 +34,8 @@ ifeq ($(BR2_sparc64),y)
 TRACE_CMD_CFLAGS += -fPIC
 endif
 
+TRACE_CMD_CFLAGS += $($(HOST_DIR)/bin/pkg-config --cflags libtracefs)
+
 # trace-cmd use CPPFLAGS to add some extra flags.
 # But like for CFLAGS, $(TARGET_CPPFLAGS) contains _LARGEFILE64_SOURCE
 # that causes build problems.
-- 
2.39.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 15+ messages in thread

* Re: [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5
  2023-01-30 14:46 ` [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5 Maxime Chevallier via buildroot
@ 2023-01-30 23:12   ` Giulio Benetti
  2023-01-31 15:15     ` Maxime Chevallier via buildroot
  0 siblings, 1 reply; 15+ messages in thread
From: Giulio Benetti @ 2023-01-30 23:12 UTC (permalink / raw)
  To: Maxime Chevallier, buildroot; +Cc: Pierre Floury, Thomas Petazzoni

Hi Maxime,

I was trying to build trace-cmd but it hangs while calling the first
make on building stage.

I've tried with both make 4.3 and 4.3.91. Which make version are you using?

Best regards
-- 
Giulio Benetti
CEO/CTO@Benetti Engineering sas

On 30/01/23 15:46, Maxime Chevallier via buildroot wrote:
> trace-cmd's dependencies 'libtracefs' and 'libtraceevent' were split
> into dedicated projects, maintained outside of trace-cmd.
> 
> This release, on top of bumping the version, adds this new dependencies.
> 
> Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
> ---
>   package/trace-cmd/Config.in      | 2 ++
>   package/trace-cmd/trace-cmd.hash | 2 +-
>   package/trace-cmd/trace-cmd.mk   | 6 ++++--
>   3 files changed, 7 insertions(+), 3 deletions(-)
> 
> diff --git a/package/trace-cmd/Config.in b/package/trace-cmd/Config.in
> index 2d0accd7ae..00b9ebbd9a 100644
> --- a/package/trace-cmd/Config.in
> +++ b/package/trace-cmd/Config.in
> @@ -4,6 +4,8 @@ config BR2_PACKAGE_TRACE_CMD
>   	depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL
>   	depends on BR2_USE_MMU # fork()
>   	depends on !BR2_STATIC_LIBS # dlopen()
> +	select BR2_PACKAGE_LIBTRACEEVENT
> +	select BR2_PACKAGE_LIBTRACEFS
>   	help
>   	  Command line reader for ftrace.
>   
> diff --git a/package/trace-cmd/trace-cmd.hash b/package/trace-cmd/trace-cmd.hash
> index 4d39e4d5ea..c0c20dc317 100644
> --- a/package/trace-cmd/trace-cmd.hash
> +++ b/package/trace-cmd/trace-cmd.hash
> @@ -1,5 +1,5 @@
>   # Locally computed
> -sha256  a74d9ade2633b88d0ad199360d51996427e23f4835594133e456cd6e3bd3a651  trace-cmd-v2.9.7.tar.gz
> +sha256  9af1ea00e312d03639470e126fa9c786789f03c16df93a57c0bc90eeffbc7d50  trace-cmd-v3.1.5.tar.gz
>   sha256  b1d04b850c1c7471b0f0896f6c6f0fcfc9f07e2dd183a5f5826af269fe9e88fb  COPYING
>   sha256  70f297763149e72306919c924e164f83041d5e512868d4c8c1826c171b3e49f9  COPYING.LIB
>   sha256  f6b78c087c3ebdf0f3c13415070dd480a3f35d8fc76f3d02180a407c1c812f79  LICENSES/GPL-2.0
> diff --git a/package/trace-cmd/trace-cmd.mk b/package/trace-cmd/trace-cmd.mk
> index 52bb99036c..049ec12925 100644
> --- a/package/trace-cmd/trace-cmd.mk
> +++ b/package/trace-cmd/trace-cmd.mk
> @@ -4,14 +4,14 @@
>   #
>   ################################################################################
>   
> -TRACE_CMD_VERSION = 2.9.7
> +TRACE_CMD_VERSION = 3.1.5
>   TRACE_CMD_SOURCE = trace-cmd-v$(TRACE_CMD_VERSION).tar.gz
>   TRACE_CMD_SITE = \
>   	https://git.kernel.org/pub/scm/utils/trace-cmd/trace-cmd.git/snapshot
>   TRACE_CMD_LICENSE = GPL-2.0, LGPL-2.1
>   TRACE_CMD_LICENSE_FILES = COPYING COPYING.LIB LICENSES/GPL-2.0 LICENSES/LGPL-2.1
>   
> -TRACE_CMD_DEPENDENCIES = host-pkgconf
> +TRACE_CMD_DEPENDENCIES = host-pkgconf libtracefs libtraceevent
>   TRACE_CMD_MAKE_OPTS = prefix=/usr etcdir=/etc
>   
>   ifeq ($(BR2_PACKAGE_AUDIT),y)
> @@ -34,6 +34,8 @@ ifeq ($(BR2_sparc64),y)
>   TRACE_CMD_CFLAGS += -fPIC
>   endif
>   
> +TRACE_CMD_CFLAGS += $($(HOST_DIR)/bin/pkg-config --cflags libtracefs)
> +
>   # trace-cmd use CPPFLAGS to add some extra flags.
>   # But like for CFLAGS, $(TARGET_CPPFLAGS) contains _LARGEFILE64_SOURCE
>   # that causes build problems.

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5
  2023-01-30 23:12   ` Giulio Benetti
@ 2023-01-31 15:15     ` Maxime Chevallier via buildroot
  2023-01-31 16:05       ` Giulio Benetti
  0 siblings, 1 reply; 15+ messages in thread
From: Maxime Chevallier via buildroot @ 2023-01-31 15:15 UTC (permalink / raw)
  To: Giulio Benetti; +Cc: Pierre Floury, Thomas Petazzoni, buildroot

Hello Giulio,

On Tue, 31 Jan 2023 00:12:47 +0100
Giulio Benetti <giulio.benetti@benettiengineering.com> wrote:

> Hi Maxime,
> 
> I was trying to build trace-cmd but it hangs while calling the first
> make on building stage.

Aw ok, do you have some logs of what happens before it hangs ?

> I've tried with both make 4.3 and 4.3.91. Which make version are you
> using?

I'm using make 4.3 on my side.

Thanks for giving my patches a try :)

Maxime


_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5
  2023-01-31 15:15     ` Maxime Chevallier via buildroot
@ 2023-01-31 16:05       ` Giulio Benetti
  2023-01-31 16:07         ` Giulio Benetti
  0 siblings, 1 reply; 15+ messages in thread
From: Giulio Benetti @ 2023-01-31 16:05 UTC (permalink / raw)
  To: Maxime Chevallier; +Cc: Pierre Floury, Thomas Petazzoni, buildroot

Hi Maxime,

On 31/01/23 16:15, Maxime Chevallier via buildroot wrote:
> Hello Giulio,
> 
> On Tue, 31 Jan 2023 00:12:47 +0100
> Giulio Benetti <giulio.benetti@benettiengineering.com> wrote:
> 
>> Hi Maxime,
>>
>> I was trying to build trace-cmd but it hangs while calling the first
>> make on building stage.
> 
> Aw ok, do you have some logs of what happens before it hangs ?

Sure:
https://pastebin.com/t883KNqZ

It hangs there forever :-/

>> I've tried with both make 4.3 and 4.3.91. Which make version are you
>> using?
> 
> I'm using make 4.3 on my side.

So we're aligned

> Thanks for giving my patches a try :)

Thank you instead for providing the bump!

Kind regards
-- 
Giulio Benetti
CEO/CTO@Benetti Engineering sas

> Maxime
> 
> 
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5
  2023-01-31 16:05       ` Giulio Benetti
@ 2023-01-31 16:07         ` Giulio Benetti
  2023-01-31 16:31           ` Giulio Benetti
  0 siblings, 1 reply; 15+ messages in thread
From: Giulio Benetti @ 2023-01-31 16:07 UTC (permalink / raw)
  To: Maxime Chevallier; +Cc: Pierre Floury, Thomas Petazzoni, buildroot

On 31/01/23 17:05, Giulio Benetti wrote:
> Hi Maxime,
> 
> On 31/01/23 16:15, Maxime Chevallier via buildroot wrote:
>> Hello Giulio,
>>
>> On Tue, 31 Jan 2023 00:12:47 +0100
>> Giulio Benetti <giulio.benetti@benettiengineering.com> wrote:
>>
>>> Hi Maxime,
>>>
>>> I was trying to build trace-cmd but it hangs while calling the first
>>> make on building stage.
>>
>> Aw ok, do you have some logs of what happens before it hangs ?
> 
> Sure:
> https://pastebin.com/t883KNqZ
> 
> It hangs there forever :-/

Ah, I've also given a try with -O0 but the behaviour is the same

> 
>>> I've tried with both make 4.3 and 4.3.91. Which make version are you
>>> using?
>>
>> I'm using make 4.3 on my side.
> 
> So we're aligned
> 
>> Thanks for giving my patches a try :)
> 
> Thank you instead for providing the bump!
> 
> Kind regards

-- 
Giulio Benetti
CEO/CTO@Benetti Engineering sas
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5
  2023-01-31 16:07         ` Giulio Benetti
@ 2023-01-31 16:31           ` Giulio Benetti
  2023-01-31 16:44             ` Maxime Chevallier via buildroot
  0 siblings, 1 reply; 15+ messages in thread
From: Giulio Benetti @ 2023-01-31 16:31 UTC (permalink / raw)
  To: Maxime Chevallier; +Cc: Pierre Floury, Thomas Petazzoni, buildroot

On 31/01/23 17:07, Giulio Benetti wrote:
> On 31/01/23 17:05, Giulio Benetti wrote:
>> Hi Maxime,
>>
>> On 31/01/23 16:15, Maxime Chevallier via buildroot wrote:
>>> Hello Giulio,
>>>
>>> On Tue, 31 Jan 2023 00:12:47 +0100
>>> Giulio Benetti <giulio.benetti@benettiengineering.com> wrote:
>>>
>>>> Hi Maxime,
>>>>
>>>> I was trying to build trace-cmd but it hangs while calling the first
>>>> make on building stage.
>>>
>>> Aw ok, do you have some logs of what happens before it hangs ?
>>
>> Sure:
>> https://pastebin.com/t883KNqZ
>>
>> It hangs there forever :-/
> 
> Ah, I've also given a try with -O0 but the behaviour is the same
> 
>>
>>>> I've tried with both make 4.3 and 4.3.91. Which make version are you
>>>> using?
>>>
>>> I'm using make 4.3 on my side.
>>
>> So we're aligned
>>
>>> Thanks for giving my patches a try :)
>>
>> Thank you instead for providing the bump!
>>
>> Kind regards
> 

This is the log after 20 minutes:
https://pastebin.com/3saYFn1a

very strange. And it still hasn't finished. I let it go and see if it
builds successfully. It sounds like a make problem. All other buildings
I'm doing works correctly. Just to be sure I've also rebooted my PC.

CPU usage on the make command is around 6% only, almost 0% of Ram 
consumption.

-- 
Giulio Benetti
CEO/CTO@Benetti Engineering sas
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5
  2023-01-31 16:31           ` Giulio Benetti
@ 2023-01-31 16:44             ` Maxime Chevallier via buildroot
  2023-05-14 13:43               ` Yann E. MORIN
  0 siblings, 1 reply; 15+ messages in thread
From: Maxime Chevallier via buildroot @ 2023-01-31 16:44 UTC (permalink / raw)
  To: Giulio Benetti; +Cc: Pierre Floury, Thomas Petazzoni, buildroot

Hello Giulio,

On Tue, 31 Jan 2023 17:31:25 +0100
Giulio Benetti <giulio.benetti@benettiengineering.com> wrote:

> On 31/01/23 17:07, Giulio Benetti wrote:
> > On 31/01/23 17:05, Giulio Benetti wrote:  
> >> Hi Maxime,
> >>
> >> On 31/01/23 16:15, Maxime Chevallier via buildroot wrote:  
> >>> Hello Giulio,
> >>>
> >>> On Tue, 31 Jan 2023 00:12:47 +0100
> >>> Giulio Benetti <giulio.benetti@benettiengineering.com> wrote:
> >>>  
> >>>> Hi Maxime,
> >>>>
> >>>> I was trying to build trace-cmd but it hangs while calling the
> >>>> first make on building stage.  
> >>>
> >>> Aw ok, do you have some logs of what happens before it hangs ?  
> >>
> >> Sure:
> >> https://pastebin.com/t883KNqZ
> >>
> >> It hangs there forever :-/  
> > 
> > Ah, I've also given a try with -O0 but the behaviour is the same
> >   
> >>  
> >>>> I've tried with both make 4.3 and 4.3.91. Which make version are
> >>>> you using?  
> >>>
> >>> I'm using make 4.3 on my side.  
> >>
> >> So we're aligned
> >>  
> >>> Thanks for giving my patches a try :)  
> >>
> >> Thank you instead for providing the bump!
> >>
> >> Kind regards  
> >   
> 
> This is the log after 20 minutes:
> https://pastebin.com/3saYFn1a
> 
> very strange. And it still hasn't finished. I let it go and see if it
> builds successfully. It sounds like a make problem. All other
> buildings I'm doing works correctly. Just to be sure I've also
> rebooted my PC.

Wow that's strange indeed, I wonder if this is a parallel build problem
in trace-cmd's makefile.

I'll try to reproduce on my side, I've tested that for arm but not
arm64, I'll give it a go and see if I can spot any similar problem.

Thanks again,

Maxime

> CPU usage on the make command is around 6% only, almost 0% of Ram 
> consumption.
> 

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5
  2023-01-31 16:44             ` Maxime Chevallier via buildroot
@ 2023-05-14 13:43               ` Yann E. MORIN
  0 siblings, 0 replies; 15+ messages in thread
From: Yann E. MORIN @ 2023-05-14 13:43 UTC (permalink / raw)
  To: Maxime Chevallier
  Cc: Giulio Benetti, Pierre Floury, Thomas Petazzoni, buildroot

Maxime, All,

On 2023-01-31 17:44 +0100, Maxime Chevallier via buildroot spake thusly:
> On Tue, 31 Jan 2023 17:31:25 +0100
> Giulio Benetti <giulio.benetti@benettiengineering.com> wrote:
[--SNIP--]
> > very strange. And it still hasn't finished. I let it go and see if it
> > builds successfully. It sounds like a make problem. All other
> > buildings I'm doing works correctly. Just to be sure I've also
> > rebooted my PC.
> Wow that's strange indeed, I wonder if this is a parallel build problem
> in trace-cmd's makefile.
> I'll try to reproduce on my side, I've tested that for arm but not
> arm64, I'll give it a go and see if I can spot any similar problem.

Any status on this issue?

I'll mark the patch as Changes Requested in the meantime.

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Buildroot] [PATCH 1/4] package/libtraceevent: new package
  2023-01-30 14:46 ` [Buildroot] [PATCH 1/4] package/libtraceevent: new package Maxime Chevallier via buildroot
@ 2023-05-14 14:01   ` Yann E. MORIN
  0 siblings, 0 replies; 15+ messages in thread
From: Yann E. MORIN @ 2023-05-14 14:01 UTC (permalink / raw)
  To: Maxime Chevallier
  Cc: Pierre Floury, Giulio Benetti, Thomas Petazzoni, buildroot

Maxime, All,

On 2023-01-30 15:46 +0100, Maxime Chevallier via buildroot spake thusly:
> Introduce the libtraceevent library, that used to be bundled with the
> trace-cmd tool. This library is now used by several tools and libraries
> such as trace-cmd, libtracefs and rtla.
> 
> This package tries to install libraries in /usr/local/lib by default,
> hence the redefinition of the "prefix" variable, so that the library
> gets installed in "/usr/lib" instead.
> 
> The same applies to the pkgconfig handling of the proved Makefile, which
> installs the .pc files in the /usr/local area by default, hence the
> redefinition of the pkgconfig_dir to either the correct directory within the
> staging area, or to empty value for the target to avoid installing the .pc
> in that case.
> 
> Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
> ---
>  DEVELOPERS                             |  3 +++
>  package/Config.in                      |  1 +
>  package/libtraceevent/Config.in        |  9 +++++++
>  package/libtraceevent/libtraceevent.mk | 33 ++++++++++++++++++++++++++

Missing hash file, see:
    https://buildroot.org/downloads/manual/manual.html#adding-packages-hash

[--SNIP--]
> diff --git a/package/libtraceevent/libtraceevent.mk b/package/libtraceevent/libtraceevent.mk
> new file mode 100644
> index 0000000000..0125023508
> --- /dev/null
> +++ b/package/libtraceevent/libtraceevent.mk
> @@ -0,0 +1,33 @@
> +################################################################################
> +#
> +# libtraceevent
> +#
> +################################################################################
> +
> +LIBTRACEEVENT_VERSION = 1.7.1
> +LIBTRACEEVENT_SITE = https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git/snapshot

Are the snapshots generated by git.kernel.org reproducible? I'd prefer
in this case, that we use the git download method.

> +LIBTRACEEVENT_INSTALL_STAGING = YES
> +LIBTRACEEVENT_LICENSE = GPL-2.0, LGPL-2.1
> +LIBTRACEEVENT_LICENSE_FILES = LICENSES/GPL-2.0 LICENSES/LGPL-2.1
> +
> +define LIBTRACEEVENT_BUILD_CMDS
> +	$(TARGET_MAKE_ENV) $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)

Please, try to keep the ordering of common options the same across the
various _CMDS. For example, in _BUILD_CMDS, you have;
    $(TARGET_CONFIGURE_OPTS) -C $(@D)

while in _INSTALL_*_CMDS, you have:
    -C $(@D) $(TARGET_CONFIGURE_OPTS)

> +endef
> +
> +define LIBTRACEEVENT_INSTALL_STAGING_CMDS
> +	$(TARGET_MAKE_ENV) $(MAKE1) -C $(@D) $(TARGET_CONFIGURE_OPTS) \
> +	DESTDIR=$(STAGING_DIR) \
> +	pkgconfig_dir="/usr/lib/pkgconfig" \
> +	prefix="/usr" \
> +	install

Addiotnally indent continuation lines, i.e.:

    \t  $(TARGET_MAKE_ENV) $(MAKE1) -C $(@D) \
    \t  \t  $(TARGET_CONFIGURE_OPTS) \
    \t  \t  DESTDIR=$(STAGING_DIR) \
    \t  \t  pkgconfig_dir="/usr/lib/pkgconfig" \
    \t  \t  prefix="/usr" \
    \t  \t  install

Why do we need MAKE1 in the install steps, and not in the build step?

Also, don't we need to also pass prefix=/usr at build time? Hmm, the
Makefile gnerates the .pc file at install time, not at build time (this
is not clean, but explains why we don;t need prefix at build time,
maybe?).

Regards,
Yann E. MORIN.

> +endef
> +
> +define LIBTRACEEVENT_INSTALL_TARGET_CMDS
> +	$(TARGET_MAKE_ENV) $(MAKE1) -C $(@D) $(TARGET_CONFIGURE_OPTS) \
> +	DESTDIR=$(TARGET_DIR) \
> +	pkgconfig_dir="" \
> +	prefix="/usr" \
> +	install
> +endef
> +
> +$(eval $(generic-package))
> -- 
> 2.39.1
> 
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Buildroot] [PATCH 2/4] package/libtracefs: new package
  2023-01-30 14:46 ` [Buildroot] [PATCH 2/4] package/libtracefs: " Maxime Chevallier via buildroot
@ 2023-05-14 14:02   ` Yann E. MORIN
  0 siblings, 0 replies; 15+ messages in thread
From: Yann E. MORIN @ 2023-05-14 14:02 UTC (permalink / raw)
  To: Maxime Chevallier
  Cc: Pierre Floury, Giulio Benetti, Thomas Petazzoni, buildroot

Maxime, All,

On 2023-01-30 15:46 +0100, Maxime Chevallier via buildroot spake thusly:
> Introduce the libtracefs library, that used to be bundled with the
> trace-cmd tool. This library is now used by several tools and libraries
> such as trace-cmd and rtla, and is used as an interface to the ftrace
> kernel subsystem through tracefs.
> 
> This package tries to install libraries in /usr/local/lib by default,
> hence the redefinition of the "prefix" variable, so that the library
> gets installed in "/usr/lib" instead.
> 
> The same applies to the pkgconfig handling of the proved Makefile, which
> installs the .pc files in the /usr/local area by default, hence the
> redefinition of the pkgconfig_dir to either the correct directory within the
> staging area, or to empty value for the target to avoid installing the .pc
> in that case.
> 
> Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
> ---
>  DEVELOPERS                       |  1 +
>  package/Config.in                |  1 +
>  package/libtracefs/Config.in     |  6 ++++++
>  package/libtracefs/libtracefs.mk | 35 ++++++++++++++++++++++++++++++++

Missing hash file.

Otherwise, I have the same comments and questions as for libtraceevent.

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 15+ messages in thread

* Re: [Buildroot] [PATCH 3/4] package/linux-tools: add rtla
  2023-01-30 14:46 ` [Buildroot] [PATCH 3/4] package/linux-tools: add rtla Maxime Chevallier via buildroot
@ 2023-05-14 14:06   ` Yann E. MORIN
  0 siblings, 0 replies; 15+ messages in thread
From: Yann E. MORIN @ 2023-05-14 14:06 UTC (permalink / raw)
  To: Maxime Chevallier
  Cc: Pierre Floury, Giulio Benetti, Thomas Petazzoni, buildroot

Maxime, All,

On 2023-01-30 15:46 +0100, Maxime Chevallier via buildroot spake thusly:
> The RealTime Linux Analysis tool includes a set of commands that relies
> on the osnoise and timerlat tracers from the ftrace kernel subsystem,
> allowing to analyze the lantency sources coming from the hardware and
> the kernel itself.
> 
> This tool was introduced in v5.17, and relies on libtracefs and
> libtraceevent, although libtraceevent itself is already a dependency for
> libtracefs.
> 
> Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
> ---
[--SNIP--]
> diff --git a/package/linux-tools/linux-tool-rtla.mk.in b/package/linux-tools/linux-tool-rtla.mk.in
> new file mode 100644
> index 0000000000..a736e3b785
> --- /dev/null
> +++ b/package/linux-tools/linux-tool-rtla.mk.in
> @@ -0,0 +1,32 @@
> +################################################################################
> +#
> +# rtla
> +#
> +################################################################################
> +
> +LINUX_TOOLS += rtla
> +
> +RTLA_DEPENDENCIES = host-pkgconf libtracefs
> +RTLA_MAKE_OPTS = $(LINUX_MAKE_FLAGS) \
> +	CC=$(TARGET_CC) \
> +	LDFLAGS="$(TARGET_LDFLAGS)" \
> +	PKG_CONFIG_PATH=$(STAGING_DIR)/usr/lib/pkgconfig

For multi-line assignment, start first assignment on its own line as
well:

    RTLA_MAKE_OPTS = \
        $(LINUX_MAKE_FLAGS) \
        CC=$(TARGET_CC) \
        LDFLAGS="$(TARGET_LDFLAGS)" \
        PKG_CONFIG_PATH=$(STAGING_DIR)/usr/lib/pkgconfig

> +define RTLA_BUILD_CMDS
> +	$(Q)if ! grep install $(LINUX_DIR)/tools/tracing/rtla/Makefile >/dev/null 2>&1 ; then \
> +		echo "Your kernel version is too old and does not implement the rtla tool." ; \
> +		echo "At least kernel 5.17 must be used." ; \
> +		exit 1 ; \
> +	fi
> +
> +	$(TARGET_MAKE_ENV) \
> +	$(MAKE) $(RTLA_MAKE_OPTS) \
> +	-C $(LINUX_DIR)/tools/tracing rtla

Similarly to libtraceevent and libtracefs, indent the continuation
lines. Also, keep coommon arguments in the same order for all _CMDS.

I've marked the whole series as Changes Requested. Sorry for the long
delay on providing that review... :-(

Regards,
Yann E. MORIN.

> +endef
> +
> +define RTLA_INSTALL_TARGET_CMDS
> +	$(TARGET_MAKE_ENV) $(MAKE) -C $(LINUX_DIR)/tools/tracing \
> +	$(RTLA_MAKE_OPTS) \
> +	DESTDIR=$(TARGET_DIR) \
> +	rtla_install
> +endef
> -- 
> 2.39.1
> 
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2023-05-14 14:07 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-30 14:46 [Buildroot] [PATCH 0/4] introduce the rtla package and its dependencies Maxime Chevallier via buildroot
2023-01-30 14:46 ` [Buildroot] [PATCH 1/4] package/libtraceevent: new package Maxime Chevallier via buildroot
2023-05-14 14:01   ` Yann E. MORIN
2023-01-30 14:46 ` [Buildroot] [PATCH 2/4] package/libtracefs: " Maxime Chevallier via buildroot
2023-05-14 14:02   ` Yann E. MORIN
2023-01-30 14:46 ` [Buildroot] [PATCH 3/4] package/linux-tools: add rtla Maxime Chevallier via buildroot
2023-05-14 14:06   ` Yann E. MORIN
2023-01-30 14:46 ` [Buildroot] [PATCH 4/4] package/trace-cmd: bump to 3.1.5 Maxime Chevallier via buildroot
2023-01-30 23:12   ` Giulio Benetti
2023-01-31 15:15     ` Maxime Chevallier via buildroot
2023-01-31 16:05       ` Giulio Benetti
2023-01-31 16:07         ` Giulio Benetti
2023-01-31 16:31           ` Giulio Benetti
2023-01-31 16:44             ` Maxime Chevallier via buildroot
2023-05-14 13:43               ` Yann E. MORIN

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.