Skip to contentSkip to conversation

pcp: Added a new recipe which provides dstat command.

PATCH New Lei Maohui 1 participant 1 message Jan 11, 2022

lore
Share & tools
lore

Lei Maohui

author
#0 lore raw

PATCH v2 1/1 pcp: Added a new recipe which provides dstat command.

Performance Co-Pilot is a system performance analysis toolkit
- Collect performance metrics from your systems efficiently.
- Analyze systems' performance metrics in real-time or using historical data.
- Extend the collected performance metrics in a simple way.

---
 meta-oe/recipes-support/pcp/pcp-native_5.3.5.bb    |  49 +++++
 meta-oe/recipes-support/pcp/pcp.inc                |  32 +++
 ...1-Remove-unsuitble-part-for-cross-compile.patch |  45 +++++
 meta-oe/recipes-support/pcp/pcp/config.linux       |  13 ++
 meta-oe/recipes-support/pcp/pcp_5.3.5.bb           | 219 +++++++++++++++++++++
 5 files changed, 358 insertions(+)
 create mode 100644 meta-oe/recipes-support/pcp/pcp-native_5.3.5.bb
 create mode 100644 meta-oe/recipes-support/pcp/pcp.inc
 create mode 100644 meta-oe/recipes-support/pcp/pcp/0001-Remove-unsuitble-part-for-cross-compile.patch
 create mode 100644 meta-oe/recipes-support/pcp/pcp/config.linux
 create mode 100644 meta-oe/recipes-support/pcp/pcp_5.3.5.bb
meta-oe/recipes-support/pcp/pcp-native_5.3.5.bb new file +49 -0
new file mode 100644
index 0000000..029a475
@@ -0,0 +1,49 @@
+require pcp.inc
+inherit python3native native 
+#autotools-brokensep 
+DEPENDS = "python3-native python3-setuptools-native flex-native bison-native"
+
+export PCP_DIR = "${D}"
+export PCP_TMP_DIR = "${D}/tmp"
+export PCP_BIN_DIR = "${D}/usr/bin"
+
+B = "${S}"
+
+do_configure:prepend() {
+    export SED=${TMPDIR}/hosttools/sed
+    export AR=${TMPDIR}/hosttools/ar
+#    export PYTHON=python3
+    
+    rm -rf ${S}/include/pcp/configsz.h
+    rm -rf ${S}/include/pcp/platformsz.h
+
+}
+do_compile:prepend() {
+    sed -i -e "s,#undef HAVE_64BIT_LONG,,g" \
+           -e "s,#undef HAVE_64BIT_PTR,,g" \
+           -e "s,#undef PM_SIZEOF_SUSECONDS_T,,g" \
+           -e "s,#undef PM_SIZEOF_TIME_T,,g" \
+           ${S}/src/include/pcp/config.h.in
+
+    export AR=${TMPDIR}/hosttools/ar
+#    export PYTHON=python3
+}
+
+do_compile() {
+        oe_runmake default_pcp
+}
+
+do_install () {
+    oe_runmake install \
+    PCP_ETC_DIR=${D}/${sysconfdir} \
+    PCP_SYSCONF_DIR=${D}/${sysconfdir} \
+    PCP_VAR_DIR=${D}/${localstatedir} \
+    PCP_SHARE_DIR=${D}/${datadir} \
+    PCP_BIN_DIR=${D}/${bindir} \
+    PCP_BINADM_DIR=${D}/${libexecdir}/pcp/bin \
+    PCP_LIBADM_DIR=${D}/${libdir} \
+    PCP_LIB_DIR=${D}/${libdir} \
+    PCP_MAN_DIR=${D}/${mandir} \
+    PCP_DOC_DIR=${D}/${docdir} 
+}
+
meta-oe/recipes-support/pcp/pcp.inc new file +32 -0
new file mode 100644
index 0000000..f6f111b
@@ -0,0 +1,32 @@
+SUMMARY = "System-level performance monitoring and performance management"
+HOMEPAGE = "http://www.pcp.io"
+SECTION =  "Applications/System"
+
+LICENSE = "GPLv2+ & LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=37ab75b580d5aad4ada04260efa3702f \
+                    "
+COMPATIBLE_HOST:libc-musl = "null"
+
+SRC_URI = "https://performancecopilot.jfrog.io/artifactory/pcp-source-release/pcp-5.3.5.src.tar.gz \
+	   file://config.linux \
+	   "
+
+SRC_URI[sha256sum] = "589a610f753a49af6d2015cede87e9d469bd07880ebef26fe1607b6ded375e97"
+
+inherit distutils3-base pkgconfig autotools
+
+B = "${S}"
+
+# Specify any options you want to pass to the configure script using EXTRA_OECONF:
+CACHED_CONFIGUREVARS = "PACKAGE_DISTRIBUTION=arch"
+EXTRA_OECONF:append = " --with-dstat-symlink=yes --with-infiniband=no \
+                --with-pmdapodman=no --with-python=no --with-python3=yes --with-perl=no \
+		--with-pmdabcc=no --with-pmdajson=no  --with-perfevent=no \
+		--with-pmdabcc=yes \
+		--with-rundir=${localstatedir}/run \
+                --with-sysconfigdir=${sysconfdir} \
+                --with-logdir=${localstatedir}/log \
+                --with-docdir=${docdir} \
+                "
+
+
meta-oe/recipes-support/pcp/pcp/0001-Remove-unsuitble-part-for-cross-compile.patch new file +45 -0

45 lines not on this page · raw message

meta-oe/recipes-support/pcp/pcp/config.linux new file +13 -0
new file mode 100644
index 0000000..191f87a
@@ -0,0 +1,13 @@
+sizeof_int=4
+sizeof_long=4
+sizeof_pointer=8
+sizeof_suseconds_t=8
+sizeof_time_t=8
+bit_field_scheme=2100
+enable_python3='yes'
+enable_python3='true'
+have_python_OrderedDict="true"
+have_python=python3
+printf_p_prefix=0x
+printf_fmt_int64=I64d
+strtoint64=strtoll
meta-oe/recipes-support/pcp/pcp_5.3.5.bb new file +219 -0

219 lines not on this page · raw message

Signature · 1 line
1.8.3.1