Build PyCEGUI from source for Linux
From CEGUI Wiki - Crazy Eddie's GUI System (Open Source)
Written for CEGUI 0.7
Works with versions 0.7.x (obsolete)
Requires at least version
0.7.4
Ubuntu 11.04
Version shipped in repositories is 6.0 so if we want 7.x we need to build it from source.
- Install dependency packages:
sudo apt-get install build-essential pkg-config python-dev libfreetype6-dev libpcre3-dev libboost-python-dev libglut3-dev libpng-dev libmng-dev libjpeg-dev libfreeimage-dev
- Obtain a copy of CEGUI here
- Extract to a folder
- Before we build, we have to symlink the site-packages directory correctly, so it installs to the correct place.
sudo rmdir /usr/local/lib/python2.6/site-packages sudo ln -s /usr/local/lib/python2.6/dist-packages/ /usr/local/lib/python2.6/site-packages
- Build CEGUI with python support
./configure && make && sudo make install && sudo ldconfig
- Note: On some Ubuntu systems it seems that CEGUI's configure system does not correctly detect the Python headers. To solve this, do the following:
export CXXFLAGS=-I/usr/include/python2.6 ./configure && make && sudo make install && sudo ldconfig
Still not working?
You can try running your program with:
PYTHONPATH="/usr/local/lib/python2.7/site-packages:$PYTHONPATH" python <file.py>
Note for Panda3D users You can run your program at the same way, using:
PYTHONPATH="/usr/local/lib/python2.7/site-packages:$PYTHONPATH" ppython <file.py>