From a2aefeb1ab11c0867f60ebfc1a6623b47d89996e Mon Sep 17 00:00:00 2001 From: Jon Simons Date: Sat, 12 Nov 2022 14:51:18 -0500 Subject: [PATCH] cmake/Modules/FindArgp.cmake: fix ARGP warning Fix this warning generated by cmake 3.24.3 on macOS: CMake Warning (dev) at /opt/homebrew/Cellar/cmake/3.24.3/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:438 (message): The package name passed to `find_package_handle_standard_args` (ARGP) does not match the name of the calling package (Argp). This can lead to problems in calling code that expects `find_package` result variables (e.g., `_FOUND`) to follow a certain pattern. Call Stack (most recent call first): cmake/Modules/FindArgp.cmake:63 (find_package_handle_standard_args) CMakeLists.txt:107 (find_package) This warning is for project developers. Use -Wno-dev to suppress it. Testing notes: - With this change, the warning is gone on my macOS setup. Signed-off-by: Jon Simons Reviewed-by: Jakub Jelen --- cmake/Modules/FindArgp.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmake/Modules/FindArgp.cmake b/cmake/Modules/FindArgp.cmake index 454965ac..b2d91562 100644 --- a/cmake/Modules/FindArgp.cmake +++ b/cmake/Modules/FindArgp.cmake @@ -60,7 +60,7 @@ if (ARGP_LIBRARY) endif (ARGP_LIBRARY) include(FindPackageHandleStandardArgs) -find_package_handle_standard_args(ARGP DEFAULT_MSG ARGP_LIBRARIES ARGP_INCLUDE_DIR) +find_package_handle_standard_args(Argp DEFAULT_MSG ARGP_LIBRARIES ARGP_INCLUDE_DIR) # show the ARGP_INCLUDE_DIR and ARGP_LIBRARIES variables only in the advanced view mark_as_advanced(ARGP_INCLUDE_DIR ARGP_LIBRARIES)