From a3991874eb3d470a4adfcdef7903ab8d6dd8f881 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Valverde?= Date: Thu, 10 Jan 2019 01:45:00 +0000 Subject: CMake: Replace PACKAGELIST magic MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is more explicit and easier to read with slightly better locality while using less code. Also less awkward when the package doesn't fit the narrow package list expectations. The ws_find_package() macro doesn't include all the status messages. The choice was to rely on standard find_package() and feature_summary() output and be less verbose. Avoid polluting the CLI build interface. Per target include paths and macro definitions are preferred. Because this patch intentionally removes the global CMAKE_*_FLAGS and include_directories() usage in favor of target properties, some untested build configurations may inadvertently break because of missing ${PACKAGE}_INCLUDE_DIRS or ${PACKAGE}_DEFINITIONS. This required a manual review of dependencies that might have been incomplete. ${PACKAGE_VAR}_LINK_FLAGS seems to be unused. Changing the CMake Qt code to use more modern CMake component syntax is left as future work. Change-Id: I3ed75252189a6e05a23ed6e619088f519cd7ed78 Reviewed-on: https://code.wireshark.org/review/31496 Petri-Dish: João Valverde Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu --- capchild/CMakeLists.txt | 2 ++ 1 file changed, 2 insertions(+) (limited to 'capchild') diff --git a/capchild/CMakeLists.txt b/capchild/CMakeLists.txt index 7fe2e8b850..cfea58eb99 100644 --- a/capchild/CMakeLists.txt +++ b/capchild/CMakeLists.txt @@ -26,6 +26,8 @@ add_library(capchild STATIC ${CAPCHILD_SRC} ) +target_link_libraries(capchild PRIVATE wsutil) + set_target_properties(capchild PROPERTIES LINK_FLAGS "${WS_LINK_FLAGS}" FOLDER "Libs") -- cgit v1.2.3