diff --git a/cmake/NNGHelpers.cmake b/cmake/NNGHelpers.cmake index a334cb8d..c5b60389 100644 --- a/cmake/NNGHelpers.cmake +++ b/cmake/NNGHelpers.cmake @@ -54,12 +54,12 @@ function(nng_link_libraries) target_link_libraries(nng PRIVATE ${ARGN}) if (DEBUG) if (ASAN) - target_link_libraries(nng_testing PRIVATE ${ARGN} -fsanitize=address) + target_link_libraries(nng_testing PRIVATE ${ARGN} -g -fsanitize=address) elseif (TSAN) - target_link_libraries(nng_testing PRIVATE ${ARGN} -fsanitize=thread) + target_link_libraries(nng_testing PRIVATE ${ARGN} -g -fsanitize=thread) endif (ASAN) else() - target_link_libraries(nng_testing PRIVATE ${ARGN} -fsanitize=address) + target_link_libraries(nng_testing PRIVATE ${ARGN} -g) endif (DEBUG) endfunction() @@ -67,12 +67,12 @@ function(nng_link_libraries_public) target_link_libraries(nng PRIVATE ${ARGN}) if (DEBUG) if (ASAN) - target_link_libraries(nng_testing PRIVATE ${ARGN} -fsanitize=address) + target_link_libraries(nng_testing PRIVATE ${ARGN} -g -fsanitize=address) elseif (TSAN) - target_link_libraries(nng_testing PRIVATE ${ARGN} -fsanitize=thread) + target_link_libraries(nng_testing PRIVATE ${ARGN} -g -fsanitize=thread) endif (ASAN) else() - target_link_libraries(nng_testing PRIVATE ${ARGN} -fsanitize=address) + target_link_libraries(nng_testing PRIVATE ${ARGN} -g) endif (DEBUG) endfunction()