From adc4c9f3c296e3adfe31596b195e5e7f50dc9bd9 Mon Sep 17 00:00:00 2001 From: Changqing Jing Date: Fri, 12 Jul 2024 13:08:25 +0800 Subject: Fix deprecated FetchContent_Populate warning third_party/uvwasi cmake build (#2440) --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index d34e642f..df6ebbff 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -573,7 +573,11 @@ if (BUILD_TOOLS) ) if(WITH_WASI) + # uvwasi uses the deprecated FetchContent_Populate function, disable it to avoid build error + set(CMAKE_POLICY_DEFAULT_CMP0169_BACK ${CMAKE_POLICY_DEFAULT_CMP0169}) + set(CMAKE_POLICY_DEFAULT_CMP0169 OLD) add_subdirectory("third_party/uvwasi" EXCLUDE_FROM_ALL) + set(CMAKE_POLICY_DEFAULT_CMP0169 ${CMAKE_POLICY_DEFAULT_CMP0169_BACK}) include_directories(third_party/uvwasi/include) add_definitions(-DWITH_WASI) set(INTERP_LIBS uvwasi_a) -- cgit v1.2.3