[Bf-blender-cvs] [f8699881d6b] master: CMake/MSVC: Disable ASAN for developer builds

Ray Molenkamp noreply at git.blender.org
Tue Nov 1 19:46:21 CET 2022


Commit: f8699881d6bf1c02586d356b1c816e77e144ad32
Author: Ray Molenkamp
Date:   Tue Nov 1 12:46:15 2022 -0600
Branches: master
https://developer.blender.org/rBf8699881d6bf1c02586d356b1c816e77e144ad32

CMake/MSVC: Disable ASAN for developer builds

ASAN is more often broken than working depending on the MSVC version
you have. As it is causing too many support incidents of people that
unknowingly turned ASAN on by running `make developer` and running
into issues starting blender due to the broken ASAN support in MSVC.

This commit changes the default not enable it for MSVC in the
developer profile. Devs that still want to enable it can do so though
turning WITH_COMPILER_ASAN on in their CMakeCache.txt or by running
`make developer asan`

===================================================================

M	build_files/cmake/config/blender_developer.cmake

===================================================================

diff --git a/build_files/cmake/config/blender_developer.cmake b/build_files/cmake/config/blender_developer.cmake
index 1f1a100d958..ebc5727a79c 100644
--- a/build_files/cmake/config/blender_developer.cmake
+++ b/build_files/cmake/config/blender_developer.cmake
@@ -8,7 +8,11 @@
 
 set(WITH_ASSERT_ABORT                 ON  CACHE BOOL "" FORCE)
 set(WITH_BUILDINFO                    OFF CACHE BOOL "" FORCE)
-set(WITH_COMPILER_ASAN                ON  CACHE BOOL "" FORCE)
+# Sadly ASAN is more often broken than working with MSVC do not enable it in the
+# developer profile for now.
+if(NOT WIN32)
+  set(WITH_COMPILER_ASAN              ON  CACHE BOOL "" FORCE)
+endif()
 set(WITH_CYCLES_NATIVE_ONLY           ON  CACHE BOOL "" FORCE)
 set(WITH_DOC_MANPAGE                  OFF CACHE BOOL "" FORCE)
 set(WITH_GTESTS                       ON  CACHE BOOL "" FORCE)



More information about the Bf-blender-cvs mailing list