mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-09 17:31:45 +00:00
cmake: put IFCXML_SUPPORT related config in IfcParse cmake config file
This commit is contained in:
committed by
Thomas Krijnen
parent
8f3e67b747
commit
81bf187ee6
@@ -345,18 +345,6 @@ find_package(Boost REQUIRED COMPONENTS ${BOOST_COMPONENTS})
|
||||
message(STATUS "Boost include files found in ${Boost_INCLUDE_DIRS}")
|
||||
message(STATUS "Boost libraries found in ${Boost_LIBRARY_DIRS}")
|
||||
|
||||
if(NOT MINIMAL_BUILD)
|
||||
# libxml2 is required for IFCXML (optional) and SVGFILL (mandatory)
|
||||
if(IFCXML_SUPPORT)
|
||||
find_package(LibXml2 REQUIRED)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(IFCXML_SUPPORT)
|
||||
add_definitions(-DWITH_IFCXML)
|
||||
set(SWIG_DEFINES ${SWIG_DEFINES} -DWITH_IFCXML)
|
||||
endif()
|
||||
|
||||
if(BUILD_IFCGEOM)
|
||||
# Open CASCADE
|
||||
if(WITH_OPENCASCADE)
|
||||
|
||||
@@ -35,12 +35,14 @@ add_library(IfcParse ${IFCPARSE_FILES})
|
||||
set_target_properties(IfcParse PROPERTIES COMPILE_FLAGS -DIFC_PARSE_EXPORTS VERSION "${PROJECT_VERSION}" SOVERSION "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}")
|
||||
|
||||
if(IFCXML_SUPPORT)
|
||||
find_package(LibXml2 REQUIRED)
|
||||
add_definitions(-DWITH_IFCXML)
|
||||
set(SWIG_DEFINES ${SWIG_DEFINES} -DWITH_IFCXML)
|
||||
|
||||
if(LibXml2_DIR)
|
||||
target_compile_definitions(IfcParse PRIVATE ${LIBXML2_DEFINITIONS})
|
||||
endif()
|
||||
|
||||
add_definitions(-DWITH_IFCXML)
|
||||
target_link_libraries(IfcParse LibXml2::LibXml2)
|
||||
endif()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user