On Tue, May 18, 2010 at 06:41:59PM +0200, David Kalnischkies wrote: > No problem, i didn't understand me currently, too. ;) > Just to add a bit more confus… clarification - i will LOL [ several APT/dpkg lists containing <awesome,1> package ] > Communicating this to the converter seems at least for me a bit > complicated as the converter will not know what the manager handles as > the same and as a different version (and vice versa?). Right, I now clearly see your point and the underlying problem (which I missed before, thanks!). Let me rephrase to make sure we have the same understanding of the issue: « given that the package <p,1> (name, version) can appear in more than one "package list", the fact that the solver will reply "install p=1" is meaningless, as the upstream package manager won't know *which* <p,1> it has to install » My first temptation would be to say that individual package lists should contain UUIDs, so that the downstream solver can annotate his solution with those and the upstream package manager will be able to disambiguate installation indication. Pragmatically, we don't have hopes to change this soon, so we need another solution. I see a solution that still preserves the "one pass" approach, not adding any need of and ping-pong between package manager and solver. The idea is that in the answer from the solver, you get package stanzas as follows: package: foo version: 1.2.3-4 id: adgf31452135hkashdfa installed: yes The idea is that "id" is an optional property (defaulting to "") and that the triple <package, version, id> uniquely identify a package for APT; i.e.: it will be able to discriminate among multi-arch, locally-rebuilt packages, and packages coming from different APT lists. The point is now obviously which kind of 'id' should be used to ease interaction with APT and friends. I see at least the following possibilities, no idea what would be the most preferable: 1) id is the sha1/md5/... of the file the package comes from 2) id is the argc (on the cmdline) of the file the package comes from 3) id is the path of the file the package comes from The advantage of (1) is that APT (I guess) already has some checksum of packages list out of the APT-secure stuff, no idea whether they are easily associable to individual packages though. Also, I don't know whether some checksum of /var/lib/dpkg/status is available already or not. (2) is pretty damn easy and quite compact. (3) is easy but not compact. Would something like the above work? Any other options? Cheers. -- Stefano Zacchiroli -o- PhD in Computer Science \ PostDoc @ Univ. Paris 7 zack@{upsilon.cc,pps.jussieu.fr,debian.org} -<>- http://upsilon.cc/zack/ Dietro un grande uomo c'è ..| . |. Et ne m'en veux pas si je te tutoie sempre uno zaino ...........| ..: |.... Je dis tu à tous ceux que j'aime
Attachment:
signature.asc
Description: Digital signature