File: FindOpenSL.cmake

package info (click to toggle)
allegro5 2%3A5.2.10.1%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 10,872 kB
  • sloc: ansic: 109,795; cpp: 12,976; objc: 4,592; java: 2,845; python: 2,595; javascript: 1,238; sh: 1,008; makefile: 41; xml: 27; pascal: 24
file content (30 lines) | stat: -rw-r--r-- 898 bytes parent folder | download | duplicates (4)
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
# - Find OpenSL (actually OpenSLES)
# Find the OpenSLES includes and libraries
#
#  OPENSL_INCLUDE_DIR - where to find dsound.h
#  OPENSL_LIBRARIES   - List of libraries when using dsound.
#  OPENSL_FOUND       - True if dsound found.

if(OPENSL_INCLUDE_DIR)
    # Already in cache, be silent
    set(OPENSL_FIND_QUIETLY TRUE)
endif(OPENSL_INCLUDE_DIR)

find_path(OPENSL_INCLUDE_DIR SLES/OpenSLES.h)

find_library(OPENSL_LIBRARY NAMES OpenSLES)

# Handle the QUIETLY and REQUIRED arguments and set OPENSL_FOUND to TRUE if
# all listed variables are TRUE.
include(FindPackageHandleStandardArgs)
set(FPHSA_NAME_MISMATCHED TRUE)
find_package_handle_standard_args(OPENSL DEFAULT_MSG
    OPENSL_INCLUDE_DIR OPENSL_LIBRARY)

if(OPENSL_FOUND)
    set(OPENSL_LIBRARIES ${OPENSL_LIBRARY})
else(OPENSL_FOUND)
    set(OPENSL_LIBRARIES)
endif(OPENSL_FOUND)

mark_as_advanced(OPENSL_INCLUDE_DIR OPENSL_LIBRARY)