Upload: bash-3.0-4 [test]

Igor Pechtchanski pechtcha@cs.nyu.edu
Tue Jul 5 17:32:00 GMT 2005

On Tue, 5 Jul 2005, Corinna Vinschen wrote:

> On Jul  5 12:33, Igor Pechtchanski wrote:
> > This isn't good enough -- I think you do need a preremove script.  I've
> > been trying to figure out why the no-preremove solution seems wrong, and
> > came up with the following scenario: suppose bash is linked against an
> > older libreadline, and the user upgrades both bash and libreadline to
> > newer versions.  /bin/sh will be a copy of the old version of bash, but
> > after the upgrade it won't have the necessary DLLs.  So, running the
> > postinstall script (with "/bin/sh --version") will result in a "Can't
> > locate DLL" popup, which should be a no-no in a postinstall script.
> Actually that would be covered by postinstall scripts which don't use
> /bin/sh at all.

Yep, that's what I meant.

> What about using md5sum to figure out if it's bash or ash and if it's an
> old or new version?

Doing this in a postinstall script sort of defeats the purpose, as any
files from the old versions are gone by the time the script runs.  Unless
you want to distribute a list of MD5 sums of all prior bash/ash versions
with the bash (ash?) package...

> I still don't like the idea of a preremove script removing /bin/sh under
> whatever circumstances.

How about using a dummy executable that doesn't depend on anything and
does nothing but print out some pre-defined message, and copying that to
/bin/sh in the preremove script?  That way, there will always be a
(non-working, but who cares) /bin/sh...  I was going to suggest
/bin/false, but the new version actually depends on cygintl-3.dll and
cygiconv-2.dll -- go figure.
      |\      _,,,---,,_		pechtcha@cs.nyu.edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor@watson.ibm.com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski, Ph.D.
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"The Sun will pass between the Earth and the Moon tonight for a total
Lunar eclipse..." -- WCBS Radio Newsbrief, Oct 27 2004, 12:01 pm EDT

More information about the Cygwin-apps mailing list