summaryrefslogtreecommitdiffstats
path: root/meta/classes-global/utility-tasks.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'meta/classes-global/utility-tasks.bbclass')
-rw-r--r--meta/classes-global/utility-tasks.bbclass59
1 files changed, 0 insertions, 59 deletions
diff --git a/meta/classes-global/utility-tasks.bbclass b/meta/classes-global/utility-tasks.bbclass
deleted file mode 100644
index 394cc3158d..0000000000
--- a/meta/classes-global/utility-tasks.bbclass
+++ /dev/null
@@ -1,59 +0,0 @@
1#
2# Copyright OpenEmbedded Contributors
3#
4# SPDX-License-Identifier: MIT
5#
6
7addtask listtasks
8do_listtasks[nostamp] = "1"
9python do_listtasks() {
10 taskdescs = {}
11 maxlen = 0
12 for t in bb.build.listtasks(d):
13 maxlen = max(maxlen, len(t))
14
15 if t.endswith('_setscene'):
16 desc = "%s (setscene version)" % (d.getVarFlag(t[:-9], 'doc') or '')
17 else:
18 desc = d.getVarFlag(t, 'doc') or ''
19 taskdescs[t] = desc
20
21 for task, doc in sorted(taskdescs.items()):
22 bb.plain("%s %s" % (task.ljust(maxlen), doc))
23}
24
25CLEANFUNCS ?= ""
26
27T:task-clean = "${LOG_DIR}/cleanlogs/${PN}"
28addtask clean
29do_clean[nostamp] = "1"
30python do_clean() {
31 """clear the build and temp directories"""
32 dir = d.expand("${WORKDIR}")
33 bb.note("Removing " + dir)
34 oe.path.remove(dir)
35
36 dir = "%s.*" % d.getVar('STAMP')
37 bb.note("Removing " + dir)
38 oe.path.remove(dir)
39
40 for f in (d.getVar('CLEANFUNCS') or '').split():
41 bb.build.exec_func(f, d)
42}
43
44addtask checkuri
45do_checkuri[nostamp] = "1"
46do_checkuri[network] = "1"
47python do_checkuri() {
48 src_uri = (d.getVar('SRC_URI') or "").split()
49 if len(src_uri) == 0:
50 return
51
52 try:
53 fetcher = bb.fetch2.Fetch(src_uri, d)
54 fetcher.checkstatus()
55 except bb.fetch2.BBFetchException as e:
56 bb.fatal(str(e))
57}
58
59