Re: How to specify shell for %post/%postun ?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Mar 31, 2005, Panu Matilainen wrote:

> On Wed, 30 Mar 2005, Matthias Kurz wrote:
> 
> >On Wed, Mar 30, 2005, Panu Matilainen wrote:
> >
> >>On Wed, 2005-03-30 at 20:05 +0200, Matthias Kurz wrote:
> >>>Hi.
> >>>
> >>>'%post' and '%postun' are using /bin/sh as default shell. How can i
> >>>change this ?
> >>>I found that this may depend on the setting of the values behind
> >>>RPMTAG_POSTINPROG and RPMTAG_POSTUNPROG. How can i _set_ these ?
> >>
> >>%post -p /usr/bin/perl
> >
> >Thanks, this works, but unfortunately it does not solve my problem.
> >Is there a way to set the values in the environment ?
> 
> No. How would you go specifying a potentially different scriptlet 
> interpreter for each and every packages every scriptlet through the 
> environment?

Well, i thought about a possibility to change the _default_. Actually i
have not seen a package where the script was set explicitely.

> >My problem is, that i want to use existing packages. The packages are 
> >created under Linux, where bash acts as /bin/sh and i want to use them 
> >under Solaris.
> 
> Create a "metapackage" with "Provides: /bin/sh" (and every other such 
> dependency) but no files in it to satisfy the dependencies. You should be 
> able to find such packages readymade on the internet for exactly this 
> purpose..

Yes, i already do something like this (providing /usr/bin/{perl,python},
/bin/sh etc.). But this works only as long as the programs are called
without paths. I'll dig into the rpm sources again. Until now it looks
like i'm forced to change the hardcoded default in lib/psm.c:runScript :(


   (mk)

-- 
Matthias Kurz; Fuldastr. 3; D-28199 Bremen; VOICE +49 421 53 600 47
  >> Im prämotorischen Cortex kann jeder ein Held sein. (bdw) <<

_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/rpm-list

[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux