1
0
mirror of https://git.yoctoproject.org/poky synced 2026-05-08 17:19:20 +00:00

Fixing my bad license parsing: license.bbclass

Fix to my bad license parsing. Also added the MIT generic license
files.

Signed-off-by: Beth Flanagan <elizabeth.flanagan@intel.com>
This commit is contained in:
Beth Flanagan
2011-02-26 14:04:41 -08:00
parent 00dee01d4b
commit d041ab31a1
3 changed files with 11 additions and 3 deletions
+4 -3
View File
@@ -66,9 +66,10 @@ python do_populate_lic() {
# I'm sure someone has written a logic parser for these fields, but if so, I don't know where it is.
# So what I do is just link to every license mentioned in the license field.
for license_type in (' '.join(license_types.replace('&', ' ').replace('+', ' ').replace('|', ' ')
.replace('(', ' ').replace(')', ' ').replace(';', ' ').replace(',', ' ').split())):
if os.path.isfile(os.path.join(generic_directory, license_type)):
for license_type in ((license_types.replace('+', '').replace('|', '&')
.replace('(', '').replace(')', '').replace(';', '')
.replace(',', '').replace(" ", "").split("&"))):
if os.path.isfile(os.path.join(generic_directory, license_type)):
gen_lic_dest = os.path.join(bb.data.getVar('LICENSE_DIRECTORY', d, True), "common-licenses")
try:
bb.mkdirhier(gen_lic_dest)