extensions-tool: Move to a subproject
The gnome-extensions tool code is really independent from the rest of the code base, and could be used either as part of the gnome-shell build or as stand-alone project (for example for the extension-ci docker image). We can actually support both cases by moving the code to a subproject. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/877
This commit is contained in:
parent
26dc2a439d
commit
51518d4d96
21
meson.build
21
meson.build
@ -132,20 +132,9 @@ else
|
|||||||
have_systemd = false
|
have_systemd = false
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if get_option('extensions_tool')
|
|
||||||
autoar_dep = dependency('gnome-autoar-0')
|
|
||||||
json_dep = dependency('json-glib-1.0')
|
|
||||||
endif
|
|
||||||
|
|
||||||
bash_completion = dependency('bash-completion', required: false)
|
|
||||||
|
|
||||||
if get_option('man')
|
if get_option('man')
|
||||||
xsltproc = find_program('xsltproc')
|
xsltproc = find_program('xsltproc')
|
||||||
|
|
||||||
if get_option('extensions_tool')
|
|
||||||
a2x = find_program('a2x')
|
|
||||||
endif
|
|
||||||
|
|
||||||
subdir('man')
|
subdir('man')
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@ -254,6 +243,16 @@ libgvc = subproject('gvc',
|
|||||||
)
|
)
|
||||||
libgvc_gir = libgvc.get_variable('libgvc_gir')
|
libgvc_gir = libgvc.get_variable('libgvc_gir')
|
||||||
|
|
||||||
|
if get_option('extensions_tool')
|
||||||
|
subproject('extensions-tool',
|
||||||
|
default_options: [
|
||||||
|
'man=@0@'.format(get_option('man')),
|
||||||
|
'package_name=@0@'.format(meson.project_name()),
|
||||||
|
]
|
||||||
|
)
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
po_dir = join_paths(meson.current_source_dir(), 'po')
|
po_dir = join_paths(meson.current_source_dir(), 'po')
|
||||||
|
|
||||||
subdir('js')
|
subdir('js')
|
||||||
|
@ -72,17 +72,6 @@ js/ui/windowAttentionHandler.js
|
|||||||
js/ui/windowManager.js
|
js/ui/windowManager.js
|
||||||
js/ui/windowMenu.js
|
js/ui/windowMenu.js
|
||||||
src/calendar-server/evolution-calendar.desktop.in
|
src/calendar-server/evolution-calendar.desktop.in
|
||||||
src/extensions-tool/command-create.c
|
|
||||||
src/extensions-tool/command-disable.c
|
|
||||||
src/extensions-tool/command-enable.c
|
|
||||||
src/extensions-tool/command-info.c
|
|
||||||
src/extensions-tool/command-install.c
|
|
||||||
src/extensions-tool/command-list.c
|
|
||||||
src/extensions-tool/command-pack.c
|
|
||||||
src/extensions-tool/command-prefs.c
|
|
||||||
src/extensions-tool/command-reset.c
|
|
||||||
src/extensions-tool/command-uninstall.c
|
|
||||||
src/extensions-tool/main.c
|
|
||||||
src/main.c
|
src/main.c
|
||||||
src/shell-app.c
|
src/shell-app.c
|
||||||
src/shell-app-system.c
|
src/shell-app-system.c
|
||||||
@ -90,5 +79,16 @@ src/shell-global.c
|
|||||||
src/shell-keyring-prompt.c
|
src/shell-keyring-prompt.c
|
||||||
src/shell-polkit-authentication-agent.c
|
src/shell-polkit-authentication-agent.c
|
||||||
src/shell-util.c
|
src/shell-util.c
|
||||||
|
subprojects/extensions-tool/src/command-create.c
|
||||||
|
subprojects/extensions-tool/src/command-disable.c
|
||||||
|
subprojects/extensions-tool/src/command-enable.c
|
||||||
|
subprojects/extensions-tool/src/command-info.c
|
||||||
|
subprojects/extensions-tool/src/command-install.c
|
||||||
|
subprojects/extensions-tool/src/command-list.c
|
||||||
|
subprojects/extensions-tool/src/command-pack.c
|
||||||
|
subprojects/extensions-tool/src/command-prefs.c
|
||||||
|
subprojects/extensions-tool/src/command-reset.c
|
||||||
|
subprojects/extensions-tool/src/command-uninstall.c
|
||||||
|
subprojects/extensions-tool/src/main.c
|
||||||
# Please do not remove this file from POTFILES.in. Run "git submodule init && git submodule update" to get it.
|
# Please do not remove this file from POTFILES.in. Run "git submodule init && git submodule update" to get it.
|
||||||
subprojects/gvc/gvc-mixer-control.c
|
subprojects/gvc/gvc-mixer-control.c
|
||||||
|
@ -6,10 +6,6 @@ subdir('hotplug-sniffer')
|
|||||||
subdir('st')
|
subdir('st')
|
||||||
subdir('tray')
|
subdir('tray')
|
||||||
|
|
||||||
if get_option('extensions_tool')
|
|
||||||
subdir('extensions-tool')
|
|
||||||
endif
|
|
||||||
|
|
||||||
script_data = configuration_data()
|
script_data = configuration_data()
|
||||||
script_data.set('bindir', bindir)
|
script_data.set('bindir', bindir)
|
||||||
script_data.set('datadir', datadir)
|
script_data.set('datadir', datadir)
|
||||||
|
42
subprojects/extensions-tool/meson.build
Normal file
42
subprojects/extensions-tool/meson.build
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
project('gnome-extensions-tool', 'c',
|
||||||
|
version: '3.35.1',
|
||||||
|
meson_version: '>= 0.47.0',
|
||||||
|
license: 'GPLv2+'
|
||||||
|
)
|
||||||
|
|
||||||
|
gio_req = '>= 2.56.0'
|
||||||
|
|
||||||
|
gnome = import('gnome')
|
||||||
|
i18n = import('i18n')
|
||||||
|
|
||||||
|
package_name = get_option('package_name')
|
||||||
|
prefix = get_option('prefix')
|
||||||
|
|
||||||
|
bindir = join_paths(prefix, get_option('bindir'))
|
||||||
|
datadir = join_paths(prefix, get_option('datadir'))
|
||||||
|
mandir = join_paths(prefix, get_option('mandir'))
|
||||||
|
|
||||||
|
localedir = join_paths(datadir, 'locale')
|
||||||
|
|
||||||
|
gio_dep = dependency('gio-2.0', version: gio_req)
|
||||||
|
gio_unix_dep = dependency('gio-unix-2.0', version: gio_req)
|
||||||
|
autoar_dep = dependency('gnome-autoar-0')
|
||||||
|
json_dep = dependency('json-glib-1.0')
|
||||||
|
|
||||||
|
cc = meson.get_compiler('c')
|
||||||
|
|
||||||
|
bash_completion = dependency('bash-completion', required: false)
|
||||||
|
|
||||||
|
subdir('src')
|
||||||
|
|
||||||
|
if bash_completion.found()
|
||||||
|
install_data('completion/bash/gnome-extensions',
|
||||||
|
install_dir: bash_completion.get_pkgconfig_variable('completionsdir')
|
||||||
|
)
|
||||||
|
endif
|
||||||
|
|
||||||
|
if get_option('man')
|
||||||
|
a2x = find_program('a2x')
|
||||||
|
|
||||||
|
subdir('man')
|
||||||
|
endif
|
11
subprojects/extensions-tool/meson_options.txt
Normal file
11
subprojects/extensions-tool/meson_options.txt
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
option('man',
|
||||||
|
type: 'boolean',
|
||||||
|
value: true,
|
||||||
|
description: 'Generate man pages'
|
||||||
|
)
|
||||||
|
|
||||||
|
option('package_name',
|
||||||
|
type: 'string',
|
||||||
|
value: 'gnome-extensions-tool',
|
||||||
|
description: 'The gettext domain name'
|
||||||
|
)
|
@ -1,5 +1,5 @@
|
|||||||
config_h = configuration_data()
|
config_h = configuration_data()
|
||||||
config_h.set_quoted('GETTEXT_PACKAGE', meson.project_name())
|
config_h.set_quoted('GETTEXT_PACKAGE', package_name)
|
||||||
config_h.set_quoted('VERSION', meson.project_version())
|
config_h.set_quoted('VERSION', meson.project_version())
|
||||||
config_h.set_quoted('LOCALEDIR', localedir)
|
config_h.set_quoted('LOCALEDIR', localedir)
|
||||||
config_h.set('HAVE_BIND_TEXTDOMAIN_CODESET', cc.has_function('bind_textdomain_codeset'))
|
config_h.set('HAVE_BIND_TEXTDOMAIN_CODESET', cc.has_function('bind_textdomain_codeset'))
|
||||||
@ -32,13 +32,3 @@ executable('gnome-extensions',
|
|||||||
dependencies: [gio_dep, gio_unix_dep, autoar_dep, json_dep],
|
dependencies: [gio_dep, gio_unix_dep, autoar_dep, json_dep],
|
||||||
install: true
|
install: true
|
||||||
)
|
)
|
||||||
|
|
||||||
if bash_completion.found()
|
|
||||||
install_data('completion/bash/gnome-extensions',
|
|
||||||
install_dir: bash_completion.get_pkgconfig_variable('completionsdir')
|
|
||||||
)
|
|
||||||
endif
|
|
||||||
|
|
||||||
if get_option('man')
|
|
||||||
subdir('man')
|
|
||||||
endif
|
|
Loading…
Reference in New Issue
Block a user