Commit adecf3d9 authored by Thibault Saunier's avatar Thibault Saunier

build: Set GST_PLUGIN_SYSTEM_PATH in the sandbox

So that gstramer does not try to work with plugins provided by the gnome
runtime.
parent 894cce2c
......@@ -36,6 +36,7 @@ CONFIGURED_PYTHONPATH = '@CONFIGURED_PYTHONPATH@'
CONFIGURED_GI_TYPELIB_PATH = '@CONFIGURED_GI_TYPELIB_PATH@'
CONFIGURED_LD_LIBRARY_PATH = '@CONFIGURED_LD_LIBRARY_PATH@'
CONFIGURED_GST_PLUGIN_PATH = '@CONFIGURED_GST_PLUGIN_PATH@'
CONFIGURED_GST_PLUGIN_SYSTEM_PATH = '@CONFIGURED_GST_PLUGIN_SYSTEM_PATH@'
LIBDIR = '@LIBDIR@'
DATADIR = '@DATADIR@'
BUILDDIR = '@BUILDDIR@'
......@@ -100,6 +101,9 @@ def _add_pitivi_path():
# ld caches LD_LIBRARY_PATH at startup so we need to execv() here. LALA.
jump_through_hoops()
if CONFIGURED_GST_PLUGIN_SYSTEM_PATH:
os.environ["GST_PLUGIN_SYSTEM_PATH"] = CONFIGURED_GST_PLUGIN_SYSTEM_PATH
if CONFIGURED_GI_TYPELIB_PATH:
_prepend_env_path("GI_TYPELIB_PATH", [CONFIGURED_GI_TYPELIB_PATH])
......
......@@ -16,7 +16,8 @@
"cflags": "-O0 -g",
"cxxflags": "-O0 -g",
"env": {
"PYTHON": "python3"
"PYTHON": "python3",
"GST_PLUGIN_SYSTEM_PATH": "/app/lib/gstreamer-1.0/"
},
"strip": false,
"no-debuginfo": true
......
#!/usr/bin/env python3
"""Print the content of an environment variable on stdout."""
import os
import sys
print(os.environ.get(sys.argv[1], ''))
......@@ -22,11 +22,19 @@ else
GITVERSION = ''
endif
geteenvvar = find_program('getenvvar.py')
cdata = configuration_data()
cdata.set('CONFIGURED_PYTHONPATH', '')
cdata.set('CONFIGURED_GI_TYPELIB_PATH', '')
cdata.set('CONFIGURED_LD_LIBRARY_PATH', '')
cdata.set('CONFIGURED_GST_PLUGIN_PATH', '')
cdata.set('CONFIGURED_PYTHONPATH',
run_command(geteenvvar, 'PYTHONPATH').stdout().strip())
cdata.set('CONFIGURED_GI_TYPELIB_PATH',
run_command(geteenvvar, 'GI_TYPELIB_PATH').stdout().strip())
cdata.set('CONFIGURED_LD_LIBRARY_PATH',
run_command(geteenvvar, 'LD_LIBRARY_PATH').stdout().strip())
cdata.set('CONFIGURED_GST_PLUGIN_PATH',
run_command(geteenvvar, 'GST_PLUGIN_PATH').stdout().strip())
cdata.set('CONFIGURED_GST_PLUGIN_SYSTEM_PATH',
run_command(geteenvvar, 'GST_PLUGIN_SYSTEM_PATH').stdout().strip())
cdata.set('LIBDIR', get_option('prefix') + '/' + get_option('libdir'))
cdata.set('DATADIR', get_option('prefix') + '/' + get_option('datadir'))
cdata.set('PACKAGE_NAME', 'Pitivi')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment