Skip to content

Commit

Permalink
src/core/CMakeLists.txt: enable UNITY_BUILD
Browse files Browse the repository at this point in the history
  • Loading branch information
rouault committed Nov 30, 2024
1 parent 5a4f837 commit d93ff88
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/core/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2339,6 +2339,14 @@ add_library(qgis_core ${LIBRARY_TYPE} ${QGIS_CORE_SRCS} ${QGIS_CORE_HDRS} ${QGIS

target_precompile_headers(qgis_core PRIVATE $<$<COMPILE_LANGUAGE:CXX>:qgis.h>)

set_target_properties(qgis_core PROPERTIES UNITY_BUILD ON)

# Exclude below files because they include tiny_gltf.h with different #define settings
set_source_files_properties(tiledscene/qgsgltfutils.cpp
tiledscene/qgsquantizedmeshtiles.cpp
tiledscene/qgstiledscenelayerrenderer.cpp
PROPERTIES SKIP_UNITY_BUILD_INCLUSION ON)

# Add meshoptimizer
if(WITH_INTERNAL_MESHOPTIMIZER)
target_sources(qgis_core PRIVATE
Expand Down

0 comments on commit d93ff88

Please sign in to comment.