We need to check the gpg version and alter its command line options
accordingly.
[YOCTO #11054]
Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
cmd = self.rpm_bin + " --addsign --define '_gpg_name %s' " % keyid
cmd += "--define '_gpg_passphrase %s' " % passphrase
+ if self.gpg_version > (2,1,):
+ cmd += "--define '_gpg_sign_cmd_extra_args --pinentry-mode=loopback' "
if self.gpg_bin:
cmd += "--define '%%__gpg %s' " % self.gpg_bin
if self.gpg_path: