[pacman-dev] Pacman configuration parser library

Xyne xyne at archlinux.ca
Sun Jan 1 20:48:09 UTC 2017


Happy new year!

It would be useful for third-party developers to have access to the Pacman
configuration file parsing functions and datatypes in src/pacman/conf.h. Would
you consider providing a shared library for this (or adding it to libalpm)? It
would be more reliable than third-party custom parsers.

Aside from providing the actual shared object file, the only change needed*
would be to remove the lines from parseconfig (conf.c) that free config->repos
so that users could access repo information directly via config->repos after
invoking the function (config_free will free that memory later).

Regards,
Xyne


* It would be nice as well to have the option of parsing a file without
  initializing alpm, but that isn't necessary and I expect that would require
  more intrusive changes due to the current use of a global variable.


More information about the pacman-dev mailing list