File: FindOGG.cmake

package info (click to toggle)
fife 0.4.2-11
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 25,312 kB
  • sloc: cpp: 42,647; xml: 18,881; python: 13,521; makefile: 24
file content (28 lines) | stat: -rw-r--r-- 658 bytes parent folder | download | duplicates (6)
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
# - Try to find OGG
# and define
#
#  OGG_FOUND        - System has OGG
#  OGG_INCLUDE_DIRS - The include directories
#  OGG_LIBRARY      - The libraries

# try to find package and provide a hint
find_package(PkgConfig QUIET)
pkg_check_modules(PC_OGG QUIET ogg)

find_path(OGG_INCLUDE_DIR 
    NAMES ogg/ogg.h 
    HINTS ${PC_OGG_INCLUDE_DIRS} 
    PATH_SUFFIXES ogg
)

find_library(OGG_LIBRARY 
    NAMES ogg libogg
    HINTS ${PC_OGG_LIBRARY_DIRS}
    PATH ${OGG_INCLUDE_DIR}/../lib lib
)

include(FindPackageHandleStandardArgs)

find_package_handle_standard_args(OGG DEFAULT_MSG OGG_LIBRARY OGG_INCLUDE_DIR)

mark_as_advanced(OGG_LIBRARY OGG_INCLUDE_DIR)