All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-security][PATCH] scap-security-guide: disable ptest by default
@ 2025-04-18  5:17 Yi Zhao
  2025-04-18 10:42 ` [yocto-patches] " Gyorgy Sarvari
  0 siblings, 1 reply; 4+ messages in thread
From: Yi Zhao @ 2025-04-18  5:17 UTC (permalink / raw)
  To: yocto-patches

Enabling ptest will significantly increase build time. Additionally,
since the ptest distro_feature is enabled by default in poky distro,
build time can be very long, which is annoying.

On my build server:
Enable ptest:
$ time build scap-security-guide
real    266m41.257s
user    1m16.895s
sys     0m1.553s

Disable ptest:
$ time build scap-security-guide
real    1m29.228s
user    0m4.604s
sys     0m0.175s

Add a switch SSG_PTEST_ENABLED and set it to 0 to disable ptest by
default.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
---
 .../scap-security-guide/scap-security-guide_0.1.76.bb         | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/recipes-compliance/scap-security-guide/scap-security-guide_0.1.76.bb b/recipes-compliance/scap-security-guide/scap-security-guide_0.1.76.bb
index 73bd576..168af33 100644
--- a/recipes-compliance/scap-security-guide/scap-security-guide_0.1.76.bb
+++ b/recipes-compliance/scap-security-guide/scap-security-guide_0.1.76.bb
@@ -18,7 +18,9 @@ DEPENDS = "openscap-native python3-pyyaml-native python3-jinja2-native libxml2-n
 S = "${UNPACKDIR}/git"
 B = "${S}/build"
 
-inherit cmake pkgconfig python3native python3targetconfig ptest
+SSG_PTEST_ENABLED = "0"
+
+inherit cmake pkgconfig python3native python3targetconfig ${@bb.utils.contains('SSG_PTEST_ENABLED', '1', 'ptest', '', d)}
 
 STAGING_OSCAP_BUILDDIR = "${TMPDIR}/work-shared/openscap/oscap-build-artifacts"
 export OSCAP_CPE_PATH="${STAGING_OSCAP_BUILDDIR}${datadir_native}/openscap/cpe"
-- 
2.34.1



^ permalink raw reply related	[flat|nested] 4+ messages in thread
* [meta-security][PATCH] scap-security-guide: disable ptest by default
@ 2025-05-28  5:54 Yi Zhao
  2025-05-28 12:53 ` Clayton Casciato
  0 siblings, 1 reply; 4+ messages in thread
From: Yi Zhao @ 2025-05-28  5:54 UTC (permalink / raw)
  To: yocto-patches; +Cc: akuster808

Enabling ptest will significantly increase build time. Additionally,
since the ptest distro_feature is enabled by default in poky distro,
build time can be very long, which is annoying.

On my build server:
Enable ptest:
$ time build scap-security-guide
real    266m41.257s
user    1m16.895s
sys     0m1.553s

Disable ptest:
$ time build scap-security-guide
real    1m29.228s
user    0m4.604s
sys     0m0.175s

Add a switch SSG_PTEST_ENABLED and set it to 0 to disable ptest by
default.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
---
 .../scap-security-guide/scap-security-guide_0.1.76.bb         | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/recipes-compliance/scap-security-guide/scap-security-guide_0.1.76.bb b/recipes-compliance/scap-security-guide/scap-security-guide_0.1.76.bb
index 73bd576..c91a5f9 100644
--- a/recipes-compliance/scap-security-guide/scap-security-guide_0.1.76.bb
+++ b/recipes-compliance/scap-security-guide/scap-security-guide_0.1.76.bb
@@ -18,7 +18,9 @@ DEPENDS = "openscap-native python3-pyyaml-native python3-jinja2-native libxml2-n
 S = "${UNPACKDIR}/git"
 B = "${S}/build"
 
-inherit cmake pkgconfig python3native python3targetconfig ptest
+SSG_PTEST_ENABLED ?= "0"
+
+inherit cmake pkgconfig python3native python3targetconfig ${@bb.utils.contains('SSG_PTEST_ENABLED', '1', 'ptest', '', d)}
 
 STAGING_OSCAP_BUILDDIR = "${TMPDIR}/work-shared/openscap/oscap-build-artifacts"
 export OSCAP_CPE_PATH="${STAGING_OSCAP_BUILDDIR}${datadir_native}/openscap/cpe"
-- 
2.34.1



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

end of thread, other threads:[~2025-05-30  2:58 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-18  5:17 [meta-security][PATCH] scap-security-guide: disable ptest by default Yi Zhao
2025-04-18 10:42 ` [yocto-patches] " Gyorgy Sarvari
2025-04-18 13:09   ` Yi Zhao
  -- strict thread matches above, loose matches on Subject: below --
2025-05-28  5:54 Yi Zhao
2025-05-28 12:53 ` Clayton Casciato
2025-05-30  2:58   ` [yocto-patches] " Yi Zhao

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.