[PATCH] setup: implement "perpetual" postinstall scripts

Achim Gratz Stromeko@nexgo.de
Wed Feb 6 22:16:00 GMT 2013


Christopher Faylor writes:
> You should make it clear why the current mechanism is unsatisfactory.

I thought I already had, apologies if I haven't been clear enough.  In
general the changes that I've posted for review aim to enable either an
unattended or a guided install (choser mode) that does the initial
install or combinations of installing/removing packages and updating
Cygwin with just a single start of setup.exe and no or (in guided mode)
minimal user interaction.

I originally did the rebasing from the install script that also calls
setup.exe, but I've had several cases where the postinstall scripts
would not run correctly without the rebasing done first and that meant I
would have to check if Cygwin was already installed and then run rebase
twice (aside from running setup.exe twice, one time for installation and
the other for updating already installed packages).  With all my changes
integrated I can now do all of this in a single invocation of setup.exe
and that is a real improvement since each invocation of setup.exe scans
the release directory before it does anything and that is very slow when
accessing the distribution server (typically about three minutes).

> _autorebase is already designed to be run whenever a dll is updated.

To the best of my knowledge that works by auto-incrementing the package
version, so it is only ever effective when another Cygwin package that
needs rebasing updates, but doesn't really do anything if the user adds
libraries through other venues (CPAN, gems and the like).  The solution
that I've implemented doesn't rely on the package version to decide on
when to run, it is instead _always_ run (it first checks if there's
anything to do so the cost of doing that is low).  This enables setup to
be run for the sole purpose of doing either an incremental or a full
rebase, something that either won't work or is much more difficult to do
with the current solution.

> Maybe it isn't being run early enough in the postinstall process but,
> if that is the case, it probably is a minor change to setup.exe which
> doesn't involve lots of new code.

As I said, there isn't all that much new code and even that can be
reduced considerably if these scripts can be put into their own
directory (I wouldn't need the extra helper class in that case nor the
checks for the correct suffix).


Regards,
Achim.
-- 
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+

SD adaptations for Waldorf Q V3.00R3 and Q+ V3.54R2:
http://Synth.Stromeko.net/Downloads.html#WaldorfSDada



More information about the Cygwin-apps mailing list