Compilation error

Asked by Lingran Zhang on 2020-02-07

Hi all,

I got this error message at 67% Yade compilation on Debian 10. The code was modified from trunk sometimes ago, but earlier the same code was able to be installed on Ubuntu 16.04.

Here is the error:

[ 65%] Building CXX object CMakeFiles/yade.dir/pkg/dem/TriaxialCompressionEngine.cpp.o
In file included from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/ndarraytypes.h:1822,
                 from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/ndarrayobject.h:12,
                 from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/arrayobject.h:4,
                 from /home/mohammay/Documents/yadeInstall/trunkModify/lib/pyutil/numpy_boost.hpp:40,
                 from /home/mohammay/Documents/yadeInstall/trunkModify/pkg/dem/TesselationWrapper.cpp:15:
/usr/lib/python2.7/dist-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: #warning "Using deprecated NumPy API, disable it with " "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
 #warning "Using deprecated NumPy API, disable it with " \
  ^~~~~~~
[ 66%] Building CXX object CMakeFiles/yade.dir/pkg/dem/TriaxialStateRecorder.cpp.o
[ 66%] Building CXX object CMakeFiles/yade.dir/pkg/dem/TriaxialStressController.cpp.o
In file included from /home/mohammay/Documents/yadeInstall/trunkModify/lib/triangulation/Tesselation.h:202,
                 from /home/mohammay/Documents/yadeInstall/trunkModify/pkg/dem/TesselationWrapper.hpp:15,
                 from /home/mohammay/Documents/yadeInstall/trunkModify/pkg/dem/TesselationWrapper.cpp:12:
/home/mohammay/Documents/yadeInstall/trunkModify/lib/triangulation/Tesselation.ipp: In instantiation of ‘CGT::_Tesselation<TT>::VertexHandle CGT::_Tesselation<TT>::move(CGT::Real, CGT::Real, CGT::Real, CGT::Real, unsigned int) [with TT = CGT::TriangulationTypes<CGT::SimpleVertexInfo, CGT::SimpleCellInfo>; CGT::_Tesselation<TT>::VertexHandle = CGAL::internal::CC_iterator<CGAL::Compact_container<CGAL::Alpha_shape_vertex_base_3<CGAL::Epick, CGAL::Triangulation_vertex_base_with_info_3<CGT::SimpleVertexInfo, CGAL::Epick, CGAL::Regular_triangulation_vertex_base_3<CGAL::Epick, CGAL::Triangulation_ds_vertex_base_3<CGAL::Triangulation_data_structure_3<CGAL::Alpha_shape_vertex_base_3<CGAL::Epick, CGAL::Triangulation_vertex_base_with_info_3<CGT::SimpleVertexInfo, CGAL::Epick, CGAL::Regular_triangulation_vertex_base_3<CGAL::Epick> >, CGAL::Boolean_tag<false>, CGAL::Boolean_tag<false> >, CGAL::Alpha_shape_cell_base_3<CGAL::Epick, CGAL::Triangulation_cell_base_with_info_3<CGT::SimpleCellInfo, CGAL::Epick, CGAL::Regular_triangulation_cell_base_3<CGAL::Epick> >, CGAL::Boolean_tag<false>, CGAL::Boolean_tag<false> >, CGAL::Sequential_tag> > > >, CGAL::Boolean_tag<false>, CGAL::Boolean_tag<false> >, CGAL::Default, CGAL::Default, CGAL::Default>, false>; CGT::Real = double]’:
/home/mohammay/Documents/yadeInstall/trunkModify/pkg/dem/TesselationWrapper.cpp:186:28: required from here
/home/mohammay/Documents/yadeInstall/trunkModify/lib/triangulation/Tesselation.ipp:78:12: error: ‘CGT::_Tesselation<CGT::TriangulationTypes<CGT::SimpleVertexInfo, CGT::SimpleCellInfo> >::RTriangulation’ {aka ‘class CGAL::Regular_triangulation_3<CGAL::Epick, CGAL::Triangulation_data_structure_3<CGAL::Alpha_shape_vertex_base_3<CGAL::Epick, CGAL::Triangulation_vertex_base_with_info_3<CGT::SimpleVertexInfo, CGAL::Epick, CGAL::Regular_triangulation_vertex_base_3<CGAL::Epick> >, CGAL::Boolean_tag<false>, CGAL::Boolean_tag<false> >, CGAL::Alpha_shape_cell_base_3<CGAL::Epick, CGAL::Triangulation_cell_base_with_info_3<CGT::SimpleCellInfo, CGAL::Epick, CGAL::Regular_triangulation_cell_base_3<CGAL::Epick> >, CGAL::Boolean_tag<false>, CGAL::Boolean_tag<false> >, CGAL::Sequential_tag>, CGAL::Default>’} has no member named ‘move_point’; did you mean ‘Bare_point’?
  Vh = Tri->move_point ( vertexHandles[id], Sphere ( Point ( x,y,z ),pow ( rad,2 ) ) );
       ~~~~~^~~~~~~~~~
       Bare_point
