R: R: R: [GRASS-windows] GRASS 6.3.0RC5

Moritz Lennert mlennert at club.worldonline.be
Thu Mar 20 16:46:00 EDT 2008


On 20/03/08 21:21, Marco Pasetti wrote:
> Hi Adam,
> 
> You're welcome.
> 
> I think that Moritz hitted the problem! I also think that the error
> has been caused by your pre-existing tcl installation; let me
> explain:
> 
> First, you don't need to set 
> GRASS_WISH=%GRASSDIR%\tcl-tk\bin\wish.exe But just leave 
> GRASS_WISH=wish.exe
> 
> Furthermore: set PATH=%PATH;%GRASSDIR%\tcl-tk\bin Is already set just
> few lines later...

I hope this is set PATH=%PATH%;%GRASSDIR%\tcl-tk\bin
(note the second % after PATH...don't have access to a win machine at
the moment, but I think this should make a difference)

> 
> The thing that adding wish.exe path to system PATH variable, before
> to set wish.exe, let me think that GRASS (before to modify
> grass63.bat) loaded the wish.exe contained in your pre-existing tcl
> installation... And that's probabbly the way it doesn't work!
[...]
> Moritz, to avoid this problem in future releases, could we set the
> PATH variable in grass63.bat before to set GRASS_WISH var?

We can, but it won't make any difference. All the .bat file does is set 
a few environment variables. The first (and only) time it actually 
executes something is at the very end.

If the problem is with ActiveState's TclTk, then whatever the order of
the file, you will see the same problem because it will find 
ActiveState's wish.exe before GRASS' wish.exe as ActiveStage probably 
puts its directories into the general path. What you would have to do is
change the order of your path assignment from

set PATH=%PATH;%GRASSDIR%\tcl-tk\bin

to

set PATH=%GRASSDIR%\tcl-tk\bin;%PATH%

That way, Windows will find the wish.exe which is in %GRASSDIR% before 
finding the other one.

I guess that in general it is a good idea to force the use of the GRASS 
versions of files before those of the general system. But Glynn or Paul, 
please correct me if I'm wrong.

Moritz

> Marco
> 
> 
> -----Messaggio originale----- Da: Adam Baker
> [mailto:adamb924 at gmail.com] Inviato: giovedì 20 marzo 2008 18.39 A:
> Moritz Lennert Cc: marco.pasetti at alice.it; Markus Neteler;
> grass-windows at lists.osgeo.org; Michael Barton Oggetto: Re: R: R:
> [GRASS-windows] GRASS 6.3.0RC5
> 
> Hello all,
> 
> First, let me thank you for your help. People like you make open
> source work.
> 
> I uninstalled and reinstalled the software, and reproduced the
> original problem (in which nothing happens at all).
> 
> As before, I modified grass63.bat so that this line: 
> GRASS_WISH=wish.exe Became this: 
> GRASS_WISH=%GRASSDIR%\tcl-tk\bin\wish.exe
> 
> That produced the same error message as before, after trying to open
> a dataset.
> 
> On a hunch, I tried changing GRASS_WISH back to the original value
> and adding %GRASSDIR%\tcl-tk\bin to the system path in grass63.bat,
> and now the program runs without incident. (I can load datasets,
> etc.)
> 
> So, to summarize for the sake of people encountering this message in
> the archive, my net change was to edit grass63.bat to insert this 
> line: set PATH=%PATH;%GRASSDIR%\tcl-tk\bin Just before this line: set
> GRASS_WISH=wish.exe
> 
> 
> That is probably something that could be changed about the
> distribution. (?) I don't know why the problem arises on my system
> and not on others, but I don't believe the above would harm anything.
> 
> 
> Thanks again, Adam
> 
> 



More information about the grass-windows mailing list