[GRASS-dev] Issues of 6.5 build on WinXP

Hello Everyone,

I've tried to compile 6.5 version of Grass (svn at rev. 38990) according to
the following link on my WinXP 32-bit:
http://trac.osgeo.org/grass/wiki/CompileOnWindows

I found there a broken link [1] during gathering all the individual
packages, but this file can be hopefully downloaded from another location
[2].

Thanks to this exhaustive description my build has been finished
successfully. Great work.

But after launching of 6.5 wxPython GUI I've encountered several issues:

1) I cannot add a new vector map layer. Only a dummy one is added without
the standard option dialog. All corresponding messages from the Command
output tab can be found at the bottom of this e-mail. Raster maps are Ok.

2) Encoding issue, probably the same described in the ticket 806 [3]. In all
places where localized strings are used in module dialogs there are strange
characters instead of non western glyphs. I think the ISO 8859-1 encoding is
probably used instead of UTF-8. In menu system all characters are fine.

My previous version 6.4 was installed using an installer without localized
strings so I cannot verify this behaviour there.

3) Freezing of app when the Manual tab is seleced in Kriging module
(Raster|Interpolate surface|Ordinary or block kriging) so the app must be
terminated. The same operation in another modules is Ok.

I'm not a programmer to be able to analyze that, but I'm willing to test
your ideas and fixes on my environment.

Regards,
Jan

__________
[1] http://downloads.sourceforge.net/mingw/gcc-g++-3.4.5-20060117-3.tar.gz

[2]
http://sourceforge.net/projects/mingw/files/GCC%20Version%203/Current%20Rele
ase_%20gcc-3.4.5-20060117-3/gcc-g%2B%2B-3.4.5-20060117-3.tar.gz/download

[3] http://trac.osgeo.org/grass/ticket/806

Traceback (most recent call last):
  File
"C:/OSGeo4W/apps/grass/grass-6.5.svn/etc/wxpython/wxgui.py",
line 1299, in OnAddVector

self.AddVector(event)
  File
"C:/OSGeo4W/apps/grass/grass-6.5.svn/etc/wxpython/wxgui.py",
line 1401, in AddVector

self.curr_page.maptree.AddLayer('vector')
  File "c:/OSGeo4W/usr/src/grass6-devel/dist.i686-pc-
mingw32/etc/wxpython/gui_modules/wxgui_utils.py", line 797,
in AddLayer

self.PropertiesDialog(layer, show=True)
  File "c:/OSGeo4W/usr/src/grass6-devel/dist.i686-pc-
mingw32/etc/wxpython/gui_modules/wxgui_utils.py", line 894,
in PropertiesDialog

parentframe=self)
  File "c:/OSGeo4W/usr/src/grass6-devel/dist.i686-pc-
mingw32/etc/wxpython/gui_modules/menuform.py", line 1763, in
ParseCommand

self.grass_task = self.ParseInterface(cmd)
  File "c:/OSGeo4W/usr/src/grass6-devel/dist.i686-pc-
mingw32/etc/wxpython/gui_modules/menuform.py", line 1731, in
ParseInterface

tree = etree.fromstring(getInterfaceDescription(cmd[0]).deco
de(enc).encode("utf-8"))
  File
"C:\OSGeo4W\apps\Python25\lib\xml\etree\ElementTree.py",
line 963, in XML

parser.feed(text)
  File
"C:\OSGeo4W\apps\Python25\lib\xml\etree\ElementTree.py",
line 1245, in feed

self._parser.Parse(data, 0)
xml.parsers.expat
.
ExpatError
:
not well-formed (invalid token): line 559, column 58
Traceback (most recent call last):
  File
"C:/OSGeo4W/apps/grass/grass-6.5.svn/etc/wxpython/wxgui.py",
line 368, in OnCBPageClosed

maptree = self.curr_page.maptree
AttributeError
:
'NoneType' object has no attribute 'maptree'

Hi,

2009/12/23 Jan Tošovský <j.tosovsky@tiscali.cz>:

I've tried to compile 6.5 version of Grass (svn at rev. 38990) according to
the following link on my WinXP 32-bit:
http://trac.osgeo.org/grass/wiki/CompileOnWindows

I found there a broken link [1] during gathering all the individual
packages, but this file can be hopefully downloaded from another location
[2].

thanks, url fixed on wiki.

1) I cannot add a new vector map layer. Only a dummy one is added without
the standard option dialog. All corresponding messages from the Command
output tab can be found at the bottom of this e-mail. Raster maps are Ok.

2) Encoding issue, probably the same described in the ticket 806 [3]. In all
places where localized strings are used in module dialogs there are strange
characters instead of non western glyphs. I think the ISO 8859-1 encoding is
probably used instead of UTF-8. In menu system all characters are fine.

Yes, it seems to be i18n-related bug. Unfortunately GRASS 6.5 starts
unlocalized on my (Czech) Windows XP. I have tried to set up LANG
variable, but it didn't help. Sorry I am GNU/Linux user:-) If I manage
to run GRASS localized, then I can try to fix the bug.

[...]

Martin

--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa

Hi,

2009/12/23 Jan Tošovský <j.tosovsky@tiscali.cz>:

[...]

3) Freezing of app when the Manual tab is seleced in Kriging module
(Raster|Interpolate surface|Ordinary or block kriging) so the app must be
terminated. The same operation in another modules is Ok.

