-
-
Notifications
You must be signed in to change notification settings - Fork 90
Expand file tree
/
Copy pathmeson.build
More file actions
77 lines (68 loc) · 2.05 KB
/
meson.build
File metadata and controls
77 lines (68 loc) · 2.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
bin_conf = configuration_data()
bin_conf.set('GJS', find_program('gjs').full_path())
bin_conf.set('version', meson.project_version() + version_suffix)
bin_conf.set('app_id', app_id)
bin_conf.set('prefix', prefix)
bin_conf.set('libdir', get_option('prefix') / get_option('libdir'))
bin_conf.set('datadir', datadir)
bin_conf.set('pkgdatadir', pkgdatadir)
bin_conf.set('sourcedir', meson.project_source_root())
bin_conf.set('command', 'SHELL=/bin/sh script --flush --quiet --return $XDG_RUNTIME_DIR/$FLATPAK_ID/typescript --command "' + app_id + ' $@"')
blueprint_compiler = find_program(
'/app/bin/blueprint-compiler',
)
meson.add_install_script('../build-aux/library.js', pkgdatadir)
subdir('langs/javascript')
subdir('langs/rust/template')
subdir('langs/typescript')
subdir('langs/vala')
configure_file(
input: 'bin.js',
output: app_id,
configuration: bin_conf,
install: true,
install_dir: get_option('bindir')
)
configure_file(
input: 'workbench',
output: 'workbench',
configuration: bin_conf,
install: true,
install_dir: get_option('bindir')
)
clibin_conf = configuration_data()
clibin_conf.merge_from(bin_conf)
clibin_conf.set('command', app_id + '.cli "$@"')
configure_file(
input: 'workbench',
output: 'workbench-cli',
configuration: clibin_conf,
install: true,
install_dir: get_option('bindir')
)
install_data('langs/javascript/biome.json', install_dir: pkgdatadir)
install_data('project-readme.md', install_dir: pkgdatadir)
subdir('libworkbench')
subdir('Previewer')
subdir('langs/python')
subdir('langs/css')
gjspack = find_program('../troll/gjspack/bin/gjspack')
custom_target('workbench',
input: ['main.js'],
output: app_id + '.src.gresource',
command: [
gjspack,
'--appid=' + app_id,
'--prefix', '/re/sonny/Workbench',
'--project-root', meson.project_source_root(),
'--resource-root', meson.project_source_root() / 'src',
'--blueprint-compiler', blueprint_compiler,
'--no-executable',
'@INPUT0@',
'@OUTDIR@',
],
install: true,
install_dir: pkgdatadir,
build_always_stale: true,
)
subdir('cli')