File: FindNVCtrlLib.cmake

package info (click to toggle)
vtk6 6.3.0%2Bdfsg1-5
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 118,532 kB
  • ctags: 138,251
  • sloc: cpp: 1,443,749; ansic: 113,395; python: 72,383; tcl: 46,998; xml: 8,127; yacc: 4,525; java: 4,239; perl: 3,108; lex: 1,694; sh: 1,093; asm: 471; makefile: 95; objc: 17
file content (38 lines) | stat: -rw-r--r-- 1,329 bytes parent folder | download | duplicates (8)
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
26
27
28
29
30
31
32
33
34
35
36
37
38
# -----------------------------------------------------------------------------
# Find NVCtrlLib SDK
# Define:
# NVCtrlLib_FOUND
# NVCtrlLib_INCLUDE_DIR
# NVCtrlLib_LIBRARY

# typically, download the source package of nvidia-settings from:
# ftp://download.nvidia.com/XFree86/nvidia-settings/
# once uncompressed, nvidia-settings-1.0/src/libXNVCtrl directory contents
# libXNVCtrl.a, NVCtrlLib.h and NVCtrl.h.

# or if it is already installed by the distribution:
# /usr/lib/libXNVCtrl.a
# /usr/include/NVCtrl/NVCtrl.h
# /usr/include/NVCtrl/NVCtrlLib.h

# License issue:
# libXNVCtrl is intended to be MIT-X11 / BSD but is marked as GPL in older
# driver versions.
# This issue has been raised in this thread:
# http://www.nvnews.net/vbulletin/showpost.php?p=1756087&postcount=8
# it has been fixed in drivers 177.82 and above

set(NVCtrlLib_FOUND false)
set(NVCtrlLib_INCLUDE_DIR)
set(NVCtrlLib_LIBRARY)

# search for libXNVCtrl.a
# typically in nvidia-settings-1.0/src/libXNVCtrl/libXNVCtrl.a
find_library(NVCtrlLib_LIBRARY XNVCtrl /usr/lib
             DOC "Path to NVCONTROL static library (libXNVCtrl.a)")
find_path(NVCtrlLib_INCLUDE_DIR NVCtrlLib.h /usr/include/NVCtrl
          DOC "Path to NVCONTROL headers (NVCtrlLib.h and NVCtrl.h)")

if(NVCtrlLib_LIBRARY AND NVCtrlLib_INCLUDE_DIR)
 set(NVCtrlLib_FOUND true)
endif()