From 6c471237810314372154b5cdaadbac68937639b6 Mon Sep 17 00:00:00 2001 From: Thomas Krijnen Date: Sun, 19 Apr 2026 10:35:04 +0200 Subject: [PATCH] Remove C++ references to ifcxml --- cmake/CMakeLists.txt | 2 -- conda/build.bat | 1 - conda/build.sh | 1 - src/ifcconvert/IfcConvert.cpp | 5 ----- src/ifcparse/CMakeLists.txt | 12 ------------ src/ifcwrap/IfcParseWrapper.i | 1 - 6 files changed, 22 deletions(-) diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt index 76fee82027..446344953c 100644 --- a/cmake/CMakeLists.txt +++ b/cmake/CMakeLists.txt @@ -79,7 +79,6 @@ option(COLLADA_SUPPORT "Build IfcConvert with COLLADA support (requires OpenCOLL option(GLTF_SUPPORT "Build IfcConvert with glTF support (requires json.hpp)." OFF) option(HDF5_SUPPORT "Enable HDF5 support (requires HDF5, zlib)" ON) option(WITH_PROJ "Enable output of Earth-Centered Earth-Fixed glTF output using the PROJ library" OFF) -option(IFCXML_SUPPORT "Build IfcParse with ifcXML support (requires libxml2)." ON) option(USD_SUPPORT "Build IfcConvert with USD support (requires pixar's USD library)." OFF) option(WITH_ROCKSDB "Support a RocksDB key-value store as a file backend in IfcOpenShell" OFF) option(WITH_ZSTD "Use Zstd compression in RocksDB writes" OFF) @@ -116,7 +115,6 @@ if(MINIMAL_BUILD) set(COLLADA_SUPPORT OFF) set(GLTF_SUPPORT OFF) set(HDF5_SUPPORT OFF) - set(IFCXML_SUPPORT OFF) set(USD_SUPPORT OFF) endif() diff --git a/conda/build.bat b/conda/build.bat index 242bc7d683..b43448e255 100644 --- a/conda/build.bat +++ b/conda/build.bat @@ -37,7 +37,6 @@ cmake -G "Ninja" ^ -D GLTF_SUPPORT:BOOL=ON ^ -D BUILD_CONVERT:BOOL=ON ^ -D BUILD_IFCMAX:BOOL=OFF ^ - -D IFCXML_SUPPORT:BOOL=ON ^ -D Boost_LIBRARY_DIR:FILEPATH="%LIBRARY_PREFIX%\lib" ^ -D Boost_INCLUDE_DIR:FILEPATH="%LIBRARY_PREFIX%\include" ^ -D Boost_USE_STATIC_LIBS:BOOL=OFF ^ diff --git a/conda/build.sh b/conda/build.sh index 132bcf2be9..83fac5809c 100644 --- a/conda/build.sh +++ b/conda/build.sh @@ -34,7 +34,6 @@ cmake ${CMAKE_ARGS} -G Ninja \ -DEIGEN_DIR:FILEPATH=$PREFIX/include/eigen3 \ -DCOLLADA_SUPPORT:BOOL=OFF \ -DBUILD_EXAMPLES:BOOL=OFF \ - -DIFCXML_SUPPORT:BOOL=ON \ -DGLTF_SUPPORT:BOOL=ON \ -DBUILD_CONVERT:BOOL=ON \ -DBUILD_IFCPYTHON:BOOL=ON \ diff --git a/src/ifcconvert/IfcConvert.cpp b/src/ifcconvert/IfcConvert.cpp index 6c8764aa71..77560c50d9 100644 --- a/src/ifcconvert/IfcConvert.cpp +++ b/src/ifcconvert/IfcConvert.cpp @@ -1056,11 +1056,6 @@ bool init_input_file(const std::string& filename, ifcopenshell::file*& ifc_file, bool requires_init = false; -#ifdef WITH_IFCXML - // if (boost::ends_with(boost::to_lower_copy(filename), ".ifcxml")) { - // ifc_file = ifcopenshell::parse_ifcxml(filename); - // } else -#endif { ifc_file = new ifcopenshell::file(ifcopenshell::uninitialized_tag{}); requires_init = true; diff --git a/src/ifcparse/CMakeLists.txt b/src/ifcparse/CMakeLists.txt index f91b642481..166a1b0944 100644 --- a/src/ifcparse/CMakeLists.txt +++ b/src/ifcparse/CMakeLists.txt @@ -38,18 +38,6 @@ add_library(parse ALIAS IfcParse) target_compile_definitions(IfcParse PUBLIC ${SCHEMA_DEFINITIONS}) 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) - target_compile_definitions(IfcParse PUBLIC WITH_IFCXML) - set(SWIG_DEFINES ${SWIG_DEFINES} -DWITH_IFCXML PARENT_SCOPE) - - if(LibXml2_DIR) - target_compile_definitions(IfcParse PRIVATE ${LIBXML2_DEFINITIONS}) - endif() - - target_link_libraries(IfcParse LibXml2::LibXml2) -endif() - if(WASM_BUILD) target_link_libraries(IfcParse plugin ${BCRYPT_LIBRARIES}) else() diff --git a/src/ifcwrap/IfcParseWrapper.i b/src/ifcwrap/IfcParseWrapper.i index b78a3ce804..8fa479cfec 100644 --- a/src/ifcwrap/IfcParseWrapper.i +++ b/src/ifcwrap/IfcParseWrapper.i @@ -951,7 +951,6 @@ object = _old_object // The file* returned by open() is to be freed by SWIG/Python %newobject open; %newobject read; -%newobject parse_ifcxml; %newobject stream_from_string; %inline %{