mirror of https://github.com/vitalif/openscad
Cleaned up library dependencies
parent
65edc63166
commit
481d3754b3
|
@ -677,16 +677,14 @@ if(NULLGL)
|
|||
endif()
|
||||
|
||||
add_library(tests-core STATIC ${CORE_SOURCES})
|
||||
target_link_libraries(tests-core ${OPENGL_LIBRARIES} ${GLIB2_LIBRARIES} )
|
||||
set(TESTS-CORE-LIBRARIES ${OPENGL_LIBRARIES} ${GLIB2_LIBRARIES} ${Boost_LIBRARIES} ${COCOA_LIBRARY})
|
||||
target_link_libraries(tests-core ${OPENGL_LIBRARIES} ${GLIB2_LIBRARIES} ${FONTCONFIG_LDFLAGS} ${FREETYPE_LDFLAGS} ${HARFBUZZ_LDFLAGS} ${Boost_LIBRARIES} ${COCOA_LIBRARY})
|
||||
|
||||
add_library(tests-common STATIC ${COMMON_SOURCES})
|
||||
target_link_libraries(tests-common tests-core)
|
||||
|
||||
add_library(tests-cgal STATIC ${CGAL_SOURCES})
|
||||
set_target_properties(tests-cgal PROPERTIES COMPILE_FLAGS "-DENABLE_CGAL ${CGAL_CXX_FLAGS_INIT}")
|
||||
target_link_libraries(tests-cgal tests-common)
|
||||
set(TESTS-CGAL-LIBRARIES ${CGAL_LIBRARY} ${CGAL_3RD_PARTY_LIBRARIES} ${GMP_LIBRARIES} ${MPFR_LIBRARIES} ${TESTS-CORE-LIBRARIES})
|
||||
target_link_libraries(tests-cgal tests-common ${CGAL_LIBRARY} ${CGAL_3RD_PARTY_LIBRARIES} ${GMP_LIBRARIES} ${MPFR_LIBRARIES})
|
||||
|
||||
#
|
||||
# Create non-CGAL tests
|
||||
|
@ -694,14 +692,12 @@ set(TESTS-CGAL-LIBRARIES ${CGAL_LIBRARY} ${CGAL_3RD_PARTY_LIBRARIES} ${GMP_LIBRA
|
|||
if (NOT NULLGL)
|
||||
add_library(tests-nocgal STATIC ${NOCGAL_SOURCES})
|
||||
target_link_libraries(tests-nocgal tests-common)
|
||||
set(TESTS-NOCGAL-LIBRARIES ${TESTS-CORE-LIBRARIES})
|
||||
else()
|
||||
message(STATUS "NULLGL: cannot use GL/GLU tessellator. see dxftess.cc")
|
||||
message(STATUS "NULLGL: non-CGAL tests will use CGAL's tessellator")
|
||||
add_library(tests-nocgal STATIC ${CGAL_SOURCES})
|
||||
set_target_properties(tests-nocgal PROPERTIES COMPILE_FLAGS "-DENABLE_CGAL ${CGAL_CXX_FLAGS_INIT}")
|
||||
target_link_libraries(tests-nocgal tests-common)
|
||||
set(TESTS-NOCGAL-LIBRARIES ${TESTS-CGAL-LIBRARIES})
|
||||
endif()
|
||||
|
||||
add_library(tests-offscreen STATIC ${OFFSCREEN_SOURCES})
|
||||
|
@ -711,27 +707,27 @@ set_target_properties(tests-offscreen PROPERTIES COMPILE_FLAGS "${ENABLE_OPENCSG
|
|||
# modulecachetest
|
||||
#
|
||||
add_executable(modulecachetest modulecachetest.cc)
|
||||
target_link_libraries(modulecachetest tests-nocgal ${TESTS-NOCGAL-LIBRARIES} ${Boost_LIBRARIES} ${FONTCONFIG_LDFLAGS} ${FREETYPE_LDFLAGS} ${HARFBUZZ_LDFLAGS})
|
||||
target_link_libraries(modulecachetest tests-nocgal)
|
||||
|
||||
#
|
||||
# csgtexttest
|
||||
#
|
||||
add_executable(csgtexttest csgtexttest.cc CSGTextRenderer.cc CSGTextCache.cc)
|
||||
target_link_libraries(csgtexttest tests-nocgal ${TESTS-NOCGAL-LIBRARIES} ${FONTCONFIG_LDFLAGS} ${FREETYPE_LDFLAGS} ${HARFBUZZ_LDFLAGS})
|
||||
target_link_libraries(csgtexttest tests-nocgal)
|
||||
|
||||
#
|
||||
# cgalcachetest
|
||||
#
|
||||
add_executable(cgalcachetest cgalcachetest.cc)
|
||||
set_target_properties(cgalcachetest PROPERTIES COMPILE_FLAGS "-DENABLE_CGAL ${CGAL_CXX_FLAGS_INIT}")
|
||||
target_link_libraries(cgalcachetest tests-cgal ${TESTS-CGAL-LIBRARIES} ${GLEW_LIBRARY} ${COCOA_LIBRARY} ${FONTCONFIG_LDFLAGS} ${FREETYPE_LDFLAGS} ${HARFBUZZ_LDFLAGS})
|
||||
target_link_libraries(cgalcachetest tests-cgal ${GLEW_LIBRARY})
|
||||
|
||||
#
|
||||
# openscad no-qt
|
||||
#
|
||||
add_executable(openscad_nogui ../src/openscad.cc)
|
||||
set_target_properties(openscad_nogui PROPERTIES COMPILE_FLAGS "-fno-strict-aliasing -DEIGEN_DONT_ALIGN -DENABLE_CGAL -DENABLE_OPENCSG ${CGAL_CXX_FLAGS_INIT}")
|
||||
target_link_libraries(openscad_nogui tests-offscreen tests-cgal tests-nocgal ${TESTS-CORE-LIBRARIES} ${TESTS-CGAL-LIBRARIES} ${GLEW_LIBRARY} ${Boost_LIBRARIES} ${OPENCSG_LIBRARY} ${COCOA_LIBRARY} ${APP_SERVICES_LIBRARY} ${FONTCONFIG_LDFLAGS} ${FREETYPE_LDFLAGS} ${HARFBUZZ_LDFLAGS})
|
||||
target_link_libraries(openscad_nogui tests-offscreen tests-cgal tests-nocgal ${GLEW_LIBRARY} ${OPENCSG_LIBRARY} ${APP_SERVICES_LIBRARY})
|
||||
|
||||
#
|
||||
# GUI binary tests
|
||||
|
|
Loading…
Reference in New Issue