Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRay Molenkamp <github@lazydodo.com>2019-06-26 00:27:21 +0300
committerRay Molenkamp <github@lazydodo.com>2019-06-26 00:27:21 +0300
commit9ab0247b6efcf0659648d006b3d216d0fd708cae (patch)
treea533771b8642bebecb34a3975dfbb1a11231ad2a /build_files/cmake/macros.cmake
parent7037ff9204475ae4dd19926b55382d558fc12a62 (diff)
MSVC: Don't share pch between debug and release builds.
Precompiled headers were sharing the PCH file between debug and release builds which is 'bad'. Adding the configuration to the path fixes the issue. Reported on chat by @mano-wii
Diffstat (limited to 'build_files/cmake/macros.cmake')
-rw-r--r--build_files/cmake/macros.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/build_files/cmake/macros.cmake b/build_files/cmake/macros.cmake
index e6ae3b5efdb..e781186ca74 100644
--- a/build_files/cmake/macros.cmake
+++ b/build_files/cmake/macros.cmake
@@ -1243,7 +1243,7 @@ macro(blender_precompile_headers target cpp header)
if(MSVC)
# get the name for the pch output file
get_filename_component( pchbase ${cpp} NAME_WE )
- set( pchfinal "${CMAKE_CURRENT_BINARY_DIR}/${pchbase}.pch" )
+ set( pchfinal "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${pchbase}.pch" )
# mark the cpp as the one outputting the pch
set_property(SOURCE ${cpp} APPEND PROPERTY OBJECT_OUTPUTS "${pchfinal}")