Skip to contentSkip to conversation

gator: Add new package

PATCH Superseded Clément Péron 2 participants 5 messages May 1, 2021 – Jun 9, 2021

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gator: Add new package

To communicate with the target device, Streamline requires the gator daemon, gatord, to be running on the device.

---

Changes since v1:
- Bump to 7.6.0
- Add upstream-status and signoff patch
- Add Kernel config requirement to summary
- Add Homepage
- Add all Licenses and checksums

 .../gator/0001-gator-don-t-strip-debug.patch  | 29 ++++++++++++++++++
 .../recipes-devtools/gator/gator_7.6.0.bb     | 30 +++++++++++++++++++
 2 files changed, 59 insertions(+)
 create mode 100644 meta-arm/recipes-devtools/gator/gator/0001-gator-don-t-strip-debug.patch
 create mode 100644 meta-arm/recipes-devtools/gator/gator_7.6.0.bb
meta-arm/recipes-devtools/gator/gator/0001-gator-don-t-strip-debug.patch new file +29 -0
new file mode 100644
index 000000000000..dc30809b58f8
@@ -0,0 +1,29 @@
+From 5b51a78186f0ea7474902d8ed8f2c96d8be91c33 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Cl=C3=A9ment=20P=C3=A9ron?= <[email protected]>
+Date: Fri, 16 Apr 2021 15:27:16 +0200
+Subject: [PATCH] gator: don't strip debug
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Upstream-Status: Submitted [https://github.com/ARM-software/gator/pull/26]
+Signed-off-by: Clément Péron <[email protected]>
+---
+ daemon/Makefile | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/daemon/Makefile b/daemon/Makefile
+index ba5f29cfeb10..6807948310f9 100644
+--- a/daemon/Makefile
++++ b/daemon/Makefile
+@@ -26,8 +26,6 @@ ifeq ($(shell expr `$(CXX) -dumpversion | cut -f1 -d.` \>= 5),1)
+ 	CXXFLAGS += -fno-sized-deallocation
+ endif
+ 
+-# -s strips the binary of debug info
+-LDFLAGS     += -s
+ LDLIBS      += -lrt -lm -pthread
+ TARGET      := $(OBJ_DIR)gatord
+ ESCAPE_EXE  := $(OBJ_DIR)escape/escape
+-- 
+2.25.1
meta-arm/recipes-devtools/gator/gator_7.6.0.bb new file +30 -0
new file mode 100644
index 000000000000..75f144b209aa
@@ -0,0 +1,30 @@
+SUMMARY = "DS-5 Streamine Gator daemon"
+DESCRIPTION = "Target-side daemon gathering data for ARM Streamline \
+Performance Analyzer. Note that Gator uses the Linux Perf API for \
+most of its data collection. Check that your Kernel follow the \
+configuration requirement specified here: \
+https://github.com/ARM-software/gator#kernel-configuration"
+HOMEPAGE = "https://github.com/ARM-software/gator"
+
+LICENSE = "GPLv2 & LGPLv2.1+ & Apache-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+		    file://libsensors/COPYING.LGPL;md5=4fbd65380cdd255951079008b364516c \
+		    file://mxml/LICENSE;md5=86d3f3a95c324c9479bd8986968f4327 \
+		    file://k/perf_event.h;endline=14;md5=e548bf30a60b2ed11ef2dcf7bfdac230 \
+		   "
+
+SRCREV = "6088d3533146d7b7c9700b8e396292053240b25f"
+SRC_URI = "git://github.com/ARM-software/gator.git;protocol=http;branch=master \
+	   file://0001-gator-don-t-strip-debug.patch;patchdir=.. \
+          "
+
+S = "${WORKDIR}/git/daemon"
+
+EXTRA_OEMAKE = "'CFLAGS=${CFLAGS} ${TARGET_CC_ARCH} -D_DEFAULT_SOURCE -DETCDIR=\"${sysconfdir}\"' \
+		 'LDFLAGS=${LDFLAGS} ${TARGET_CC_ARCH}' 'CROSS_COMPILE=${TARGET_PREFIX}' \
+		 'CXXFLAGS=${CXXFLAGS} ${TARGET_CC_ARCH} -fno-rtti' CC='${CC}' CXX='${CXX}'"
+
+do_install() {
+        install -d ${D}${sbindir}
+        install -m 0755 ${S}/gatord ${D}${sbindir}/gatord
+}
Signature · 1 line
2.25.1
#1 lore raw
Quoted 1 line · Clément Péron

+SUMMARY = "DS-5 Streamine Gator daemon"

Typo in "Streamline"

meta-arm/recipes-devtools/gator/gator_7.6.0.bb line 6

Quoted 5 lines
meta-arm/recipes-devtools/gator/gator_7.6.0.bb new file +5 -0
+DESCRIPTION = "Target-side daemon gathering data for ARM Streamline \
+Performance Analyzer. Note that Gator uses the Linux Perf API for \
+most of its data collection. Check that your Kernel follow the \
+configuration requirement specified here: \
+https://github.com/ARM-software/gator#kernel-configuration"

Far too verbose a DESCRIPTION, the first sentence is sufficient. You can put the kernel configuration in a comment in the recipe.

Quoted 3 lines

SRC_URI = "git://github.com/ARM-software/gator.git;protocol=http;branch=master \
. file://0001-gator-don-t-strip-debug.patch;patchdir=.. \
. "

There's a mix of spaces and tabs on the line with the patch, just spaces please.

Quoted 1 line

EXTRA_OEMAKE = "'CFLAGS=${CFLAGS} ${TARGET_CC_ARCH} -D_DEFAULT_SOURCE -DETCDIR=\"${sysconfdir}\"' \

Also pass V=1 so the build log is verbose.

I'm guessing this doesn't work on x86-64 hosts? If so add COMPATIBLE_HOST = "aarch64.*-linux" to make that explicit (as otherwise a world build with meta-arm present will try to build it).

As this is just the daemon, should the recipe be gator-daemon? Or do you plan to add the rest of the tools in the future?

Ross

#2 lore raw

Good news: that patch is now merged upstream.

Do you plan on sending a revised gator recipe?

Ross

Quoted 33 lines · Ross Burton
Quoted 1 line · Clément Péron

+SUMMARY = "DS-5 Streamine Gator daemon"

Typo in "Streamline"

meta-arm/recipes-devtools/gator/gator_7.6.0.bb line 6

Quoted 5 lines
meta-arm/recipes-devtools/gator/gator_7.6.0.bb new file +5 -0
+DESCRIPTION = "Target-side daemon gathering data for ARM Streamline \
+Performance Analyzer. Note that Gator uses the Linux Perf API for \
+most of its data collection. Check that your Kernel follow the \
+configuration requirement specified here: \
+https://github.com/ARM-software/gator#kernel-configuration"

Far too verbose a DESCRIPTION, the first sentence is sufficient. You can put the kernel configuration in a comment in the recipe.

Quoted 3 lines

SRC_URI = "git://github.com/ARM-software/gator.git;protocol=http;branch=master \
. file://0001-gator-don-t-strip-debug.patch;patchdir=.. \
. "

There's a mix of spaces and tabs on the line with the patch, just spaces please.

Quoted 1 line

EXTRA_OEMAKE = "'CFLAGS=${CFLAGS} ${TARGET_CC_ARCH} -D_DEFAULT_SOURCE -DETCDIR=\"${sysconfdir}\"' \

Also pass V=1 so the build log is verbose.

I'm guessing this doesn't work on x86-64 hosts? If so add COMPATIBLE_HOST = "aarch64.*-linux" to make that explicit (as otherwise a world build with meta-arm present will try to build it).

As this is just the daemon, should the recipe be gator-daemon? Or do you plan to add the rest of the tools in the future?

Ross

#3 lore raw

Hi Ross,

I will send a v2.

Quoted 39 lines · Ross Burton

Good news: that patch is now merged upstream.

Do you plan on sending a revised gator recipe?

Ross

Quoted 31 lines · Ross Burton
Quoted 1 line · Clément Péron

+SUMMARY = "DS-5 Streamine Gator daemon"

Typo in "Streamline"

meta-arm/recipes-devtools/gator/gator_7.6.0.bb line 6

Quoted 5 lines
meta-arm/recipes-devtools/gator/gator_7.6.0.bb new file +5 -0
+DESCRIPTION = "Target-side daemon gathering data for ARM Streamline \
+Performance Analyzer. Note that Gator uses the Linux Perf API for \
+most of its data collection. Check that your Kernel follow the \
+configuration requirement specified here: \
+https://github.com/ARM-software/gator#kernel-configuration"

Far too verbose a DESCRIPTION, the first sentence is sufficient. You can put the kernel configuration in a comment in the recipe.

Quoted 3 lines

SRC_URI = "git://github.com/ARM-software/gator.git;protocol=http;branch=master \
. file://0001-gator-don-t-strip-debug.patch;patchdir=.. \
. "

There's a mix of spaces and tabs on the line with the patch, just spaces please.

Quoted 1 line

EXTRA_OEMAKE = "'CFLAGS=${CFLAGS} ${TARGET_CC_ARCH} -D_DEFAULT_SOURCE -DETCDIR=\"${sysconfdir}\"' \

Also pass V=1 so the build log is verbose.

I'm guessing this doesn't work on x86-64 hosts? If so add COMPATIBLE_HOST = "aarch64.*-linux" to make that explicit (as otherwise a world build with meta-arm present will try to build it).

As this is just the daemon, should the recipe be gator-daemon? Or do you plan to add the rest of the tools in the future?

I don't plan for the moment to add the rest of the tools but maybe someone will. For the package name up to you, what do you prefer?

Clement

Quoted 2 lines
Quoted 2 lines

Ross

#4 lore raw
Quoted 2 lines · Clément Péron

I don't plan for the moment to add the rest of the tools but maybe someone will. For the package name up to you, what do you prefer?

Maybe use gator-daemon so that if the rest of the suite is built in the future we don't need to rename anything.

Ross