Re: R: starxwin.bat always "misfires" the xterm once - it works!

2009-02-18 Thread Dan Tsafrir
On Wed, Feb 18, 2009 at 12:14 PM, Jon TURNEY
 wrote:
>
> Making startxwin.bat just launch startx or xinit would also largely solve
> the problem of overwriting people's customisations to startxwin.bat, as it
> has defined places to put those.

I would like to point out that currently, it appears that in the eyes
of the average user (like me?), startx does not produce acceptable
results, as was just discussed here:

http://www.cygwin.com/ml/cygwin-xfree/2009-02/msg00165.html

so making startxwin.bat a wrapper around startx would potentially
create a problem for many users, who, mind you, were already forced to
waste some time in finding a workaround to the unfortunate fact that
startx stopped working after "up" grade to xorg :(

--Dan

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: R: starxwin.bat always "misfires" the xterm once - it works!

2009-02-18 Thread Jon TURNEY

Owen Rees wrote:

--On Monday, February 16, 2009 17:40:15 +0100 Franz di Coccio wrote:


Marco,

 your suggestion to insert


%CYGWIN_ROOT%\bin\sleep 4

before the xterm launch instruction

%RUN% xterm -e /usr/bin/bash -l

in starxwin.bat did the trick!
Thanks a lot! Grazie!

F

PS That's a weird behaviour, anyway... I wonder why the pause is needed
only for the first execution after the system boot. Whatever... Now it
works :)


Because the second time, the X server is already running.

The command to start the X server has --silent-dup-error, so it does nothing 
when the server is already running.


The problem seems to be the one that prompted the thread that contains 
this message:



As I understand it, the process that starts the X server finishes before 
the X server is ready to accept connections. This means that there is 
then a race condition between the X server start up and the next command 
in the startup script. If the server is ready first all is well but if 
not, the next command - xterm - fails to connect and gives up.


This is correct.

The real solution, is to use startx/xinit, as that actually has code to wait
until the X server is accepting connections before starting the clients.

Making startxwin.bat just launch startx or xinit would also largely solve the 
problem of overwriting people's customisations to startxwin.bat, as it has 
defined places to put those.


Unfortunately, there is one important difference:  xinit does't work quite the 
same way as startxwin.bat, in that it waits for the last client started (or 
the default Xterm) to exit, and when that exits, also kills the X server; 
startxwin just starts everything and exits.


A patch to add a 'don't wait around, just exit' switch to xinit would be most 
useful :-)


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: R: starxwin.bat always "misfires" the xterm once - it works!

2009-02-17 Thread Owen Rees

--On Monday, February 16, 2009 17:40:15 +0100 Franz di Coccio wrote:


Marco,

 your suggestion to insert


%CYGWIN_ROOT%\bin\sleep 4

before the xterm launch instruction

%RUN% xterm -e /usr/bin/bash -l

in starxwin.bat did the trick!
Thanks a lot! Grazie!

F

PS That's a weird behaviour, anyway... I wonder why the pause is needed
only for the first execution after the system boot. Whatever... Now it
works :)


The problem seems to be the one that prompted the thread that contains this 
message:



As I understand it, the process that starts the X server finishes before 
the X server is ready to accept connections. This means that there is then 
a race condition between the X server start up and the next command in the 
startup script. If the server is ready first all is well but if not, the 
next command - xterm - fails to connect and gives up.


--
Owen Rees; speaking personally, and not on behalf of HP.

Hewlett-Packard Limited.   Registered No: 690597 England
Registered Office:  Cain Road, Bracknell, Berks RG12 1HN

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



R: starxwin.bat always "misfires" the xterm once - it works!

2009-02-16 Thread Franz di Coccio
Marco,

 your suggestion to insert


%CYGWIN_ROOT%\bin\sleep 4

before the xterm launch instruction

%RUN% xterm -e /usr/bin/bash -l

in starxwin.bat did the trick!
Thanks a lot! Grazie!

F

PS That's a weird behaviour, anyway... I wonder why the pause is needed
only for the first execution after the system boot. Whatever... Now it works :)

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



R: starxwin.bat always "misfires" the xterm once

2009-02-16 Thread Marco Atzeri


--- Lun 16/2/09, Franz di Coccio  ha scritto:

> Da: Franz di Coccio 
> Oggetto: starxwin.bat always "misfires" the xterm once
> A: cygwin-xfree@cygwin.com
> Data: Lunedì 16 febbraio 2009, 11:08
> Hi all,
> 
>  I have installed cygwin-x on windows XP and I'm pretty
> much happy about it.
> There is only one little annoying thing that I am not able
> to fix.
> I use cygwin-x to ssh into linux systems and occasionally
> launch
> remote applications.
> I do not use a x-desktop.
> 
> I've added an icon to the quick-launch windows toolbar
> pointing to
> startxwin.bat.
> Pressing that icon should launch cygwin-x and open a xterm.
> It does so on my other window box, running win 2000.
> 
> However, on windows xp there seems to be some glitch. The
> first time I
> launch the cygwin-x
> icon after booting the OS, no xterm pops up. At least, not
> immediatly.

I have a similar issue.
It is probably due to Xwin not yet ready when xterm
tries to verify the existence of a X server

try to add 

%CYGWIN_ROOT%\bin\sleep 4

so a 4 second delay (or what ever value is fine for 
you system) before

%RUN% xterm -e /usr/bin/bash -l

this should allow xterm to find a ready Xwin.

> I've been waiting
> a few minutes, but no trace of xterm all the same.
> The xserver is running, though. I can launch an xterm from
> by right
> clicking the small X icon
> in the icon tray, but it opens in /usr/X11R6/bin, prompting
> "bash-3.2$".
> 
> If I close the xserver and launch it a second time, all
> goes as I expect to.
> The xserver is started again, and an xterm almost
> immediatly pops out
> as required
> in startxwin.bat. The xterm correctly starts from my home
> directory.
> 
> Therefore I always have to launch cygwin-x, shut down the
> server and
> launch it again.
> As I mention, this "double launching" is not
> necessary in win 2000.
> The xterm pops up the first time I launch startxwin.bat.
> 
> Is this a known problem? I've tried to search the
> mailing list but
> came up with nothing.
> Perhaps I've used the wrong search terms.
> 
> Thanks a lot for any help
> 
> F

Regards
Marco


  Passa a Yahoo! Mail.

La webmail che ti offre GRATIS spazio illimitato, 
antispam e messenger integrato.
http://it.mail.yahoo.com/  

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/