On Sun, Mar 07, 2004 at 01:17:46PM +0100, Andreas Metzler wrote: > On 2004-03-07 Colin Watson <[EMAIL PROTECTED]> wrote: > > On Sun, Mar 07, 2004 at 11:23:40AM +0100, Andreas Metzler wrote: > >> When jumping from 4.3 to 4.5 I'd like to rename pgrep to pcregrep and > >> to provide seamless upgrades I'd introduce a dummy package pgrep > >> depending on pcregrep, however replaces/conflicts gives me a headache. > > >> Package: pcregrep > >> Architecture: any > >> Depends: ${shlibs:Depends} > >> Conflicts: pgrep(<<4.5) > >> Replaces: pgrep(<<4.5) > > >> Package: pgrep > >> Section: oldlibs > >> Architecture: all > >> Depends: pcregrep > > >> This looks correct, doesn't it? Any[1] version of pgrep fulfilling (<<4.5) > >> is no dummy package and contains /usr/bin/pcregrep, therefore pcregrep > >> must conflict with it. > > > I think you just need Replaces: pgrep (<< 4.5), not Conflicts: at all. > > It's a straightforward file conflict. Conflicts: makes the upgrade > > painful because it adds extra complexity to the unpack order: this is > > why policy recommends against it.
Actually, Replaces:/Conflicts: has the special meaning of "this package completely replaces that other package", which I guess is what you want. Nothing depends on pgrep, so is the dummy package really needed? > So it is no bug that this file-conflict > > | X:/ dpkg -i /apt-zusatz/pgrep_4.3-0.0.1_i386.deb > | dpkg - warning: downgrading pgrep from 4.5-0.1 to 4.3-0.0.1. > | (Reading database ... 9669 files and directories currently installed.) > | Preparing to replace pgrep 4.5-0.1 (using > | .../pgrep_4.3-0.0.1_i386.deb) ... > | Unpacking replacement pgrep ... > | dpkg: error processing /apt-zusatz/pgrep_4.3-0.0.1_i386.deb > | (--install): > | trying to overwrite `/usr/bin/pcregrep', which is also in package > | pcregrep > | Errors were encountered while processing: > | /apt-zusatz/pgrep_4.3-0.0.1_i386.deb > > is not expressed in Conflicts: because basically we only care about > upgrading? That's really a bug in dpkg. -- Colin Watson [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]