[GRASS-dev] python2/3 and GRASS build on Arch

Glynn Clements glynn at gclements.plus.com
Wed Oct 8 04:04:01 PDT 2014


Maciej Sieczka wrote:

>      --with-wxwidgets=/usr/bin/wx-config-2.8
> 
> Per 2.8 wxWidgets specified, I don't get it why 
> /usr/lib/python2.7/site-packages/wx-3.0-gtk2/ gets involved in iclass 
> build. I would rather expect it to pick 
> /usr/lib/python2.7/site-packages/wx-2.8-gtk2-unicode/. Some details:

--with-wxwidgets only affects compiled (C/C++) code which links
against the wxWidges libraries. In 7.0, this means the wximgview
module (visualization/wximgview) and nothing else. It doesn't affect
wxGUI.

In theory, code which uses the wxPython library is supposed to use
something like:

	import wxversion
	wxversion.select('2.8')
	import wx

to ensure that the correct version is used when there are multiple
versions present on the system.

> This is an Arch box. I do have all the NumPy stuff installed. There is a 
> problem on Arch that wx-3.0-gtk2/wx/lib/plot.py fails to import 
> numpy.oldnumeric [1] leading to those "NumPy not found" errors, but that 
> would not happen if iclass build referred to 
> wx-2.8-gtk2-unicode/wx/lib/plot.py instead - like I guess all the other 
> GRASS 7 Python modules do.

Maybe everything is using wx-3.0, but only iclass is using the broken
plots.py functionality?

If you can run some other g.gui.* module, you can check which
libraries it's actually using with "cat /proc/<pid>/maps", where <pid>
is the PID of the g.gui.* process.

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


More information about the grass-dev mailing list