forked from leapmotion/cmake-modules
-
Notifications
You must be signed in to change notification settings - Fork 0
/
FindIrrklang.cmake
48 lines (43 loc) · 1.22 KB
/
FindIrrklang.cmake
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
41
42
43
44
45
46
47
48
#.rst
# FindIrrklang
# ------------
#
# Created by Walter Gray.
# Locate and configure Irrklang
#
# Interface Targets
# ^^^^^^^^^^^^^^^^^
# Irrklang::Irrklang
#
# Variables
# ^^^^^^^^^
# Irrklang_ROOT_DIR
# Irrklang_FOUND
# Irrklang_INCLUDE_DIR
# Irrklang_LIBRARY
# Irrklang_IMPORT_LIB
find_path(Irrklang_ROOT_DIR
NAMES include/irrKlang.h
HINTS ${EXTERNAL_LIBRARY_DIR}
PATH_SUFFIXES irrKlang-${Irrklang_FIND_VERSION}
irrKlang)
find_path(Irrklang_INCLUDE_DIR
NAMES irrKlang.h
HINTS "${Irrklang_ROOT_DIR}/include")
if(MSVC)
find_file(Irrklang_LIBRARY
NAMES irrKlang.dll
HINTS "${Irrklang_ROOT_DIR}/bin/win32-visualStudio/")
find_library(Irrklang_IMPORT_LIB
NAMES irrKlang.lib
HINTS "${Irrklang_ROOT_DIR}/lib/win32-visualStudio/")
mark_as_advanced(Irrklang_IMPORT_LIB)
else()
find_library(Irrklang_LIBRARY
NAMES libirrklang.dylib
HINTS "${Irrklang_ROOT_DIR}/bin/macosx-gcc/")
endif()
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Irrklang DEFAULT_MSG Irrklang_INCLUDE_DIR Irrklang_LIBRARY)
include(CreateImportTargetHelpers)
generate_import_target(Irrklang SHARED)