[pacman-dev] pacman 3.1 release ?

Xavier shiningxc at gmail.com
Sat Sep 15 16:24:51 EDT 2007

On Sat, Sep 15, 2007 at 05:30:19PM +0200, Nagy Gabor wrote:
> Let me explain (now I can't create pactest, sorry). PM_SYNC_TYPE_REPLACE
> indicates that install of "replacer" package will induce the removal of packages
> listed in data field. This is a nice trick: if you later decide that you won't 
> install "replacer", removing of this syncpkg from target list will automatically
> revert the induced removal. Conflict resolution also uses this trick. If pkgA
> conflicts with pkgB, and pkgA is in the target list, then pkgA becomes a
> replacer (and syncpkg type of pkgA will be _changed_ to PM_SYNC_TYPE_REPLACE,
> here you will loose information!), and the to-be-removed conflicting local pkgB
> package will be listed in its data field. See sync.c:567-569, that part (without
> any further discussion) is wrong.

I see. I'm attaching a pactest that should reproduce this.
-------------- next part --------------
self.description = "A dep induces a replacement."

lp1 = pmpkg("pkg1")
self.addpkg2db("local", lp1);

sp2 = pmpkg("pkg2")
sp2.depends = ["pkg3"]
self.addpkg2db("sync", sp2);

sp3 = pmpkg("pkg3")
sp3.conflicts = ["pkg1"]
self.addpkg2db("sync", sp3);

self.args = "-S pkg2"


More information about the pacman-dev mailing list