The preferred way to prevent a task from running is not to deltask it,
but setting the noexec flag. That way various implicit dependencies
through the task in question are preserved, avoiding ad hoc
workarounds, such as the one right here.

Signed-off-by: Rasmus Villemoes <rasmus.villem...@prevas.dk>
---
 meta/classes/externalsrc.bbclass | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/meta/classes/externalsrc.bbclass b/meta/classes/externalsrc.bbclass
index d200129987..7b4d8b369f 100644
--- a/meta/classes/externalsrc.bbclass
+++ b/meta/classes/externalsrc.bbclass
@@ -100,14 +100,11 @@ python () {
                 d.setVarFlag(task, 'cleandirs', ' '.join(cleandirs))
 
         fetch_tasks = ['do_fetch', 'do_unpack']
-        # If we deltask do_patch, there's no dependency to ensure do_unpack 
gets run, so add one
-        # Note that we cannot use d.appendVarFlag() here because deps is 
expected to be a list object, not a string
-        d.setVarFlag('do_configure', 'deps', (d.getVarFlag('do_configure', 
'deps', False) or []) + ['do_unpack'])
 
         for task in d.getVar("SRCTREECOVEREDTASKS").split():
             if local_srcuri and task in fetch_tasks:
                 continue
-            bb.build.deltask(task, d)
+            d.setVarFlag(task, 'noexec', '1')
 
         d.prependVarFlag('do_compile', 'prefuncs', 
"externalsrc_compile_prefunc ")
         d.prependVarFlag('do_configure', 'prefuncs', 
"externalsrc_configure_prefunc ")
-- 
2.23.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#142722): 
https://lists.openembedded.org/g/openembedded-core/message/142722
Mute This Topic: https://lists.openembedded.org/mt/77015066/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to