Subject: Re: "make install" owerwrites files without asking
To: Pavel Cahyna <email@example.com>
From: Jeremy C. Reed <firstname.lastname@example.org>
Date: 06/27/2005 06:52:21
On Sun, 26 Jun 2005, Pavel Cahyna wrote:
> I installed libxen from pkgsrc-wip and at the end, the following was
> ===> Registering installation for libxen-2.0.6
> pkg_create: Overwriting /usr/pkg/include/xc.h - pkg xentools12-040418 bogus/conflicting?
> pkg_create: Overwriting /usr/pkg/lib/libxc.so - pkg xentools12-040418 bogus/conflicting?
> This warning was not very useful, because those files belonging to
> xentools12 were already overwritten when it was printed.
> Shouldn't the check for conflicting files be performed before the actual
> installation, instead of after it? Currently, a package without explicit
> conflict can damage other installed packages, which seems wrong to me.
It could be a little difficult to check this using pkgsrc, but possible.
One way would be to create wrappers for all INSTALL_* scripts, cp, mv,
tar, cpio, pax, and any other tools used to install files so they can
check first. Also we would need to check to make sure /bin/cp and other
hard-coded tools for installing are not done also and just use our
wrappers instead. I don't have the time to do this myself for even the
packages that I help maintain.
As for just using binary packages with pkg_add it would be good if it
didn't blindly overwrite files unless specifically requested.
Jeremy C. Reed
Media Relations and Publishing Services