On Fri, Sep 18, 2009 at 3:32 PM, Marc - A. Dahlhaus [ Administration | Westermann GmbH ] <mad@wol.de> wrote:
Do we even want to print out the "useless" deltas in the first place?
I guess only if we want to keep this outside of repo-add. If this cleanup code is inside repo-add, we can indeed juste rewrite the deltas file. Anyway, I wrote some C code just for fun. It is on my working branch : http://code.toofishes.net/cgit/xavier/pacman.git/log/?h=working The core code I had to add to libalpm is minimal as I expected, just 40 lines. All the rest can be re-used. But I also had to write a standalone script using this. It only does simple things but the simplest things in C require a lot of code :) The benefit is that its much faster (10x), and finds all useless deltas correctly. But currently, the way to load a sync db with libalpm really sucks, because it's not flexible at all.