[GRASS-user] Re: Georectify problem

Adam Dershowitz, Ph.D., P.E. adershowitz at exponent.com
Wed Dec 2 14:13:18 EST 2009



On Dec 2, 2009, at 10:20 AM, William Kyngesburye wrote:

> On Dec 2, 2009, at 11:43 AM, Adam Dershowitz, Ph.D., P.E. wrote:
> 
>> While, when I run William Kyngesburye's build I see this in the terminal:
>> Rebuilding Addon menu...
>> Python 2.6.4 found.
>> 
>> But, at the command line, if I just do python, I end up with Apple version 2.6.1.  I will also ask about this on the macports list, which is very active.
>> 
>> For what it is worth, I know that in the past, with 10.5, and Macports installed I was able to run the wxpython version, but I can't seem to get it to work now.  
> 
> Where does MacPorts install its Python?  And is it a frameowrk build?  I know it normally keeps everything isolated in its own folder, but maybe Python is different, if it's a framework.
> 
> The way I have the python detection setup in the OSX startup, the first priority is always the same major.minor version it was built with, and for my Snow build it's 2.6.  Then the priorities are:
> 
> $GRASS_PYTHON setting
> in $PATH
> /Library/Frameworks/Python.framework
> System python

Success!  
Just doing this in my .profile:
 export GRASS_PYTHON=/usr/bin/pythonw2.6

solved the problem.  So I think that the issue is that macports just makes links for "python" and "pythonw" while you were actually searching for "pythonw2.6".

But, Micheal, this fix doesn't work for your build.  I think that reason is that your version of MacOS/grass.sh in 6.4 (I haven't checked any others) actually contains this:
pyver_want="2.5"

While William's contains this:
pyver_want="2.6"

So, your version is searching for, and finding, pythonw2.5, which is the macports only version.  If macports wasn't installed, then it would move on to the 2.6 version, since it can't find 2.5.  

Thanks for all the help from both of you....
Although I have not yet tried to georectify with wxpython, which was the whole point of this exercise initially.

--Adam


More information about the grass-user mailing list