clang/gcc: Add build option FREECAD_WARN_ERROR to force to make warnings into errors

This commit is contained in:
wmayer
2024-05-29 13:12:17 +02:00
committed by wwmayer
parent 8ac14f83c6
commit 560cab6f31
52 changed files with 172 additions and 7 deletions

View File

@@ -17,7 +17,6 @@ include_directories(
link_directories(${OCC_LIBRARY_DIR})
set(Path_LIBS
# Robot
Part
area-native
FreeCADApp
@@ -120,6 +119,9 @@ SOURCE_GROUP("Module" FILES ${Mod_SRCS})
add_library(Path SHARED ${Path_SRCS})
target_link_libraries(Path ${Path_LIBS})
if (FREECAD_WARN_ERROR)
target_compile_warn_error(Path)
endif()
# Boost >= 1.75.0
if(NOT ${Boost_VERSION} LESS 107500)

View File

@@ -85,6 +85,9 @@ SET(PathGuiIcon_SVG
add_library(PathGui SHARED ${PathGui_SRCS} ${PathGuiIcon_SVG})
target_link_libraries(PathGui ${PathGui_LIBS})
if (FREECAD_WARN_ERROR)
target_compile_warn_error(PathGui)
endif()
SET_BIN_DIR(PathGui PathGui /Mod/CAM)
SET_PYTHON_PREFIX_SUFFIX(PathGui)

View File

@@ -43,6 +43,9 @@ SOURCE_GROUP("Python" FILES ${Python_SRCS})
add_library(PathSimulator SHARED ${PathSimulator_SRCS})
target_link_libraries(PathSimulator ${PathSimulator_LIBS})
if (FREECAD_WARN_ERROR)
target_compile_warn_error(PathSimulator)
endif()
SET_BIN_DIR(PathSimulator PathSimulator /Mod/CAM)
SET_PYTHON_PREFIX_SUFFIX(PathSimulator)

View File

@@ -96,6 +96,9 @@ endif(FREECAD_USE_PCH)
add_library(CAMSimulator SHARED ${CAMSimulator_SRCS})
target_link_libraries(CAMSimulator ${CAMSimulator_LIBS})
if (FREECAD_WARN_ERROR)
target_compile_warn_error(CAMSimulator)
endif()
SET_BIN_DIR(CAMSimulator CAMSimulator /Mod/CAM)
SET_PYTHON_PREFIX_SUFFIX(CAMSimulator)