1
0
mirror of synced 2024-11-24 07:40:17 +01:00

build: Add option to not generate PDB files in release builds

This commit is contained in:
WerWolv 2024-01-15 23:33:31 +01:00
parent b3d3794e1d
commit 2cc07f0e73
2 changed files with 5 additions and 0 deletions

View File

@ -16,6 +16,7 @@ option(IMHEX_STRICT_WARNINGS "Enable most available warnings and treat them as e
option(IMHEX_STATIC_LINK_PLUGINS "Statically link all plugins into the main executable" OFF)
option(IMHEX_GENERATE_PACKAGE "Specify if a native package should be built. Only usable on Windows and MacOS" OFF)
option(IMHEX_ENABLE_UNITY_BUILD "Enables building ImHex as a unity build." OFF)
option(IMHEX_GENERATE_PDBS "Enable generating PDB files in non-debug builds" ON)
# Basic compiler and cmake configurations
set(CMAKE_CXX_STANDARD 23)

View File

@ -648,6 +648,10 @@ function(enableUnityBuild TARGET)
endfunction()
function(generatePDBs)
if (NOT IMHEX_GENERATE_PDBS)
return()
endif ()
if (NOT WIN32 OR CMAKE_BUILD_TYPE STREQUAL "Debug")
return()
endif ()