On Tue, Jan 18, 2011 at 7:41 PM, Allan McRae <allan@archlinux.org> wrote:
On 19/01/11 10:50, Dan McGee wrote:
Nothing will use this yet, but we might as well read the info in while processing the database. The drawback would be vastly increased memory usage, so we might want to add a flag enabling/disabling the loading of this data.
This will at least for now be unused by pacman, but a pkgfile.c program at least now has the option of using standard libalpm interfaces to search for file ownership.
Signed-off-by: Dan McGee<dan@archlinux.org> --- Thoughts from the peanut gallery?
Not only will memory usage increase massively, but the read speed of the sync databases will also take a decent hit. I'd very much want to reintroduce some lazy loading to the sync database reading just for this, especially since that files list would only be needed for a -So operation.
Sure- but I wasn't planning on telling anyone to point pacman at any databases with files anytime soon. However, thi would be extremely useful for a libalpm-based pkgfile replacement as I said in the commit message. Right now, there is no possibility at all of doing that with libalpm. I'm also leaning against reintroducing lazy loading, and more toward a DB-register-time argument that will allow or deny the loading of files entries from the sync DB handed to the library. This will keep us from having to add back all the cache BS we worked hard to remove. -Dan