Add option to bundle gstreamer plugins on Linux

This commit is contained in:
Jonas Kvinge 2019-08-27 22:29:48 +02:00
parent 2a61b1202b
commit 9b45f0661e
2 changed files with 12 additions and 6 deletions

View File

@ -347,14 +347,20 @@ optional_component(MOODBAR ON "Moodbar"
DEPENDS "gstreamer" HAVE_GSTREAMER
)
if(APPLE)
option(USE_BUNDLE "Bundle macOS dependencies" OFF)
if(LINUX OR APPLE)
option(USE_BUNDLE "Bundle dependencies" OFF)
elseif(WIN32)
option(USE_BUNDLE "Bundle Windows dependencies" ON)
option(USE_BUNDLE "Bundle dependencies" ON)
endif()
if (APPLE AND USE_BUNDLE AND NOT USE_BUNDLE_DIR)
if (USE_BUNDLE AND NOT USE_BUNDLE_DIR)
if(LINUX)
set(USE_BUNDLE_DIR "../plugins")
endif(LINUX)
if(APPLE)
set(USE_BUNDLE_DIR "../PlugIns")
endif()
endif(APPLE)
endif(USE_BUNDLE AND NOT USE_BUNDLE_DIR)
# Check that we have sqlite3 with FTS5

View File

@ -66,7 +66,7 @@ void GstStartup::SetEnvironment() {
// On Windows and macOS we bundle the gstreamer plugins with strawberry
#ifdef USE_BUNDLE
#if defined(Q_OS_MACOS)
#if defined(Q_OS_LINUX) || defined(Q_OS_MACOS)
scanner_path = QCoreApplication::applicationDirPath() + "/" + USE_BUNDLE_DIR + "/gst-plugin-scanner";
plugin_path = QCoreApplication::applicationDirPath() + "/" + USE_BUNDLE_DIR + "/gstreamer";
#elif defined(Q_OS_WIN32)