Add SPDX-specific source tree variable for recipes where $S is a subdirectory of the source tree.
Signed-off-by: leimaohui <leimao...@cn.fujitsu.com> --- meta/classes/spdx.bbclass | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/meta/classes/spdx.bbclass b/meta/classes/spdx.bbclass index 55ce3af..27169f0 100644 --- a/meta/classes/spdx.bbclass +++ b/meta/classes/spdx.bbclass @@ -18,13 +18,15 @@ SPDXOUTPUTDIR = "${WORKDIR}/spdx_output_dir" SPDXSSTATEDIR = "${WORKDIR}/spdx_sstate_dir" +SPDX_S ?= "${S}" + python do_spdx () { import os, sys import json info = {} info['workdir'] = (d.getVar('WORKDIR', True) or "") - info['sourcedir'] = (d.getVar('S', True) or "") + info['sourcedir'] = (d.getVar('SPDX_S', True) or "") info['pn'] = (d.getVar( 'PN', True ) or "") info['pv'] = (d.getVar( 'PV', True ) or "") info['src_uri'] = (d.getVar( 'SRC_URI', True ) or "") -- 1.9.1 -- _______________________________________________ yocto mailing list yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/yocto