From 4bab4b2e0c44fdeabad73ae8d81d30825a9adc1c Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Tue, 11 Sep 2018 20:14:52 -0700 Subject: OK, try to prevent -Wunused-function warnings with llvm-gcc as well. Change-Id: I53e48eb14d157eacd24322fb978f039e57377ed8 Reviewed-on: https://code.wireshark.org/review/29622 Reviewed-by: Guy Harris --- CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index de23e91c22..ec29925396 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -503,9 +503,14 @@ else() # ! MSVC # So we only add -Wshorten-64-to-32 if either 1) we're not building # on/for Apple or 2) we're using Clang. # + # We also suppress -Wunused-function; that's enabled by -Wall, + # but it's another warning that can be difficult to suppress + # in generated code. + # if ((NOT APPLE) OR CMAKE_C_COMPILER_ID MATCHES "Clang") list(APPEND WIRESHARK_COMMON_FLAGS -Wshorten-64-to-32 + -Wno-unused-function ) endif() -- cgit v1.2.3