On 06/02/18 12:47, Eli Schwartz wrote:
Currently this seems to be only theoretically useful. The most likely reason for wanting a packagelist is in order to script makepkg and derive the filenames for the packages we want to install or repo-add, but in the current implementation this requires a lot of additional post-processing which must be duplicated in every utility to wrap makepkg.
- It is of minimal use to know what packages might get created on some other device utilizing a different CPU/OS architecture, so don't list them. - It is non-trivial to reimplement makepkg's logic for sourcing any of several makepkg.conf configuration files, then applying environment overrides in order to get the PKGDEST and PKGEXT, so include them directly in the returned filenames. - Output is null-delimited, in order that the filenames can be reliably parsed.
Signed-off-by: Eli Schwartz <eschwartz@archlinux.org> ---
v2: use null delimited text, update manpage with the effects of the patch.
Newline separation should be fine. makepkg ensures most (all?) of the fields are not allowed to have newlines in them. If any can, we need to catch that in out PKGBUILD linting and error out. Probably need to add a check that the fields from makepkg.conf don't have newlines either. A