summaryrefslogtreecommitdiff
path: root/indra/media_plugins/libvlc/CMakeLists.txt
diff options
context:
space:
mode:
authorRider Linden <rider@lindenlab.com>2016-10-17 14:58:29 -0700
committerRider Linden <rider@lindenlab.com>2016-10-17 14:58:29 -0700
commit38d06dcce66ce3a7f5a7a1521f0305dbc0ea0bc5 (patch)
tree38745f1a60a13b496014a64690e7afda14611830 /indra/media_plugins/libvlc/CMakeLists.txt
parentb2eded73b9bf55e2253a9c39113ff0598c2c18cb (diff)
parent086c1342152895da28d2e0130d09432152604ca8 (diff)
Merged lindenlab/viewer-release into default
Diffstat (limited to 'indra/media_plugins/libvlc/CMakeLists.txt')
-rw-r--r--indra/media_plugins/libvlc/CMakeLists.txt86
1 files changed, 86 insertions, 0 deletions
diff --git a/indra/media_plugins/libvlc/CMakeLists.txt b/indra/media_plugins/libvlc/CMakeLists.txt
new file mode 100644
index 0000000000..535d29125b
--- /dev/null
+++ b/indra/media_plugins/libvlc/CMakeLists.txt
@@ -0,0 +1,86 @@
+# -*- cmake -*-
+
+project(media_plugin_libvlc)
+
+include(00-Common)
+include(LLCommon)
+include(LLImage)
+include(LLPlugin)
+include(LLMath)
+include(LLRender)
+include(LLWindow)
+include(Linking)
+include(PluginAPI)
+include(MediaPluginBase)
+include(OpenGL)
+
+include(LibVLCPlugin)
+
+include_directories(
+ ${LLPLUGIN_INCLUDE_DIRS}
+ ${MEDIA_PLUGIN_BASE_INCLUDE_DIRS}
+ ${LLCOMMON_INCLUDE_DIRS}
+ ${LLMATH_INCLUDE_DIRS}
+ ${LLIMAGE_INCLUDE_DIRS}
+ ${LLRENDER_INCLUDE_DIRS}
+ ${LLWINDOW_INCLUDE_DIRS}
+ ${VLC_INCLUDE_DIR}
+)
+include_directories(SYSTEM
+ ${LLCOMMON_SYSTEM_INCLUDE_DIRS}
+ )
+
+
+### media_plugin_libvlc
+
+if(NOT WORD_SIZE EQUAL 32)
+ if(WINDOWS)
+ add_definitions(/FIXED:NO)
+ else(WINDOWS) # not windows therefore gcc LINUX and DARWIN
+ add_definitions(-fPIC)
+ endif(WINDOWS)
+endif(NOT WORD_SIZE EQUAL 32)
+
+set(media_plugin_libvlc_SOURCE_FILES
+ media_plugin_libvlc.cpp
+ )
+
+add_library(media_plugin_libvlc
+ SHARED
+ ${media_plugin_libvlc_SOURCE_FILES}
+)
+
+target_link_libraries(media_plugin_libvlc
+ ${LLPLUGIN_LIBRARIES}
+ ${MEDIA_PLUGIN_BASE_LIBRARIES}
+ ${LLCOMMON_LIBRARIES}
+ ${VLC_PLUGIN_LIBRARIES}
+ ${PLUGIN_API_WINDOWS_LIBRARIES}
+)
+
+add_dependencies(media_plugin_libvlc
+ ${LLPLUGIN_LIBRARIES}
+ ${MEDIA_PLUGIN_BASE_LIBRARIES}
+ ${LLCOMMON_LIBRARIES}
+)
+
+if (WINDOWS)
+ set_target_properties(
+ media_plugin_libvlc
+ PROPERTIES
+ LINK_FLAGS "/MANIFEST:NO /SAFESEH:NO /LTCG /NODEFAULTLIB:LIBCMT"
+ )
+endif (WINDOWS)
+
+if (DARWIN)
+ # Don't prepend 'lib' to the executable name, and don't embed a full path in the library's install name
+ set_target_properties(
+ media_plugin_libvlc
+ PROPERTIES
+ PREFIX ""
+ BUILD_WITH_INSTALL_RPATH 1
+ INSTALL_NAME_DIR "@executable_path"
+ LINK_FLAGS "-exported_symbols_list ${CMAKE_CURRENT_SOURCE_DIR}/../base/media_plugin_base.exp"
+ )
+
+endif (DARWIN)