extensionPrefs: Move data/sources into subdirectories

As we will eventually move the code to a subproject, start arranging
it like a top-level srcdir.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1081
This commit is contained in:
Florian Müllner 2020-03-08 14:50:59 +01:00 committed by Florian Müllner
parent e572d5d08c
commit c8a4a91681
15 changed files with 58 additions and 47 deletions

View File

@ -0,0 +1,7 @@
gnome.compile_resources(
app_id + '.data',
app_id + '.data.gresource.xml',
gresource_bundle: true,
install: true,
install_dir: pkgdatadir
)

View File

@ -0,0 +1,35 @@
launcherconf = configuration_data()
launcherconf.set('app_id', app_id)
launcherconf.set('PACKAGE_NAME', meson.project_name())
launcherconf.set('PACKAGE_VERSION', meson.project_version())
launcherconf.set('prefix', prefix)
launcherconf.set('libdir', libdir)
launcherconf.set('pkgdatadir', pkgdatadir)
launcherconf.set('gjs', gjs.path())
configure_file(
input: prgname + '.in',
output: prgname,
configuration: launcherconf,
install_dir: bindir,
install_mode: 'rwxr-xr-x',
)
configure_file(
input: app_id + '.in',
output: app_id,
configuration: launcherconf,
install_dir: pkgdatadir,
)
config_dir = '@0@/../..'.format(meson.current_build_dir())
gnome.compile_resources(
app_id + '.src',
app_id + '.src.gresource.xml',
dependencies: [config_js],
source_dir: ['.', '../..', config_dir],
gresource_bundle: true,
install: true,
install_dir: pkgdatadir
)

View File

@ -0,0 +1,2 @@
/* The version of this package */
var PACKAGE_VERSION = '@PACKAGE_VERSION@';

View File

@ -0,0 +1,8 @@
jsconf = configuration_data()
jsconf.set('PACKAGE_VERSION', meson.project_version())
extensions_config = configure_file(
input: 'config.js.in',
output: 'config.js',
configuration: jsconf
)

View File

@ -1,46 +1,5 @@
app_id = 'org.gnome.Extensions'
prgname = 'gnome-shell-extension-prefs'
launcherconf = configuration_data()
launcherconf.set('app_id', app_id)
launcherconf.set('PACKAGE_NAME', meson.project_name())
launcherconf.set('PACKAGE_VERSION', meson.project_version())
launcherconf.set('prefix', prefix)
launcherconf.set('libdir', libdir)
launcherconf.set('pkgdatadir', pkgdatadir)
launcherconf.set('gjs', gjs.path())
configure_file(
input: prgname + '.in',
output: prgname,
configuration: launcherconf,
install_dir: bindir,
install_mode: 'rwxr-xr-x',
)
configure_file(
input: app_id + '.in',
output: app_id,
configuration: launcherconf,
install_dir: pkgdatadir,
)
config_dir = '@0@/..'.format(meson.current_build_dir())
gnome.compile_resources(
app_id + '.src',
app_id + '.src.gresource.xml',
dependencies: [config_js],
source_dir: ['.', '..', config_dir],
gresource_bundle: true,
install: true,
install_dir: pkgdatadir
)
gnome.compile_resources(
app_id + '.data',
app_id + '.data.gresource.xml',
gresource_bundle: true,
install: true,
install_dir: pkgdatadir
)
subdir('data')
subdir('js')

View File

@ -17,7 +17,7 @@ rules:
overrides:
- files: js/**
excludedFiles:
- js/extensionPrefs/*
- js/extensionPrefs/**
- js/portalHelper/*
globals:
global: readonly

View File

@ -5,9 +5,9 @@ data/org.gnome.Extensions.desktop.in.in
data/org.gnome.Shell.desktop.in.in
data/org.gnome.shell.gschema.xml.in
data/org.gnome.Shell.PortalHelper.desktop.in.in
js/extensionPrefs/main.js
js/extensionPrefs/ui/extension-row.ui
js/extensionPrefs/ui/extensions-window.ui
js/extensionPrefs/js/main.js
js/extensionPrefs/data/ui/extension-row.ui
js/extensionPrefs/data/ui/extensions-window.ui
js/gdm/authPrompt.js
js/gdm/loginDialog.js
js/gdm/util.js