Fixing build failures (#756)
* Addresses doctest.h -- error: call of overloaded ‘log10(unsigned int)’ is ambiguous #722
Typecast first argument with static_cast<double>
* Fixes build failures for clang debug type
Fixes issue #733
* Only make changes for clang
* Add dwarf info to CMakeLists.txt
* build failure fix adding gdwarf-4
* Fix clang build failures.Address issue #733 and #722
Use gdwarf-4 compile only for clang on non-windows
* Fixing build failures in workflow
* build failures
* main.yml changes
* Fix build failures
* Fix clang-14 errors
* Build failures
* Fix build failures
* fix build failures
* Build failures apt-key
* Fix build failures
* Fix build failures with gpg
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures
* Fix build failures.
* Fix build failures
* Fix for clang-14 for ubuntu-22.04
Fix for apt-key is deprecated
diff --git a/CMakeLists.txt b/CMakeLists.txt
index ac69929..6d384fa 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -53,6 +53,14 @@
target_include_directories(${PROJECT_NAME} INTERFACE $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/>)
endif()
+if(CMAKE_BUILD_TYPE STREQUAL "Debug")
+ if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
+ if (NOT WIN32)
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -gdwarf-4 ")
+ endif()
+ endif()
+endif()
+
# hack to support building on XCode 6 and 7 - propagate the definition to everything
if(DEFINED DOCTEST_THREAD_LOCAL)
target_compile_definitions(${PROJECT_NAME} INTERFACE