All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] perf: fix packaging of scripting modules
@ 2018-03-02  4:44 Anuj Mittal
  2018-03-02  4:44 ` [PATCH 2/2] perf: enable support for libaudit Anuj Mittal
  2018-03-15  4:02 ` ✗ patchtest: failure for "perf: fix packaging of scripti..." and 1 more (rev2) Patchwork
  0 siblings, 2 replies; 5+ messages in thread
From: Anuj Mittal @ 2018-03-02  4:44 UTC (permalink / raw)
  To: openembedded-core

Make sure that python and perl scripts are packaged in the correct rpm.

Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
---
 meta/recipes-kernel/perf/perf.bb | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/meta/recipes-kernel/perf/perf.bb b/meta/recipes-kernel/perf/perf.bb
index 1bad6f4..d798492 100644
--- a/meta/recipes-kernel/perf/perf.bb
+++ b/meta/recipes-kernel/perf/perf.bb
@@ -223,13 +223,14 @@ RDEPENDS_${PN}-tests =+ "python"
 RSUGGESTS_SCRIPTING = "${@bb.utils.contains('PACKAGECONFIG', 'scripting', '${PN}-perl ${PN}-python', '',d)}"
 RSUGGESTS_${PN} += "${PN}-archive ${PN}-tests ${RSUGGESTS_SCRIPTING}"
 
-#FILES_${PN} += "${libexecdir}/perf-core ${exec_prefix}/libexec/perf-core /usr/lib64/traceevent ${libdir}/traceevent"
 FILES_${PN} += "${libexecdir}/perf-core ${exec_prefix}/libexec/perf-core ${libdir}/traceevent"
 FILES_${PN}-archive = "${libdir}/perf/perf-core/perf-archive"
 FILES_${PN}-tests = "${libdir}/perf/perf-core/tests ${libexecdir}/perf-core/tests"
-FILES_${PN}-python = "${libdir}/perf/perf-core/scripts/python ${PYTHON_SITEPACKAGES_DIR}"
-FILES_${PN}-python += "${libexecdir}/perf-core/scripts/python/*"
-FILES_${PN}-perl = "${libdir}/perf/perf-core/scripts/perl"
+FILES_${PN}-python = " \
+                       ${PYTHON_SITEPACKAGES_DIR} \
+                       ${libexecdir}/perf-core/scripts/python \
+                       "
+FILES_${PN}-perl = "${libexecdir}/perf-core/scripts/perl"
 
 
 INHIBIT_PACKAGE_DEBUG_SPLIT="1"
-- 
2.7.4



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

* [PATCH 2/2] perf: enable support for libaudit
  2018-03-02  4:44 [PATCH 1/2] perf: fix packaging of scripting modules Anuj Mittal
@ 2018-03-02  4:44 ` Anuj Mittal
  2018-03-14 16:54   ` Burton, Ross
  2018-03-15  3:41   ` [PATCH v2] " Anuj Mittal
  2018-03-15  4:02 ` ✗ patchtest: failure for "perf: fix packaging of scripti..." and 1 more (rev2) Patchwork
  1 sibling, 2 replies; 5+ messages in thread
From: Anuj Mittal @ 2018-03-02  4:44 UTC (permalink / raw)
  To: openembedded-core

perf needs audit-python to be able to show syscall names and for
'perf trace' to work.

Enable dependency on audit-python if present in PACKAGECONFIG. It's
disabled by default since audit as of now is in meta-selinux.

Fixes [YOCTO #3343]
Fixes [YOCTO #3358]

Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
---
 meta/recipes-kernel/perf/perf.bb | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/meta/recipes-kernel/perf/perf.bb b/meta/recipes-kernel/perf/perf.bb
index d798492..abd9290 100644
--- a/meta/recipes-kernel/perf/perf.bb
+++ b/meta/recipes-kernel/perf/perf.bb
@@ -12,7 +12,7 @@ LICENSE = "GPLv2"
 PR = "r9"
 
 PACKAGECONFIG ??= "scripting tui libunwind"
-PACKAGECONFIG[scripting] = ",NO_LIBPERL=1 NO_LIBPYTHON=1,perl python"
+PACKAGECONFIG[scripting] = ",NO_LIBPERL=1,perl python"
 # gui support was added with kernel 3.6.35
 # since 3.10 libnewt was replaced by slang
 # to cover a wide range of kernel we add both dependencies
@@ -22,6 +22,10 @@ PACKAGECONFIG[libnuma] = ",NO_LIBNUMA=1"
 PACKAGECONFIG[systemtap] = ",NO_SDT=1,systemtap"
 PACKAGECONFIG[jvmti] = ",NO_JVMTI=1"
 
+# libaudit support needs python to be present
+PACKAGECONFIG[audit] = ",NO_LIBAUDIT=1,audit python"
+PACKAGECONFIG_CONFARGS += "${@bb.utils.contains_any('PACKAGECONFIG', 'scripting audit', '', 'NO_LIBPYTHON=1', d)}"
+
 DEPENDS = " \
     virtual/${MLPREFIX}libc \
     ${MLPREFIX}elfutils \
@@ -38,7 +42,7 @@ PROVIDES = "virtual/perf"
 inherit linux-kernel-base kernel-arch
 
 # needed for building the tools/perf Python bindings
-inherit ${@bb.utils.contains('PACKAGECONFIG', 'scripting', 'pythonnative', '', d)}
+inherit ${@bb.utils.contains_any('PACKAGECONFIG', 'scripting audit', 'pythonnative', '', d)}
 inherit python-dir
 export PYTHON_SITEPACKAGES_DIR
 
@@ -111,7 +115,7 @@ do_install() {
 	unset CFLAGS
 	oe_runmake install
 	# we are checking for this make target to be compatible with older perf versions
-	if ${@bb.utils.contains('PACKAGECONFIG', 'scripting', 'true', 'false', d)} && grep -q install-python_ext ${S}/tools/perf/Makefile*; then
+	if ${@bb.utils.contains_any('PACKAGECONFIG', 'scripting audit', 'true', 'false', d)} && grep -q install-python_ext ${S}/tools/perf/Makefile*; then
 		oe_runmake DESTDIR=${D} install-python_ext
 	fi
 }
@@ -216,7 +220,7 @@ PACKAGES =+ "${PN}-archive ${PN}-tests ${PN}-perl ${PN}-python"
 RDEPENDS_${PN} += "elfutils bash"
 RDEPENDS_${PN}-doc += "man"
 RDEPENDS_${PN}-archive =+ "bash"
-RDEPENDS_${PN}-python =+ "bash python python-modules"
+RDEPENDS_${PN}-python =+ "bash python python-modules ${@bb.utils.contains('PACKAGECONFIG', 'audit', 'audit-python', '', d)}"
 RDEPENDS_${PN}-perl =+ "bash perl perl-modules"
 RDEPENDS_${PN}-tests =+ "python"
 
-- 
2.7.4



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

* Re: [PATCH 2/2] perf: enable support for libaudit
  2018-03-02  4:44 ` [PATCH 2/2] perf: enable support for libaudit Anuj Mittal
@ 2018-03-14 16:54   ` Burton, Ross
  2018-03-15  3:41   ` [PATCH v2] " Anuj Mittal
  1 sibling, 0 replies; 5+ messages in thread
From: Burton, Ross @ 2018-03-14 16:54 UTC (permalink / raw)
  To: Anuj Mittal; +Cc: OE-core

[-- Attachment #1: Type: text/plain, Size: 963 bytes --]

On 2 March 2018 at 04:44, Anuj Mittal <anuj.mittal@intel.com> wrote:

>  # gui support was added with kernel 3.6.35
>  # since 3.10 libnewt was replaced by slang
>  # to cover a wide range of kernel we add both dependencies
> @@ -22,6 +22,10 @@ PACKAGECONFIG[libnuma] = ",NO_LIBNUMA=1"
>  PACKAGECONFIG[systemtap] = ",NO_SDT=1,systemtap"
>  PACKAGECONFIG[jvmti] = ",NO_JVMTI=1"
>
> +# libaudit support needs python to be present
> +PACKAGECONFIG[audit] = ",NO_LIBAUDIT=1,audit python"
>

All you need in this patch is:

+# audit needs scripting to be enabled.
+PACKAGECONFIG[audit] = ",NO_LIBAUDIT=1,audit"

The convoluted logic will only get more complicated over time, when a
comment saying "if you want audit to work, turn on scripting" is sufficient.

+PACKAGECONFIG_CONFARGS += "${@bb.utils.contains_any('PACKAGECONFIG',
> 'scripting audit', '', 'NO_LIBPYTHON=1', d)}


PACKAGECONFG_CONFAGS isn't for assigning in a recipe.

Ross

[-- Attachment #2: Type: text/html, Size: 1739 bytes --]

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

* [PATCH v2] perf: enable support for libaudit
  2018-03-02  4:44 ` [PATCH 2/2] perf: enable support for libaudit Anuj Mittal
  2018-03-14 16:54   ` Burton, Ross
@ 2018-03-15  3:41   ` Anuj Mittal
  1 sibling, 0 replies; 5+ messages in thread
From: Anuj Mittal @ 2018-03-15  3:41 UTC (permalink / raw)
  To: openembedded-core

perf needs audit-python to be able to show syscall names and for
'perf trace' to work.

Enable dependency on audit-python if present in PACKAGECONFIG. It's
disabled by default since audit as of now is in meta-selinux.

Fixes [YOCTO #3343]
Fixes [YOCTO #3358]

Signed-off-by: Anuj Mittal <anuj.mittal@intel.com>
---
 meta/recipes-kernel/perf/perf.bb | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/meta/recipes-kernel/perf/perf.bb b/meta/recipes-kernel/perf/perf.bb
index d798492..872b5f0 100644
--- a/meta/recipes-kernel/perf/perf.bb
+++ b/meta/recipes-kernel/perf/perf.bb
@@ -22,6 +22,9 @@ PACKAGECONFIG[libnuma] = ",NO_LIBNUMA=1"
 PACKAGECONFIG[systemtap] = ",NO_SDT=1,systemtap"
 PACKAGECONFIG[jvmti] = ",NO_JVMTI=1"
 
+# libaudit support would need scripting to be enabled
+PACKAGECONFIG[audit] = ",NO_LIBAUDIT=1,audit"
+
 DEPENDS = " \
     virtual/${MLPREFIX}libc \
     ${MLPREFIX}elfutils \
@@ -216,7 +219,7 @@ PACKAGES =+ "${PN}-archive ${PN}-tests ${PN}-perl ${PN}-python"
 RDEPENDS_${PN} += "elfutils bash"
 RDEPENDS_${PN}-doc += "man"
 RDEPENDS_${PN}-archive =+ "bash"
-RDEPENDS_${PN}-python =+ "bash python python-modules"
+RDEPENDS_${PN}-python =+ "bash python python-modules ${@bb.utils.contains('PACKAGECONFIG', 'audit', 'audit-python', '', d)}"
 RDEPENDS_${PN}-perl =+ "bash perl perl-modules"
 RDEPENDS_${PN}-tests =+ "python"
 
-- 
2.7.4



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

* ✗ patchtest: failure for "perf: fix packaging of scripti..." and 1 more (rev2)
  2018-03-02  4:44 [PATCH 1/2] perf: fix packaging of scripting modules Anuj Mittal
  2018-03-02  4:44 ` [PATCH 2/2] perf: enable support for libaudit Anuj Mittal
@ 2018-03-15  4:02 ` Patchwork
  1 sibling, 0 replies; 5+ messages in thread
From: Patchwork @ 2018-03-15  4:02 UTC (permalink / raw)
  To: Anuj Mittal; +Cc: openembedded-core

== Series Details ==

Series: "perf: fix packaging of scripti..." and 1 more (rev2)
Revision: 2
URL   : https://patchwork.openembedded.org/series/11183/
State : failure

== Summary ==


Thank you for submitting this patch series to OpenEmbedded Core. This is
an automated response. Several tests have been executed on the proposed
series by patchtest resulting in the following failures:



* Issue             Series does not apply on top of target branch [test_series_merge_on_head] 
  Suggested fix    Rebase your series on top of targeted branch
  Targeted branch  master (currently at 073d8d0010)



If you believe any of these test results are incorrect, please reply to the
mailing list (openembedded-core@lists.openembedded.org) raising your concerns.
Otherwise we would appreciate you correcting the issues and submitting a new
version of the patchset if applicable. Please ensure you add/increment the
version number when sending the new version (i.e. [PATCH] -> [PATCH v2] ->
[PATCH v3] -> ...).

---
Guidelines:     https://www.openembedded.org/wiki/Commit_Patch_Message_Guidelines
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest
Test suite:     http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe



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

end of thread, other threads:[~2018-03-15  4:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-02  4:44 [PATCH 1/2] perf: fix packaging of scripting modules Anuj Mittal
2018-03-02  4:44 ` [PATCH 2/2] perf: enable support for libaudit Anuj Mittal
2018-03-14 16:54   ` Burton, Ross
2018-03-15  3:41   ` [PATCH v2] " Anuj Mittal
2018-03-15  4:02 ` ✗ patchtest: failure for "perf: fix packaging of scripti..." and 1 more (rev2) Patchwork

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.