From d70772a42debc40d4c13fd735913ee6ae322aa9b Mon Sep 17 00:00:00 2001 From: Ivan Maidanski Date: Mon, 17 Apr 2023 20:30:51 +0300 Subject: Prevent 'function should return a value' BCC error in CMake script * CMakeLists.txt [enable_werror && BORLAND && enable_threads]: Pass "/w-rvl" to add_compile_options; add comment. --- CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'CMakeLists.txt') diff --git a/CMakeLists.txt b/CMakeLists.txt index a9e11847..7bf50784 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -394,6 +394,11 @@ endif(enable_checksums) if (enable_werror) if (BORLAND) add_compile_options(/w!) + if (enable_threads) + # Workaround "function should return a value" warning for several + # asm functions in atomic_ops/sysdeps/msftc/x86.h. + add_compile_options(/w-rvl) + endif(enable_threads) elseif (MSVC) add_compile_options(/WX) # Workaround "typedef ignored on left of ..." warning reported in -- cgit v1.2.1