Cgal version 3.5 - How to Download and Install on Mac OS X
Saturday the 21st of November, 2009

    version 3.5

      View the most recent changes for the cgal port at: cgal.darwinports.com/diff
      Scroll down toward the bottom of the page to get installation instructions for cgal.
      The raw portfile for cgal 3.5 is located here:
      http://cgal.darwinports.com/dports/gis/cgal/Portfile
      Find related portfiles with the unique DarwinPorts.com search feature.
      Check for any related Fink projects here: pdb.finkproject.org/pdb/package.php/cgal


      # -*- coding: utf-8; mode: tcl; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=2:ts=2:sts=2

      PortSystem 1.0

      Name: cgal
      Version: 3.5
      license LGPL - QPL
      Category: gis science
      Maintainers: vince
      Description: Computational Geometry Algorithm Library
      Long Description: The goal of the CGAL is to provide easy access to efficient and reliable geometric algorithms in the form of a C++ library. CGAL is used in various areas needing geometric computation, such as: computer graphics, scientific visualization, computer aided design and modeling, geographic information systems, molecular biology, medical imaging, robotics and motion planning, mesh generation, numerical methods...

      Platform: darwin
      Homepage: http://www.cgal.org/
      Master Sites: http://gforge.inria.fr/frs/download.php/24197
      distname ${name}-${version}

      Checksums: md5 c14d142780d07e3d05dea2f54dd7ae53 sha1 4b0f7ce3123ebcea3aca14cab6f1baaafc80e48d rmd160 6af203a21dae84e41b59e5d581eaca259e7c307e

      depends_lib port:cmake
      depends_lib-append port:boost port:mpfr

      configure.cmd cmake .

      # Configuration
      # Start with no configure arguments: override defaults
      configure.pre_args
      configure.args
      configure.cflags
      configure.cxxflags

      configure.args-append -DCMAKE_INSTALL_PREFIX=${prefix}
      configure.args-append -DCMAKE_BUILD_TYPE=Release
      configure.args-append -DBUILD_SHARED_LIBS=TRUE
      configure.args-append -DCMAKE_C_COMPILER=${configure.cc}
      configure.args-append -DCMAKE_CXX_COMPILER=${configure.cxx}

      Variant: universal {
      configure.universal_args-delete --disable-dependency-tracking
      configure.args-append -DCGAL_CXX_FLAGS=${configure.universal_args}
      configure.args-append -DCGAL_MODULE_LINKER_FLAGS=${configure.universal_args}
      configure.args-append -DCGAL_SHARED_LINKER_FLAGS=${configure.universal_args}
      configure.args-append -DCGAL_EXE_LINKER_FLAGS=${configure.universal_args}

      configure.universal_args
      }

      Variant: demos {
      depends_lib-append port:qt4-mac

      configure.args-append -DWITH_examples=TRUE
      configure.args-append -DWITH_demos=TRUE
      }

      build.target

      post-build {
      system "find ${worksrcpath} -name '*.dylib' -exec install_name_tool -change ${worksrcpath}/lib/libCGAL.4.dylib ${prefix}/lib/libCGAL.4.dylib {} \\;"
      }

    If you haven't already installed Darwin Ports, you can find easy instructions for doing so at the main Darwin Ports page.

    Once Darwin Ports has been installed, in a terminal window and while online, type the following and hit return:


      %  cd /opt/local/bin/portslocation/dports/cgal
      % sudo port install cgal
      Password:
    You will then be prompted for your root password, which you should enter. You may have to wait for a few minutes while the software is retrieved from the network and installed for you. Y ou should see something that looks similar to:

      ---> Fetching cgal
      ---> Verifying checksum for cgal
      ---> Extracting cgal
      ---> Configuring cgal
      ---> Building cgal with target all
      ---> Staging cgal into destroot
      ---> Installing cgal
    - Make sure that you do not close the terminal window while Darwin Ports is working. Once the software has been installed, you can find further information about using cgal with these commands:
      %  man cgal
      % apropos cgal
      % which cgal
      % locate cgal

     Where to find more information:

    Darwin Ports



    Lightbox this page.