mirror of
https://github.com/ukui/apt.git
synced 2026-06-16 19:16:16 -07:00
apt-key: Allow depending on gpg instead of gnupg
Maintainer scripts that need to use apt-key del might as well depend on gpg, they don't need the full gnupg suite.
This commit is contained in:
+2
-2
@@ -671,10 +671,10 @@ prepare_gpg_home() {
|
||||
# well as the script hopefully uses apt-key optionally then like e.g.
|
||||
# debian-archive-keyring for (upgrade) cleanup did
|
||||
if [ -n "$DPKG_MAINTSCRIPT_PACKAGE" ] && [ -z "$APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE" ]; then
|
||||
if ! dpkg-query --show --showformat '${Pre-Depends}${Depends}${Recommends}\n' "$DPKG_MAINTSCRIPT_PACKAGE" 2>/dev/null | grep -q gnupg; then
|
||||
if ! dpkg-query --show --showformat '${Pre-Depends}${Depends}${Recommends}\n' "$DPKG_MAINTSCRIPT_PACKAGE" 2>/dev/null | grep -E -q 'gpg|gnupg'; then
|
||||
cat >&2 <<EOF
|
||||
Warning: The $DPKG_MAINTSCRIPT_NAME maintainerscript of the package $DPKG_MAINTSCRIPT_PACKAGE
|
||||
Warning: seems to use apt-key (provided by apt) without depending on gnupg or gnupg2.
|
||||
Warning: seems to use apt-key (provided by apt) without depending on gpg, gnupg, or gnupg2.
|
||||
Warning: This will BREAK in the future and should be fixed by the package maintainer(s).
|
||||
Note: Check first if apt-key functionality is needed at all - it probably isn't!
|
||||
EOF
|
||||
|
||||
Reference in New Issue
Block a user