File: FindLibgcrypt.cmake

package info (click to toggle)
kodi 2%3A20.1%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 143,820 kB
  • sloc: cpp: 664,925; xml: 68,398; ansic: 37,223; python: 6,903; sh: 4,209; javascript: 2,325; makefile: 1,754; perl: 969; java: 513; cs: 390; objc: 340
file content (25 lines) | stat: -rw-r--r-- 783 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#.rst:
# FindLibgcrypt
# -------
# Finds the Libgcrypt library
#
# This will define the following variables::
#
# LIBGCRYPT_FOUND - system has Libgcrypt
# LIBGCRYPT_INCLUDE_DIRS - the Libgcrypt include directory
# LIBGCRYPT_LIBRARIES - the Libgcrypt libraries
# LIBGCRYPT_DEFINITIONS - the Libgcrypt compile definitions

find_path(LIBGCRYPT_INCLUDE_DIR gcrypt.h)
find_library(LIBGCRYPT_LIBRARY NAMES gcrypt)

include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Libgcrypt REQUIRED_VARS LIBGCRYPT_LIBRARY LIBGCRYPT_INCLUDE_DIR)

if(LIBGCRYPT_FOUND)
  set(LIBGCRYPT_LIBRARIES ${LIBGCRYPT_LIBRARY})
  set(LIBGCRYPT_INCLUDE_DIRS ${LIBGCRYPT_INCLUDE_DIR})
  set(LIBGCRYPT_DEFINITIONS -DHAVE_GCRYPT=1)
endif()

mark_as_advanced(LIBGCRYPT_LIBRARY LIBGCRYPT_INCLUDE_DIR)