Double-check where the setup.py install step installed the files, but you will probably need to use something like /opt/wx/2.8/lib/python2.7/site-packages/wx-2.8-gtk-unicode
there is no python2.7 folder in /opt/wx/2.8/
[===>08:36:20]~:cd /opt/wx/2.8/lib/
[===>08:36:49]lib:ls
libwx_based-2.8.so libwx_gtk2d_core-2.8.so.0
libwx_based-2.8.so.0 libwx_gtk2d_core-2.8.so.0.8.0
libwx_based-2.8.so.0.8.0 libwx_gtk2d_html-2.8.so
libwx_based_net-2.8.so libwx_gtk2d_html-2.8.so.0
libwx_based_net-2.8.so.0 libwx_gtk2d_html-2.8.so.0.8.0
libwx_based_net-2.8.so.0.8.0 libwx_gtk2d_qa-2.8.so
libwx_based_xml-2.8.so libwx_gtk2d_qa-2.8.so.0
libwx_based_xml-2.8.so.0 libwx_gtk2d_qa-2.8.so.0.8.0
libwx_based_xml-2.8.so.0.8.0 libwx_gtk2d_richtext-2.8.so
libwx_gtk2d_adv-2.8.so libwx_gtk2d_richtext-2.8.so.0
libwx_gtk2d_adv-2.8.so.0 libwx_gtk2d_richtext-2.8.so.0.8.0
libwx_gtk2d_adv-2.8.so.0.8.0 libwx_gtk2d_xrc-2.8.so
libwx_gtk2d_aui-2.8.so libwx_gtk2d_xrc-2.8.so.0
libwx_gtk2d_aui-2.8.so.0 libwx_gtk2d_xrc-2.8.so.0.8.0
libwx_gtk2d_aui-2.8.so.0.8.0 wx
libwx_gtk2d_core-2.8.so
Look at the sys.path and see how the wx folders are ordered. The first one in the list containing a matching ‘wx’ package name will be the one that is imported with “import wx”
import sys, pprint
pprint.pprint(sys.path)
Experiment with setting PYTHONPATH and/or creating .pth files and check how it affects sys.path until you get it to have your desired version of wx first in the list. Another option would be to use virtualenv which would let you have more control over what modules and packages are available to the python in the virtualenv.
import pprint
pprint.pprint(sys.path)
[‘’,
‘/home/workspace/Python_modules’,
‘/opt/wx/2.8/lib’,
‘/usr/lib/python2.7’,
‘/usr/lib/python2.7/plat-linux2’,
‘/usr/lib/python2.7/lib-tk’,
‘/usr/lib/python2.7/lib-old’,
‘/usr/lib/python2.7/lib-dynload’,
‘/usr/local/lib/python2.7/dist-packages’,
‘/usr/lib/python2.7/dist-packages’,
‘/usr/lib/python2.7/dist-packages/PIL’,
‘/usr/lib/python2.7/dist-packages/gst-0.10’,
‘/usr/lib/python2.7/dist-packages/gtk-2.0’,
‘/usr/lib/pymodules/python2.7’,
‘/usr/lib/python2.7/dist-packages/ubuntu-sso-client’,
‘/usr/lib/python2.7/dist-packages/ubuntuone-client’,
‘/usr/lib/python2.7/dist-packages/ubuntuone-control-panel’,
‘/usr/lib/python2.7/dist-packages/ubuntuone-couch’,
‘/usr/lib/python2.7/dist-packages/ubuntuone-installer’,
‘/usr/lib/python2.7/dist-packages/ubuntuone-storage-protocol’,
‘/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode’]
You’ll either need to figure out what is missing on your system that is preventing the configure step from succeeding, or you’ll need to edit build-wxpython.py and build-wxwidgets.py to make building the GLCanvas optional.
which part should I change in attached file for the GLCanvas optional? and I couldn’t find the file “build-wxwidgets.py”
Wonjun, Choi
build-wxpython.py (18.2 KB)