Introduce EndOfProcessCleanups rather than subverting CloseFiles.

This allows to separate the end of process action from just
closing the files (used by pyroot).

See commit ae57174d1b1ffba66cbbecfef77ee55365c14127

(cherry picked from commit ba20713500ff54c53be414f98ae617c436a3d9df)
Fix order of deletion TROOT destructor and EndOfProcessCleanups.

Some objects (TParallelCoord) manipulate global objects (TStyles)
in their destructor.  Reorder the deletion of the global object
to avoid conflicts.

(cherry picked from commit e4d35d67365bb119cbfaa71c6595e14cd62fc6f6)