This page contains more detailed instructions to compile a full-featured version of Gmsh, including the compilation of common dependencies: OpenCASCADE (https://www.opencascade.com/content/latest-release) and FLTK (http://www.fltk.org). In addition to CMake and C++ compiler, you should have (preferably optimized) versions of the BLAS and LAPACK libraries on your system (e.g. OpenBLAS, ATLAS or the MKL).
OpenCASCADE is a free CAD kernel that Gmsh uses extensively for constructive solid geometry and for importing STEP files. To compile OpenCASCADE, download and uncompress the sources from the official site, then (here for occt 7.1.0):
cd opencascade-7.1.0 mkdir build cd build cmake -DCMAKE_BUILD_TYPE=Release -DBUILD_MODULE_Draw=0 -DBUILD_MODULE_Visualization=0 -DBUILD_MODULE_ApplicationFramework=0 .. make install
Gmsh's default graphical user interface used the FLTK widget toolkit. To compile FLTK:
svn co http://seriss.com/public/fltk/fltk/branches/branch-1.3/ fltk-1.3 cd fltk-1.3 make install
You can then compile Gmsh as follows:
git clone http://gitlab.onelab.info/gmsh/gmsh.git cd gmsh mkdir build cd build cmake .. make