aboutsummaryrefslogtreecommitdiffstats
path: root/cmake
diff options
context:
space:
mode:
authorSaturneric <[email protected]>2023-10-18 13:53:16 +0000
committerSaturneric <[email protected]>2023-10-18 13:53:16 +0000
commitedf86e2e65ac2cbcde73fa0afe31a1bf5150eb38 (patch)
tree72cbe2826336440357bcb4d48636c826e05daee9 /cmake
parentfeat: simplify the thread system and improve its stability (diff)
downloadGpgFrontend-edf86e2e65ac2cbcde73fa0afe31a1bf5150eb38.tar.gz
GpgFrontend-edf86e2e65ac2cbcde73fa0afe31a1bf5150eb38.zip
fix: solve build issues on macOS
Diffstat (limited to 'cmake')
-rw-r--r--cmake/FindGpgme.cmake20
1 files changed, 11 insertions, 9 deletions
diff --git a/cmake/FindGpgme.cmake b/cmake/FindGpgme.cmake
index ffb14b7f..7e616456 100644
--- a/cmake/FindGpgme.cmake
+++ b/cmake/FindGpgme.cmake
@@ -418,15 +418,17 @@ if ( GPGME_PTH_FOUND )
set( _gpgme_flavours "${_gpgme_flavours} pth" )
endif()
-set(GPGME_LIBRARIES "")
-
-# determine the library in one of the found flavors, can be reused e.g. by FindQgpgme.cmake, Alex
-foreach(_currentFlavour vanilla glib qt pth pthread)
- if(NOT GPGME_LIBRARY_DIR)
- get_filename_component(GPGME_LIBRARY_DIR "${_gpgme_${_currentFlavour}_lib}" PATH)
- list(APPEND GPGME_LIBRARIES "${_gpgme_${_currentFlavour}_lib}")
- endif()
-endforeach()
+if(NOT GPGME_LIBRARIES)
+ # determine the library in one of the found flavors, can be reused e.g. by FindQgpgme.cmake, Alex
+ set(GPGME_LIBRARIES "")
+ foreach(_currentFlavour vanilla glib qt pth pthread)
+ if(NOT GPGME_LIBRARY_DIR)
+ get_filename_component(GPGME_LIBRARY_DIR "${_gpgme_${_currentFlavour}_lib}" PATH)
+ list(APPEND GPGME_LIBRARIES "${_gpgme_${_currentFlavour}_lib}")
+ endif()
+ endforeach()
+
+endif()
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Gpgme