From 6f8db2f64a4dec33b07565624c5375b3929980f1 Mon Sep 17 00:00:00 2001 From: Liuzr <34875556+cntpro@users.noreply.github.com> Date: Sat, 20 May 2023 09:15:21 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=9C=A8nmake=E4=B8=8Butf-8?= =?UTF-8?q?=E7=BC=96=E7=A0=81=E7=9A=84=E6=94=AF=E6=8C=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修正msvc编译错误。 --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 056e83cdc..01a335ae2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -354,6 +354,10 @@ if (CMAKE_C_COMPILER_ID MATCHES "MSVC") set(CMAKE_INSTALL_PREFIX "C:/Program Files/GmSSL") # change by `cmake -DCMAKE_INSTALL_PREFIX=C:\path\to\install` # run `set path=%path%;C:\Program Files\GmSSL\bin` add_compile_definitions(_CRT_SECURE_NO_WARNINGS) + + target_compile_options(gmssl PRIVATE /utf-8) + target_compile_options(gmssl-bin PRIVATE /utf-8) + # target_compile_options(gmssl PRIVATE /wd4996) # target_compile_options(gmssl-bin PRIVATE /wd4996) endif()