File: Findseriousproton.cmake

package info (click to toggle)
seriousproton 2020.01.15%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 720 kB
  • sloc: cpp: 7,666; ansic: 376; php: 59; makefile: 15
file content (35 lines) | stat: -rw-r--r-- 1,086 bytes parent folder | download
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
#Finds an installation of Serious Proton on your system.
#
#Usage:
# find_package(seriousproton)
#
#Output:
# The following variables will be defined by this script:
# - SERIOUS_PROTON_FOUND:
#       Set to TRUE when an installation of Serious Proton was found, or to
#       FALSE if it was not found. If no installation was found, the rest of
#       the output variables will be empty.
# - SERIOUS_PROTON_LIB:
#       Path to the Serious Proton library.
# - SERIOUS_PROTON_INCLUDE_DIR:
#		Directory containing the header files for Serious Proton.


find_library(SERIOUS_PROTON_LIB
	NAMES seriousproton libseriousproton
)

find_path(SERIOUS_PROTON_INCLUDE_DIR
	NAMES multiplayer_server_scanner.h
	PATH_SUFFIXES seriousproton
)

string(FIND ${SERIOUS_PROTON_LIB} "-NOTFOUND" LIBRARY_FOUND)
string(FIND ${SERIOUS_PROTON_INCLUDE_DIR} "-NOTFOUND" HEADERS_FOUND)
if(${LIBRARY_FOUND} LESS 0 AND ${HEADERS_FOUND} LESS 0)
	set(SERIOUS_PROTON_FOUND TRUE)
	message(STATUS "Found seriousproton!")
else()
	set(SERIOUS_PROTON_FOUND FALSE)
	message(WARNING "Could NOT find seriousproton!")
endif()