Please try r40130 where is enabled customized GUI of v.krige.

Martin

--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa

Hello,

2) Encoding issue, probably the same described in the
ticket 806 [3]. In all
> places where localized strings are used in module dialogs
there are strange
> characters instead of non western glyphs. I think the ISO
8859-1 encoding is
> probably used instead of UTF-8. In menu system all
characters are fine.

Yes, it seems to be i18n-related bug. Unfortunately GRASS 6.5 starts
unlocalized on my (Czech) Windows XP. I have tried to set up LANG
variable, but it didn't help. Sorry I am GNU/Linux user:-) If I manage
to run GRASS localized, then I can try to fix the bug.

what is also interesting is a language detection. In the Tcl/Tk GUI it works
fine, but in the wxPython GUI only partially. Without modifying the
environment variable (set LC_ALL=cs_CZ) all the menus are in English, but
several strings in dialogs are in OS language (czech in my case) so some
detection mechanism seems to be built-in. If above mentioned variable is
set, not only complete menu system is localized but also another strings
from dialogs, as can be seen in enclosed images. These additional strings
are encoded properly...

Jan

(attachments)

lang_default.png
lang_cs_CZ.png

Hi,

2009/12/26 Jan Tošovský <j.tosovsky@tiscali.cz>:

what is also interesting is a language detection. In the Tcl/Tk GUI it works
fine, but in the wxPython GUI only partially. Without modifying the
environment variable (set LC_ALL=cs_CZ) all the menus are in English, but

it's not working for me, still unlocalized wxGUI starts...
Interestingly TCL/TK-based GUI is localized. Seems to be a bug.

Martin

--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa

> Without modifying the environment variable
> (set LC_ALL=cs_CZ) all the menus are in English

it's not working for me, still unlocalized wxGUI starts...
Interestingly TCL/TK-based GUI is localized. Seems to be
a bug.

FYI: I've set this environment variable at the begining of
C:\OSGeo4W\etc\ini\grass.bat file. Setting this variable in the OS control
panel directly may require restart of Windows (but I am not sure) to have
any effect.

Hi,

2009/12/26 Jan Tošovský <j.tosovsky@tiscali.cz>:

> Without modifying the environment variable
> (set LC_ALL=cs_CZ) all the menus are in English

it's not working for me, still unlocalized wxGUI starts...
Interestingly TCL/TK-based GUI is localized. Seems to be
a bug.

FYI: I've set this environment variable at the begining of
C:\OSGeo4W\etc\ini\grass.bat file. Setting this variable in the OS control
panel directly may require restart of Windows (but I am not sure) to have
any effect.

Unfortunately it's not working on my machine

$ env | grep LC_ALL
LC_ALL=cs_CZ

but wxGUI starts still unlocalized...

Martin

--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa

2009/12/27 Martin Landa <landa.martin@gmail.com>:

FYI: I've set this environment variable at the begining of
C:\OSGeo4W\etc\ini\grass.bat file. Setting this variable in the OS control
panel directly may require restart of Windows (but I am not sure) to have
any effect.

Unfortunately it's not working on my machine

$ env | grep LC_ALL
LC_ALL=cs_CZ

but wxGUI starts still unlocalized...

mystery partly solved, during compilation process in not created
'locale' directory and 'make' says

$ make clean; make
../include/Make/Module.make:25: warning: overriding commands for
target `install'
../include/Make/Rules.make:82: warning: ignoring old commands for
target `install'
Creating translations (= 'make mo')
make[1]: Entering directory `/c/OSGeo4W/usr/src/grass6_devel/locale'
../include/Make/Module.make:25: warning: overriding commands for
target `install'
../include/Make/Rules.make:82: warning: ignoring old commands for
target `install'
make[1]: Nothing to be done for `mo'.
make[1]: Leaving directory `/c/OSGeo4W/usr/src/grass6_devel/locale'

Not sure what is wrong...

Martin

--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa

Martin Landa wrote:

>> FYI: I've set this environment variable at the begining of
>> C:\OSGeo4W\etc\ini\grass.bat file. Setting this variable in the OS control
>> panel directly may require restart of Windows (but I am not sure) to have
>> any effect.
>
> Unfortunately it's not working on my machine
>
> $ env | grep LC_ALL
> LC_ALL=cs_CZ
>
> but wxGUI starts still unlocalized...

mystery partly solved, during compilation process in not created
'locale' directory and 'make' says

$ make clean; make

Creating translations (= 'make mo')
make[1]: Entering directory `/c/OSGeo4W/usr/src/grass6_devel/locale'

make[1]: Nothing to be done for `mo'.
make[1]: Leaving directory `/c/OSGeo4W/usr/src/grass6_devel/locale'

Not sure what is wrong...

First, ensure that you have GNU make 3.81; I wouldn't trust older
versions to handle non-trivial use of "eval".

FWIW, the locale directory from GRASS 6.5 builds fine for me on
Windows (with make 3.81).

--
Glynn Clements <glynn@gclements.plus.com>

Hi,

2009/12/28 Glynn Clements <glynn@gclements.plus.com>:

Not sure what is wrong...

First, ensure that you have GNU make 3.81; I wouldn't trust older
versions to handle non-trivial use of "eval".

FWIW, the locale directory from GRASS 6.5 builds fine for me on
Windows (with make 3.81).

right, it was cased by the fact that I was using make < 3.81. Thanks, Martin

--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa