A course has just started on coursera.org that uses vpython as a software tool.
It appears openSUSE 12.3 does not provide a package for this - the closest appears to be mayavi.
Source files for vpython are available, requiring boost as one of the dependencies.
During the python setup.py build I get this error:
/usr/lib64/gcc/x86_64-suse-linux/4.7/../../../../x86_64-suse-linux/bin/ld: cannot find -lboost_python-mt-py27
collect2: error: ld returned 1 exit status
On 2013-08-19, colbec <colbec@no-mx.forums.opensuse.org> wrote:
> It appears openSUSE 12.3 does not provide a package for this - the
> closest appears to be mayavi.
I couldn’t make mayavi work… but that’s probably just me. I haven’t tried vpython myself either and have given up with
Python and 3D because of the ever-changing and unstable package depencies (and distutils is a rubbish package deployment
method that’s bound to fail with different distros).
> Source files for vpython are available, requiring boost as one of the
> dependencies.
> During the python setup.py build I get this error:
>
>
> Code:
> --------------------
> /usr/lib64/gcc/x86_64-suse-linux/4.7/…/…/…/…/x86_64-suse-linux/bin/ld: cannot find -lboost_python-mt-py27
> collect2: error: ld returned 1 exit status
> --------------------
> <SNIP>
Have you installed the Boost::Python runtime libraries ?
sh-4.2$ sudo zypper in libboost_python1_49_0
sh-4.2$
According to the (rather Debian-centric) INSTALL.txt file that comes with the download you also need (before `python setup.py
install’) to do:
sh-4.2$ sudo zypper in gtk2-devel freeglut-devel gstreamer-0_10-devel gstreamer-0_10-plugins-base-devel python-devel
sh-4.2$
but it looks sloppily written so it wouldn’t surprise me if there are any more (undocumented) pre-requisites.
Yes all the boost stuff should be in there, but there is only the one boost_python so provided in Yast.
I also checked the pre-requisites on the line you noted, they are all properly in place. But as you guessed there were other dependencies to work through, gtkglextmm being one difficult pain to resolve. I took a chance and installed a build from 12.2 Education rep. At least the build starts now, but as noted I can’t get it past the boost error.
On 2013-08-19, colbec <colbec@no-mx.forums.opensuse.org> wrote:
> I also checked the pre-requisites on the line you noted, they are all
> properly in place. But as you guessed there were other dependencies to
> work through, gtkglextmm being one difficult pain to resolve. I took a
> chance and installed a build from 12.2 Education rep. At least the build
> starts now, but as noted I can’t get it past the boost error.
It may be a versioning issue. Quick stupid question first: obviously you are using Python 2.7 and not 3.x? I don’t have
a 12.2 box to hand but if they tested it on openSUSE12.2, their build might work with it.
If you really need vpython I see three options for you:
Try it on openSUSE 12.2 on a different partition/virtual machine.
Try it on another distro on a different partition/virtual machine.
Try contacting the vpython mailing list (they have one) and see if they can help.
Not helpful I know. You might repost this issue to the openSUSE programming/scripting subforum in case there are any
Boost specialists who might be able to help you. I avoid Boost like the plague because I find it sucks bigtime!
Yes, I have both python 2.7 and 3.x installed and working fine. I’m using 2.7 to work with vpython.
I recompiled boost on my machine but it did not offer me anything like boost_python-mt-py27.
It’s not worth going to the lengths of virtual OS just to get this installed. It should work under my 12.3 otherwise it is not worth launching myself down that road.
Good suggestion about the list. The old list is now discontinued but there is a Google groups forum. I have posted an enquiry.
OK a bit of progress here.
My error in omitting the “.so” at the end of my symlink. This allowed the linking at the end of the compile to proceed correctly.
The GUI vidle now runs and loads a module, but running the module fails.
Selecting many of the test modules in the examples directory and the course provided test routine results in:
Traceback (most recent call last):
File "/home/colin/Downloads/lab1start/lab1start.py", line 3
from visual import *
File "/home/colin/Downloads/vpython-wx-6.05/build/lib.linux-x86_64-2.7/visual/__init__.py", line 33
from visual.visual_all import * # this statement not included in vis/__init__.py
File "/home/colin/Downloads/vpython-wx-6.05/build/lib.linux-x86_64-2.7/visual/visual_all.py", line 10
from visual_common.cvisual import vector
ImportError: /usr/lib64/libgdkglextmm-x11-1.2.so.0: undefined symbol: gdk_gl_draw_icosahedron
I’m pretty sure the gkglext are fresh, I have recompiled from source a few times. But draw_icosahedron remains a puzzle.
On 2013-08-20, colbec <colbec@no-mx.forums.opensuse.org> wrote:
> I’m pretty sure the gkglext are fresh, I have recompiled from source
> a few times. But draw_icosahedron remains a puzzle.
Looks like more GTK-based dependencies (and potentially obsolete ones). Is there any possibility of switching to vpython-wx?
I think that is what I am working with, version 6.05.
This whole experience has me wondering about the wisdom of the selection of software tools in this course. Coursera prides itself on being globally accessible at no or very little cost even in developing countries, which often means choosing a distro of Linux. The course installation instructions seem to be entirely Windows dependent.
On 2013-08-20, colbec <colbec@no-mx.forums.opensuse.org> wrote:
> This whole experience has me wondering about the wisdom of the
> selection of software tools in this course. Coursera prides itself on
> being globally accessible at no or very little cost even in developing
> countries, which often means choosing a distro of Linux. The course
> installation instructions seem to be entirely Windows dependent.
If you want a highly portable Python API with a thin wrapper around OpenGL, then I’d recommend having a look at pyglet.