dolfin compilation issues caused by CGAL

Asked by andrés León Baldelli on 2013-03-30

Hi,
I'm having troubles compiling dolfin on a darwin12. I'm using the basic set of packages as of mountainlion.platform file.
During compile I have an error coming from CGAL, which however passes CGAL_TEST_RUNS successfully. CGAL is linked to macport's gmp and mpfr libraries.

-- Checking for package 'CGAL'
-- Performing Test CGAL_TEST_RUNS
-- Performing Test CGAL_TEST_RUNS - Success
-- Found CGAL: /opt/HPC/FEniCS/tao/lib/libCGAL.dylib;/opt/local/lib/libboost_thread-mt.dylib;/opt/local/lib/libboost_system-mt.dylib;/usr/local/lib/libgmp.a;/usr/local/lib/libmpfr.a (Required is at least version "4.1")

The relevant part of dolfin_build.log is:

1 error generated.
make[2]: *** [dolfin/CMakeFiles/dolfin.dir/generation/Triangulate.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /opt/HPC/FEniCS/src/tao/dolfin/generation/CSGCGALMeshGenerator3D.cpp:26:
In file included from /opt/HPC/FEniCS/src/tao/dolfin/generation/GeometryToCGALConverter.h:30:
In file included from /opt/HPC/FEniCS/src/tao/dolfin/generation/cgal_csg3d.h:17:
In file included from /opt/HPC/FEniCS/tao/include/CGAL/Mesh_triangulation_3.h:27:
In file included from /opt/HPC/FEniCS/tao/include/CGAL/Regular_triangulation_3.h:30:
In file included from /opt/HPC/FEniCS/tao/include/CGAL/Triangulation_3.h:37:
In file included from /opt/HPC/FEniCS/tao/include/CGAL/Triangulation_data_structure_3.h:45:
/opt/HPC/FEniCS/tao/include/CGAL/Triangulation_ds_cell_base_3.h:51:7: error: array initializer must be an initializer list
    : V((Vertex_handle[4]) {v0, v1, v2, v3} ) {}
      ^

Do you have any advice?
Some help would be much appreciated

Cheers,
Andrés

Question information

Language:
English Edit question
Status:
Answered
For:
DOLFIN Edit question
Assignee:
No assignee Edit question
Last query:
2013-03-30
Last reply:
2013-04-03

Hi Andrés,

It looks like the version of CGAL that is installed on your system is too old. As the installer says: Required is at least version "4.1".

For me, downloading and compiling CGAL was a breeze. Just go to http://www.cgal.org/download.html and build the library. Then use -DCGAL_DIR=/path/to/the/new/CGAL as an option to CMake when you are compiling Dolfin.

Johannes Ring (johannr) said : #2

If you have the latest development version of Dorsal, you should get CGAL 4.1 by default.

Can you help with this problem?

Provide an answer of your own, or ask andrés León Baldelli for more information if necessary.

To post a message you must log in.