RPM Community Forums

Mailing List Message of <rpm-users>

Re: Replacing a file already owned by another rpm package

From: Oguz Yilmaz <oguzyilmazlist@gmail.com>
Date: Mon 12 Jul 2010 - 14:14:10 CEST
Message-ID: <AANLkTinGhQHtQAAmhUm11_ViBI8vFp3A3fhxRVXYkqUD@mail.gmail.com>
On Mon, Jul 12, 2010 at 3:06 PM, Jeff Johnson <n3npq@mac.com> wrote:
> On Jul 12, 2010, at 1:53 AM, Oguz Yilmaz wrote:
>> Hi all,
>> I am on a task for packaging a kernel module.
>> kernel-xx.rpm has already e1000e.ko module in it.
>> I will make a new rpm with e1000e.ko with the same path.
>> What do you suggest for installing new rpm without conflicts and
>> force? There may be some hacks in my mind:
>> For example:
>> Adding e1000e.ko file with another path in the rpm and use postinstall
>> script to replace old file.
> Using %post is one way. The usual failure point with %post is
> that the effect of replacing a file in another package
> doesn't survive an upgrade. i Then a %trigger* script is needed.

I think %post will not prevent the conflict error, and package will
not be installed without "--force". However, because I am using yum
update for my systems, I have to have all packages installing without
any "--force".

If the is not a legal method for replacing a file of another rpm, I
will add a postinstall script while adding the file with another path;
and move the file to the original location in postinstall script.

> But for replacing e1000e.ko a %post will "work", kernel packages
> are never upgraded.
> See also the "Dell Kernel Module System" (DKMS if I've remembered
> the name). DKMS is an orderly way to add a 3rd party driver to
> an existing kernel package, including rebuilding when the kernel
> is replaced.
>> However, if exists and if possible, I want to use most standard way of
>> doing this.
> There is no 1 standard way to replace a file in another package using RPM.
> hth
> 73 de Jeff
> ______________________________________________________________________
> RPM Package Manager                                    http://rpm5.org
> User Communication List                             rpm-users@rpm5.org
Received on Mon Jul 12 14:14:28 2010
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.