• Diff for "C++Compiling"
  • Immutable Page
  • Info
  • Attachments
Differences between revisions 4 and 5
Revision 4 as of 2009-01-20 19:39:39
Size: 3843
Editor: c-67-174-177-80
Comment:
Revision 5 as of 2009-01-20 19:59:47
Size: 4352
Editor: flits102-164
Comment: Slight cleanup (I think)
Deletions are marked like this. Additions are marked like this.
Line 2: Line 2:
This is a preliminary 'rough' guide explaining how to compile and install compiz++ to a non standard prefix. This assumes you are a developer, know exactly what you're doing or do not mind breaking your system. For sake of simplicity we'll assume the prefix /opt/compiz++/ and the source will be contained and built in /usr/local/src/ The dependency list is changing and will be added later. You will need at least cmake, boost devel and git packages installed. Refer to the dep list [[http://wiki.compiz-fusion.org/Installation|here]] to get an idea of what other packages might need to be installed. This is a preliminary 'rough' guide explaining how to compile and install compiz++ to a non standard prefix. This assumes you are a developer, know exactly what you're doing or do not mind breaking your system. For sake of simplicity we'll assume the prefix /opt/compiz++/ and the source will be contained and built in /usr/local/src/ but other paths work too (both paths can be below your home directory if you prefer). Make sure your regular user has write access to the source directory (do not run the build as root). The dependency list is changing and will be added later. You will need at least cmake, boost devel and git packages installed. Refer to the dep list [[http://wiki.compiz-fusion.org/Installation|here]] to get an idea of what other packages might need to be installed.
Line 19: Line 19:
For compizconfig-python and ccsm do this compizconfig-python needs to be rebuilt to work with the development version of libcompizconfig but has no changes specific to compiz++, so there is no compiz++ branch. You can create a local branch if you like, but this is probably not necessary:
Line 22: Line 22:
ccsm does not have (or need) a compiz++ branch either.
Line 48: Line 49:
8) Build compizconfig-python and ccsm 8) Build compizconfig-python and ccsm (building ccsm is probably not required but does not hurt)

Building and Installing Compiz++

This is a preliminary 'rough' guide explaining how to compile and install compiz++ to a non standard prefix. This assumes you are a developer, know exactly what you're doing or do not mind breaking your system. For sake of simplicity we'll assume the prefix /opt/compiz++/ and the source will be contained and built in /usr/local/src/ but other paths work too (both paths can be below your home directory if you prefer). Make sure your regular user has write access to the source directory (do not run the build as root). The dependency list is changing and will be added later. You will need at least cmake, boost devel and git packages installed. Refer to the dep list here to get an idea of what other packages might need to be installed.

Obtain the source

The source code can be downloaded from git. We'll demonstrate how to install compiz, bcop libcompizconfig, compizconfig-python, ccsm and an example plugin in that order. Important notes about cmake: Choose a location in which to store the code that does not contain spaces or any questionable characters. Compiz++ will be built in a different location than where the code is actually contained. After you begin, do not move or rename this directory because it may cause future problems when updating or uninstalling. That said, here we go.

1) Grab the source using git

mkdir -p /usr/local/src/compiz; cd /usr/local/src/compiz
git clone git://anongit.freedesktop.org/git/xorg/app/compiz compiz++
git clone git://anongit.compiz-fusion.org/fusion/libraries/bcop bcop++
git clone git://anongit.compiz-fusion.org/fusion/compizconfig/libcompizconfig libcompizconfig++
git clone git://anongit.compiz-fusion.org/fusion/compizconfig/compizconfig-python compizconfig-python++
git clone git://anongit.compiz-fusion.org/fusion/compizconfig/ccsm ccsm++

2) You must switch to the compiz++ branch for each repo you clone. From each directory do the following

git checkout -b compiz++ --track origin/compiz++

compizconfig-python needs to be rebuilt to work with the development version of libcompizconfig but has no changes specific to compiz++, so there is no compiz++ branch. You can create a local branch if you like, but this is probably not necessary:

git checkout -b compiz++ --track

ccsm does not have (or need) a compiz++ branch either. 3) Create a directory in which to build the source and run cmake

mkdir -p /usr/local/src/compiz/compiz_build; cd /usr/local/src/compiz/compiz_build
cmake -DCMAKE_INSTALL_PREFIX=/opt/compiz++ /usr/local/src/compiz/compiz++

4) After cmake succeeds (meaning all dependencies were met) compile and install

make
sudo make install

5) Build and install bcop

cd /usr/local/src/compiz/bcop++
./autogen.sh --prefix=/opt/compiz++
./configure --prefix=/opt/compiz++
make
sudo make install

6) Now that compiz and bcop are installed, we'll set some environment variables so we can build libcompizconfig and other components

export LD_LIBRARY_PATH=/opt/compiz++/lib/
export PKG_CONFIG_PATH=/opt/compiz++/lib/pkgconfig:/opt/compiz++/share/pkgconfig

7) Build and install libcompizconfig

cd /usr/local/src/compiz/libcompizconfig++
./autogen.sh --prefix=/opt/compiz++
./configure --prefix=/opt/compiz++
make
sudo make install

8) Build compizconfig-python and ccsm (building ccsm is probably not required but does not hurt)

cd /usr/local/src/compiz/compizconfig-python++
./autogen.sh --prefix=/opt/compiz++
./configure --prefix=/opt/compiz++
make
sudo make install
cd /usr/local/src/compiz/ccsm++
sudo python setup.py install --prefix=/opt/compiz++

9) Build any additional plugins alternatively setting BUILD_GLOBAL and installing as root to install into PREFIX as opposed to ~/.compiz

mkdir -p /usr/local/src/compiz/plugins; cd /usr/local/src/compiz/plugins
git clone git://git.compiz-fusion.org/users/smspillaz/example example
cd example
git checkout -b compiz++ --track
make
BUILD_GLOBAL=true sudo -E make install

10) Run compiz and ccsm

LD_LIBRARY_PATH=/opt/compiz++/lib/ /opt/compiz++/bin/compiz --replace ccp
PYTHONPATH=/opt/compiz++/lib/python2.5/site-packages /opt/compiz++/bin/ccsm


C++Compiling (last edited 2012-06-27 00:20:55 by modemcable088)