[ 67%] Building CXX object CMakeFiles/yade.dir/pkg/dem/TriaxialTest.cpp.o
In file included from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/ndarrayobject.h:21,
                 from /usr/lib/python2.7/dist-packages/numpy/core/include/numpy/arrayobject.h:4,
                 from /home/mohammay/Documents/yadeInstall/trunkModify/lib/pyutil/numpy_boost.hpp:40,
                 from /home/mohammay/Documents/yadeInstall/trunkModify/pkg/dem/TesselationWrapper.cpp:15:
/usr/lib/python2.7/dist-packages/numpy/core/include/numpy/__multiarray_api.h:1463:1: warning: ‘int _import_array()’ defined but not used [-Wunused-function]
 _import_array(void)
 ^~~~~~~~~~~~~
make[2]: *** [CMakeFiles/yade.dir/build.make:1493: CMakeFiles/yade.dir/pkg/dem/TesselationWrapper.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [CMakeFiles/Makefile2:145: CMakeFiles/yade.dir/all] Error 2
make: *** [Makefile:130: all] Error 2

Here is the cmake information:

-- The C compiler identification is GNU 8.3.0
-- The CXX compiler identification is GNU 8.3.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found PythonInterp: /usr/bin/python (found version "2.7.16")
-- Found OpenMP_C: -fopenmp (found version "4.5")
-- Found OpenMP_CXX: -fopenmp (found version "4.5")
-- Found OpenMP: TRUE (found version "4.5")
qmake: could not exec '/usr/lib/x86_64-linux-gnu/qt4/bin/qmake': No such file or directory
-- Found unsuitable Qt version "" from NOTFOUND
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29")
-- Version is set to Unknown
CMake Warning (dev) at /usr/share/cmake-3.13/Modules/FindOpenGL.cmake:270 (message):
  Policy CMP0072 is not set: FindOpenGL prefers GLVND by default when
  available. Run "cmake --help-policy CMP0072" for policy details. Use the
  cmake_policy command to set the policy and suppress this warning.

  FindOpenGL found both a legacy GL library:

    OPENGL_gl_LIBRARY: /usr/lib/x86_64-linux-gnu/libGL.so

  and GLVND libraries for OpenGL and GLX:

    OPENGL_opengl_LIBRARY: /usr/lib/x86_64-linux-gnu/libOpenGL.so
    OPENGL_glx_LIBRARY: /usr/lib/x86_64-linux-gnu/libGLX.so

  OpenGL_GL_PREFERENCE has not been set to "GLVND" or "LEGACY", so for
  compatibility with CMake 3.10 and below the legacy GL library will be used.
Call Stack (most recent call first):
  CMakeLists.txt:41 (INCLUDE)
This warning is for project developers. Use -Wno-dev to suppress it.

-- Found OpenGL: /usr/lib/x86_64-linux-gnu/libOpenGL.so
-- GTS using gts-config /usr/bin/gts-config
-- Using GTS from /usr
-- Found GL2PS: /usr/lib/x86_64-linux-gnu/libgl2ps.so
-- Found CGAL: /usr/include, /usr/lib/x86_64-linux-gnu/libCGAL.so
-- Found NumPy: version "1.16.2" /usr/lib/python2.7/dist-packages/numpy/core/include
-- Found Loki: /usr/include
-- GCC Version >= 4.8. Adding -ftrack-macro-expansion=0
-- GCC Version >= 4.8. Adding -save-temps
-- GCC Version >= 4.9. Adding -fstack-protector-strong
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Boost version: 1.67.0
-- Found the following Boost libraries:
-- python
-- thread
-- filesystem
-- iostreams
-- regex
-- serialization
-- system
-- date_time
-- chrono
-- atomic
-- Boost_VERSION: 106700
-- Boost_LIB_VERSION: 1_67
-- Boost_INCLUDE_DIRS: /usr/include
-- Boost_LIBRARIES: /usr/lib/x86_64-linux-gnu/libboost_python.so/usr/lib/x86_64-linux-gnu/libboost_thread.so-lpthread/usr/lib/x86_64-linux-gnu/libboost_filesystem.so/usr/lib/x86_64-linux-gnu/libboost_iostreams.so/usr/lib/x86_64-linux-gnu/libboost_regex.so/usr/lib/x86_64-linux-gnu/libboost_serialization.so/usr/lib/x86_64-linux-gnu/libboost_system.so/usr/lib/x86_64-linux-gnu/libboost_date_time.so/usr/lib/x86_64-linux-gnu/libboost_chrono.so/usr/lib/x86_64-linux-gnu/libboost_atomic.so
-- Found Eigen3: /usr/include/eigen3 (Required is at least version "2.91.0")
-- Found BZip2: /usr/lib/x86_64-linux-gnu/libbz2.so (found version "1.0.6")
-- Looking for BZ2_bzCompressInit
-- Looking for BZ2_bzCompressInit - found
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.11")
-- Found PythonLibs: /usr/lib/x86_64-linux-gnu/libpython2.7.so (found version "2.7.16")
-- Found Eigen3, version: 3.3.7
-- Disable vectorization
-- The imported target "vtkRenderingPythonTkWidgets" references the file
   "/usr/lib/x86_64-linux-gnu/libvtkRenderingPythonTkWidgets.so"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/cmake/vtk-6.3/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtk" references the file
   "/usr/bin/vtk"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/cmake/vtk-6.3/VTKTargets.cmake"
but not all the files it references.

-- Found VTK
-- Found OpenMP_C: -fopenmp (found version "4.5")
-- Found OpenMP_CXX: -fopenmp (found version "4.5")
-- Found OpenMP
-- GTS using gts-config /usr/bin/gts-config
-- Using GTS from /usr
-- Checking for one of the modules 'glib-2.0'
-- Found GLib2: glib-2.0 /usr/include/glib-2.0;/usr/lib/x86_64-linux-gnu/glib-2.0/include
-- Looking for include file glib/gregex.h
-- Looking for include file glib/gregex.h - not found
-- Found GTS
-- Found GLUT: /usr/lib/x86_64-linux-gnu/libglut.so
-- USE QT5
-- Found QGLVIEWER-qt5: /usr/include/QGLViewer
-- Found GUI-Qt5-LIBS
-- GMP libs: /usr/lib/x86_64-linux-gnu/libgmp.so /usr/lib/x86_64-linux-gnu/libgmpxx.so
-- Found GMP: /usr/include/x86_64-linux-gnu
-- GMP libs: /usr/lib/x86_64-linux-gnu/libgmp.so /usr/lib/x86_64-linux-gnu/libgmpxx.so
-- Found CGAL
-- SuiteSparse version 5.4.0 found, CHOLMOD direct solver for CPU activated.
-- Found Cholmod: /usr/lib/x86_64-linux-gnu/libcholmod.so
-- Found OpenBlas: /usr/lib/x86_64-linux-gnu/libopenblas.so
-- Found Metis: /usr/include
-- Found Cholmod in /usr/lib/x86_64-linux-gnu/libcholmod.so
-- Found OpenBlas in /usr/lib/x86_64-linux-gnu/libopenblas.so
-- Found Metis in /usr/lib/x86_64-linux-gnu/libmetis.so
-- Found GL2PS
LBMFLOW is still experimental, building and running LBM engine are at your own risk!
Yade will be installed to /home/mohammay/Documents/yadeInstall/install
-- Suffix is set to -Unknown
-- LIBRARY_OUTPUT_PATH is set to lib/x86_64-linux-gnu
-- runtimePREFIX is set to /home/mohammay/Documents/yadeInstall/install
-- Found gts: /usr/lib/python2.7/dist-packages/gts
-- Use system gts version
-- Found minieigen: /usr/lib/python2.7/dist-packages/minieigen.so
-- Found Tkinter: /usr/lib/python2.7/lib-tk/Tkinter.pyc
-- VTK version >5 is found
-- ===========================================================
-- Yade configured with following features: Odeint VTK OpenMP GTS GUI-Qt5 CGAL PFVFLOW TWOPHASEFLOW LINSOLV GL2PS LBMFLOW
-- Disabled features: CHOLMOD_GPU SPH DEFORM LIQMIGRATION MASK_ARBITRARY PROFILING PotentialParticles PotentialBlocks
-- Optimized build
-- ===========================================================
-- Configuring done
-- Generating done
-- Build files have been written to: /home/mohammay/Documents/yadeInstall/build

Any ideas what's wrong? is it related to VTK?

Thank you!

Lingran

Question information

Language:
English Edit question
Status:
Solved
For:
Yade Edit question
Assignee:
No assignee Edit question
Solved by:
Robert Caulk
Solved:
2020-02-12
Last query:
2020-02-12
Last reply:
2020-02-10
Robert Caulk (rcaulk) said : #1

Debian 10 runs a different version of libcgal [1] than ubuntu 16.04 [2]. The yade version you are using requires the older version of libcgal. You can either manually compile the old version of cgal on Debian 10, or update your Yade sources.

[1]https://packages.debian.org/buster/libcgal-dev
[2]https://packages.ubuntu.com/xenial/libcgal-dev

Lingran Zhang (lingran) said : #2

Hi Robert,

Thank you for your suggestions.

Here is the feedback:

- manually compile the cgal (version 4.12.1 and 4.8): the same error persists.

- download the newest trunk by git clone: errors are produced only when DFNflow is compiled:

[ 89%] Building CXX object CMakeFiles/yade.dir/lib/triangulation/Tenseur3.cpp.o
/home/zhang7/Documents/compareYade/trunk_download_dfn/pkg/pfv/DFNFlow.cpp: In member function ‘void yade::DFNBoundingSphere::saveVtk(const char*, bool)’:
/home/zhang7/Documents/compareYade/trunk_download_dfn/pkg/pfv/DFNFlow.cpp:59:41: error: unused parameter ‘withBoundaries’ [-Werror=unused-parameter]
   void saveVtk(const char* folder, bool withBoundaries) //FIXME: withBoundaries does nothing in DFNFlow right now. Needed for consistent templating.
                                    ~~~~~^~~~~~~~~~~~~~
[ 90%] Building CXX object CMakeFiles/yade.dir/lib/triangulation/Timer.cpp.o
/home/zhang7/Documents/compareYade/trunk_download_dfn/pkg/pfv/DFNFlow.cpp: In member function ‘void yade::DFNFlowEngine::interpolateCrack(yade::TemplateFlowEngine_DFNFlowEngineT<yade::DFNCellInfo, yade::DFNVertexInfo, yade::CGT::_Tesselation<yade::CGT::TriangulationTypes<yade::DFNVertexInfo, yade::DFNCellInfo> >, yade::DFNBoundingSphere>::Tesselation&, yade::TemplateFlowEngine_DFNFlowEngineT<yade::DFNCellInfo, yade::DFNVertexInfo, yade::CGT::_Tesselation<yade::CGT::TriangulationTypes<yade::DFNVertexInfo, yade::DFNCellInfo> >, yade::DFNBoundingSphere>::Tesselation&)’:
/home/zhang7/Documents/compareYade/trunk_download_dfn/pkg/pfv/DFNFlow.cpp:208:22: error: variable ‘cellEnd’ set but not used [-Werror=unused-but-set-variable]
  FiniteCellsIterator cellEnd = newTri.finite_cells_end();
                      ^~~~~~~
[ 90%] Building CXX object CMakeFiles/yade.dir/lib/triangulation/TriaxialState.cpp.o
[ 91%] Building CXX object CMakeFiles/yade.dir/lib/triangulation/basicVTKwritter.cpp.o
[ 91%] Building CXX object CMakeFiles/yade.dir/lib/computational-geometry/MarchingCube.cpp.o
cc1plus: all warnings being treated as errors
make[2]: *** [CMakeFiles/yade.dir/build.make:1896: CMakeFiles/yade.dir/pkg/pfv/DFNFlow.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [CMakeFiles/Makefile2:143: CMakeFiles/yade.dir/all] Error 2
make: *** [Makefile:130: all] Error 2

Here is what cmake gives:

-- The C compiler identification is GNU 8.3.0
-- The CXX compiler identification is GNU 8.3.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Version is set to 2020-02-02.git-472f4cb
-- GCC Version >= 4.8. Adding -ftrack-macro-expansion=0
-- GCC Version >= 4.8. Adding -save-temps
-- Found Eigen3: /usr/include/eigen3 (Required is at least version "2.91.0")
-- Log filtering: enabled
-- Enabling boost::log library and DEBUG=OFF. Logging will work nicely, backtraces will not have debug info, files will be small.
Loop on the following python versions and check available dependencies:3.8;3.7;3.6;3.5;3.4;3.3;3.2;3.1;3.0;2.7;2.6
-- Found PythonInterp: /usr/bin/python (found version "2.7.16")
-- Found PythonInterp: /usr/bin/python3.7 (found version "3.7.3")
Python version 3.7.3 found, try to import dependencies...
-- Found NumPy: version "1.16.2" /usr/lib/python3/dist-packages/numpy/core/include
-- Found IPython: /usr/lib/python3/dist-packages/IPython
-- Found matplotlib: /usr/lib/python3/dist-packages/matplotlib
-- Found pygraphviz: /usr/lib/python3/dist-packages/pygraphviz
-- Found Xlib: /usr/lib/python3/dist-packages/Xlib
-- Found minieigen: /usr/lib/python3/dist-packages/minieigen.cpython-37m-x86_64-linux-gnu.so
-- Found future: /usr/lib/python3/dist-packages/future
-- Found past: /usr/lib/python3/dist-packages/past
-- Found tkinter: /usr/lib/python3.7/tkinter
-- Boost_VERSION: 106700
-- Boost_LIB_VERSION: 1_67
-- Boost_INCLUDE_DIRS: /usr/include
-- Boost_LIBRARIES: /usr/lib/x86_64-linux-gnu/libboost_python37.so/usr/lib/x86_64-linux-gnu/libboost_thread.so-lpthread/usr/lib/x86_64-linux-gnu/libboost_filesystem.so/usr/lib/x86_64-linux-gnu/libboost_iostreams.so/usr/lib/x86_64-linux-gnu/libboost_regex.so/usr/lib/x86_64-linux-gnu/libboost_serialization.so/usr/lib/x86_64-linux-gnu/libboost_system.so/usr/lib/x86_64-linux-gnu/libboost_date_time.so/usr/lib/x86_64-linux-gnu/libboost_log.so/usr/lib/x86_64-linux-gnu/libboost_chrono.so/usr/lib/x86_64-linux-gnu/libboost_atomic.so/usr/lib/x86_64-linux-gnu/libboost_log_setup.so
Found all python dependencies with version 3.7.3, will compile yade with that.
-- Chosen compiler flags are: CMAKE_CXX_FLAGS = -Werror -Wformat -Wformat-security -Wformat-nonliteral -Wall -Wextra -Wnarrowing -Wreturn-type -Wuninitialized -Wfloat-conversion -Wcast-align -Wdisabled-optimization -Wtrampolines -Wpointer-arith -Wswitch-bool -Wwrite-strings -Wnon-virtual-dtor -Wreturn-local-addr -Wno-error=maybe-uninitialized -Wno-comment -Wno-cast-function-type -Wshadow=compatible-local -Wno-error=cpp -fdce -fstack-protector-strong
-- Found BZip2: /usr/lib/x86_64-linux-gnu/libbz2.so (found version "1.0.6")
-- Looking for BZ2_bzCompressInit
-- Looking for BZ2_bzCompressInit - found
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.11")
-- Found Eigen3, version: 3.3.7
-- Disable vectorization
-- The imported target "vtkRenderingPythonTkWidgets" references the file
   "/usr/lib/x86_64-linux-gnu/libvtkRenderingPythonTkWidgets.so"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/cmake/vtk-6.3/VTKTargets.cmake"
but not all the files it references.

-- The imported target "vtk" references the file
   "/usr/bin/vtk"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
   "/usr/lib/cmake/vtk-6.3/VTKTargets.cmake"
but not all the files it references.

-- Found VTK
-- Found OpenMP_C: -fopenmp (found version "4.5")
-- Found OpenMP_CXX: -fopenmp (found version "4.5")
-- Found OpenMP: TRUE (found version "4.5")
-- Found OpenMP
-- GTS using gts-config /usr/bin/gts-config
-- Using GTS from /usr
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29")
-- Checking for one of the modules 'glib-2.0'
-- Found GLib2: glib-2.0 /usr/include/glib-2.0;/usr/lib/x86_64-linux-gnu/glib-2.0/include
-- Looking for include file glib/gregex.h
-- Looking for include file glib/gregex.h - not found
-- Found GTS
CMake Warning (dev) at /usr/share/cmake-3.13/Modules/FindOpenGL.cmake:270 (message):
  Policy CMP0072 is not set: FindOpenGL prefers GLVND by default when
  available. Run "cmake --help-policy CMP0072" for policy details. Use the
  cmake_policy command to set the policy and suppress this warning.

  FindOpenGL found both a legacy GL library:

    OPENGL_gl_LIBRARY: /usr/lib/x86_64-linux-gnu/libGL.so

  and GLVND libraries for OpenGL and GLX:

    OPENGL_opengl_LIBRARY: /usr/lib/x86_64-linux-gnu/libOpenGL.so
    OPENGL_glx_LIBRARY: /usr/lib/x86_64-linux-gnu/libGLX.so

  OpenGL_GL_PREFERENCE has not been set to "GLVND" or "LEGACY", so for
  compatibility with CMake 3.10 and below the legacy GL library will be used.
Call Stack (most recent call first):
  CMakeLists.txt:424 (FIND_PACKAGE)
This warning is for project developers. Use -Wno-dev to suppress it.

-- Found OpenGL: /usr/lib/x86_64-linux-gnu/libOpenGL.so
-- Found GLUT: /usr/lib/x86_64-linux-gnu/libglut.so
-- USE QT5
-- Found QGLVIEWER-qt5: /usr/include/QGLViewer
-- Found GUI-Qt5-LIBS
-- GMP libs: /usr/lib/x86_64-linux-gnu/libgmp.so /usr/lib/x86_64-linux-gnu/libgmpxx.so
-- Found GMP: /usr/include/x86_64-linux-gnu
-- Found CGAL: /usr/include, /usr/lib/x86_64-linux-gnu/libCGAL.so
-- GMP libs: /usr/lib/x86_64-linux-gnu/libgmp.so /usr/lib/x86_64-linux-gnu/libgmpxx.so
-- Found CGAL
-- Using typical suitesparse path /usr
-- SuiteSparse version 5.4.0 found, CHOLMOD direct solver for CPU activated.
-- Found Cholmod: /usr/lib/x86_64-linux-gnu/libcholmod.so
-- Found OpenBlas: /usr/lib/x86_64-linux-gnu/libopenblas.so
-- BLAS_INCLUDE_DIR=/usr/include/x86_64-linux-gnu
-- Found Metis: /usr/include
-- Found Cholmod in /usr/lib/x86_64-linux-gnu/libcholmod.so
-- Found OpenBlas in /usr/lib/x86_64-linux-gnu/libopenblas.so
-- Found Metis in /usr/lib/x86_64-linux-gnu/libmetis.so
-- Found MPI_C: /usr/lib/x86_64-linux-gnu/openmpi/lib/libmpi.so (found version "3.1")
-- Found MPI_CXX: /usr/lib/x86_64-linux-gnu/openmpi/lib/libmpi_cxx.so (found version "3.1")
-- Found MPI: TRUE (found version "3.1")
-- Found MPI4PY: /usr/lib/python3/dist-packages/mpi4py/include
-- MPI found
-- Found GL2PS: /usr/lib/x86_64-linux-gnu/libgl2ps.so
-- Found GL2PS
LBMFLOW is still experimental, building and running LBM engine are at your own risk!
-- BLAS_INCLUDE_DIR=/usr/include/x86_64-linux-gnu
-- Looking for sgemm_
-- Looking for sgemm_ - not found
-- Found Threads: TRUE
-- Looking for sgemm_
-- Looking for sgemm_ - found
-- Found BLAS: /usr/lib/x86_64-linux-gnu/libopenblas.so
-- Looking for cheev_
-- Looking for cheev_ - found
-- A library with LAPACK API found.
-- Found OpenBlas
-- Found Lapack
-- Found CLP: /usr/include/coin, /usr/lib/x86_64-linux-gnu/libClp.so
-- BLAS_INCLUDE_DIR=/usr/include/x86_64-linux-gnu
-- A library with LAPACK API found.
-- Found CLP version: 1.16.11, coinutils version: 2.10.14
-- WARNING: coinutils version older than 2.11.3. Falling back to C++14.
-- md5sum of freegult /usr/include/GL/freeglut_std.h is: 791a2febd8584ec530cdd7676191b6d5
-- freegult version is 2.8.1
Yade will be installed to /home/zhang7/Documents/compareYade/install
-- Suffix is set to -2020-02-02.git-472f4cb
-- LIBRARY_OUTPUT_PATH is set to lib/x86_64-linux-gnu
-- runtimePREFIX is set to /home/zhang7/Documents/compareYade/install
-- Could NOT find gts (missing: PY_gts)
-- Use embedded version of gts. Please, consider installing the corresponding package
-- VTK version >5 and <8 is found
-- ===========================================================
-- Yade configured with following features: BoostLog Odeint VTK OpenMP GTS GUI-Qt5 CGAL PFVFLOW PFVFLOW LINSOLV MPI TWOPHASEFLOW FEMLIKE GL2PS LBMFLOW THERMAL PotentialParticles PotentialBlocks
-- Disabled features: CHOLMOD_GPU SPH DEFORM LIQMIGRATION MASK_ARBITRARY PROFILING
-- Using MAX_LOG_LEVEL=5, ENABLE_LOGGER=ON
-- Optimized build
-- C++ standard version: 14
-- ===========================================================
-- Configuring done
-- Generating done
-- Build files have been written to: /home/zhang7/Documents/compareYade/build

Can you have a look if there is a bug in DFNflow.cpp?

Many thanks!
Lingran

Best Robert Caulk (rcaulk) said : #3

- manually compile the cgal (version 4.12.1 and 4.8): the same error persists.

Xenial is libcgal 4.7.4 [1]. And did you link the alternative library (cgal 4.7.4) correctly during the cmake step?

- error: unused parameter ‘withBoundaries’ [-Werror=unused-parameter]
- error: variable ‘cellEnd’ set but not used [-Werror=unused-but-set-variable]

You can remove those parameters or set -DENABLE_USEFUL_ERRORS=OFF during cmake step.

[1]https://packages.ubuntu.com/xenial/libcgal-dev

Lingran Zhang (lingran) said : #4

Hi Robert,

And did you link the alternative library (cgal 4.7.4) correctly during the cmake step?
>> How do I link this library to cmake? shall I modify the CMakeLists.txt in the source code?

By setting -DENABLE_USEFUL_ERRORS=OFF, the new yade code has been successfully compiled.
Thank you very much!

Lingran

Robert Caulk (rcaulk) said : #5

>> How do I link this library to cmake? shall I modify the CMakeLists.txt in the source code?

You can modify cMake/FindCGAL.cmake to hard code the path to the alternative librabry or you can make sure the alternative library is the only version installed on your system and that it is installed in one of the paths searched by FindCGAL.cmake.

Lingran Zhang (lingran) said : #6

Thank you very much Robert!

Lingran

Lingran Zhang (lingran) said : #7

Thanks Robert Caulk, that solved my question.