I'm working on a class project in C++ using CLION which requires the CGAL library, and I'm having trouble getting the library to work with my project.
We're trying to get the library working in it's header-only configuration for simplicity, however the documentation for CGAL is a bit thin on details when it comes to this way of doing things. In this part of the installation documentation we're told to extract the CGAL library data somewhere and reference it in a variable in our cmake file. However we can't seem to reference any of CGAL's headers in our project - none of the directories or files can be found at all.
We've tried to fix this ourselves for a while but we don't really know where to look or what the problem is, and the documentation for CGAL isn't being of much help. Below I've attached our CMakeLists file contents, have we done something really wrong or is it as it should be?
cmake_minimum_required(VERSION 3.9)
project(remeshing_project)
set(CMAKE_CXX_STANDARD 17)
if(MINGW OR CYGWIN)
add_definitions(-O3)
endif()
set(ENV{CGAL_DIR} S:/dev/cgal)
add_definitions(-DCGAL_DIR=$(CGAL_DIR))
#add_definitions(-DCGAL_LINKED_WITH_TBB)
#add_definitions(-DCGAL_USE_GMP)
#add_definitions(-DCGAL_USE_MPFR)
#add_definitions(-DCGAL_USE_ZLIB)
link_libraries(../external/glew_2_1_0/lib/Release/Win32/glew32s)
link_libraries(../external/glfw/lib-vc2015/glfw3)
link_libraries(../external/openGL/OPENGL32)
link_libraries(../external/openGL/glut32)
link_libraries(../external/openGL/glu32)
#Header Locations
set(HEADER_DIRS external/tinyply
external/libigl/include/
external/glfw/include/
external/eigen-git-mirror/
external/glew_2_1_0/include/
external/nanoflann/
external/spectra/
external/halfedge/
external/
$(CGAL_DIR)/)
add_executable(Remesher src/main.cpp external/halfedge/trimesh.cpp src/meshMetrics.cpp src/meshMetrics.h src/remeshingTools.cpp src/remeshingTools.h src/dataStructures.h)
target_include_directories(Remesher PRIVATE ${HEADER_DIRS})
Any help would be hugely appreciated, we've been banging our head against this for a while and are at a loss. Thanks in advance!