[pacman-dev] [feature request] ignore certain file conflicts

Nagy Gabor ngaba at bibl.u-szeged.hu
Mon Mar 2 15:50:07 EST 2009

> Nagy Gabor wrote:
> >> Redux:
> >> /usr/lib/zomg.so is not owned by any package. Allow foobar-1.0-2 to
> >> overwrite this file? [y/N]
> >>
> >> Optional:
> >> s/overwrite/claim ownership of/
> >>     
> >
> > In this case we don't need overwrite option at all, right? (This can be
> > detected automatically. However, this detection is slow.)
> >   
> I had just thought the same thing but why would it be so slow?  Would 
> the conflict checking not already find the conflict with an unowned file 
> on the system and so this is just adding a query?

No, fileconflict checks whether we will remove that file or not *in the
transaction*, so it only considers transaction packages only, not all
local packages.

And see src/pacman/query.c/query_fileowner(). Briefly, the problem is
that symlinks can mess things up, so we have to call realpath on
localpkg->files, which is slow. However, Xavier had a clever patch which
reduced realpath usage by checking basenames first, it might have made
query_fileowner() much faster, I dunno.


More information about the pacman-dev mailing list