Merge pull request #17779 from wwmayer/noboostpy

Remove support for Boost.Python
This commit is contained in:
Chris Hennes
2025-03-17 00:00:32 -05:00
committed by GitHub
10 changed files with 27 additions and 955 deletions

View File

@@ -203,6 +203,10 @@ macro(InitializeFreeCADBuildOptions)
set(BUILD_SMESH OFF)
endif()
if (BUILD_CAM OR BUILD_FLAT_MESH)
set(FREECAD_USE_PYBIND11 ON)
endif()
# force build directory to be different to source directory
if (BUILD_FORCE_DIRECTORY)
if(${CMAKE_SOURCE_DIR} STREQUAL ${CMAKE_BINARY_DIR})

View File

@@ -87,7 +87,6 @@ macro(PrintFinalReport)
value(Python3_EXECUTABLE)
value(PYTHON_LIBRARY)
value(FREECAD_CREATE_MAC_APP)
value(FREECAD_USE_PYBIND11)
value(FREECAD_USE_EXTERNAL_KDL)
value(FREECAD_USE_PYSIDE)
value(FREECAD_USE_SHIBOKEN)

View File

@@ -2,7 +2,6 @@ macro(SetupPybind11)
# -------------------------------- PyBind11 -----------------------------
# necessary for flat-mesh feature
option(FREECAD_USE_PYBIND11 "Use pybind11" OFF)
if (FREECAD_USE_PYBIND11)
find_package(pybind11 REQUIRED)
endif()

View File

@@ -19,6 +19,9 @@ if(FREECAD_LIBPACK_VERSION VERSION_GREATER_EQUAL "3.1.0")
find_package(pybind11 REQUIRED PATHS ${FREECAD_LIBPACK_DIR}/share/cmake/pybind11 NO_DEFAULT_PATH)
message(STATUS "Found LibPack 3 pybind11 ${pybind11_VERSION}")
set(FREECAD_USE_PYBIND11 ON)
else()
# We have completely removed support for boost-python and require pybind11, which requires LibPack 3.1 or later
message(FATAL_ERROR "FreeCAD now requires LibPack 3.1.0 or newer (you are using ${FREECAD_LIBPACK_VERSION}): please upgrade your LibPack")
endif()
find_package(XercesC REQUIRED PATHS ${FREECAD_LIBPACK_DIR}/cmake NO_DEFAULT_PATH)
@@ -28,6 +31,7 @@ find_package(yaml-cpp REQUIRED PATHS ${FREECAD_LIBPACK_DIR}/lib/cmake NO_DEFAULT
message(STATUS "Found LibPack 3 yaml-cpp ${yaml-cpp_VERSION}")
find_package(Coin REQUIRED PATHS ${FREECAD_LIBPACK_DIR}/lib/cmake NO_DEFAULT_PATH)
message(STATUS "Found LibPack 3 Coin ${Coin_VERSION}")
# For compatibility with the rest of the cMake scripts:
set (COIN3D_FOUND TRUE)