diff options
author | Jacek Antonelli | 2008-09-06 18:24:57 -0500 |
---|---|---|
committer | Jacek Antonelli | 2008-09-06 18:25:07 -0500 |
commit | 798d367d54a6c6379ad355bd8345fa40e31e7fe9 (patch) | |
tree | 1921f1708cd0240648c97bc02df2c2ab5f2fc41e /linden/indra/cmake/FMOD.cmake | |
parent | Second Life viewer sources 1.20.15 (diff) | |
download | meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.zip meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.gz meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.bz2 meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.xz |
Second Life viewer sources 1.21.0-RC
Diffstat (limited to 'linden/indra/cmake/FMOD.cmake')
-rw-r--r-- | linden/indra/cmake/FMOD.cmake | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/linden/indra/cmake/FMOD.cmake b/linden/indra/cmake/FMOD.cmake new file mode 100644 index 0000000..759b8f1 --- /dev/null +++ b/linden/indra/cmake/FMOD.cmake | |||
@@ -0,0 +1,64 @@ | |||
1 | # -*- cmake -*- | ||
2 | |||
3 | include(Linking) | ||
4 | |||
5 | if(INSTALL_PROPRIETARY) | ||
6 | include(Prebuilt) | ||
7 | use_prebuilt_binary(fmod) | ||
8 | endif(INSTALL_PROPRIETARY) | ||
9 | |||
10 | find_library(FMOD_LIBRARY_RELEASE | ||
11 | NAMES fmod fmodvc fmod-3.75 | ||
12 | PATHS | ||
13 | ${ARCH_PREBUILT_DIRS_RELEASE} | ||
14 | ) | ||
15 | |||
16 | find_library(FMOD_LIBRARY_DEBUG | ||
17 | NAMES fmod fmodvc fmod-3.75 | ||
18 | PATHS | ||
19 | ${ARCH_PREBUILT_DIRS_DEBUG} | ||
20 | ) | ||
21 | |||
22 | if (FMOD_LIBRARY_RELEASE AND FMOD_LIBRARY_DEBUG) | ||
23 | set(FMOD_LIBRARY | ||
24 | debug ${FMOD_LIBRARY_DEBUG} | ||
25 | optimized ${FMOD_LIBRARY_RELEASE}) | ||
26 | elseif (FMOD_LIBRARY_RELEASE) | ||
27 | set(FMOD_LIBRARY ${FMOD_LIBRARY_RELEASE}) | ||
28 | endif (FMOD_LIBRARY_RELEASE AND FMOD_LIBRARY_DEBUG) | ||
29 | |||
30 | if (NOT FMOD_LIBRARY) | ||
31 | set(FMOD_SDK_DIR CACHE PATH "Path to the FMOD SDK.") | ||
32 | if (FMOD_SDK_DIR) | ||
33 | find_library(FMOD_LIBRARY | ||
34 | NAMES fmodvc fmod-3.75 fmod | ||
35 | PATHS | ||
36 | ${FMOD_SDK_DIR}/api/lib | ||
37 | ${FMOD_SDK_DIR}/api | ||
38 | ${FMOD_SDK_DIR}/lib | ||
39 | ${FMOD_SDK_DIR} | ||
40 | ) | ||
41 | endif (FMOD_SDK_DIR) | ||
42 | endif (NOT FMOD_LIBRARY) | ||
43 | |||
44 | find_path(FMOD_INCLUDE_DIR fmod.h | ||
45 | ${LIBS_PREBUILT_DIR}/include | ||
46 | ${FMOD_SDK_DIR}/api/inc | ||
47 | ${FMOD_SDK_DIR}/inc | ||
48 | ${FMOD_SDK_DIR} | ||
49 | ) | ||
50 | |||
51 | if (FMOD_LIBRARY AND FMOD_INCLUDE_DIR) | ||
52 | set(FMOD ON CACHE BOOL "Use closed source FMOD sound library.") | ||
53 | else (FMOD_LIBRARY AND FMOD_INCLUDE_DIR) | ||
54 | set(FMOD_LIBRARY "") | ||
55 | set(FMOD_INCLUDE_DIR "") | ||
56 | if (FMOD) | ||
57 | message(STATUS "No support for FMOD audio (need to set FMOD_SDK_DIR?)") | ||
58 | endif (FMOD) | ||
59 | set(FMOD OFF CACHE BOOL "Use closed source FMOD sound library.") | ||
60 | endif (FMOD_LIBRARY AND FMOD_INCLUDE_DIR) | ||
61 | |||
62 | if (FMOD) | ||
63 | message(STATUS "Building with FMOD audio support") | ||
64 | endif (FMOD) | ||