[GRASS5] Tcl/Tk console1 bug on Mac OS X

Jeshua Lacock jeshua at openosx.com
Thu Nov 14 22:24:38 EST 2002


On Thursday, November 14, 2002, at 05:50 PM, Glynn Clements wrote:

>
> Jeshua Lacock wrote:
>
>> I am able to reproduce the following with Grass 5.0.0 with Tcl/Tk 
>> 8.4.1
>> on Mac OS X 10.2.x:
>>
>> Start Grass, select location via GUI
>> Start a Monitor
>> Display a raster with the GUI (the command line works)
>>
>> Then a message states "channel 'console1' wasn't opened for writing".
>
> Just a guess, but this might be related to writing to stderr; I can't
> find any explicit references to "console" in the tcltkgrass code.

Hello Glynn,

Thanks for the information.

>> If  I just quit the Tcl/Tk Grass interface and select the "stop all X
>> monitors" option, then start the GUI again, it works great until I 
>> quit
>> out of Grass (quiting the GUI is fine).
>>
>> The error does not happen with the non-Aqua or "UNIX/XFree" version of
>> wish.
>>
>> I greped around a bit and could not find anything. Any ideas and/or
>> help would be greatly appreciated.
>
> GRASS is written for Unix/X11 systems. On "hybrid" systems (e.g.
> Cygwin, MacOSX), where you may have both Unix/X11 and "native"
> versions of particular packages (primarily Tcl/Tk and OpenGL), you
> have to use the Unix/X11 version.
>
> E.g. on Cygwin, there are three distinct "types" of Tcl/Tk:
>
> 1. Native Windows,
> 2. Cygwin,
> 3. "vanilla" Unix/X11 (i.e. compile the Tcl/Tk source as for a
> Unix/X11 system; the resulting version of "wish" uses X, and hence
> needs an X server).
>
> Only option 3 works; the other two versions have incompatible
> differences. I suspect that the situation is similar on MacOSX.
>
> It shouldn't be particularly hard to get tcltkgrass working natively
> on MacOSX. The things which might need changes are the use of the "wm"
> command, and use of X-specific utilities (xterm, xwininfo).
>
> A similar situation applies to NVIZ; only more so, as it uses both
> Tcl/Tk and OpenGL.

Tcltkgrass is running natively (minus the use of XFree for displaying 
and some interactivity).

Everything thing works excellent, except this minor inconvenience, 
which I am sure is something simple. It also actually turns out that I 
just need to quit the tcltk interface and start it again, I do not need 
to select the "stop all X monitors" option.

In the short term I would like to fix this small bug and in the long 
term I would like to eliminate XFree altogether.

It seems like some variable is not set until the GUI is launched.  I do 
not any notable difference in the environment variables before or after 
launching the GUI however.


Thanks again,

Jeshua Lacock __________________________
Programmer/Owner            Phone:   760.935.4736
http://OpenOSX.com           Fax:        760.935.4845
-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_




More information about the grass-dev mailing list