CGAL Installation

Table of Contents

1 Install on FU system

In order to compile CGAL with all its examples and demos (actually only those using Qt4), several additional tweaks have to be done. The following packages are missing on FU's servers:

  • QGLViewer
  • Eigen3

Both are needed for example for the Surface_reconstruction_point_3 demo.

Remark: The instruction given assume the usage of BASH shell.

1.1 Installation Steps

1.1.1 Preliminaries

  1. QGLViewer: Follow the instructions given in the following link, using make option, and remember where your compiled the library. Remark: Don't try sudo make install, you don't have administrator permissions.
  2. Set the environment variable:

    export QGLVIEWERROOT=/absolute/path/to/root/directory/of/QGViewer_library

  3. Eigen3: Download at least version 3.1.0 and extract it somewhere in your $HOME. Again, remember the location of the extraction.
  4. Set the environment variable export EIGEN3_INC_DIR=


Note: The file signature_of_eigen3_matrix_library should be in the directory where you extracted EIGEN3.

1.1.2 Setting CGAL

  1. In your home directory create a directory named CGAL
  2. Download the latest version of CGAL (currently 4.0.2) and extract it there.
  3. Go to the location where your extracted CGAL and run:

    cmake . -DWITH_demos=ON -DWITH_examples=ON. NOTE: You can ignore all the warnings, e.g. GLEW is not needed.

  4. Run make in the CGAL's directory.
  5. Finally, add the environment variable

export CGAL_DIR=/absolute/path/to/where/you/have/built/CGAL/

1.2 Test Installation

We will run two tests, one for an example and one for a demo.

1.2.1 Example test

  1. Go to ./CGAL/examples/Arrangement_on_surface_2/
  2. Run make
  3. Try to run the generated executables.

1.2.2 Demo test

  1. Go to ./CGAL/demos/Surface_reconstruction_points_3/
  2. Run make (might generate warnings which can be ignored)
  3. Run ./Point_set_demo
  4. Try to reconstruct the test point set provided in the data directory.

2 Installing on Mac OSX

2.1 Qt4 installation

Seems like version 4.7.4 which can be downloaded from the archive here is the one needed for CGAL.

2.2 Fix BOOST problem

In the file ./CGAL/cmake/modules/CGAL_SetupBoost.cmake replace

  • find_package( Boost 1.33.1 REQUIRED thread)


  • find_package( Boost 1.33.1 REQUIRED thread system)

Date: 2012-11-06T00:41+0100

Author: Dror Atariah

Org version 7.9.2 with Emacs version 23

Validate XHTML 1.0