mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-06-16 13:00:41 +00:00
Add initial meson devenv support
There is still a few things missing compared to gst-env.py, but it is functional. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1162>
This commit is contained in:
parent
7cb2dff830
commit
14115b714f
12
meson.build
12
meson.build
|
@ -12,6 +12,7 @@ gst_version = '>= @0@'.format(meson.project_version())
|
||||||
build_system = build_machine.system()
|
build_system = build_machine.system()
|
||||||
cc = meson.get_compiler('c')
|
cc = meson.get_compiler('c')
|
||||||
|
|
||||||
|
fs = import('fs')
|
||||||
gnome = import('gnome')
|
gnome = import('gnome')
|
||||||
pkgconfig = import('pkgconfig')
|
pkgconfig = import('pkgconfig')
|
||||||
python3 = import('python').find_installation()
|
python3 = import('python').find_installation()
|
||||||
|
@ -219,13 +220,24 @@ if documented_projects != ''
|
||||||
endif
|
endif
|
||||||
|
|
||||||
all_plugins_paths = []
|
all_plugins_paths = []
|
||||||
|
all_plugins_dirs = []
|
||||||
foreach plugin: all_plugins
|
foreach plugin: all_plugins
|
||||||
all_plugins_paths += plugin.full_path()
|
all_plugins_paths += plugin.full_path()
|
||||||
|
all_plugins_dirs += fs.parent(plugin.full_path())
|
||||||
endforeach
|
endforeach
|
||||||
# Work around meson bug: https://github.com/mesonbuild/meson/pull/6770
|
# Work around meson bug: https://github.com/mesonbuild/meson/pull/6770
|
||||||
pathsep = host_machine.system() == 'windows' ? ';' : ':'
|
pathsep = host_machine.system() == 'windows' ? ';' : ':'
|
||||||
all_plugins_paths = pathsep.join(all_plugins_paths)
|
all_plugins_paths = pathsep.join(all_plugins_paths)
|
||||||
|
|
||||||
|
devenv = environment()
|
||||||
|
devenv.set('GST_PLUGIN_PATH', all_plugins_dirs)
|
||||||
|
devenv.set('CURRENT_GST', meson.current_source_dir())
|
||||||
|
devenv.set('GST_VERSION', meson.project_version())
|
||||||
|
devenv.set('GST_ENV', 'gst-' + meson.project_version())
|
||||||
|
devenv.set('GST_REGISTRY', meson.current_build_dir() / 'registry.dat')
|
||||||
|
devenv.set('GST_PLUGIN_SYSTEM_PATH', '')
|
||||||
|
meson.add_devenv(devenv)
|
||||||
|
|
||||||
generate_plugins_paths = find_program('scripts/generate_plugins_path.py')
|
generate_plugins_paths = find_program('scripts/generate_plugins_path.py')
|
||||||
configure_file(
|
configure_file(
|
||||||
output : 'GstPluginsPath.json',
|
output : 'GstPluginsPath.json',
|
||||||
|
|
Loading…
Reference in a new issue