mirror of
https://github.com/curl/curl.git
synced 2026-07-23 14:17:20 +03:00
cmake/FindNettle: skip pkg-config for custom configs
If either `NETTLE_INCLUDE_DIR` or `NETTLE_LIBRARY` is set to customize the `nettle` dependency, skip `pkg-config` and use the CMake-native detection to honor these custom settings. Closes #14584
This commit is contained in:
parent
5b2a659ea6
commit
47849be5d5
1 changed files with 4 additions and 2 deletions
|
|
@ -23,7 +23,7 @@
|
|||
###########################################################################
|
||||
# Find the nettle library
|
||||
#
|
||||
# Input variables (when CURL_USE_PKGCONFIG=OFF):
|
||||
# Input variables:
|
||||
#
|
||||
# NETTLE_INCLUDE_DIR The nettle include directory
|
||||
# NETTLE_LIBRARY Path to nettle library
|
||||
|
|
@ -35,7 +35,9 @@
|
|||
# NETTLE_LIBRARIES The nettle library names
|
||||
# NETTLE_VERSION Version of nettle
|
||||
|
||||
if(CURL_USE_PKGCONFIG)
|
||||
if(CURL_USE_PKGCONFIG AND
|
||||
NOT DEFINED NETTLE_INCLUDE_DIR AND
|
||||
NOT DEFINED NETTLE_LIBRARY)
|
||||
find_package(PkgConfig QUIET)
|
||||
pkg_check_modules(NETTLE "nettle")
|
||||
endif()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue