aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/cmake
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--linden/indra/cmake/00-Common.cmake8
-rw-r--r--linden/indra/cmake/APR.cmake23
-rw-r--r--linden/indra/cmake/CopyWinLibs.cmake106
-rw-r--r--linden/indra/cmake/DirectX.cmake22
-rw-r--r--linden/indra/cmake/FindMono.cmake18
-rw-r--r--linden/indra/cmake/GStreamer.cmake2
-rw-r--r--linden/indra/cmake/GooglePerfTools.cmake6
-rw-r--r--linden/indra/cmake/LLAudio.cmake3
-rw-r--r--linden/indra/cmake/LLKDU.cmake20
-rw-r--r--linden/indra/cmake/LLXML.cmake2
-rw-r--r--linden/indra/cmake/Linking.cmake8
-rw-r--r--linden/indra/cmake/NDOF.cmake6
-rw-r--r--linden/indra/cmake/OPENAL.cmake85
-rw-r--r--linden/indra/cmake/Python.cmake1
-rw-r--r--linden/indra/cmake/QuickTime.cmake22
15 files changed, 220 insertions, 112 deletions
diff --git a/linden/indra/cmake/00-Common.cmake b/linden/indra/cmake/00-Common.cmake
index 977e588..c41591f 100644
--- a/linden/indra/cmake/00-Common.cmake
+++ b/linden/indra/cmake/00-Common.cmake
@@ -49,6 +49,10 @@ if (WINDOWS)
49 ) 49 )
50 50
51 if(MSVC80 OR MSVC90) 51 if(MSVC80 OR MSVC90)
52 set(CMAKE_CXX_FLAGS_RELEASE
53 "${CMAKE_CXX_FLAGS_RELEASE} -D_SECURE_STL=0 -D_HAS_ITERATOR_DEBUGGING=0"
54 CACHE STRING "C++ compiler release options" FORCE)
55
52 add_definitions( 56 add_definitions(
53 /Zc:wchar_t- 57 /Zc:wchar_t-
54 ) 58 )
@@ -165,6 +169,10 @@ if (DARWIN)
165 set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_CXX_LINK_FLAGS}") 169 set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_CXX_LINK_FLAGS}")
166 set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mlong-branch") 170 set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mlong-branch")
167 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mlong-branch") 171 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mlong-branch")
172 # NOTE: it's critical that the optimization flag is put in front.
173 # NOTE: it's critical to have both CXX_FLAGS and C_FLAGS covered.
174 set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O0 ${CMAKE_CXX_FLAGS_RELWITHDEBINFO}")
175 set(CMAKE_C_FLAGS_RELWITHDEBINFO "-O0 ${CMAKE_C_FLAGS_RELWITHDEBINFO}")
168endif (DARWIN) 176endif (DARWIN)
169 177
170 178
diff --git a/linden/indra/cmake/APR.cmake b/linden/indra/cmake/APR.cmake
index 2a96d70..2563a98 100644
--- a/linden/indra/cmake/APR.cmake
+++ b/linden/indra/cmake/APR.cmake
@@ -15,24 +15,16 @@ if (STANDALONE)
15else (STANDALONE) 15else (STANDALONE)
16 use_prebuilt_binary(apr_suite) 16 use_prebuilt_binary(apr_suite)
17 if (WINDOWS) 17 if (WINDOWS)
18 set(WINLIBS_PREBUILT_DEBUG_DIR
19 ${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/debug
20 )
21 set(WINLIBS_PREBUILT_RELEASE_DIR
22 ${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/release
23 )
24 set(APR_LIBRARIES 18 set(APR_LIBRARIES
25 debug ${WINLIBS_PREBUILT_DEBUG_DIR}/apr-1.lib 19 debug ${ARCH_PREBUILT_DIRS_DEBUG}/apr-1.lib
26 optimized ${WINLIBS_PREBUILT_RELEASE_DIR}/apr-1.lib 20 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/apr-1.lib
27 ) 21 )
28 set(APRUTIL_LIBRARIES 22 set(APRUTIL_LIBRARIES
29 debug ${WINLIBS_PREBUILT_DEBUG_DIR}/aprutil-1.lib 23 debug ${ARCH_PREBUILT_DIRS_DEBUG}/aprutil-1.lib
30 optimized ${WINLIBS_PREBUILT_RELEASE_DIR}/aprutil-1.lib 24 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/aprutil-1.lib
31 )
32 set(APRICONV_LIBRARIES
33 debug ${WINLIBS_PREBUILT_DEBUG_DIR}/apriconv-1.lib
34 optimized ${WINLIBS_PREBUILT_RELEASE_DIR}/apriconv-1.lib
35 ) 25 )
26 # Doesn't need to link with iconv.dll
27 set(APRICONV_LIBRARIES "")
36 elseif (DARWIN) 28 elseif (DARWIN)
37 set(APR_LIBRARIES 29 set(APR_LIBRARIES
38 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libapr-1.a 30 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libapr-1.a
@@ -42,10 +34,11 @@ else (STANDALONE)
42 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libaprutil-1.a 34 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libaprutil-1.a
43 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/libaprutil-1.a 35 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/libaprutil-1.a
44 ) 36 )
45 set(APRICONV_LIBRARIES apriconv-1) 37 set(APRICONV_LIBRARIES iconv)
46 else (WINDOWS) 38 else (WINDOWS)
47 set(APR_LIBRARIES apr-1) 39 set(APR_LIBRARIES apr-1)
48 set(APRUTIL_LIBRARIES aprutil-1) 40 set(APRUTIL_LIBRARIES aprutil-1)
41 set(APRICONV_LIBRARIES iconv)
49 endif (WINDOWS) 42 endif (WINDOWS)
50 set(APR_INCLUDE_DIR ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/apr-1) 43 set(APR_INCLUDE_DIR ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/apr-1)
51 44
diff --git a/linden/indra/cmake/CopyWinLibs.cmake b/linden/indra/cmake/CopyWinLibs.cmake
index 345761a..3d70c8f 100644
--- a/linden/indra/cmake/CopyWinLibs.cmake
+++ b/linden/indra/cmake/CopyWinLibs.cmake
@@ -14,7 +14,6 @@ set(vivox_files
14 ssleay32.dll 14 ssleay32.dll
15 SLVoiceAgent.exe 15 SLVoiceAgent.exe
16 srtp.dll 16 srtp.dll
17 alut.dll
18 vivoxsdk.dll 17 vivoxsdk.dll
19 ortp.dll 18 ortp.dll
20 wrap_oal.dll 19 wrap_oal.dll
@@ -22,12 +21,15 @@ set(vivox_files
22 21
23set(debug_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/debug") 22set(debug_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/debug")
24set(debug_files 23set(debug_files
24 alut.dll
25 freebl3.dll 25 freebl3.dll
26 gksvggdiplus.dll 26 gksvggdiplus.dll
27 js3250.dll 27 js3250.dll
28 nspr4.dll 28 nspr4.dll
29 nss3.dll 29 nss3.dll
30 nssckbi.dll 30 nssckbi.dll
31 openal32.dll
32 openjpegd.dll
31 plc4.dll 33 plc4.dll
32 plds4.dll 34 plds4.dll
33 smime3.dll 35 smime3.dll
@@ -35,7 +37,6 @@ set(debug_files
35 ssl3.dll 37 ssl3.dll
36 xpcom.dll 38 xpcom.dll
37 xul.dll 39 xul.dll
38 openjpegd.dll
39 windbgdlg.exe 40 windbgdlg.exe
40 ) 41 )
41 42
@@ -57,12 +58,15 @@ set(all_targets ${all_targets} ${out_targets})
57 58
58set(release_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/release") 59set(release_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/release")
59set(release_files 60set(release_files
61 alut.dll
60 freebl3.dll 62 freebl3.dll
61 gksvggdiplus.dll 63 gksvggdiplus.dll
62 js3250.dll 64 js3250.dll
63 nspr4.dll 65 nspr4.dll
64 nss3.dll 66 nss3.dll
65 nssckbi.dll 67 nssckbi.dll
68 openal32.dll
69 openjpeg.dll
66 plc4.dll 70 plc4.dll
67 plds4.dll 71 plds4.dll
68 smime3.dll 72 smime3.dll
@@ -70,7 +74,6 @@ set(release_files
70 ssl3.dll 74 ssl3.dll
71 xpcom.dll 75 xpcom.dll
72 xul.dll 76 xul.dll
73 openjpeg.dll
74 ) 77 )
75 78
76copy_if_different( 79copy_if_different(
@@ -105,51 +108,60 @@ copy_if_different(
105 ) 108 )
106set(all_targets ${all_targets} ${out_targets}) 109set(all_targets ${all_targets} ${out_targets})
107 110
108set(internal_llkdu_path "${CMAKE_SOURCE_DIR}/llkdu") 111
109if(EXISTS ${internal_llkdu_path}) 112# Copy MS C runtime dlls, required for packaging.
110 set(internal_llkdu_src "${CMAKE_BINARY_DIR}/llkdu/${CMAKE_CFG_INTDIR}/llkdu.dll") 113# *TODO - Adapt this to support VC9
111 set(llkdu_dst "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/llkdu.dll") 114if (MSVC80)
112 ADD_CUSTOM_COMMAND( 115 FIND_PATH(debug_msvc8_redist_path msvcr80d.dll
113 OUTPUT ${llkdu_dst} 116 PATHS
114 COMMAND ${CMAKE_COMMAND} -E copy_if_different ${internal_llkdu_src} ${llkdu_dst} 117 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\8.0\\Setup\\VC;ProductDir]/redist/Debug_NonRedist/x86/Microsoft.VC80.DebugCRT
115 DEPENDS ${internal_llkdu_src}
116 COMMENT "Copying llkdu.dll ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}"
117 )
118 set(all_targets ${all_targets} ${llkdu_dst})
119else(EXISTS ${internal_llkdu_path})
120 set(debug_llkdu_src "${debug_src_dir}/llkdu.dll")
121 set(debug_llkdu_dst "${CMAKE_CURRENT_BINARY_DIR}/Debug/llkdu.dll")
122 ADD_CUSTOM_COMMAND(
123 OUTPUT ${debug_llkdu_dst}
124 COMMAND ${CMAKE_COMMAND} -E copy_if_different ${debug_llkdu_src} ${debug_llkdu_dst}
125 DEPENDS ${debug_llkdu_src}
126 COMMENT "Copying llkdu.dll ${CMAKE_CURRENT_BINARY_DIR}/Debug"
127 )
128 set(all_targets ${all_targets} ${debug_llkdu_dst})
129
130 set(release_llkdu_src "${release_src_dir}/llkdu.dll")
131 set(release_llkdu_dst "${CMAKE_CURRENT_BINARY_DIR}/Release/llkdu.dll")
132 ADD_CUSTOM_COMMAND(
133 OUTPUT ${release_llkdu_dst}
134 COMMAND ${CMAKE_COMMAND} -E copy_if_different ${release_llkdu_src} ${release_llkdu_dst}
135 DEPENDS ${release_llkdu_src}
136 COMMENT "Copying llkdu.dll ${CMAKE_CURRENT_BINARY_DIR}/Release"
137 ) 118 )
138 set(all_targets ${all_targets} ${release_llkdu_dst}) 119
139 120 if(EXISTS ${debug_msvc8_redist_path})
140 set(relwithdebinfo_llkdu_dst "${CMAKE_CURRENT_BINARY_DIR}/RelWithDebInfo/llkdu.dll") 121 set(debug_msvc8_files
141 ADD_CUSTOM_COMMAND( 122 msvcr80d.dll
142 OUTPUT ${relwithdebinfo_llkdu_dst} 123 msvcp80d.dll
143 COMMAND ${CMAKE_COMMAND} -E copy_if_different ${release_llkdu_src} ${relwithdebinfo_llkdu_dst} 124 Microsoft.VC80.DebugCRT.manifest
144 DEPENDS ${release_llkdu_src} 125 )
145 COMMENT "Copying llkdu.dll ${CMAKE_CURRENT_BINARY_DIR}/RelWithDebInfo" 126
127 copy_if_different(
128 ${debug_msvc8_redist_path}
129 "${CMAKE_CURRENT_BINARY_DIR}/Debug"
130 out_targets
131 ${debug_msvc8_files}
132 )
133 set(all_targets ${all_targets} ${out_targets})
134 endif (EXISTS ${debug_msvc8_redist_path})
135
136 FIND_PATH(release_msvc8_redist_path msvcr80.dll
137 PATHS
138 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\VisualStudio\\8.0\\Setup\\VC;ProductDir]/redist/x86/Microsoft.VC80.CRT
146 ) 139 )
147 set(all_targets ${all_targets} ${relwithdebinfo_llkdu_dst})
148
149endif (EXISTS ${internal_llkdu_path})
150 140
151add_custom_target(copy_win_libs ALL DEPENDS ${all_targets}) 141 if(EXISTS ${release_msvc8_redist_path})
142 set(release_msvc8_files
143 msvcr80.dll
144 msvcp80.dll
145 Microsoft.VC80.CRT.manifest
146 )
152 147
153if(EXISTS ${internal_llkdu_path}) 148 copy_if_different(
154 add_dependencies(copy_win_libs llkdu) 149 ${release_msvc8_redist_path}
155endif(EXISTS ${internal_llkdu_path}) 150 "${CMAKE_CURRENT_BINARY_DIR}/Release"
151 out_targets
152 ${release_msvc8_files}
153 )
154 set(all_targets ${all_targets} ${out_targets})
155
156 copy_if_different(
157 ${release_msvc8_redist_path}
158 "${CMAKE_CURRENT_BINARY_DIR}/RelWithDebInfo"
159 out_targets
160 ${release_msvc8_files}
161 )
162 set(all_targets ${all_targets} ${out_targets})
163
164 endif (EXISTS ${release_msvc8_redist_path})
165endif (MSVC80)
166
167add_custom_target(copy_win_libs ALL DEPENDS ${all_targets})
diff --git a/linden/indra/cmake/DirectX.cmake b/linden/indra/cmake/DirectX.cmake
index 4d2d5e0..d406f37 100644
--- a/linden/indra/cmake/DirectX.cmake
+++ b/linden/indra/cmake/DirectX.cmake
@@ -3,12 +3,13 @@
3if (VIEWER AND WINDOWS) 3if (VIEWER AND WINDOWS)
4 find_path(DIRECTX_INCLUDE_DIR dxdiag.h 4 find_path(DIRECTX_INCLUDE_DIR dxdiag.h
5 "$ENV{DXSDK_DIR}/Include" 5 "$ENV{DXSDK_DIR}/Include"
6 "C:/Program Files/Microsoft DirectX SDK (June 2008)/Include" 6 "$ENV{PROGRAMFILES}/Microsoft DirectX SDK (August 2008)/Include"
7 "C:/Program Files/Microsoft DirectX SDK (March 2008)/Include" 7 "$ENV{PROGRAMFILES}/Microsoft DirectX SDK (June 2008)/Include"
8 "C:/Program Files/Microsoft DirectX SDK (November 2007)/Include" 8 "$ENV{PROGRAMFILES}/Microsoft DirectX SDK (March 2008)/Include"
9 "C:/Program Files/Microsoft DirectX SDK (August 2007)/Include" 9 "$ENV{PROGRAMFILES}/Microsoft DirectX SDK (November 2007)/Include"
10 "$ENV{PROGRAMFILES}/Microsoft DirectX SDK (August 2007)/Include"
10 "C:/DX90SDK/Include" 11 "C:/DX90SDK/Include"
11 "C:/Program Files/DX90SDK/Include" 12 "$ENV{PROGRAMFILES}/DX90SDK/Include"
12 ) 13 )
13 if (DIRECTX_INCLUDE_DIR) 14 if (DIRECTX_INCLUDE_DIR)
14 include_directories(${DIRECTX_INCLUDE_DIR}) 15 include_directories(${DIRECTX_INCLUDE_DIR})
@@ -22,12 +23,13 @@ if (VIEWER AND WINDOWS)
22 23
23 find_path(DIRECTX_LIBRARY_DIR dxguid.lib 24 find_path(DIRECTX_LIBRARY_DIR dxguid.lib
24 "$ENV{DXSDK_DIR}/Lib/x86" 25 "$ENV{DXSDK_DIR}/Lib/x86"
25 "C:/Program Files/Microsoft DirectX SDK (June 2008)/Lib/x86" 26 "$ENV{PROGRAMFILES}/Microsoft DirectX SDK (August 2008)/Lib/x86"
26 "C:/Program Files/Microsoft DirectX SDK (March 2008)/Lib/x86" 27 "$ENV{PROGRAMFILES}/Microsoft DirectX SDK (June 2008)/Lib/x86"
27 "C:/Program Files/Microsoft DirectX SDK (November 2007)/Lib/x86" 28 "$ENV{PROGRAMFILES}/Microsoft DirectX SDK (March 2008)/Lib/x86"
28 "C:/Program Files/Microsoft DirectX SDK (August 2007)/Lib/x86" 29 "$ENV{PROGRAMFILES}/Microsoft DirectX SDK (November 2007)/Lib/x86"
30 "$ENV{PROGRAMFILES}/Microsoft DirectX SDK (August 2007)/Lib/x86"
29 "C:/DX90SDK/Lib" 31 "C:/DX90SDK/Lib"
30 "C:/Program Files/DX90SDK/Lib" 32 "$ENV{PROGRAMFILES}/DX90SDK/Lib"
31 ) 33 )
32 if (DIRECTX_LIBRARY_DIR) 34 if (DIRECTX_LIBRARY_DIR)
33 if (DIRECTX_FIND_QUIETLY) 35 if (DIRECTX_FIND_QUIETLY)
diff --git a/linden/indra/cmake/FindMono.cmake b/linden/indra/cmake/FindMono.cmake
index f0a0705..c36d725 100644
--- a/linden/indra/cmake/FindMono.cmake
+++ b/linden/indra/cmake/FindMono.cmake
@@ -14,29 +14,29 @@
14# Removed the check for gmcs 14# Removed the check for gmcs
15 15
16FIND_PROGRAM (MONO_EXECUTABLE mono 16FIND_PROGRAM (MONO_EXECUTABLE mono
17 "C:/Program Files/Mono-1.9.1/bin" 17 "$ENV{PROGRAMFILES}/Mono-1.9.1/bin"
18 "C:/Program Files/Mono-1.2.6/bin" 18 "$ENV{PROGRAMFILES}/Mono-1.2.6/bin"
19 /bin 19 /bin
20 /usr/bin 20 /usr/bin
21 /usr/local/bin 21 /usr/local/bin
22) 22)
23FIND_PROGRAM (MCS_EXECUTABLE mcs 23FIND_PROGRAM (MCS_EXECUTABLE mcs
24 "C:/Program Files/Mono-1.9.1/bin" 24 "$ENV{PROGRAMFILES}/Mono-1.9.1/bin"
25 "C:/Program Files/Mono-1.2.6/bin" 25 "$ENV{PROGRAMFILES}/Mono-1.2.6/bin"
26 /bin 26 /bin
27 /usr/bin 27 /usr/bin
28 /usr/local/bin 28 /usr/local/bin
29) 29)
30FIND_PROGRAM (GMCS_EXECUTABLE gmcs 30FIND_PROGRAM (GMCS_EXECUTABLE gmcs
31 "C:/Program Files/Mono-1.9.1/bin" 31 "$ENV{PROGRAMFILES}/Mono-1.9.1/bin"
32 "C:/Program Files/Mono-1.2.6/bin" 32 "$ENV{PROGRAMFILES}/Mono-1.2.6/bin"
33 /bin 33 /bin
34 /usr/bin 34 /usr/bin
35 /usr/local/bin 35 /usr/local/bin
36) 36)
37FIND_PROGRAM (GACUTIL_EXECUTABLE gacutil 37FIND_PROGRAM (GACUTIL_EXECUTABLE gacutil
38 "C:/Program Files/Mono-1.9.1/bin" 38 "$ENV{PROGRAMFILES}/Mono-1.9.1/bin"
39 "C:/Program Files/Mono-1.2.6/bin" 39 "$ENV{PROGRAMFILES}/Mono-1.2.6/bin"
40 /bin 40 /bin
41 /usr/bin 41 /usr/bin
42 /usr/local/bin 42 /usr/local/bin
@@ -44,7 +44,7 @@ FIND_PROGRAM (GACUTIL_EXECUTABLE gacutil
44FIND_PROGRAM (ILASM_EXECUTABLE 44FIND_PROGRAM (ILASM_EXECUTABLE
45 ilasm 45 ilasm
46 NO_DEFAULT_PATH 46 NO_DEFAULT_PATH
47 PATHS "C:/Program Files/Mono-1.9.1/bin" "C:/Apps/Mono-1.2.6/bin" "C:/Program Files/Mono-1.2.6/bin" /bin /usr/bin /usr/local/bin 47 PATHS "$ENV{PROGRAMFILES}/Mono-1.9.1/bin" "$ENV{PROGRAMFILES}/Mono-1.2.6/bin" /bin /usr/bin /usr/local/bin
48) 48)
49 49
50SET (MONO_FOUND FALSE) 50SET (MONO_FOUND FALSE)
diff --git a/linden/indra/cmake/GStreamer.cmake b/linden/indra/cmake/GStreamer.cmake
index 10d5207..4369445 100644
--- a/linden/indra/cmake/GStreamer.cmake
+++ b/linden/indra/cmake/GStreamer.cmake
@@ -15,6 +15,8 @@ elseif (LINUX)
15 set(GSTREAMER_INCLUDE_DIRS 15 set(GSTREAMER_INCLUDE_DIRS
16 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/gstreamer-0.10 16 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/gstreamer-0.10
17 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/glib-2.0 17 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/glib-2.0
18 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/glib-2.0/glib
19 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/glib-2.0/gobject
18 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/libxml2 20 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/libxml2
19 ) 21 )
20 # We don't need to explicitly link against gstreamer itself, because 22 # We don't need to explicitly link against gstreamer itself, because
diff --git a/linden/indra/cmake/GooglePerfTools.cmake b/linden/indra/cmake/GooglePerfTools.cmake
index 9b3eca0..25e9f6d 100644
--- a/linden/indra/cmake/GooglePerfTools.cmake
+++ b/linden/indra/cmake/GooglePerfTools.cmake
@@ -19,10 +19,14 @@ if (GOOGLE_PERFTOOLS_FOUND)
19 set(USE_GOOGLE_PERFTOOLS ON CACHE BOOL "Build with Google PerfTools support.") 19 set(USE_GOOGLE_PERFTOOLS ON CACHE BOOL "Build with Google PerfTools support.")
20endif (GOOGLE_PERFTOOLS_FOUND) 20endif (GOOGLE_PERFTOOLS_FOUND)
21 21
22# XXX Disable temporarily, until we have compilation issues on 64-bit
23# Etch sorted.
24set(USE_GOOGLE_PERFTOOLS OFF)
25
22if (USE_GOOGLE_PERFTOOLS) 26if (USE_GOOGLE_PERFTOOLS)
23 set(TCMALLOC_FLAG -DLL_USE_TCMALLOC=1) 27 set(TCMALLOC_FLAG -DLL_USE_TCMALLOC=1)
24 include_directories(${GOOGLE_PERFTOOLS_INCLUDE_DIR}) 28 include_directories(${GOOGLE_PERFTOOLS_INCLUDE_DIR})
25 set(GOOGLE_PERFTOOLS_LIBRARIES ${TCMALLOC_LIBRARIES} ${STACKTRACE_LIBRARIES}) 29 set(GOOGLE_PERFTOOLS_LIBRARIES ${TCMALLOC_LIBRARIES} ${STACKTRACE_LIBRARIES} ${PROFILER_LIBRARIES})
26else (USE_GOOGLE_PERFTOOLS) 30else (USE_GOOGLE_PERFTOOLS)
27 set(TCMALLOC_FLAG -ULL_USE_TCMALLOC) 31 set(TCMALLOC_FLAG -ULL_USE_TCMALLOC)
28endif (USE_GOOGLE_PERFTOOLS) 32endif (USE_GOOGLE_PERFTOOLS)
diff --git a/linden/indra/cmake/LLAudio.cmake b/linden/indra/cmake/LLAudio.cmake
index 7b9f254..dcfd269 100644
--- a/linden/indra/cmake/LLAudio.cmake
+++ b/linden/indra/cmake/LLAudio.cmake
@@ -1,9 +1,11 @@
1# -*- cmake -*- 1# -*- cmake -*-
2 2
3include(Audio) 3include(Audio)
4include(OPENAL)
4 5
5set(LLAUDIO_INCLUDE_DIRS 6set(LLAUDIO_INCLUDE_DIRS
6 ${LIBS_OPEN_DIR}/llaudio 7 ${LIBS_OPEN_DIR}/llaudio
8 ${OPENAL_INCLUDE_DIRS}
7 ) 9 )
8 10
9set(LLAUDIO_LIBRARIES 11set(LLAUDIO_LIBRARIES
@@ -12,4 +14,5 @@ set(LLAUDIO_LIBRARIES
12 ${VORBISFILE_LIBRARIES} 14 ${VORBISFILE_LIBRARIES}
13 ${VORBIS_LIBRARIES} 15 ${VORBIS_LIBRARIES}
14 ${OGG_LIBRARIES} 16 ${OGG_LIBRARIES}
17 ${OPENAL_LIBRARIES}
15 ) 18 )
diff --git a/linden/indra/cmake/LLKDU.cmake b/linden/indra/cmake/LLKDU.cmake
deleted file mode 100644
index a02b5d9..0000000
--- a/linden/indra/cmake/LLKDU.cmake
+++ /dev/null
@@ -1,20 +0,0 @@
1# -*- cmake -*-
2include(Prebuilt)
3
4if (NOT STANDALONE AND EXISTS ${LIBS_CLOSED_DIR}/llkdu)
5 use_prebuilt_binary(kdu)
6 if (WINDOWS)
7 set(KDU_LIBRARY debug kdu_cored optimized kdu_core)
8 elseif (LINUX)
9 set(KDU_LIBRARY kdu_v42R)
10 else (WINDOWS)
11 set(KDU_LIBRARY kdu)
12 endif (WINDOWS)
13
14 set(KDU_INCLUDE_DIR ${LIBS_PREBUILT_DIR}/include)
15
16 set(LLKDU_LIBRARY llkdu)
17 set(LLKDU_STATIC_LIBRARY llkdu_static)
18 set(LLKDU_LIBRARIES ${LLKDU_LIBRARY})
19 set(LLKDU_STATIC_LIBRARIES ${LLKDU_STATIC_LIBRARY})
20endif (NOT STANDALONE AND EXISTS ${LIBS_CLOSED_DIR}/llkdu)
diff --git a/linden/indra/cmake/LLXML.cmake b/linden/indra/cmake/LLXML.cmake
index 1ce93c0..dd2ebca 100644
--- a/linden/indra/cmake/LLXML.cmake
+++ b/linden/indra/cmake/LLXML.cmake
@@ -1,9 +1,11 @@
1# -*- cmake -*- 1# -*- cmake -*-
2 2
3include(Boost)
3include(EXPAT) 4include(EXPAT)
4 5
5set(LLXML_INCLUDE_DIRS 6set(LLXML_INCLUDE_DIRS
6 ${LIBS_OPEN_DIR}/llxml 7 ${LIBS_OPEN_DIR}/llxml
8 ${Boost_INCLUDE_DIRS}
7 ${EXPAT_INCLUDE_DIRS} 9 ${EXPAT_INCLUDE_DIRS}
8 ) 10 )
9 11
diff --git a/linden/indra/cmake/Linking.cmake b/linden/indra/cmake/Linking.cmake
index c9748e3..167c5dd 100644
--- a/linden/indra/cmake/Linking.cmake
+++ b/linden/indra/cmake/Linking.cmake
@@ -7,15 +7,15 @@ if (NOT STANDALONE)
7 set(ARCH_PREBUILT_DIRS_DEBUG ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/lib/debug) 7 set(ARCH_PREBUILT_DIRS_DEBUG ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/lib/debug)
8 elseif (LINUX) 8 elseif (LINUX)
9 if (VIEWER) 9 if (VIEWER)
10 set(ARCH_PREBUILT_DIRS 10 set(ARCH_PREBUILT_DIRS ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/lib_release_client)
11 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/lib_release_client)
12 set(ARCH_PREBUILT_DIRS_RELEASE ${ARCH_PREBUILT_DIRS})
13 set(ARCH_PREBUILT_DIRS_DEBUG ${ARCH_PREBUILT_DIRS})
14 else (VIEWER) 11 else (VIEWER)
15 set(ARCH_PREBUILT_DIRS ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/lib_release) 12 set(ARCH_PREBUILT_DIRS ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/lib_release)
16 endif (VIEWER) 13 endif (VIEWER)
14 set(ARCH_PREBUILT_DIRS_RELEASE ${ARCH_PREBUILT_DIRS})
15 set(ARCH_PREBUILT_DIRS_DEBUG ${ARCH_PREBUILT_DIRS})
17 elseif (DARWIN) 16 elseif (DARWIN)
18 set(ARCH_PREBUILT_DIRS_RELEASE ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/lib_release) 17 set(ARCH_PREBUILT_DIRS_RELEASE ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/lib_release)
18 set(ARCH_PREBUILT_DIRS ${ARCH_PREBUILT_DIRS_RELEASE})
19 set(ARCH_PREBUILT_DIRS_DEBUG ${ARCH_PREBUILT_DIRS_RELEASE}) 19 set(ARCH_PREBUILT_DIRS_DEBUG ${ARCH_PREBUILT_DIRS_RELEASE})
20 endif (WINDOWS) 20 endif (WINDOWS)
21endif (NOT STANDALONE) 21endif (NOT STANDALONE)
diff --git a/linden/indra/cmake/NDOF.cmake b/linden/indra/cmake/NDOF.cmake
index 3f715a2..dad74e9 100644
--- a/linden/indra/cmake/NDOF.cmake
+++ b/linden/indra/cmake/NDOF.cmake
@@ -3,12 +3,12 @@ include(Prebuilt)
3 3
4use_prebuilt_binary(ndofdev) 4use_prebuilt_binary(ndofdev)
5 5
6if (WINDOWS OR DARWIN) 6if (WINDOWS OR DARWIN OR LINUX)
7 add_definitions(-DLIB_NDOF=1) 7 add_definitions(-DLIB_NDOF=1)
8endif (WINDOWS OR DARWIN) 8endif (WINDOWS OR DARWIN OR LINUX)
9 9
10if (WINDOWS) 10if (WINDOWS)
11 set(NDOF_LIBRARY libndofdev) 11 set(NDOF_LIBRARY libndofdev)
12elseif (DARWIN) 12elseif (DARWIN OR LINUX)
13 set(NDOF_LIBRARY ndofdev) 13 set(NDOF_LIBRARY ndofdev)
14endif (WINDOWS) 14endif (WINDOWS)
diff --git a/linden/indra/cmake/OPENAL.cmake b/linden/indra/cmake/OPENAL.cmake
new file mode 100644
index 0000000..a2bae5d
--- /dev/null
+++ b/linden/indra/cmake/OPENAL.cmake
@@ -0,0 +1,85 @@
1# -*- cmake -*-
2
3set(OPENAL ON CACHE BOOL "Enable OpenAL")
4
5
6if (OPENAL)
7
8 # message(STATUS "Building with OpenAL audio support")
9
10 # OPENAL_LIB
11
12 find_library(OPENAL_LIB
13 NAMES openal OpenAL OpenAL32 wrap_oal
14 PATHS ${ARCH_PREBUILT_DIRS_RELEASE}
15 )
16
17 if (NOT OPENAL_LIB)
18 message(FATAL_ERROR "OpenAL not found!")
19 else (NOT OPENAL_LIB)
20 # message(STATUS "OpenAL found: ${OPENAL_LIB}")
21 endif (NOT OPENAL_LIB)
22
23
24
25 # OPENAL_INCLUDE_DIR
26
27 find_path(OPENAL_INCLUDE_DIR
28 NAMES al.h
29 PATHS ${LIBS_PREBUILT_DIR}/include /usr/include/AL
30 )
31
32 if (NOT OPENAL_INCLUDE_DIR)
33 message(FATAL_ERROR "al.h not found!")
34 else (NOT OPENAL_INCLUDE_DIR)
35 # message(STATUS "al.h found in: ${OPENAL_INCLUDE_DIR}")
36 endif (NOT OPENAL_INCLUDE_DIR)
37
38
39
40 # ALUT_LIB
41
42 find_library(ALUT_LIB
43 NAMES alut freealut
44 PATHS ${ARCH_PREBUILT_DIRS_RELEASE}
45 )
46
47 if (NOT ALUT_LIB)
48 message(FATAL_ERROR "ALUT not found!")
49 else (NOT ALUT_LIB)
50 # message(STATUS "ALUT found: ${ALUT_LIB}")
51 endif (NOT ALUT_LIB)
52
53
54
55 # ALUT_INCLUDE_DIR
56
57 find_path(ALUT_INCLUDE_DIR
58 NAMES alut.h
59 PATHS ${LIBS_PREBUILT_DIR}/include /usr/include/AL
60 )
61
62 if (NOT ALUT_INCLUDE_DIR)
63 message(FATAL_ERROR "alut.h not found!")
64 else (NOT ALUT_INCLUDE_DIR)
65 # message(STATUS "alut.h found in: ${ALUT_INCLUDE_DIR}")
66 endif (NOT ALUT_INCLUDE_DIR)
67
68
69
70 set(OPENAL_LIBRARIES
71 ${OPENAL_LIB}
72 ${ALUT_LIB}
73 )
74
75 set(OPENAL_INCLUDE_DIRS
76 ${OPENAL_INCLUDE_DIR}
77 ${ALUT_INCLUDE_DIR}
78 )
79
80
81 set(OPENAL_FOUND TRUE CACHE BOOL
82 "Found OpenAL and ALUT libraries successfully"
83 )
84
85endif (OPENAL)
diff --git a/linden/indra/cmake/Python.cmake b/linden/indra/cmake/Python.cmake
index e9505fb..4f86d32 100644
--- a/linden/indra/cmake/Python.cmake
+++ b/linden/indra/cmake/Python.cmake
@@ -9,6 +9,7 @@ if (WINDOWS)
9 NAMES python25.exe python23.exe python.exe 9 NAMES python25.exe python23.exe python.exe
10 NO_DEFAULT_PATH # added so that cmake does not find cygwin python 10 NO_DEFAULT_PATH # added so that cmake does not find cygwin python
11 PATHS 11 PATHS
12 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.6\\InstallPath]
12 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.5\\InstallPath] 13 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.5\\InstallPath]
13 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.4\\InstallPath] 14 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.4\\InstallPath]
14 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.3\\InstallPath] 15 [HKEY_LOCAL_MACHINE\\SOFTWARE\\Python\\PythonCore\\2.3\\InstallPath]
diff --git a/linden/indra/cmake/QuickTime.cmake b/linden/indra/cmake/QuickTime.cmake
index b79ac11..4352709 100644
--- a/linden/indra/cmake/QuickTime.cmake
+++ b/linden/indra/cmake/QuickTime.cmake
@@ -9,13 +9,29 @@ if (DARWIN)
9 include(CMakeFindFrameworks) 9 include(CMakeFindFrameworks)
10 find_library(QUICKTIME_LIBRARY QuickTime) 10 find_library(QUICKTIME_LIBRARY QuickTime)
11elseif (WINDOWS) 11elseif (WINDOWS)
12 set(QUICKTIME_SDK_DIR "C:\\Program Files\\QuickTime SDK" 12 set(QUICKTIME_SDK_DIR "$ENV{PROGRAMFILES}/QuickTime SDK"
13 CACHE PATH "Location of the QuickTime SDK.") 13 CACHE PATH "Location of the QuickTime SDK.")
14 find_library(QUICKTIME_LIBRARY qtmlclient 14
15 find_library(DEBUG_QUICKTIME_LIBRARY qtmlclient
16 PATHS
17 ${ARCH_PREBUILT_DIRS_DEBUG}
18 "${QUICKTIME_SDK_DIR}\\libraries"
19 )
20
21 find_library(RELEASE_QUICKTIME_LIBRARY qtmlclient
15 PATHS 22 PATHS
16 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/lib/release 23 ${ARCH_PREBUILT_DIRS_RELEASE}
17 "${QUICKTIME_SDK_DIR}\\libraries" 24 "${QUICKTIME_SDK_DIR}\\libraries"
18 ) 25 )
26
27 if (DEBUG_QUICKTIME_LIBRARY AND RELEASE_QUICKTIME_LIBRARY)
28 set(QUICKTIME_LIBRARY
29 optimized ${RELEASE_QUICKTIME_LIBRARY}
30 debug ${DEBUG_QUICKTIME_LIBRARY}
31 )
32
33 endif (DEBUG_QUICKTIME_LIBRARY AND RELEASE_QUICKTIME_LIBRARY)
34
19 include_directories( 35 include_directories(
20 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/quicktime 36 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/quicktime
21 "${QUICKTIME_SDK_DIR}\\CIncludes" 37 "${QUICKTIME_SDK_DIR}\\CIncludes"