diff --git a/examples/ffi/CMakeLists.txt b/examples/ffi/CMakeLists.txt index b7b7150745..154a1340d3 100644 --- a/examples/ffi/CMakeLists.txt +++ b/examples/ffi/CMakeLists.txt @@ -11,13 +11,13 @@ function(set_vcruntime_link_type binary link_type) if (link_type STREQUAL "DLL") set_property(TARGET ${binary} PROPERTY MSVC_RUNTIME_LIBRARY "MultiThreaded$<$:Debug>DLL") else() - set_property(TARGET ${binary} PROPERTY MSVC_RUNTIME_LIBRARY "MultiThreaded$<$:Debug>") + set_property(TARGET ${binary} PROPERTY MSVC_RUNTIME_LIBRARY "MultiThreaded$<$:Debug>") endif() endif() endfunction() # Uncomment to debug build commands -# set(CMAKE_VERBOSE_MAKEFILE ON) +set(CMAKE_VERBOSE_MAKEFILE ON) add_executable(exporter exporter.cpp) # needed for designated initializers @@ -32,6 +32,7 @@ target_link_libraries(crashinfo PRIVATE Datadog::Profiling) if(CMAKE_CXX_COMPILER_ID MATCHES "MSVC") + set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /MT") target_compile_definitions(exporter PUBLIC _CRT_SECURE_NO_WARNINGS) endif() diff --git a/examples/ffi/trace_exporter.c b/examples/ffi/trace_exporter.c index c8cfb99933..2dd351ccf2 100644 --- a/examples/ffi/trace_exporter.c +++ b/examples/ffi/trace_exporter.c @@ -1,10 +1,10 @@ // Copyright 2021-Present Datadog, Inc. https://www.datadoghq.com/ // SPDX-License-Identifier: Apache-2.0 -#include -#include #include #include +#include +#include #define TRY(expr) \ { \