Re: gensrclist call to rpm

Panu Matilainen <[email protected]> Sat, 14 Aug 2004 18:02:11 +0300 (EEST)
Newsgroups gmane.linux.conectiva.apt-rpm
Message-ID <[email protected]>
Sorry for the late reply...

On Thu, 5 Aug 2004, Aamer Akhter wrote:

> On Thu, 5 Aug 2004 09:05:29 +0300 (EEST), Panu Matilainen
> 
> > Not knowing the
> > environment it's hard to make suggestions but wouldn't it be easier to
> > build rpm with --sysconfdif=/etc (or such) so that no matter where the rpm
> > executable lives, rpmrc can always be found in a predicable place, even if
> > that means copying (or symlinking) rpmrc into place on each host?
> 
> that's actually not a bad idea. :-)
> reality is that the users installing this layered environment will not
> always have root/sudo access. additionally, the strategy has been that
> any files realted to the environmnet should be local to the directory
> tree installed. otherwise there'll be other probs down the road wrt to
> portability etc.

Ok, sounds like, um.. interesting environment :) Still I think for example 
NFS-mounted trees in standard places for a given OS/version would help the 
situation a bit - something in style of
/share/solaris-8/apps/rpm-4.1
                ...../rpm-4.2
/share/solaris-9/apps/rpm-4.1
...etc would help the situation a bit (a place where I worked 
previously had something like that for locally-built applications) but 
then again, you apparently have some rather special requirements :)

> 
> i do like your patch below, it seems to give better control. Have you
> considered providing the patch to the rpm guys? I'm sure other people
> may find it usefull also.

If you conform it fixes things for you then sure, I'll forward the patch 
to rpm-devel...

> 
> > 
> > The attached patch adds a new configuration setting RPM::RCFile so you can
> > use 'apt-get -o RPM::RCFile="/where/ever/rpmrc" install foo' BUT this
> > doesn't fix the gen*list case, since although you could set RPM::RCFile in
> > apt.conf I guess that's not in any predictable place either(?) 
> 
> but thankfully, there's an env variable to control the location of apt.conf.

Hum.. oh, so it seems. Never noticed that before :)
So I guess it would then be useful to apply the patch upstream... (and fix 
the gen*list to use rpm::rcfile as well)

[...] 
> cool. i looked at this very quickly before getting on a plane, been in
> transit all day, and the 4.1 code is the same. i'll play around with
> this and get back to the mailing list with the results. i should
> mention that the above code does away with pulling in the users rpmrc
> file (which is represented in defrcfiles). maybe the thing to do is to
> do a prependto defrcfiles...

But isn't that the situation when specifying --rcfile to rpm as well? 
You can always just set the RPM_RCFILE env.variable to 
~/.rpmrc;/what/ever/path if the user environment needs to be taken into 
account (unless I'm totally mistaken of course :)

	- Panu -