PyVrui is a Python wrapper for the Vrui library, using the Py++ code generator. This allows Cave applications to be written in the Python language instead of C++.
The repository is located at https://vcs.cse.ucdavis.edu/svn/PyVrui and has anonymous read-only access. Cave developers can commit changes using their campus Kerberos login.
In July 2011, Ed and Dawn worked on installing PyVrui and PyBullet on Dawn's OS 10.6.8 Here's how we successfully got them to run with a few comments. Instructions for installing PyVrui on Linux can be found here.
We first tried to build them against Enthought Python Distribution with Boost that Dawn had installed for Mycelia. We had a variety of problems and decided to use the system python and the version of Boost that Ed had used. However, there were other issues with Dawn's computer including some architecture issues and a gccxml installation with a xml parser but. It may be that these problems were the cause of all of the errors and the build may work against EPD and other versions of Boost. However, we did not test this. Also, in an attempt to fix the xml error, Dawn installed Xcode v4. This should not be necessary, but I've mentioned it here for completeness.
Some of the steps are in a required order and some are not.
Boost is a very sensitive software package, with many interface dependencies. It has to be built against the right python to work. If it isn't, a huge number of case call (I think that's what Ed called them) errors are thrown and have to be dealt with.
Prerequisites: ( pyvrui_prereqs.zip with the following packages, 134 MB)
cmake 2.6 or later #Dawn already had, but in the pyvrui_preqs folder Boost 1.36 or later Vrui 1-68 gccxml pygccxml-1.0.0 pyplusplus-1.0.0 #patched version of Py++ from Ed PyOpenGL
Unpack these tar/zip packages into ~/src (skipped cmake because Dawn has it):
bullet-2.75.tgz gccxml.tgz pybullet.tgz pygccxml-1.0.0.zip pyplusplus-1.0.0.zip PyOpenGL-3.0.1.tar.gz pyVrui.tgz
cd ~/src/PyOpenGL-3.0.1 python setup.py install
cd ~/src mkdir gccxml_build cd gccxml_build cmake ../gccxml make sudo make install
cd ~/src/Py++-1.0.0 python setup.py install
cd ~/src/pygcc-1.0.0 python setup.py install
cd ~/src/pypputils python setup.py install
cd ~/src/boost ./bootstrap.sh #- configures boost with knowledge of the darwin architecture ./bjam sudo ./bjam install
Makefile changes: #will vary if not using the system python
cd ~/src ln -s Vrui-1.0-068/ Vrui-1.0 #- Makes a link in ~/src to the current version of Vrui (or could change the Makefile) cp ~/src/pyvrui_prereqs/pyVrui_headers.h ~/src/Vrui-1.0-068 cp ~/src/pyvrui_prereqs/Vrui-1.0.068_Math_Constants.h ~/src/Vrui-1.0-068/Math/Constants.h cp ~/src/pyvrui_prereqs/Vrui-1.0-068_SceneGraph_GeometryNode.h ~/src/Vrui-1.0-068/SceneGraph/GeometryNode.h #- adds a definition that was left out cd ~/src/pyVrui make make install
OSX:
cd ~/src/bullet-2.75 cmake -DBUILD_SHARED_LIBS=ON -DFRAMEWORK=ON -DCMAKE_INSTALL_PREFIX=~/Library/Frameworks -DCMAKE_INSTALL_NAME_DIR=~/Library/Frameworks -DCMAKE_OSX_ARCHITECTURES='ppc;i386;x86_64' -DCMAKE_BUILD_TYPE=RelWithDebugInfo make make install
Building bullet on Ubuntu Linux: (didn’t test on Dawn’s computer…)
apt-get install freeglut3-dev cmake -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=RelWithDebugInfo make sudo make install
Both
cd bullet-2.75/Demos make
Makefile changes: #will vary if not using the system python
make make install