From 445459b204d384a417dd39ffdfb8c273e377fad2 Mon Sep 17 00:00:00 2001 From: UE4SS Date: Wed, 13 Sep 2023 23:34:45 +0200 Subject: [PATCH] Added printf=printf_s macro for Clang This fixes an error where printf_s doesn't exist. --- CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 650f4368a..344968895 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -85,6 +85,7 @@ if (${CMAKE_CXX_COMPILER_ID} STREQUAL MSVC) elseif (${CMAKE_CXX_COMPILER_ID} STREQUAL Clang) set(PRIVATE_COMPILE_OPTIONS "$,,-g;-gcodeview;-fcolor-diagnostics;-Wno-unknown-pragmas;-Wno-unused-parameter>") set(PRIVATE_LINK_OPTIONS "$,,-g>") + add_compile_definitions(printf_s=printf) endif () set(PUBLIC_COMPILE_FEATURES cxx_std_20) set(CMAKE_EXPORT_COMPILE_COMMANDS ON)