[ITA] _autorebase

Corinna Vinschen corinna-cygwin@cygwin.com
Mon Dec 15 10:21:00 GMT 2014


On Dec 13 23:06, Achim Gratz wrote:
> Ken Brown writes:
> > 1. Shouldn't you have removed the following line from rebase_do?
> >
> >     peflags ${verbose} -d0 -t0 -T "${g}"
> 
> That isn't redundant and has nothing to do with the stuff in peflags_do,
> although I don't remember exactly what the problem was that was resolved
> by this.  The current toolchain should be clean, though, so it may best
> be an optional step.

This looks wrong.  -d0 is ok on 32 bit due to the tight memory layout,
but -t0 is very certainly wrong.  You *want* Cygwin executables to be
TS aware, so, if at all, -t1 would be required.

<history lesson>

Way back when none of the Cygwin binaries were TS aware (before we
defaulted to it in GCC), we had mysterious crashes when trying to run
bash from terminal server session on "real" terminal servers (in
contrast to remote desktop sessions on XP++ and non-TS servers).  I even
opened a case with Microsoft at the time.

It turned out that terminal servers check the TS awareness bit, and if
it's unset, a compatibility layer DLL is hooked into the process, which
performs certain compatibility tests.  For some reason, one of the test
left some pages in the process text segment unexecutable, which then
resulted in a very quick SEGV in bash.  After the Microsofties
discovered that the problem was based on the missing TS-awareness flag
in bash, they dropped the issue as "won't fix".  The solution was "set
the TS-awareness flag".

</history lesson>


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin-apps/attachments/20141215/4cf308b6/attachment.sig>


More information about the Cygwin-apps mailing list