aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/cmake
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--linden/indra/cmake/00-Common.cmake12
-rw-r--r--linden/indra/cmake/CopyWinLibs.cmake297
-rw-r--r--linden/indra/cmake/DBusGlib.cmake1
-rw-r--r--linden/indra/cmake/ExamplePlugin.cmake16
-rw-r--r--linden/indra/cmake/FindLLQtWebkit.cmake62
-rw-r--r--linden/indra/cmake/GStreamer.cmake127
-rw-r--r--linden/indra/cmake/GStreamer010Plugin.cmake66
-rw-r--r--linden/indra/cmake/Glui.cmake28
-rw-r--r--linden/indra/cmake/Glut.cmake19
-rw-r--r--linden/indra/cmake/LLAudio.cmake2
-rw-r--r--linden/indra/cmake/LLCommon.cmake13
-rw-r--r--linden/indra/cmake/LLMedia.cmake14
-rw-r--r--linden/indra/cmake/LLPlugin.cmake8
-rw-r--r--linden/indra/cmake/MediaPluginBase.cmake8
-rw-r--r--linden/indra/cmake/Mozlib.cmake47
-rw-r--r--linden/indra/cmake/PluginAPI.cmake16
-rw-r--r--linden/indra/cmake/PulseAudio.cmake28
-rw-r--r--linden/indra/cmake/QuickTimePlugin.cmake46
-rw-r--r--linden/indra/cmake/UI.cmake3
-rw-r--r--linden/indra/cmake/Variables.cmake1
-rw-r--r--linden/indra/cmake/WebKitLibPlugin.cmake79
21 files changed, 570 insertions, 323 deletions
diff --git a/linden/indra/cmake/00-Common.cmake b/linden/indra/cmake/00-Common.cmake
index 0e90073..4c04be9 100644
--- a/linden/indra/cmake/00-Common.cmake
+++ b/linden/indra/cmake/00-Common.cmake
@@ -9,9 +9,9 @@ include(Variables)
9 9
10set(CMAKE_CXX_FLAGS_DEBUG "-D_DEBUG -DLL_DEBUG=1") 10set(CMAKE_CXX_FLAGS_DEBUG "-D_DEBUG -DLL_DEBUG=1")
11set(CMAKE_CXX_FLAGS_RELEASE 11set(CMAKE_CXX_FLAGS_RELEASE
12 "-DLL_RELEASE=1 -DLL_RELEASE_FOR_DOWNLOAD=1 -D_SECURE_SCL=0 -DNDEBUG") 12 "-DLL_RELEASE=1 -DLL_RELEASE_FOR_DOWNLOAD=1 -D_SECURE_SCL=0 -DLL_SEND_CRASH_REPORTS=1 -DNDEBUG")
13set(CMAKE_CXX_FLAGS_RELWITHDEBINFO 13set(CMAKE_CXX_FLAGS_RELWITHDEBINFO
14 "-DLL_RELEASE=1 -D_SECURE_SCL=0 -DNDEBUG -DLL_RELEASE_WITH_DEBUG_INFO=1") 14 "-DLL_RELEASE=1 -D_SECURE_SCL=0 -DLL_SEND_CRASH_REPORTS=0 -DNDEBUG -DLL_RELEASE_WITH_DEBUG_INFO=1")
15 15
16 16
17# Don't bother with a MinSizeRel build. 17# Don't bother with a MinSizeRel build.
@@ -20,6 +20,14 @@ set(CMAKE_CONFIGURATION_TYPES "RelWithDebInfo;Release;Debug" CACHE STRING
20 "Supported build types." FORCE) 20 "Supported build types." FORCE)
21 21
22 22
23# Determine the number of bits of this processor
24
25if(CMAKE_SIZEOF_VOID_P MATCHES 4)
26 set( HAVE_64_BIT 0 )
27else(CMAKE_SIZEOF_VOID_P MATCHES 4)
28 set( HAVE_64_BIT 1 )
29endif(CMAKE_SIZEOF_VOID_P MATCHES 4)
30
23# Platform-specific compilation flags. 31# Platform-specific compilation flags.
24 32
25if (WINDOWS) 33if (WINDOWS)
diff --git a/linden/indra/cmake/CopyWinLibs.cmake b/linden/indra/cmake/CopyWinLibs.cmake
index b544c15..a091a31 100644
--- a/linden/indra/cmake/CopyWinLibs.cmake
+++ b/linden/indra/cmake/CopyWinLibs.cmake
@@ -6,6 +6,7 @@
6 6
7include(CMakeCopyIfDifferent) 7include(CMakeCopyIfDifferent)
8 8
9# Copying vivox's alut.dll breaks inworld audio, never use it
9set(vivox_src_dir "${CMAKE_SOURCE_DIR}/newview/vivox-runtime/i686-win32") 10set(vivox_src_dir "${CMAKE_SOURCE_DIR}/newview/vivox-runtime/i686-win32")
10set(vivox_files 11set(vivox_files
11 SLVoice.exe 12 SLVoice.exe
@@ -14,76 +15,20 @@ set(vivox_files
14 ortp.dll 15 ortp.dll
15 wrap_oal.dll 16 wrap_oal.dll
16 ) 17 )
18copy_if_different(
19 ${vivox_src_dir}
20 "${CMAKE_CURRENT_BINARY_DIR}/Debug"
21 out_targets
22 ${vivox_files}
23 )
24set(all_targets ${all_targets} ${out_targets})
17 25
18set(debug_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/debug") 26set(debug_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/debug")
19set(debug_files 27set(debug_files
20 alut.dll 28 alut.dll
21 freebl3.dll
22 js3250.dll
23 nspr4.dll
24 nss3.dll
25 nssckbi.dll
26 openal32.dll 29 openal32.dll
27 openjpegd.dll 30 openjpegd.dll
28 libhunspell.dll 31 libhunspell.dll
29 plc4.dll
30 plds4.dll
31 smime3.dll
32 softokn3.dll
33 ssl3.dll
34 xpcom.dll
35 xul.dll
36 windbgdlg.exe
37 iconv.dll
38 libxml2.dll
39 libcairo-2.dll
40 libfaad-2.dll
41 libgio-2.0-0.dll
42 libglib-2.0-0.dll
43 libgmodule-2.0-0.dll
44 libgobject-2.0-0.dll
45 libgthread-2.0-0.dll
46 charset.dll
47 intl.dll
48 libgcrypt-11.dll
49 libgnutls-26.dll
50 libgpg-error-0.dll
51 libgstapp.dll
52 libgstaudio.dll
53 libgstaudio-0.10.dll
54 libgstbase-0.10.dll
55 libgstcdda.dll
56 libgstcontroller-0.10.dll
57 libgstdataprotocol-0.10.dll
58 libgstdshow.dll
59 libgstfft.dll
60 libgstinterfaces.dll
61 libgstnet-0.10.dll
62 libgstnetbuffer.dll
63 libgstpbutils.dll
64 libgstreamer-0.10.dll
65 libgstriff.dll
66 libgstrtp.dll
67 libgstrtsp.dll
68 libgstsdp.dll
69 libgsttag.dll
70 libgstvideo.dll
71 libjpeg.dll
72 libmp3lame-0.dll
73 libneon-27.dll
74 libogg-0.dll
75 liboil-0.3-0.dll
76 libopenjpeg-2.dll
77 libpng12-0.dll
78 libschroedinger-1.0-0.dll
79 libspeex-1.dll
80 libtheora-0.dll
81 libvorbis-0.dll
82 libvorbisenc-2.dll
83 libxml2-2.dll
84 glew32.dll
85 xvidcore.dll
86 zlib1.dll
87 ) 32 )
88 33
89copy_if_different( 34copy_if_different(
@@ -94,82 +39,176 @@ copy_if_different(
94 ) 39 )
95set(all_targets ${all_targets} ${out_targets}) 40set(all_targets ${all_targets} ${out_targets})
96 41
42# Debug config runtime files required for the plugin test mule
43set(plugintest_debug_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/debug")
44set(plugintest_debug_files
45 libeay32.dll
46 qtcored4.dll
47 qtguid4.dll
48 qtnetworkd4.dll
49 qtopengld4.dll
50 qtwebkitd4.dll
51 qtxmlpatternsd4.dll
52 ssleay32.dll
53 )
97copy_if_different( 54copy_if_different(
98 ${vivox_src_dir} 55 ${plugintest_debug_src_dir}
99 "${CMAKE_CURRENT_BINARY_DIR}/Debug" 56 "${CMAKE_CURRENT_BINARY_DIR}/../test_apps/llplugintest/Debug"
100 out_targets 57 out_targets
101 ${vivox_files} 58 ${plugintest_debug_files}
59 )
60set(all_targets ${all_targets} ${out_targets})
61
62# Debug config runtime files required for the plugin test mule (Qt image format plugins)
63set(plugintest_debug_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/debug/imageformats")
64set(plugintest_debug_files
65 qgifd4.dll
66 qicod4.dll
67 qjpegd4.dll
68 qmngd4.dll
69 qsvgd4.dll
70 qtiffd4.dll
71 )
72copy_if_different(
73 ${plugintest_debug_src_dir}
74 "${CMAKE_CURRENT_BINARY_DIR}/../test_apps/llplugintest/Debug/imageformats"
75 out_targets
76 ${plugintest_debug_files}
77 )
78set(all_targets ${all_targets} ${out_targets})
79
80copy_if_different(
81 ${plugintest_debug_src_dir}
82 "${CMAKE_CURRENT_BINARY_DIR}/llplugin/imageformats"
83 out_targets
84 ${plugintest_debug_files}
85 )
86set(all_targets ${all_targets} ${out_targets})
87
88# Release & ReleaseDebInfo config runtime files required for the plugin test mule
89set(plugintest_release_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/release")
90set(plugintest_release_files
91 libeay32.dll
92 qtcore4.dll
93 qtgui4.dll
94 qtnetwork4.dll
95 qtopengl4.dll
96 qtwebkit4.dll
97 qtxmlpatterns4.dll
98 ssleay32.dll
99 )
100copy_if_different(
101 ${plugintest_release_src_dir}
102 "${CMAKE_CURRENT_BINARY_DIR}/../test_apps/llplugintest/Release"
103 out_targets
104 ${plugintest_release_files}
105 )
106set(all_targets ${all_targets} ${out_targets})
107
108copy_if_different(
109 ${plugintest_release_src_dir}
110 "${CMAKE_CURRENT_BINARY_DIR}/../test_apps/llplugintest/RelWithDebInfo"
111 out_targets
112 ${plugintest_release_files}
113 )
114set(all_targets ${all_targets} ${out_targets})
115
116# Release & ReleaseDebInfo config runtime files required for the plugin test mule (Qt image format plugins)
117set(plugintest_release_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/release/imageformats")
118set(plugintest_release_files
119 qgif4.dll
120 qico4.dll
121 qjpeg4.dll
122 qmng4.dll
123 qsvg4.dll
124 qtiff4.dll
125 )
126copy_if_different(
127 ${plugintest_release_src_dir}
128 "${CMAKE_CURRENT_BINARY_DIR}/../test_apps/llplugintest/Release/imageformats"
129 out_targets
130 ${plugintest_release_files}
131 )
132set(all_targets ${all_targets} ${out_targets})
133
134copy_if_different(
135 ${plugintest_release_src_dir}
136 "${CMAKE_CURRENT_BINARY_DIR}/../test_apps/llplugintest/RelWithDebInfo/imageformats"
137 out_targets
138 ${plugintest_release_files}
139 )
140set(all_targets ${all_targets} ${out_targets})
141
142copy_if_different(
143 ${plugintest_release_src_dir}
144 "${CMAKE_CURRENT_BINARY_DIR}/Release/llplugin/imageformats"
145 out_targets
146 ${plugintest_release_files}
147 )
148set(all_targets ${all_targets} ${out_targets})
149
150copy_if_different(
151 ${plugintest_release_src_dir}
152 "${CMAKE_CURRENT_BINARY_DIR}/RelWithDebInfo/llplugin/imageformats"
153 out_targets
154 ${plugintest_release_files}
155 )
156set(all_targets ${all_targets} ${out_targets})
157
158# Debug config runtime files required for the plugins
159set(plugins_debug_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/debug")
160set(plugins_debug_files
161 libeay32.dll
162 qtcored4.dll
163 qtguid4.dll
164 qtnetworkd4.dll
165 qtopengld4.dll
166 qtwebkitd4.dll
167 qtxmlpatternsd4.dll
168 ssleay32.dll
169 )
170copy_if_different(
171 ${plugins_debug_src_dir}
172 "${CMAKE_CURRENT_BINARY_DIR}/Debug/llplugin"
173 out_targets
174 ${plugins_debug_files}
175 )
176set(all_targets ${all_targets} ${out_targets})
177
178# Release & ReleaseDebInfo config runtime files required for the plugins
179set(plugins_release_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/release")
180set(plugins_release_files
181 libeay32.dll
182 qtcore4.dll
183 qtgui4.dll
184 qtnetwork4.dll
185 qtopengl4.dll
186 qtwebkit4.dll
187 qtxmlpatterns4.dll
188 ssleay32.dll
189 )
190copy_if_different(
191 ${plugins_release_src_dir}
192 "${CMAKE_CURRENT_BINARY_DIR}/Release/llplugin"
193 out_targets
194 ${plugins_release_files}
195 )
196set(all_targets ${all_targets} ${out_targets})
197
198copy_if_different(
199 ${plugins_release_src_dir}
200 "${CMAKE_CURRENT_BINARY_DIR}/RelWithDebInfo/llplugin"
201 out_targets
202 ${plugins_release_files}
102 ) 203 )
103set(all_targets ${all_targets} ${out_targets}) 204set(all_targets ${all_targets} ${out_targets})
104 205
105set(release_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/release") 206set(release_src_dir "${CMAKE_SOURCE_DIR}/../libraries/i686-win32/lib/release")
106set(release_files 207set(release_files
107 alut.dll 208 alut.dll
108 freebl3.dll
109 js3250.dll
110 nspr4.dll
111 nss3.dll
112 nssckbi.dll
113 openal32.dll 209 openal32.dll
114 openjpeg.dll 210 openjpeg.dll
115 libhunspell.dll 211 libhunspell.dll
116 plc4.dll
117 plds4.dll
118 smime3.dll
119 softokn3.dll
120 ssl3.dll
121 xpcom.dll
122 xul.dll
123 iconv.dll
124 libxml2.dll
125 libcairo-2.dll
126 libfaad-2.dll
127 libgio-2.0-0.dll
128 libglib-2.0-0.dll
129 libgmodule-2.0-0.dll
130 libgobject-2.0-0.dll
131 libgthread-2.0-0.dll
132 charset.dll
133 intl.dll
134 libgcrypt-11.dll
135 libgnutls-26.dll
136 libgpg-error-0.dll
137 libgstapp.dll
138 libgstaudio.dll
139 libgstaudio-0.10.dll
140 libgstbase-0.10.dll
141 libgstcdda.dll
142 libgstcontroller-0.10.dll
143 libgstdataprotocol-0.10.dll
144 libgstdshow.dll
145 libgstfft.dll
146 libgstinterfaces.dll
147 libgstnet-0.10.dll
148 libgstnetbuffer.dll
149 libgstpbutils.dll
150 libgstreamer-0.10.dll
151 libgstriff.dll
152 libgstrtp.dll
153 libgstrtsp.dll
154 libgstsdp.dll
155 libgsttag.dll
156 libgstvideo.dll
157 libjpeg.dll
158 libmp3lame-0.dll
159 libneon-27.dll
160 libogg-0.dll
161 liboil-0.3-0.dll
162 libopenjpeg-2.dll
163 libpng12-0.dll
164 libschroedinger-1.0-0.dll
165 libspeex-1.dll
166 libtheora-0.dll
167 libvorbis-0.dll
168 libvorbisenc-2.dll
169 libxml2-2.dll
170 glew32.dll
171 xvidcore.dll
172 zlib1.dll
173 ) 212 )
174 213
175copy_if_different( 214copy_if_different(
diff --git a/linden/indra/cmake/DBusGlib.cmake b/linden/indra/cmake/DBusGlib.cmake
index dfda0ad..b78a0b1 100644
--- a/linden/indra/cmake/DBusGlib.cmake
+++ b/linden/indra/cmake/DBusGlib.cmake
@@ -7,6 +7,7 @@ if (STANDALONE)
7 pkg_check_modules(DBUSGLIB REQUIRED dbus-glib-1) 7 pkg_check_modules(DBUSGLIB REQUIRED dbus-glib-1)
8 8
9elseif (LINUX) 9elseif (LINUX)
10 use_prebuilt_binary(glib) # dbusglib needs glib
10 use_prebuilt_binary(dbusglib) 11 use_prebuilt_binary(dbusglib)
11 set(DBUSGLIB_FOUND ON FORCE BOOL) 12 set(DBUSGLIB_FOUND ON FORCE BOOL)
12 set(DBUSGLIB_INCLUDE_DIRS 13 set(DBUSGLIB_INCLUDE_DIRS
diff --git a/linden/indra/cmake/ExamplePlugin.cmake b/linden/indra/cmake/ExamplePlugin.cmake
new file mode 100644
index 0000000..599787a
--- /dev/null
+++ b/linden/indra/cmake/ExamplePlugin.cmake
@@ -0,0 +1,16 @@
1# -*- cmake -*-
2include(Linking)
3include(Prebuilt)
4
5if (STANDALONE)
6 set(EXAMPLEPLUGIN OFF CACHE BOOL
7 "EXAMPLEPLUGIN support for the llplugin/llmedia test apps.")
8else (STANDALONE)
9 set(EXAMPLEPLUGIN ON CACHE BOOL
10 "EXAMPLEPLUGIN support for the llplugin/llmedia test apps.")
11endif (STANDALONE)
12
13if (WINDOWS)
14elseif (DARWIN)
15elseif (LINUX)
16endif (WINDOWS)
diff --git a/linden/indra/cmake/FindLLQtWebkit.cmake b/linden/indra/cmake/FindLLQtWebkit.cmake
new file mode 100644
index 0000000..c747ec3
--- /dev/null
+++ b/linden/indra/cmake/FindLLQtWebkit.cmake
@@ -0,0 +1,62 @@
1# -*- cmake -*-
2
3# - Find llqtwebkit
4# Find the llqtwebkit includes and library
5# This module defines
6# LLQTWEBKIT_INCLUDE_DIR, where to find llqtwebkit.h, etc.
7# LLQTWEBKIT_LIBRARY, the llqtwebkit library with full path.
8# LLQTWEBKIT_FOUND, If false, do not try to use llqtwebkit.
9# also defined, but not for general use are
10# LLQTWEBKIT_LIBRARIES, the libraries needed to use llqtwebkit.
11# LLQTWEBKIT_LIBRARY_DIRS, where to find the llqtwebkit library.
12# LLQTWEBKIT_DEFINITIONS - You should add_definitions(${LLQTWEBKIT_DEFINITIONS})
13# before compiling code that includes llqtwebkit library files.
14
15# Try to use pkg-config first.
16# This allows to have two different libllqtwebkit packages installed:
17# one for viewer 2.x and one for viewer 1.x.
18include(FindPkgConfig)
19if (PKG_CONFIG_FOUND)
20 if (LLQtWebkit_FIND_REQUIRED AND LLQtWebkit_FIND_VERSION)
21 set(_PACKAGE_ARGS libllqtwebkit>=${LLQtWebkit_FIND_VERSION} REQUIRED)
22 else (LLQtWebkit_FIND_REQUIRED AND LLQtWebkit_FIND_VERSION)
23 set(_PACKAGE_ARGS libllqtwebkit)
24 endif (LLQtWebkit_FIND_REQUIRED AND LLQtWebkit_FIND_VERSION)
25 if (NOT "${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}" VERSION_LESS "2.8")
26 # As virtually nobody will have a pkg-config file for this, do this check always quiet.
27 # Unfortunately cmake 2.8 or higher is required for pkg_check_modules to have a 'QUIET'.
28 set(_PACKAGE_ARGS ${_PACKAGE_ARGS} QUIET)
29 endif ()
30 pkg_check_modules(LLQTWEBKIT ${_PACKAGE_ARGS})
31endif (PKG_CONFIG_FOUND)
32set(LLQTWEBKIT_DEFINITIONS ${LLQTWEBKIT_CFLAGS_OTHER})
33
34find_path(LLQTWEBKIT_INCLUDE_DIR llqtwebkit.h NO_SYSTEM_ENVIRONMENT_PATH HINTS ${LLQTWEBKIT_INCLUDE_DIRS})
35
36find_library(LLQTWEBKIT_LIBRARY NAMES llqtwebkit NO_SYSTEM_ENVIRONMENT_PATH HINTS ${LLQTWEBKIT_LIBRARY_DIRS})
37
38if (NOT PKG_CONFIG_FOUND OR NOT LLQTWEBKIT_FOUND) # If pkg-config couldn't find it, pretend we don't have pkg-config.
39 set(LLQTWEBKIT_LIBRARIES llqtwebkit)
40 get_filename_component(LLQTWEBKIT_LIBRARY_DIRS ${LLQTWEBKIT_LIBRARY} PATH)
41endif (NOT PKG_CONFIG_FOUND OR NOT LLQTWEBKIT_FOUND)
42
43# Handle the QUIETLY and REQUIRED arguments and set LLQTWEBKIT_FOUND
44# to TRUE if all listed variables are TRUE.
45include(FindPackageHandleStandardArgs)
46find_package_handle_standard_args(
47 LLQTWEBKIT
48 DEFAULT_MSG
49 LLQTWEBKIT_LIBRARY
50 LLQTWEBKIT_INCLUDE_DIR
51 LLQTWEBKIT_LIBRARIES
52 LLQTWEBKIT_LIBRARY_DIRS
53 )
54
55mark_as_advanced(
56 LLQTWEBKIT_LIBRARY
57 LLQTWEBKIT_INCLUDE_DIR
58 LLQTWEBKIT_LIBRARIES
59 LLQTWEBKIT_LIBRARY_DIRS
60 LLQTWEBKIT_DEFINITIONS
61 )
62
diff --git a/linden/indra/cmake/GStreamer.cmake b/linden/indra/cmake/GStreamer.cmake
deleted file mode 100644
index 82c417a..0000000
--- a/linden/indra/cmake/GStreamer.cmake
+++ /dev/null
@@ -1,127 +0,0 @@
1# -*- cmake -*-
2include(Prebuilt)
3
4if (STANDALONE)
5 include(FindPkgConfig)
6
7 pkg_check_modules(GSTREAMER REQUIRED gstreamer-0.10)
8 pkg_check_modules(GSTREAMER_PLUGINS_BASE REQUIRED gstreamer-plugins-base-0.10)
9 pkg_check_modules(GSTREAMER_VIDEO REQUIRED gstreamer-video-0.10)
10
11else (STANDALONE)
12
13 # libxml and glib should have their own .cmake files
14 use_prebuilt_binary(libxml)
15 use_prebuilt_binary(glib)
16
17 set(GSTREAMER_FOUND ON FORCE BOOL)
18 set(GSTREAMER_PLUGINS_BASE_FOUND ON FORCE BOOL)
19 set(GSTREAMER_VIDEO_FOUND ON FORCE BOOL)
20
21 use_prebuilt_binary(gstreamer)
22 use_prebuilt_binary(gstreamer-plugins)
23
24if (WINDOWS)
25
26 use_prebuilt_binary(iconv)
27 set(GSTREAMER_FOUND ON FORCE BOOL)
28 set(GSTREAMER_INCLUDE_DIRS
29 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/glib
30 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/gio
31 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/gobject
32 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/libxml2
33 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/iconv
34 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/gst
35 )
36
37 set(GSTREAMER_LIBRARIES
38 glib-2.0
39 gio-2.0
40 gmodule-2.0
41 gobject-2.0
42 gthread-2.0
43 libgstvideo.lib
44 libgsttag.lib
45 libgstsdp.lib
46 libgstrtsp.lib
47 libgstrtp.lib
48 libgstriff.lib
49 libgstreamer-0.10.lib
50 libgstpbutils.lib
51 libgstnetbuffer.lib
52 libgstnet-0.10.lib
53 libgstinterfaces.lib
54 libgstdshow.lib
55 libgstdataprotocol-0.10.lib
56 libgstcontroller-0.10.lib
57 libgstbase-0.10.lib
58 libgstaudio.lib
59 libgstapp.lib
60 libxml2
61 libxml2_a
62 libxml2_a_dll
63 iconv
64 iconv_a
65 )
66
67else (WINDOWS)
68
69 set(GSTREAMER_INCLUDE_DIRS
70 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/gstreamer-0.10
71 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/glib-2.0
72 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/glib-2.0/glib
73 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/glib-2.0/gobject
74 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/libxml2
75 )
76
77 if (DARWIN) # Mac
78
79 use_prebuilt_binary(flac)
80 use_prebuilt_binary(liboil)
81 use_prebuilt_binary(neon)
82 use_prebuilt_binary(theora)
83
84 set(GSTREAMER_LIBRARIES
85 gstvideo-0.10
86 gstaudio-0.10
87 gstbase-0.10
88 gstreamer-0.10
89 gobject-2.0
90 gmodule-2.0
91 gthread-2.0
92 glib-2.0
93 xml2.2
94 )
95
96 else (DARWIN) # Linux
97
98 use_prebuilt_binary(liboil)
99 use_prebuilt_binary(theora)
100
101 set(GSTREAMER_LIBRARIES
102 gstvideo-0.10
103 gstaudio-0.10
104 gstbase-0.10
105 gstreamer-0.10
106 gobject-2.0
107 gmodule-2.0
108 dl
109 gthread-2.0
110 rt
111 glib-2.0
112 gio-2.0
113 )
114
115 endif (DARWIN)
116
117endif (WINDOWS)
118
119endif (STANDALONE)
120
121if (GSTREAMER_FOUND AND GSTREAMER_PLUGINS_BASE_FOUND AND GSTREAMER_VIDEO_FOUND)
122 set(GSTREAMER ON CACHE BOOL "Build with GStreamer streaming media support.")
123endif (GSTREAMER_FOUND AND GSTREAMER_PLUGINS_BASE_FOUND AND GSTREAMER_VIDEO_FOUND)
124
125if (GSTREAMER)
126 add_definitions(-DLL_GSTREAMER_ENABLED=1)
127endif (GSTREAMER)
diff --git a/linden/indra/cmake/GStreamer010Plugin.cmake b/linden/indra/cmake/GStreamer010Plugin.cmake
new file mode 100644
index 0000000..90ed35c
--- /dev/null
+++ b/linden/indra/cmake/GStreamer010Plugin.cmake
@@ -0,0 +1,66 @@
1# -*- cmake -*-
2include(Prebuilt)
3
4if (STANDALONE)
5 include(FindPkgConfig)
6
7 pkg_check_modules(GSTREAMER010 REQUIRED gstreamer-0.10)
8 pkg_check_modules(GSTREAMER010_PLUGINS_BASE REQUIRED gstreamer-plugins-base-0.10)
9
10else (STANDALONE)
11
12 # Possibly libxml and glib should have their own .cmake file instead...
13 use_prebuilt_binary(glib) # gstreamer needs glib
14 use_prebuilt_binary(libxml)
15 use_prebuilt_binary(gstreamer)
16 set(GSTREAMER010_FOUND ON FORCE BOOL)
17 set(GSTREAMER010_PLUGINS_BASE_FOUND ON FORCE BOOL)
18 set(GSTREAMER010_INCLUDE_DIRS
19 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/gstreamer-0.10
20 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/glib-2.0
21 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/libxml2
22 )
23
24endif (STANDALONE)
25
26if (WINDOWS)
27 # We don't need to explicitly link against gstreamer itself, because
28 # LLMediaImplGStreamer probes for the system's copy at runtime.
29 set(GSTREAMER010_LIBRARIES
30 libgstvideo
31 libgstaudio
32 libgstbase-0.10
33 libgstreamer-0.10
34 gobject-2.0
35 gmodule-2.0
36 gthread-2.0
37 glib-2.0
38 )
39else (WINDOWS)
40 # We don't need to explicitly link against gstreamer itself, because
41 # LLMediaImplGStreamer probes for the system's copy at runtime.
42 set(GSTREAMER010_LIBRARIES
43 gstvideo-0.10
44 gstaudio-0.10
45 gstbase-0.10
46 gstreamer-0.10
47 gobject-2.0
48 gmodule-2.0
49 dl
50 gthread-2.0
51 rt
52 glib-2.0
53 )
54
55
56endif (WINDOWS)
57
58
59if (GSTREAMER010_FOUND AND GSTREAMER010_PLUGINS_BASE_FOUND)
60 set(GSTREAMER010 ON CACHE BOOL "Build with GStreamer-0.10 streaming media support.")
61 add_definitions(-DLL_GSTREAMER010_ENABLED=1)
62endif (GSTREAMER010_FOUND AND GSTREAMER010_PLUGINS_BASE_FOUND)
63
64
65
66
diff --git a/linden/indra/cmake/Glui.cmake b/linden/indra/cmake/Glui.cmake
new file mode 100644
index 0000000..f62a568
--- /dev/null
+++ b/linden/indra/cmake/Glui.cmake
@@ -0,0 +1,28 @@
1# -*- cmake -*-
2include(Linking)
3include(Prebuilt)
4
5if (STANDALONE)
6 set(GLUI OFF CACHE BOOL
7 "GLUI support for the llplugin/llmedia test apps.")
8else (STANDALONE)
9 use_prebuilt_binary(glui)
10 set(GLUI ON CACHE BOOL
11 "GLUI support for the llplugin/llmedia test apps.")
12endif (STANDALONE)
13
14if (LINUX)
15 set(GLUI ON CACHE BOOL
16 "llplugin media apps HACK for Linux.")
17endif (LINUX)
18
19if (DARWIN OR LINUX)
20 set(GLUI_LIBRARY
21 glui)
22endif (DARWIN OR LINUX)
23
24if (WINDOWS)
25 set(GLUI_LIBRARY
26 debug glui32.lib
27 optimized glui32.lib)
28endif (WINDOWS)
diff --git a/linden/indra/cmake/Glut.cmake b/linden/indra/cmake/Glut.cmake
new file mode 100644
index 0000000..314da30
--- /dev/null
+++ b/linden/indra/cmake/Glut.cmake
@@ -0,0 +1,19 @@
1# -*- cmake -*-
2include(Linking)
3include(Prebuilt)
4
5if (WINDOWS)
6 use_prebuilt_binary(freeglut)
7 set(GLUT_LIBRARY
8 debug freeglut_static.lib
9 optimized freeglut_static.lib)
10endif (WINDOWS)
11
12if (LINUX)
13 FIND_LIBRARY(GLUT_LIBRARY glut)
14endif (LINUX)
15
16if (DARWIN)
17 include(CMakeFindFrameworks)
18 find_library(GLUT_LIBRARY GLUT)
19endif (DARWIN)
diff --git a/linden/indra/cmake/LLAudio.cmake b/linden/indra/cmake/LLAudio.cmake
index 625e212..89b790c 100644
--- a/linden/indra/cmake/LLAudio.cmake
+++ b/linden/indra/cmake/LLAudio.cmake
@@ -1,11 +1,9 @@
1# -*- cmake -*- 1# -*- cmake -*-
2 2
3include(Audio) 3include(Audio)
4include(OPENAL)
5 4
6set(LLAUDIO_INCLUDE_DIRS 5set(LLAUDIO_INCLUDE_DIRS
7 ${LIBS_OPEN_DIR}/llaudio 6 ${LIBS_OPEN_DIR}/llaudio
8 ${OPENAL_INCLUDE_DIRS}
9 ) 7 )
10 8
11set(LLAUDIO_LIBRARIES llaudio ${OPENAL_LIBRARIES}) 9set(LLAUDIO_LIBRARIES llaudio ${OPENAL_LIBRARIES})
diff --git a/linden/indra/cmake/LLCommon.cmake b/linden/indra/cmake/LLCommon.cmake
index 410766e..9158e98 100644
--- a/linden/indra/cmake/LLCommon.cmake
+++ b/linden/indra/cmake/LLCommon.cmake
@@ -12,4 +12,15 @@ set(LLCOMMON_INCLUDE_DIRS
12 ${Boost_INCLUDE_DIRS} 12 ${Boost_INCLUDE_DIRS}
13 ) 13 )
14 14
15set(LLCOMMON_LIBRARIES llcommon) 15# Files that need PIC code (pluginAPI) need to set REQUIRE_PIC on 64bit systems
16# this will link against a llcommon built with Position Independent Code
17# this is a requirment to link a static library (.a) to a DSO on 64 bit systems
18
19if(REQUIRE_PIC)
20 set(LLCOMMON_LIBRARIES llcommonPIC)
21else(REQUIRE_PIC)
22 set(LLCOMMON_LIBRARIES llcommon)
23endif(REQUIRE_PIC)
24
25#force clear the flag, files that need this must explicity set it themselves
26set(REQUIRE_PIC 0) \ No newline at end of file
diff --git a/linden/indra/cmake/LLMedia.cmake b/linden/indra/cmake/LLMedia.cmake
deleted file mode 100644
index e7769db..0000000
--- a/linden/indra/cmake/LLMedia.cmake
+++ /dev/null
@@ -1,14 +0,0 @@
1# -*- cmake -*-
2
3include(GStreamer)
4
5set(LLMEDIA_INCLUDE_DIRS
6 ${LIBS_OPEN_DIR}/llmedia
7 )
8
9set(LLMEDIA_LIBRARIES
10 llmedia
11 ${GSTREAMER_LIBRARIES}
12 ${GSTREAMER_PLUGINS_BASE_LIBRARIES}
13 ${GSTREAMER_VIDEO_LIBRARIES}
14 )
diff --git a/linden/indra/cmake/LLPlugin.cmake b/linden/indra/cmake/LLPlugin.cmake
new file mode 100644
index 0000000..9722f16
--- /dev/null
+++ b/linden/indra/cmake/LLPlugin.cmake
@@ -0,0 +1,8 @@
1# -*- cmake -*-
2
3
4set(LLPLUGIN_INCLUDE_DIRS
5 ${LIBS_OPEN_DIR}/llplugin
6 )
7
8set(LLPLUGIN_LIBRARIES llplugin)
diff --git a/linden/indra/cmake/MediaPluginBase.cmake b/linden/indra/cmake/MediaPluginBase.cmake
new file mode 100644
index 0000000..2be035b
--- /dev/null
+++ b/linden/indra/cmake/MediaPluginBase.cmake
@@ -0,0 +1,8 @@
1# -*- cmake -*-
2
3
4set(MEDIA_PLUGIN_BASE_INCLUDE_DIRS
5 ${LIBS_OPEN_DIR}/media_plugins/base/
6 )
7
8set(MEDIA_PLUGIN_BASE_LIBRARIES media_plugin_base)
diff --git a/linden/indra/cmake/Mozlib.cmake b/linden/indra/cmake/Mozlib.cmake
index e9555df..e69de29 100644
--- a/linden/indra/cmake/Mozlib.cmake
+++ b/linden/indra/cmake/Mozlib.cmake
@@ -1,47 +0,0 @@
1# -*- cmake -*-
2include(Linking)
3include(Prebuilt)
4
5if (STANDALONE)
6 set(MOZLIB OFF CACHE BOOL
7 "Enable Mozilla support in the viewer (requires llmozlib library).")
8else (STANDALONE)
9 use_prebuilt_binary(llmozlib)
10 set(MOZLIB ON CACHE BOOL
11 "Enable Mozilla support in the viewer (requires llmozlib library).")
12endif (STANDALONE)
13
14if (MOZLIB)
15 add_definitions(-DLL_LLMOZLIB_ENABLED=1)
16
17 if (LINUX)
18 link_directories(${CMAKE_SOURCE_DIR}/newview/app_settings/mozilla-runtime-linux-${ARCH})
19 set(MOZLIB_LIBRARIES
20 llmozlib2
21 mozjs
22 nspr4
23 plc4
24 plds4
25 xpcom
26 xul
27 profdirserviceprovider_s
28 )
29 elseif (WINDOWS)
30 if (MSVC71)
31 set(MOZLIB_LIBRARIES
32 debug llmozlib2d
33 optimized llmozlib2)
34 elseif (MSVC80 OR MSVC90)
35 set(MOZLIB_LIBRARIES
36 debug llmozlib2d-vc80
37 optimized llmozlib2-vc80)
38 endif (MSVC71)
39 else (LINUX)
40 set(MOZLIB_LIBRARIES
41 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/libllmozlib2.dylib
42 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libllmozlib2.dylib
43 )
44 endif (LINUX)
45else (MOZLIB)
46 add_definitions(-DLL_LLMOZLIB_ENABLED=0)
47endif (MOZLIB)
diff --git a/linden/indra/cmake/PluginAPI.cmake b/linden/indra/cmake/PluginAPI.cmake
new file mode 100644
index 0000000..d1649e8
--- /dev/null
+++ b/linden/indra/cmake/PluginAPI.cmake
@@ -0,0 +1,16 @@
1# -*- cmake -*-
2
3if (WINDOWS)
4 set(PLUGIN_API_WINDOWS_LIBRARIES
5 wsock32
6 ws2_32
7 psapi
8 netapi32
9 advapi32
10 user32
11 )
12else (WINDOWS)
13 set(PLUGIN_API_WINDOWS_LIBRARIES "")
14endif (WINDOWS)
15
16
diff --git a/linden/indra/cmake/PulseAudio.cmake b/linden/indra/cmake/PulseAudio.cmake
new file mode 100644
index 0000000..f8087a8
--- /dev/null
+++ b/linden/indra/cmake/PulseAudio.cmake
@@ -0,0 +1,28 @@
1# -*- cmake -*-
2include(Prebuilt)
3
4if (STANDALONE)
5 include(FindPkgConfig)
6
7 pkg_check_modules(PULSEAUDIO REQUIRED libpulse-mainloop-glib)
8
9elseif (LINUX)
10 use_prebuilt_binary(pulseaudio)
11 set(PULSEAUDIO_FOUND ON FORCE BOOL)
12 set(PULSEAUDIO_INCLUDE_DIRS
13 ${LIBS_PREBUILT_DIR}/include
14 )
15 # We don't need to explicitly link against pulseaudio itself, because
16 # the viewer probes for the system's copy at runtime.
17 set(PULSEAUDIO_LIBRARIES
18 # none needed!
19 )
20endif (STANDALONE)
21
22if (PULSEAUDIO_FOUND)
23 set(PULSEAUDIO ON CACHE BOOL "Build with PulseAudio support, if available.")
24endif (PULSEAUDIO_FOUND)
25
26if (PULSEAUDIO)
27 add_definitions(-DLL_PULSEAUDIO_ENABLED=1)
28endif (PULSEAUDIO)
diff --git a/linden/indra/cmake/QuickTimePlugin.cmake b/linden/indra/cmake/QuickTimePlugin.cmake
new file mode 100644
index 0000000..8afd8f3
--- /dev/null
+++ b/linden/indra/cmake/QuickTimePlugin.cmake
@@ -0,0 +1,46 @@
1# -*- cmake -*-
2
3if(INSTALL_PROPRIETARY)
4 include(Prebuilt)
5 use_prebuilt_binary(quicktime)
6endif(INSTALL_PROPRIETARY)
7
8if (DARWIN)
9 include(CMakeFindFrameworks)
10 find_library(QUICKTIME_LIBRARY QuickTime)
11elseif (WINDOWS)
12 set(QUICKTIME_SDK_DIR "$ENV{PROGRAMFILES}/QuickTime SDK"
13 CACHE PATH "Location of the QuickTime SDK.")
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
22 PATHS
23 ${ARCH_PREBUILT_DIRS_RELEASE}
24 "${QUICKTIME_SDK_DIR}\\libraries"
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
35 include_directories(
36 ${LIBS_PREBUILT_DIR}/${LL_ARCH_DIR}/include/quicktime
37 "${QUICKTIME_SDK_DIR}\\CIncludes"
38 )
39endif (DARWIN)
40
41mark_as_advanced(QUICKTIME_LIBRARY)
42
43if (QUICKTIME_LIBRARY)
44 set(QUICKTIME ON CACHE BOOL "Build with QuickTime streaming media support.")
45endif (QUICKTIME_LIBRARY)
46
diff --git a/linden/indra/cmake/UI.cmake b/linden/indra/cmake/UI.cmake
index 9d068c4..7a02dff 100644
--- a/linden/indra/cmake/UI.cmake
+++ b/linden/indra/cmake/UI.cmake
@@ -31,8 +31,9 @@ if (STANDALONE)
31 add_definitions(${${pkg}_CFLAGS_OTHERS}) 31 add_definitions(${${pkg}_CFLAGS_OTHERS})
32 endforeach(pkg) 32 endforeach(pkg)
33else (STANDALONE) 33else (STANDALONE)
34 use_prebuilt_binary(gtk-etc)
35 if (LINUX) 34 if (LINUX)
35 use_prebuilt_binary(glib) # gtk-etc needs glib
36 use_prebuilt_binary(gtk-etc)
36 set(UI_LIBRARIES 37 set(UI_LIBRARIES
37 atk-1.0 38 atk-1.0
38 cairo 39 cairo
diff --git a/linden/indra/cmake/Variables.cmake b/linden/indra/cmake/Variables.cmake
index 8a06133..eb9c004 100644
--- a/linden/indra/cmake/Variables.cmake
+++ b/linden/indra/cmake/Variables.cmake
@@ -45,6 +45,7 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Windows")
45 set(ARCH i686) 45 set(ARCH i686)
46 set(LL_ARCH ${ARCH}_win32) 46 set(LL_ARCH ${ARCH}_win32)
47 set(LL_ARCH_DIR ${ARCH}-win32) 47 set(LL_ARCH_DIR ${ARCH}-win32)
48 set(WORD_SIZE 32)
48endif (${CMAKE_SYSTEM_NAME} MATCHES "Windows") 49endif (${CMAKE_SYSTEM_NAME} MATCHES "Windows")
49 50
50if (${CMAKE_SYSTEM_NAME} MATCHES "Linux") 51if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
diff --git a/linden/indra/cmake/WebKitLibPlugin.cmake b/linden/indra/cmake/WebKitLibPlugin.cmake
new file mode 100644
index 0000000..a4befa4
--- /dev/null
+++ b/linden/indra/cmake/WebKitLibPlugin.cmake
@@ -0,0 +1,79 @@
1# -*- cmake -*-
2include(Linking)
3include(Prebuilt)
4
5if (STANDALONE)
6 # The minimal version, 4.4.3, is rather arbitrary: it's the version in Debian/Lenny.
7 find_package(Qt4 4.4.3 COMPONENTS QtCore QtGui QtNetwork QtOpenGL QtWebKit REQUIRED)
8 include(${QT_USE_FILE})
9 set(QTDIR $ENV{QTDIR})
10 if (QTDIR AND NOT "${QT_BINARY_DIR}" STREQUAL "${QTDIR}/bin")
11 message(FATAL_ERROR "\"${QT_BINARY_DIR}\" is unequal \"${QTDIR}/bin\"; "
12 "Qt is found by looking for qmake in your PATH. "
13 "Please set your PATH such that 'qmake' is found in \$QTDIR/bin, "
14 "or unset QTDIR if the found Qt is correct.")
15 endif (QTDIR AND NOT "${QT_BINARY_DIR}" STREQUAL "${QTDIR}/bin")
16 find_package(LLQtWebkit REQUIRED QUIET)
17 # Add the plugins.
18 set(QT_PLUGIN_LIBRARIES)
19 foreach(qlibname qgif qjpeg)
20 find_library(QT_PLUGIN_${qlibname} ${qlibname} PATHS ${QT_PLUGINS_DIR}/imageformats NO_DEFAULT_PATH)
21 if (QT_PLUGIN_${qlibname})
22 list(APPEND QT_PLUGIN_LIBRARIES ${QT_PLUGIN_${qlibname}})
23 else (QT_PLUGIN_${qtlibname})
24 message(FATAL_ERROR "Could not find the Qt plugin ${qlibname} in \"${QT_PLUGINS_DIR}/imageformats\"!")
25 endif (QT_PLUGIN_${qlibname})
26 endforeach(qlibname)
27 # qjpeg depends on libjpeg
28 list(APPEND QT_PLUGIN_LIBRARIES jpeg)
29 set(WEBKITLIBPLUGIN OFF CACHE BOOL
30 "WEBKITLIBPLUGIN support for the llplugin/llmedia test apps.")
31else (STANDALONE)
32 use_prebuilt_binary(llqtwebkit)
33 set(WEBKITLIBPLUGIN ON CACHE BOOL
34 "WEBKITLIBPLUGIN support for the llplugin/llmedia test apps.")
35endif (STANDALONE)
36
37if (WINDOWS)
38 set(WEBKIT_PLUGIN_LIBRARIES
39 debug llqtwebkitd
40 debug QtWebKitd4
41 debug QtOpenGLd4
42 debug QtNetworkd4
43 debug QtGuid4
44 debug QtCored4
45 debug qtmaind
46 optimized llqtwebkit
47 optimized QtWebKit4
48 optimized QtOpenGL4
49 optimized QtNetwork4
50 optimized QtGui4
51 optimized QtCore4
52 optimized qtmain
53 )
54elseif (DARWIN)
55 set(WEBKIT_PLUGIN_LIBRARIES
56 optimized ${ARCH_PREBUILT_DIRS_RELEASE}/libllqtwebkit.dylib
57 debug ${ARCH_PREBUILT_DIRS_DEBUG}/libllqtwebkit.dylib
58 )
59elseif (LINUX)
60 if (STANDALONE)
61 set(WEBKIT_PLUGIN_LIBRARIES ${LLQTWEBKIT_LIBRARY} ${QT_LIBRARIES} ${QT_PLUGIN_LIBRARIES})
62 else (STANDALONE)
63 set(WEBKIT_PLUGIN_LIBRARIES
64 llqtwebkit
65 qgif
66 qjpeg
67 QtWebKit
68 QtOpenGL
69 QtNetwork
70 QtGui
71 QtCore
72 jpeg
73 fontconfig
74 X11
75 Xrender
76 GL
77 )
78 endif (STANDALONE)
79endif (WINDOWS)