Debian Codegraph @

cmake/modules/FindSunPinyin.cmake

raw
1 # - Try to find SunPinyin
2 # Once done, this will define
3 #
4 # SunPinyin_FOUND - system has iBus
5 # SunPinyin_INCLUDE_DIRS - the iBus include directories
6 # SunPinyin_LIBRARIES - link these to use iBus
7
8 include(LibFindMacros)
9
10 # Dependencies
11
12 # Use pkg-config to get hints about paths
13 libfind_pkg_check_modules(SunPinyin_PKGCONF sunpinyin-2.0)
14
15 # Include dir
16 find_path(SunPinyin_INCLUDE_DIR
17 NAMES sunpinyin.h
18 PATHS ${SunPinyin_PKGCONF_INCLUDE_DIRS}
19 )
20
21 # Finally the library itself
22 find_library(SunPinyin_LIBRARY
23 NAMES sunpinyin
24 PATHS ${SunPinyin_PKGCONF_LIBRARY_DIRS}
25 )
26
27 # Set the include dir variables and the libraries and let libfind_process do the
28 # rest.
29 # NOTE: Singular variables for this library, plural for libraries this this lib
30 # depends on.
31 set(SunPinyin_PROCESS_INCLUDES SunPinyin_INCLUDE_DIR)
32 set(SunPinyin_PROCESS_LIBS SunPinyin_LIBRARY)
33 libfind_process(SunPinyin)
34
35 # -*- indent-tabs-mode: nil -*- vim:et:ts=4