diff options
| author | Ross Burton <ross@burtonini.com> | 2021-09-06 15:36:13 +0100 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2021-09-10 09:25:38 +0100 |
| commit | d42e12a0bd6dd94e1f43d1bd363b2c18624fb925 (patch) | |
| tree | aa5794993aefb985e723cf5e1609c57b413cee6e /meta/classes/create-spdx.bbclass | |
| parent | dbac3e8432326e9a3989a9baac42fbaa2284254d (diff) | |
| download | poky-d42e12a0bd6dd94e1f43d1bd363b2c18624fb925.tar.gz | |
create-spdx: handle CLOSED license
The special CLOSED license means that this is closed source code with
no other licensing assertions. It's not a generic license in oe-core,
and not a SPDX license, so transform it to NONE explicitly.
(From OE-Core rev: b71bfba1b5076ad1b9a10c08ef0e3393ccbed92a)
Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/create-spdx.bbclass')
| -rw-r--r-- | meta/classes/create-spdx.bbclass | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/meta/classes/create-spdx.bbclass b/meta/classes/create-spdx.bbclass index 0a2fad5640..db85677d4c 100644 --- a/meta/classes/create-spdx.bbclass +++ b/meta/classes/create-spdx.bbclass | |||
| @@ -105,6 +105,9 @@ def convert_license_to_spdx(lic, document, d, existing={}): | |||
| 105 | if l == "|": | 105 | if l == "|": |
| 106 | return "OR" | 106 | return "OR" |
| 107 | 107 | ||
| 108 | if l == "CLOSED": | ||
| 109 | return "NONE" | ||
| 110 | |||
| 108 | spdx_license = d.getVarFlag("SPDXLICENSEMAP", l) or l | 111 | spdx_license = d.getVarFlag("SPDXLICENSEMAP", l) or l |
| 109 | if spdx_license in license_data["licenses"]: | 112 | if spdx_license in license_data["licenses"]: |
| 110 | return spdx_license | 113 | return spdx_license |
