From: Konrad Scherer <[email protected]> While experimenting with signing rpms, I attempted to import the keys into a temporary keyring and set GPG_PATH to the temporary keyring. This fails because the gpg export call cannot find the requested key in the default keyring.
Signed-off-by: Konrad Scherer <[email protected]> --- meta/recipes-core/meta/signing-keys.bb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/meta/recipes-core/meta/signing-keys.bb b/meta/recipes-core/meta/signing-keys.bb index c19a5fe..ecfcfd0 100644 --- a/meta/recipes-core/meta/signing-keys.bb +++ b/meta/recipes-core/meta/signing-keys.bb @@ -26,8 +26,11 @@ def export_gpg_pubkey(d, keyid, path): bb.utils.mkdirhier(os.path.dirname(path)) gpg_bin = d.getVar('GPG_BIN', True) or \ bb.utils.which(os.getenv('PATH'), "gpg") - cmd = '%s --batch --yes --export --armor -o %s %s' % \ - (gpg_bin, path, keyid) + cmd = gpg_bin + if d.getVar('GPG_PATH', True): + cmd += " --homedir %s" % d.getVar('GPG_PATH', True) + cmd += ' --batch --yes --export --armor -o %s %s' % (path, keyid) + status, output = oe.utils.getstatusoutput(cmd) if status: raise bb.build.FuncFailed('Failed to export gpg public key (%s): %s' % -- 2.6.3 -- _______________________________________________ Openembedded-core mailing list [email protected] http://lists.openembedded.org/mailman/listinfo/openembedded-core
