From cd9d29bf2b5e4eadab2b07747db05126c225a893 Mon Sep 17 00:00:00 2001 From: Jeremy <51220084+jeremy-rifkin@users.noreply.github.com> Date: Mon, 6 Nov 2023 17:14:54 -0500 Subject: [PATCH] Suppress ranlib "has no symbols" warnings --- CMakeLists.txt | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 621705e..fd1345a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -255,6 +255,14 @@ target_compile_features( PRIVATE cxx_std_11 ) +if(APPLE) + set_property( + TARGET ${target_name} + APPEND + PROPERTY STATIC_LIBRARY_FLAGS "-no_warning_for_no_symbols" + ) +endif() + # =============================================== Apply options to build =============================================== if(HAS_CXX_EXCEPTION_TYPE)