Mousetrap Installation Guide

This guide is intended to explain how to install the MouseTrap code found in the git repository.


The MouseTrap direct dependencies are:





>= 2.12

The GTK+ Toolkit


>= 2.8.4

GTK+ Python bindings


>= 2.6

Python platform


>= 1.0

Open Computer Vision Library


>= 0.13

Python Xlib library (just in case user doesn't use gnome)


>= 0.6

Python AT-SPI bindings


>= 1.5

A documentation system for C++, C, Java, IDL and PHP (this package is required for building the documentation)

NOTE: Each dependency may require other dependencies to be installed.

Pre-installation Requirements

Install Git. Git is a distributed version control system. You will need it to get, compile, and run the source code for Mousetrap.

$ sudo apt-get install git-core

Use git to clone the repository on your local machine.

$ git clone git://


Navigate to the directory where you cloned the repository and run the following command to begin installation:

$ ./

If you run into errors, see the section entitled “Troubleshooting.” Next you need to compile the source code. To do this, run the following command:

$ make

Once this completes, you will need to install Mousetrap with the following command:

$ sudo make install

It is possible to modify the installation path using --prefix=/non/standard/path. After installing, you can run the program by typing:

$ mousetrap


These problems occur in Ubuntu 9.04 but may also appear in other distributions.



You need to install gnome-common from the GNOME CVS

$ sudo apt-get install gnome-common

***Error***: You must have glib-gettext >= 2.2.0 installed to build mouseTrap.

$ sudo apt-get install libglib2.0-dev

configure: error: Could not find python headers needed to build Python extensions

$ sudo apt-get install python2.6-dev

configure: error: Could not find python module Xlib

$ sudo apt-get install python-xlib

configure: error: Could not find python module opencv

$ sudo apt-get install python-opencv


There's not a first run configuration wizard nor a text console based one, yet. To configure MouseTrap it is necessary to execute MouseTrap and it will create the configuration file automatically.

$ mouseTrap



To enable the compilation for the developers documentation it is necessary to use this 2 flags --enable-pydoc --enable-doxygen in the ./

The developer's documentation is available using using pydoc or doxygen.

Final Users

To generate the final users documentation it is necessary to set this flag --enable-docbook in the ./ command. After running make there will be some .html files in the docs/docbook/ folder, open the index.html to see the main page.

Projects/MouseTrap/Installation (last edited 2013-11-22 15:20:57 by WilliamJonMcCann)