File: FindRSSDK.cmake

package info (click to toggle)
obs-studio 26.1.2%2Bdfsg1-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 30,216 kB
  • sloc: ansic: 164,164; cpp: 67,957; objc: 1,003; makefile: 834; sh: 660; python: 137
file content (40 lines) | stat: -rw-r--r-- 715 bytes parent folder | download | duplicates (2)
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
39
40
# Once done these will be defined:
#
#  RSSDK_FOUND
#  RSSDK_INCLUDE_DIRS
#  RSSDK_LIBRARIES
#
# For use in OBS:
#
#  RSSDK_INCLUDE_DIR

if(CMAKE_SIZEOF_VOID_P EQUAL 8)
	set(_RSSDK_lib_dir "x64")
else()
	set(_RSSDK_lib_dir "Win32")
endif()

find_path(RSSDK_INCLUDE_DIR
	NAMES pxcsession.h
	HINTS
		ENV RSSDK_DIR
	PATH_SUFFIXES
		include)

find_library(RSSDK_LIB
	NAMES libpxc
	HINTS
		ENV RSSDK_DIR
	PATH_SUFFIXES
		lib/${_RSSDK_lib_dir}
	)

include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(RSSDK DEFAULT_MSG RSSDK_LIB RSSDK_INCLUDE_DIR)
mark_as_advanced(RSSDK_INCLUDE_DIR RSSDK_LIB)

if(RSSDK_FOUND)
	set(RSSDK_INCLUDE_DIRS ${RSSDK_INCLUDE_DIR})
	set(RSSDK_LIBRARIES ${RSSDK_LIB})
endif()