summaryrefslogtreecommitdiffstats
path: root/scripts/lib/recipetool/create.py
diff options
context:
space:
mode:
authorStefan Herbrechtsmeier <stefan.herbrechtsmeier@weidmueller.com>2021-10-08 09:48:28 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-10-14 11:48:45 +0100
commitf0a43c39cb6eb436fe49c2b6143ddf97a6a4f5e6 (patch)
tree811e0820a24d039b71f2f50d77de29e1570e3033 /scripts/lib/recipetool/create.py
parentd8655d3e15f971f305fe6976e6b8c87cedfa108f (diff)
downloadpoky-f0a43c39cb6eb436fe49c2b6143ddf97a6a4f5e6.tar.gz
recipetool: ignore empty license files
(From OE-Core rev: a00720344d1996db9e4afff1c974b3158fb8dae7) Signed-off-by: Stefan Herbrechtsmeier <stefan.herbrechtsmeier@weidmueller.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/lib/recipetool/create.py')
-rw-r--r--scripts/lib/recipetool/create.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/scripts/lib/recipetool/create.py b/scripts/lib/recipetool/create.py
index 893980a5ce..87b25ebc7e 100644
--- a/scripts/lib/recipetool/create.py
+++ b/scripts/lib/recipetool/create.py
@@ -1126,9 +1126,10 @@ def guess_license(srctree, d):
1126 license = md5sums.get(md5value, None) 1126 license = md5sums.get(md5value, None)
1127 if not license: 1127 if not license:
1128 license, crunched_md5, lictext = crunch_license(licfile) 1128 license, crunched_md5, lictext = crunch_license(licfile)
1129 if not license: 1129 if lictext and not license:
1130 license = 'Unknown' 1130 license = 'Unknown'
1131 licenses.append((license, os.path.relpath(licfile, srctree), md5value)) 1131 if license:
1132 licenses.append((license, os.path.relpath(licfile, srctree), md5value))
1132 1133
1133 # FIXME should we grab at least one source file with a license header and add that too? 1134 # FIXME should we grab at least one source file with a license header and add that too?
1134 1135