[winGRASS] d.mon socket problem

Mike Thomas miketh at brisbane.paradigmgeo.com
Wed May 21 01:34:11 EDT 2003


Hi there.

Actually, I built both the X and generic Cygwin binary downloads with
__W98__ defined to ensure that both versions would work on Windows 98 (upon
which platform fork() was indeed broken a year or two ago).

This turned out to be a good thing as I got a report the other day from a
user who was in fact running the X build of Grass 5.0.2 on a Pentium 166
Windows 98 laptop.

Cheers

Mike Thomas.

| -----Original Message-----
| From: wingrass-admin at grass.itc.it [mailto:wingrass-admin at grass.itc.it]On
| Behalf Of Glynn Clements
| Sent: Wednesday, May 21, 2003 2:20 PM
| To: Markus Neteler
| Cc: wingrass at grass.itc.it
| Subject: Re: [winGRASS] d.mon socket problem
|
|
|
| Markus Neteler wrote:
|
| > > The problem is not with Grass5; rather with the Cygwin XWin.
| >
| > I am rather sure that it also appears with the generic driver (without
| > Xwin). But as libG11.dll uses some X related code it may be the same
| > problem?
|
| No. libG11 implements parts of the Xlib API by calling Windows GDI
| functions, whereas the real Xlib works by building X protocol requests
| from the functions' arguments and sending them to an X server.
|
| As for the startup message:
|
| > GRASS >d.mon x0
| > Socket is already in use or not accepting connections.
| > Use d.mon to select a monitor
| > Problem selecting x0. Will try once more
|
| This indicates that either:
|
| a) you're using the "generic" version of mon.start, or
| b) Cygwin's process management functions are badly broken.
|
| The normal (i.e. Unix) mon.start uses execl() to start the driver, so
| the system() call in d.mon won't return until the driver fork()s, and
| this doesn't happen until after listen() has been called on the
| socket, so the subsequent mon.select is bound to succeed (unless the
| driver dies outright).
|
| The "generic" mon.start (i.e. if --enable-w11 was used) uses spawnl()
| to start the driver in the background (and passes "-" as argv[2], so
| the driver doesn't fork()). spawnl() returns immediately, so the first
| time that mon.select is run, the driver probably won't have finished
| initialising, so you get the above messages.
|
| If you use the "generic" mon.start with the "real" X11 XDRIVER, you
| will get the warning due to the first mon.select attempt failing, but
| it should work otherwise (unless the second attempt also fails; note
| that there isn't an explicit delay, so this is quite possible).
|
| Given that your symptoms match option a) above, and you imply that you
| have both versions of XDRIVER, I'm tempted to suspect that you're
| switching between XDRIVER versions without also switching mon.start.
|
| --
| Glynn Clements <glynn.clements at virgin.net>
| _______________________________________________
| winGRASS mailing list
| winGRASS at grass.itc.it
| http://grass.itc.it/mailman/listinfo/wingrass
|
|





More information about the grass-windows mailing list