[oe-commits] Mark Hatle : terminal.bbclass: Fix BB_RUNFMT processing

git at git.openembedded.org git at git.openembedded.org
Thu Jul 18 20:18:31 UTC 2013


Module: openembedded-core.git
Branch: master
Commit: 95f6e9a3d8fa24acc3bab392719e2d92be25d806
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=95f6e9a3d8fa24acc3bab392719e2d92be25d806

Author: Mark Hatle <mark.hatle at windriver.com>
Date:   Mon Jul 15 15:10:27 2013 -0500

terminal.bbclass: Fix BB_RUNFMT processing

BB_RUNFMT can include task and taskfunc, as well as func and pid.  Add the
two missing items toe the runfmt processing.

Also BB_RUNFMT can include arbitrary directory structure.

Signed-off-by: Mark Hatle <mark.hatle at windriver.com>
Signed-off-by: Saul Wold <sgw at linux.intel.com>

---

 meta/classes/terminal.bbclass |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/meta/classes/terminal.bbclass b/meta/classes/terminal.bbclass
index ae338e9..591b4ac 100644
--- a/meta/classes/terminal.bbclass
+++ b/meta/classes/terminal.bbclass
@@ -18,8 +18,10 @@ def emit_terminal_func(command, envdata, d):
     envdata.setVarFlag(cmd_func, 'func', 1)
 
     runfmt = d.getVar('BB_RUNFMT', True) or "run.{func}.{pid}"
-    runfile = runfmt.format(func=cmd_func, pid=os.getpid())
+    runfile = runfmt.format(func=cmd_func, task=cmd_func, taskfunc=cmd_func, pid=os.getpid())
     runfile = os.path.join(d.getVar('T', True), runfile)
+    bb.mkdirhier(os.path.dirname(runfile))
+
     with open(runfile, 'w') as script:
         script.write('#!/bin/sh -e\n')
         bb.data.emit_func(cmd_func, script, envdata)



More information about the Openembedded-commits mailing list