diff options
Diffstat (limited to 'indra/cmake/LibVLCPlugin.cmake')
-rw-r--r-- | indra/cmake/LibVLCPlugin.cmake | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/indra/cmake/LibVLCPlugin.cmake b/indra/cmake/LibVLCPlugin.cmake index 599ce02844..f4ec34ec1b 100644 --- a/indra/cmake/LibVLCPlugin.cmake +++ b/indra/cmake/LibVLCPlugin.cmake @@ -5,9 +5,26 @@ include(Prebuilt) include_guard() add_library( ll::libvlc INTERFACE IMPORTED ) +if (USE_AUTOBUILD_3P OR USE_CONAN) use_prebuilt_binary(vlc-bin) set(LIBVLCPLUGIN ON CACHE BOOL "LIBVLCPLUGIN support for the llplugin/llmedia test apps.") +else () + include(FindPkgConfig) + if (DARWIN) + set(CMAKE_PREFIX_PATH "/opt/local/libexec/vlc3/lib/pkgconfig") + pkg_check_modules(Libvlc REQUIRED libvlc) + target_link_libraries( ll::libvlc INTERFACE vlccore ) + else () + pkg_check_modules(Libvlc REQUIRED libvlc vlc-plugin) + endif () + target_include_directories( ll::libvlc SYSTEM INTERFACE ${Libvlc_INCLUDE_DIRS} ) + target_link_directories( ll::libvlc INTERFACE ${Libvlc_LIBRARY_DIRS} ) + target_link_libraries( ll::libvlc INTERFACE ${Libvlc_LIBRARIES} ) + set(LIBVLCPLUGIN ON CACHE BOOL + "LIBVLCPLUGIN support for the llplugin/llmedia test apps.") + return() +endif () if (WINDOWS) target_link_libraries( ll::libvlc INTERFACE |