[Bug 2142108] Re: dpkg-source crashes with "Undefined subroutine &Dpkg::OpenPGP::Backend::GnuPG::g" when verifying upstream signatures

Launchpad Bug Tracker 2142108 at bugs.launchpad.net
Wed Feb 18 12:56:48 UTC 2026


** Merge proposal linked:
   https://code.launchpad.net/~nadzeya/ubuntu/+source/lintian/+git/lintian/+merge/499573

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to dpkg in Ubuntu.
https://bugs.launchpad.net/bugs/2142108

Title:
  dpkg-source crashes with "Undefined subroutine
  &Dpkg::OpenPGP::Backend::GnuPG::g" when verifying upstream signatures

Status in dpkg package in Ubuntu:
  New

Bug description:
  dpkg-source crashes when verifying upstream signatures on Ubuntu:

  ```
  Undefined subroutine &Dpkg::OpenPGP::Backend::GnuPG::g_ called at
  /usr/share/perl5/Dpkg/OpenPGP/Backend/GnuPG.pm line 133.
  ```

  This happens because scripts/Dpkg/OpenPGP/Backend/GnuPG.pm is missing
  `use Dpkg::Gettext;`, which provides the g_() function. The same bug
  was previously fixed for the Sequoia backend in dpkg 1.22.18
  (bug in Debian 1099866).

  This does not affect Debian because debian/control lists sq (Sequoia)
  before gnupg in the Build-Depends alternatives, so the Sequoia backend
  is used instead. Ubuntu's delta reorders the alternatives to prefer
  gnupg over sq, causing the GnuPG backend to be used and hitting the
  missing import.

  The fix is to add 'use Dpkg::Gettext;' to
  scripts/Dpkg/OpenPGP/Backend/GnuPG.pm, matching what was done for
  scripts/Dpkg/OpenPGP/Backend/Sequoia.pm.

  This was discovered while building lintian 2.129.0 from source. The test suite
  runs dpkg-buildpackage on test recipes that include upstream signatures
  (e.g. control-file-upstream-signature-missing), and dpkg-source -b
  crashes when verifying .orig.tar.gz.asc files.

  Steps to reproduce:
  1. Build lintian 2.129.0 from source on Ubuntu resolute (dpkg 1.23.5ubuntu1)
  2. The test suite runs dpkg-buildpackage on test recipes that include
  upstream signatures (e.g. control-file-upstream-signature-missing)
  3. dpkg-source -b crashes when verifying .orig.tar.gz.asc files

  Affected version: dpkg 1.23.5ubuntu1 (resolute)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/dpkg/+bug/2142108/+subscriptions




More information about the foundations-bugs mailing list