For Linux (ubuntu)
- Install boost. Go to http://boost.org/ to check the newest version available. The newest version as of feb,2008 is 1.34.1.
- Open a terminal and input
sudo apt-get install libboost.*-dev libboost-doc libboost.*1.34.1
- Boost is installed in a standard location and should be found by CGAL installation program automatically.
- Download latest CGAL from this link.
- Decompress the downloaded file by inputting
sudo tar xfv CGAL-3.3.1.tar.gz
- Go to the directory CGAL-3.3.1 and input ./install_cgal -i. -i for interactive mode.
- Input T for testing the setup. After the testing, the boost you just installed should appear on the the support for menu.
- Type B to build the CGAL library. If you h sudo apt-get install libmpfr-devave error message, like “Compilation of libCGAL static failed”, check the install.log file. That is probably due to the missing of MPFR or GMP. Below are the commands to install them respectively.
sudo apt-get install libgmp3-dev
sudo apt-get install libmpfr-dev
After you install MPFR or GMP, go to the main menu and input S -> 7 or 5 -> 0 to auto find the library. If library is installed correctly, it should appear on the the support for: on the main menu along with other library like BOOST.
- If you prefer to install CGAL into other directory, Press I and then D to change the installation directory to any director you want, for example, /usr/local/CGAL. Then press I again to let the installer to copy all include/lib/exe files to the designated directory.
- If you have problem creating directory in step 9. Just exit the installer and input the command
./install_cgal –prefix /usr/local/CGAL -i.
Then under the main men, press I and install root directory defined by the –prefix parameter should be changed to /usr/local/CGAL. You don’t need to press D to change the install root directory again. Simply press I, the installer should work fine and all required files will be copied to the designated directory.
- DONE! 🙂