From 0a15214408a8d5d409d2a29c8ceac4834d59238e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stankovi=C4=87=20Milan?= Date: Fri, 2 Feb 2024 09:40:27 +0100 Subject: [PATCH] Explicitly enabled experimental coroutine support on MSVC compilers --- windows/CMakeLists.txt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/windows/CMakeLists.txt b/windows/CMakeLists.txt index 8521ea6..8989c40 100644 --- a/windows/CMakeLists.txt +++ b/windows/CMakeLists.txt @@ -51,6 +51,10 @@ add_library(${PLUGIN_NAME} SHARED "util/string_converter.cc" ) +if(MSVC) + target_compile_options(${PLUGIN_NAME} PRIVATE "/await") +endif() + if(NOT FLUTTER_WEBVIEW_WINDOWS_USE_TEXTURE_FALLBACK) message(STATUS "Building with D3D texture support.") target_compile_definitions("${PLUGIN_NAME}" PRIVATE @@ -67,7 +71,7 @@ else() ) # Enable AVX2 for pixel buffer conversions if(MSVC) - target_compile_options(${PLUGIN_NAME} PRIVATE "/arch:AVX2") + target_compile_options(${PLUGIN_NAME} PRIVATE "/arch:AVX2" "/await") endif() endif()