[GRASS-windows] Compiling grass7 on msys/mingw?

Colin Nielsen colin.nielsen at gmail.com
Mon Jan 12 11:30:30 EST 2009


> I suspect that Python wants PYTHONPATH to use Windows syntax, e.g.
> (untested):
>
> -       PYTHONPATH="$(GISBASE)/etc/python:$$PYTHONPATH" \
> +       PYTHONPATH="$(call mkpath,$(GISBASE)/etc/python,$$PYTHONPATH)" \
> +
> +ifneq ($(MINGW32),)
> +mkpath = $(shell g.dirseps -h $(1))\;$(2)
> +else
> +mkpath = $(1):$(2)
> +endif

I applied this to the Html.make file and tried again. I got:

$ make
if [ "/usr/local/src/grass_trunk/dist.i686-pc-mingw32/scripts/d.correlate"
!= "" ] ; then GISRC=/usr/local/src/grass_trunk/dist.i686-pc-mingw32/demolocation/.grassrc70
GISBASE=C:/MinGW/msys/local/src/grass_trunk/dist.i686-pc-mingw32
PATH="/usr/local/src/grass_trunk/dist.i686-pc-mingw32/bin:$PATH"
PYTHONPATH="/usr/local/src/grass_trunk/dist.i686-pc-mingw32/etc/python:YTHONPATH"
 ; fi
make: *** Recursive variable `PATH' references itself (eventually).  Stop.

Note the "YTHONPATH".

I then checked the variable PYTHONPATH and found that my Arc
installation over-wrote the PYTHONPATH variable to its own folder. I
changed this back to /usr/local/src/grass_trunk/lib/Python and ran it
again (with the original Html.make) and got:

$ make
if [ "/usr/local/src/grass_trunk/dist.i686-pc-mingw32/scripts/d.correlate"
!= "" ] ; then GISRC=/usr/local/src/grass_trunk/dist.i686-pc-mingw32/demolocation/.grassrc70
GISBASE=C:/MinGW/msys/local/src/grass_trunk/dist.i686-pc-mingw32
PATH="/usr/local/src/grass_trunk/dist.i686-pc-mingw32/bin:$PATH"
PYTHONPATH="/usr/local/src/grass_trunk/dist.i686-pc-mingw32/etc/python:$PYTHONPATH"
PATH="/usr/local/src/grass_trunk/dist.i686-pc-mingw32/bin:/usr/local/src/grass_trunk/dist.i686-pc-mingw32/lib:.:/usr/local/bin:/mingw/bin:/bin:/c/Windows/system32:/c/Windows:/c/Windows/System32/Wbem:/mingw/Python"
LC_ALL=C /usr/local/src/grass_trunk/dist.i686-pc-mingw32/scripts/d.correlate
--html-description < /dev/null | grep -v '</body>\|</html>' >
d.correlate.tmp.html ; fi
Traceback (most recent call last):
  File "C:/MinGW/msys/local/src/grass_trunk/dist.i686-pc-mingw32/scripts/d.correlate",
line 103, in <module>
    options, flags = grass.parser()
  File "C:\MinGW\msys\local\src\grass_trunk\dist.i686-pc-mingw32\etc\python\grass.py",
line 208, in parser
    os.execvp("g.parser", [name] + argv)
  File "C:\MinGW\Python\lib\os.py", line 353, in execvp
    _execvpe(file, args)
  File "C:\MinGW\Python\lib\os.py", line 389, in _execvpe
    func(fullname, *argrest)
OSError: [Errno 2] No such file or directory
make: *** [d.correlate.tmp.html] Error 1
rm d.correlate.tmp.html

Before I continue with this, is this some peculiarity with my
installation or a more general problem with grass7 on mingw/msys?

Thanks for the help,
-Colin


More information about the grass-windows mailing list