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

insane.bbclass: Fix message for LIC_FILES_CHKSUM Errors

Signed-off-by: Saul Wold <sgw@linux.intel.com>
This commit is contained in:
Saul Wold
2011-01-05 18:18:55 -08:00
committed by Richard Purdie
parent b91c0f435b
commit d2d5456cd3
+8 -8
View File
@@ -349,7 +349,7 @@ def package_qa_check_license(workdir, d):
# just throw a warning now. Once licensing data in entered for enough of the recipes, # just throw a warning now. Once licensing data in entered for enough of the recipes,
# this will be converted into error and False will be returned. # this will be converted into error and False will be returned.
bb.error(pn + ": Recipe file does not have license file information (LIC_FILES_CHKSUM)") bb.error(pn + ": Recipe file does not have license file information (LIC_FILES_CHKSUM)")
return True return False
srcdir = bb.data.getVar('S', d, True) srcdir = bb.data.getVar('S', d, True)
@@ -357,10 +357,10 @@ def package_qa_check_license(workdir, d):
(type, host, path, user, pswd, parm) = bb.decodeurl(url) (type, host, path, user, pswd, parm) = bb.decodeurl(url)
srclicfile = os.path.join(srcdir, path) srclicfile = os.path.join(srcdir, path)
if not os.path.isfile(srclicfile): if not os.path.isfile(srclicfile):
raise bb.build.FuncFailed( "LIC_FILES_CHKSUM points to invalid file: " + path) raise bb.build.FuncFailed( pn + ": LIC_FILES_CHKSUM points to invalid file: " + path)
if 'md5' not in parm: if 'md5' not in parm:
bb.error("md5 checksum is not specified for ", url) bb.error(pn + ": md5 checksum is not specified for ", url)
return False return False
beginline, endline = 0, 0 beginline, endline = 0, 0
if 'beginline' in parm: if 'beginline' in parm:
@@ -391,11 +391,11 @@ def package_qa_check_license(workdir, d):
os.unlink(tmplicfile) os.unlink(tmplicfile)
if parm['md5'] == md5chksum: if parm['md5'] == md5chksum:
bb.note ("md5 checksum matched for ", url) bb.note (pn + ": md5 checksum matched for ", url)
else: else:
bb.error ("md5 data is not matching for ", url) bb.error (pn + ": md5 data is not matching for ", url)
bb.error ("The new md5 checksum is ", md5chksum) bb.error (pn + ": The new md5 checksum is ", md5chksum)
bb.error ("Check if the license information has changed, and if it has update the .bb file with correct license") bb.error (pn + ": Check if the license information has changed in")
sane = False sane = False
return sane return sane
@@ -605,5 +605,5 @@ Rerun configure task after fixing this. The path was '%s'""" % root)
Missing inherit gettext?""" % config) Missing inherit gettext?""" % config)
if not package_qa_check_license(workdir, d): if not package_qa_check_license(workdir, d):
bb.error("Licensing warning: LIC_FILES_CHKSUM does not match, please fix") bb.fatal("Licensing Error: LIC_FILES_CHKSUM does not match, please fix")
} }