From cc3bcbf0693a07eb49c054952debec22d6272ffe Mon Sep 17 00:00:00 2001
From: nyako <36525792+nyyakko@users.noreply.github.com>
Date: Mon, 8 Jan 2024 03:05:41 -0300
Subject: [PATCH] ftxui_set_options: properly check the current compiler.
 (#802)

This solve the issue encountered when using clang under MSVC.
---
 cmake/ftxui_set_options.cmake | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/cmake/ftxui_set_options.cmake b/cmake/ftxui_set_options.cmake
index d01cafe5..ad4acaae 100644
--- a/cmake/ftxui_set_options.cmake
+++ b/cmake/ftxui_set_options.cmake
@@ -45,7 +45,7 @@ function(ftxui_set_options library)
 
   # Force Microsoft Visual Studio to decode sources files in UTF-8. This applies
   # to the library and the library users.
-  if (MSVC)
+  if (CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
     target_compile_options(${library} PUBLIC "/utf-8")
   endif()
 
-- 
GitLab