mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-13 10:57:49 +00:00
examples - further simplify linking
This commit is contained in:
@@ -39,6 +39,8 @@ if(STANDALONE_PROJECT)
|
||||
find_package(IfcOpenShell CONFIG REQUIRED)
|
||||
set(SCHEMA_VERSIONS ${IFCOPENSHELL_SCHEMA_VERSIONS})
|
||||
set(WITH_OPENCASCADE ${IFCOPENSHELL_WITH_OPENCASCADE})
|
||||
else()
|
||||
include_directories("${CMAKE_SOURCE_DIR}/../src")
|
||||
endif()
|
||||
|
||||
if(SCHEMA_VERSIONS MATCHES "2x3")
|
||||
@@ -62,16 +64,10 @@ if(SCHEMA_VERSIONS MATCHES "2x3")
|
||||
find_package(Eigen3 CONFIG REQUIRED)
|
||||
find_package(CGAL CONFIG REQUIRED)
|
||||
find_package(OpenCASCADE CONFIG REQUIRED)
|
||||
add_library(CGAL::CGAL_INTERFACE INTERFACE IMPORTED)
|
||||
target_link_libraries(CGAL::CGAL_INTERFACE INTERFACE CGAL::CGAL)
|
||||
|
||||
target_link_libraries(IfcHouseInterface
|
||||
INTERFACE ${OpenCASCADE_LIBRARIES} RocksDB::rocksdb
|
||||
IfcOpenShell::IfcParse IfcOpenShell::geometry_serializer
|
||||
)
|
||||
target_link_libraries(IfcHouseInterface INTERFACE IfcOpenShell::IfcParse IfcOpenShell::geometry_serializer)
|
||||
else()
|
||||
target_include_directories(IfcHouseInterface INTERFACE "${CMAKE_SOURCE_DIR}/../src")
|
||||
target_link_libraries(IfcHouseInterface INTERFACE ${IFCOPENSHELL_LIBRARIES} ${OpenCASCADE_LIBRARIES})
|
||||
target_link_libraries(IfcHouseInterface INTERFACE IfcParse geometry_serializer)
|
||||
set_target_properties(IfcOpenHouse PROPERTIES FOLDER Examples)
|
||||
set_target_properties(IfcAdvancedHouse PROPERTIES FOLDER Examples)
|
||||
endif()
|
||||
@@ -87,11 +83,9 @@ if(SCHEMA_VERSIONS MATCHES "4x3_add2")
|
||||
add_library(IfcAlignmentInterface INTERFACE)
|
||||
|
||||
if(STANDALONE_PROJECT)
|
||||
target_link_libraries(IfcAlignment PRIVATE IfcOpenShell::IfcParse)
|
||||
target_link_libraries(IfcSimplifiedAlignment PRIVATE IfcOpenShell::IfcParse)
|
||||
target_link_libraries(IfcAlignmentInterface INTERFACE IfcOpenShell::IfcParse)
|
||||
else()
|
||||
target_include_directories(IfcAlignmentInterface INTERFACE "${CMAKE_SOURCE_DIR}/../src")
|
||||
target_link_libraries(IfcAlignmentInterface INTERFACE ${IFCOPENSHELL_LIBRARIES})
|
||||
target_link_libraries(IfcAlignmentInterface INTERFACE IfcParse)
|
||||
set_target_properties(IfcAlignment PROPERTIES FOLDER Examples)
|
||||
set_target_properties(IfcSimplifiedAlignment PROPERTIES FOLDER Examples)
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user