From e5ba177910724ab96dc66b219303a3e6a5f0cff7 Mon Sep 17 00:00:00 2001 From: Sebastian Krzyszkowiak Date: Thu, 2 Nov 2023 07:42:01 +0100 Subject: [PATCH] cmake: Enable assertions for Emscripten Debug builds --- cmake/libsuperderpy.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmake/libsuperderpy.cmake b/cmake/libsuperderpy.cmake index f1a702e..afbd836 100644 --- a/cmake/libsuperderpy.cmake +++ b/cmake/libsuperderpy.cmake @@ -120,8 +120,8 @@ if (NOT LIBSUPERDERPY_CONFIG_INCLUDED) message(STATUS "Sanitizers unavailable under Emscripten, disabling...") set(SANITIZERS_ARGS "") endif() - set(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -g3 -s ASSERTIONS=1") - set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -g3 -s ASSERTIONS=1") + set(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -g3 -s ASSERTIONS=2 -s SAFE_HEAP=1") + set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -g3 -s ASSERTIONS=2 -s SAFE_HEAP=1") else() if(MAEMO5 AND SANITIZERS_ARGS) message(STATUS "Sanitizers unavailable on Maemo, disabling...")