[RFC][WIP][PATCH 0/5] adding extended package data

Andrew Gregory andrew.gregory.8 at gmail.com
Sun Feb 6 18:30:36 UTC 2022


ALPM is currently parsing several fields that are not particularly relevant to
managing package installation (e.g. pkgbase, pkgtype, makedepends,
checkdepends).  pkgtype in particular is not even exposed in any way through
the API, it has to be included in the parser with a "not actually used"
comment.  This patchset adds an extended data field to packages that can be
used by packagers or package-building infrastructure to store arbitrary package
data in a way that doesn't require altering alpm for every field and allows the
data to actually be retrieved via alpm (though not as easily as first-class
fields).

Andrew Gregory (5):
  query: only strip leading local/ for db packages
  query: allow querying extra info for package files
  add data field for arbitrary package data
  query: print extended data when extra info is requested
  makepkg: store package type in extended data

 lib/libalpm/alpm.h       |  7 +++++++
 lib/libalpm/be_local.c   | 25 +++++++++++++++++++++++++
 lib/libalpm/be_package.c |  6 ++++++
 lib/libalpm/be_sync.c    | 16 ++++++++++++++++
 lib/libalpm/package.c    | 17 +++++++++++++++++
 lib/libalpm/package.h    |  6 ++++++
 scripts/makepkg.sh.in    |  2 +-
 src/pacman/package.c     | 13 +++++++++++++
 src/pacman/query.c       | 16 ++++++----------
 9 files changed, 97 insertions(+), 11 deletions(-)

-- 
2.35.0



More information about the pacman-dev mailing list