CMake: Remove FREECAD_USE_PYBIND11 as a build option

This commit is contained in:
wmayer
2024-11-15 18:58:17 +01:00
committed by Chris Hennes
parent 1489015caf
commit c532683060
4 changed files with 6 additions and 4 deletions

View File

@@ -201,6 +201,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

@@ -99,7 +99,7 @@ INSTALL(TARGETS MeshPart DESTINATION ${CMAKE_INSTALL_LIBDIR})
################################ flat mesh ###############################
if (BUILD_FLAT_MESH AND FREECAD_USE_PYBIND11)
if (BUILD_FLAT_MESH)
SET(FLATMESH_SRCS
MeshFlattening.cpp
MeshFlattening.h
@@ -117,5 +117,5 @@ if (BUILD_FLAT_MESH AND FREECAD_USE_PYBIND11)
SET_BIN_DIR(flatmesh flatmesh /Mod/MeshPart)
install(TARGETS flatmesh DESTINATION ${CMAKE_INSTALL_LIBDIR})
endif(BUILD_FLAT_MESH AND FREECAD_USE_PYBIND11)
endif(BUILD_FLAT_MESH)
############################################################################