From patchwork Tue Jan 29 21:17:20 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [PATCHv3] license: fix LICENSE_CREATE_PACKAGE to stay disabled by default Date: Tue, 29 Jan 2013 21:17:20 -0000 From: Martin Jansa X-Patchwork-Id: 43661 Message-Id: <1359494240-11040-1-git-send-email-Martin.Jansa@gmail.com> To: openembedded-core@lists.openembedded.org * as reported by Enrico on #oe 11:06:50 < ensc|w> JaMa: might this be caused by dc78ef91a2bf01efb8028c9afbe69e506e016265 which checks for 'd.getVar('LICENSE_CREATE_PACKAGE', True)' evaluating to 'True' for every string (including the default 0) Signed-off-by: Martin Jansa --- meta/classes/license.bbclass | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/meta/classes/license.bbclass b/meta/classes/license.bbclass index d4ebb26..170bdd9 100644 --- a/meta/classes/license.bbclass +++ b/meta/classes/license.bbclass @@ -7,6 +7,7 @@ LICENSE_DIRECTORY ??= "${DEPLOY_DIR}/licenses" LICSSTATEDIR = "${WORKDIR}/license-destdir/" # Create extra package with license texts and add it to RRECOMMENDS_${PN} +LICENSE_CREATE_PACKAGE[type] = "boolean" LICENSE_CREATE_PACKAGE ??= "0" LICENSE_PACKAGE_SUFFIX ??= "-lic" LICENSE_FILES_DIRECTORY ??= "${datadir}/licenses/" @@ -102,7 +103,7 @@ python do_populate_lic() { # it would be better to copy them in do_install_append, but find_license_filesa is python python perform_packagecopy_prepend () { - enabled = d.getVar('LICENSE_CREATE_PACKAGE', True) + enabled = oe.data.typed_value('LICENSE_CREATE_PACKAGE', d) if d.getVar('CLASSOVERRIDE', True) == 'class-target' and enabled: lic_files_paths = find_license_files(d)