Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 947253 - media-video/ffmpeg: fix verify-sig on prefix systems (patch)
Summary: media-video/ffmpeg: fix verify-sig on prefix systems (patch)
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All All
: Normal normal
Assignee: Gentoo Media-video project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-12-31 00:40 UTC by jlucas
Modified: 2024-12-31 03:52 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
0001-media-video-ffmpeg-fix-verify-sig-on-prefix-systems.patch (0001-media-video-ffmpeg-fix-verify-sig-on-prefix-systems.patch,4.91 KB, patch)
2024-12-31 00:40 UTC, jlucas
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description jlucas 2024-12-31 00:40:58 UTC
Created attachment 915562 [details, diff]
0001-media-video-ffmpeg-fix-verify-sig-on-prefix-systems.patch

Trying to emerge media-video/ffmpeg with USE=verify-sig fails at unpack on Gentoo Prefix systems.

The attached patch fixes it by passing the path to the PGP key in the VERIFY_SIG_OPENPGP_KEY_PATH environment variable rather than as an argument to verify-sig_verify_detached, otherwise it will not prepend the prefix to the path, pointing to a most likely non-existing file.

Perhaps this should be considered a bug on the verify-sig_* functions for not prepending the prefix? I can't think of a good reason to have this inconsistent behavior.

jlucas
Comment 1 Mike Gilbert gentoo-dev 2024-12-31 03:48:38 UTC
(In reply to jlucas from comment #0)
> Perhaps this should be considered a bug on the verify-sig_* functions for
> not prepending the prefix? I can't think of a good reason to have this
> inconsistent behavior.

It's fairly rare for these functions to be called directly, and I think we should expect ebuild authors to correctly prefix any paths.

Forcing a prefix of BROOT would make the functions less flexible. For example, this would prevent the use of relative paths, or paths that live under WORKDIR or DISTDIR.
Comment 2 Mike Gilbert gentoo-dev 2024-12-31 03:50:27 UTC
As for why VERIFY_SIG_OPENPGP_KEY_PATH is treated specially: this variable is supposed to be set in global scope. BROOT cannot be referenced in global scope, so we prepend it as a compromise for the most common usage.