Skip to content
Snippets Groups Projects
CMakeLists.txt 759 B
################################################################################
# CSG Parser
################################################################################

set(csg-eb_SOURCES)
list(APPEND csg-eb_SOURCES
  csg.cpp
  levelset_2d.cpp
  levelset_3d.cpp
  matrix_functions.cpp
  parser.cpp
  exception.cpp
  )

if (CSG_CGAL_ENABLED)
   list(APPEND csg-eb_SOURCES
      cgal_helper_polygon.cpp
      cgal_helper_polyhedron.cpp
   )
endif()

add_library(csg-eb ${csg-eb_SOURCES})

target_link_libraries(csg-eb PRIVATE
                      stdc++fs
                      taocpp::pegtl
                      )
if (CSG_CGAL_ENABLED)
   target_link_libraries(csg-eb PRIVATE CGAL::CGAL)
endif()

if (BUILD_TESTING)
   add_subdirectory(tests)
endif()