Last change
on this file since 2617 was
2616,
checked in by rgrieder, 16 years ago
|
- Split FindOggVorbis.cmake in two. Having them in one file doesn't make sense, we can group it somewhere else.
- Updated all find scripts
- Removed all standard paths (like /usr /usr/local, etc.) because they're already searched by CMake anyway
- Several workarounds for certain libraries when using the find script in the CMake module path.
|
-
Property svn:eol-style set to
native
|
File size:
1.4 KB
|
Rev | Line | |
---|
[2509] | 1 | # - Try to find ogg/vorbis |
---|
| 2 | # Once done this will define |
---|
| 3 | # |
---|
| 4 | # VORBIS_FOUND - system has vorbis |
---|
| 5 | # VORBIS_INCLUDE_DIR |
---|
| 6 | # VORBIS_LIBRARY |
---|
| 7 | # VORBISENC_LIBRARY |
---|
| 8 | # VORBISFILE_LIBRARY |
---|
| 9 | # |
---|
[2616] | 10 | # $VORBISDIR is an environment variable used |
---|
| 11 | # for finding vorbis. |
---|
[2509] | 12 | # |
---|
[1776] | 13 | # Several changes and additions by Fabian 'x3n' Landau |
---|
[2509] | 14 | # Most of all rewritten by Adrian Friedli |
---|
[1776] | 15 | # > www.orxonox.net < |
---|
[1505] | 16 | |
---|
[2583] | 17 | INCLUDE(FindPackageHandleStandardArgs) |
---|
| 18 | INCLUDE(HandleLibraryTypes) |
---|
| 19 | |
---|
[1505] | 20 | FIND_PATH(VORBIS_INCLUDE_DIR vorbis/codec.h |
---|
[2616] | 21 | PATHS $ENV{VORBISDIR} |
---|
[2509] | 22 | PATH_SUFFIXES include |
---|
| 23 | ) |
---|
[2616] | 24 | FIND_LIBRARY(VORBIS_LIBRARY_OPTIMIZED |
---|
| 25 | NAMES vorbis |
---|
| 26 | PATHS $ENV{VORBISDIR} |
---|
[2509] | 27 | PATH_SUFFIXES lib |
---|
| 28 | ) |
---|
[2616] | 29 | FIND_LIBRARY(VORBIS_LIBRARY_DEBUG |
---|
| 30 | NAMES vorbisd vorbis_d |
---|
| 31 | PATHS $ENV{VORBISDIR} |
---|
[2509] | 32 | PATH_SUFFIXES lib |
---|
| 33 | ) |
---|
[2616] | 34 | FIND_LIBRARY(VORBISFILE_LIBRARY_OPTIMIZED |
---|
| 35 | NAMES vorbisfile |
---|
| 36 | PATHS $ENV{VORBISDIR} |
---|
[2509] | 37 | PATH_SUFFIXES lib |
---|
| 38 | ) |
---|
[2616] | 39 | FIND_LIBRARY(VORBISFILE_LIBRARY_DEBUG |
---|
| 40 | NAMES vorbisfiled vorbisfile_d |
---|
| 41 | PATHS $ENV{VORBISDIR} |
---|
[2579] | 42 | PATH_SUFFIXES lib |
---|
| 43 | ) |
---|
[1505] | 44 | |
---|
[2616] | 45 | # Handle the REQUIRED argument and set VORBIS_FOUND |
---|
| 46 | FIND_PACKAGE_HANDLE_STANDARD_ARGS(Vorbis DEFAULT_MSG |
---|
[2579] | 47 | VORBIS_LIBRARY_OPTIMIZED |
---|
| 48 | VORBISFILE_LIBRARY_OPTIMIZED |
---|
[2509] | 49 | VORBIS_INCLUDE_DIR |
---|
| 50 | ) |
---|
[1505] | 51 | |
---|
[2616] | 52 | # Collect optimized and debug libraries |
---|
[2614] | 53 | HANDLE_LIBRARY_TYPES(VORBIS) |
---|
| 54 | HANDLE_LIBRARY_TYPES(VORBISFILE) |
---|
[2616] | 55 | SET(VORBIS_LIBRARIES ${VORBIS_LIBRARY} ${VORBISFILE_LIBRARY}) |
---|
[2579] | 56 | |
---|
[2509] | 57 | MARK_AS_ADVANCED( |
---|
[2616] | 58 | VORBIS_INCLUDE_DIR |
---|
[2579] | 59 | VORBIS_LIBRARY_OPTIMIZED |
---|
| 60 | VORBIS_LIBRARY_DEBUG |
---|
| 61 | VORBISFILE_LIBRARY_OPTIMIZED |
---|
| 62 | VORBISFILE_LIBRARY_DEBUG |
---|
[2509] | 63 | ) |
---|
Note: See
TracBrowser
for help on using the repository browser.