Skip to content

Commit 017cf87

Browse files
oleavrhsorbo
andcommitted
[build] Add Meson build system
Co-authored-by: Håvard Sørbø <[email protected]>
1 parent 95c460f commit 017cf87

File tree

27 files changed

+2739
-0
lines changed

27 files changed

+2739
-0
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@
4848
/perf.data.old
4949
/src/inspector/build/closure-compiler
5050
/src/inspector/build/closure-compiler.tar.gz
51+
/subprojects/zlib
5152
/test/benchmarks/data
5253
/test/fuzzer/wasm_corpus
5354
/test/fuzzer/wasm_corpus.tar.gz

include/cppgc/internal/meson.build

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
cppgc_internal_headers = [
2+
'write-barrier.h',
3+
'gc-info.h',
4+
'persistent-node.h',
5+
'name-trait.h',
6+
'pointer-policies.h',
7+
'logging.h',
8+
'api-constants.h',
9+
'atomic-entry-flag.h',
10+
'member-storage.h',
11+
'compiler-specific.h',
12+
'finalizer-trait.h',
13+
'caged-heap-local-data.h',
14+
'base-page-handle.h',
15+
'caged-heap.h',
16+
]
17+
18+
install_headers(cppgc_internal_headers, subdir: install_header_subdir / 'cppgc' / 'internal')

include/cppgc/meson.build

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
cppgc_headers = [
2+
'testing.h',
3+
'cross-thread-persistent.h',
4+
'name-provider.h',
5+
'persistent.h',
6+
'prefinalizer.h',
7+
'allocation.h',
8+
'process-heap-statistics.h',
9+
'ephemeron-pair.h',
10+
'custom-space.h',
11+
'type-traits.h',
12+
'heap-state.h',
13+
'default-platform.h',
14+
'heap-statistics.h',
15+
'heap-handle.h',
16+
'visitor.h',
17+
'garbage-collected.h',
18+
'trace-trait.h',
19+
'object-size-trait.h',
20+
'common.h',
21+
'heap-consistency.h',
22+
'macros.h',
23+
'heap.h',
24+
'sentinel-pointer.h',
25+
'liveness-broker.h',
26+
'member.h',
27+
'platform.h',
28+
'source-location.h',
29+
'explicit-management.h',
30+
]
31+
32+
install_headers(cppgc_headers, subdir: install_header_subdir / 'cppgc')
33+
34+
subdir('internal')

include/libplatform/meson.build

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
libplatform_headers = [
2+
'libplatform-export.h',
3+
'libplatform.h',
4+
'v8-tracing.h',
5+
]
6+
7+
install_headers(libplatform_headers, subdir: install_header_subdir / 'libplatform')

include/meson.build

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
install_header_subdir = 'v8-' + api_version
2+
3+
v8_inspector_js_protocol = files('js_protocol.pdl')
4+
5+
v8_headers = [
6+
'v8-array-buffer.h',
7+
'v8-callbacks.h',
8+
'v8-container.h',
9+
'v8-context.h',
10+
'v8-cppgc.h',
11+
'v8-data.h',
12+
'v8-date.h',
13+
'v8-debug.h',
14+
'v8-embedder-heap.h',
15+
'v8-embedder-state-scope.h',
16+
'v8-exception.h',
17+
'v8-extension.h',
18+
'v8-external.h',
19+
'v8-fast-api-calls.h',
20+
'v8-forward.h',
21+
'v8-function-callback.h',
22+
'v8-function.h',
23+
'v8-initialization.h',
24+
'v8-inspector-protocol.h',
25+
'v8-inspector.h',
26+
'v8-internal.h',
27+
'v8-isolate.h',
28+
'v8-json.h',
29+
'v8-local-handle.h',
30+
'v8-locker.h',
31+
'v8-maybe.h',
32+
'v8-memory-span.h',
33+
'v8-message.h',
34+
'v8-metrics.h',
35+
'v8-microtask-queue.h',
36+
'v8-microtask.h',
37+
'v8-object.h',
38+
'v8-persistent-handle.h',
39+
'v8-platform.h',
40+
'v8-primitive-object.h',
41+
'v8-primitive.h',
42+
'v8-profiler.h',
43+
'v8-promise.h',
44+
'v8-proxy.h',
45+
'v8-regexp.h',
46+
'v8-script.h',
47+
'v8-snapshot.h',
48+
'v8-statistics.h',
49+
'v8-template.h',
50+
'v8-traced-handle.h',
51+
'v8-typed-array.h',
52+
'v8-unwinder-state.h',
53+
'v8-unwinder.h',
54+
'v8-util.h',
55+
'v8-value-serializer-version.h',
56+
'v8-value-serializer.h',
57+
'v8-value.h',
58+
'v8-version-string.h',
59+
'v8-version.h',
60+
'v8-wasm-trap-handler-posix.h',
61+
'v8-wasm-trap-handler-win.h',
62+
'v8-wasm.h',
63+
'v8-weak-callback-info.h',
64+
'v8.h',
65+
'v8config.h',
66+
]
67+
68+
install_headers(v8_headers, subdir: install_header_subdir)
69+
70+
command = [
71+
gen_v8_gn,
72+
'-o', '@OUTPUT@',
73+
]
74+
foreach d : enabled_external_defines
75+
command += ['-p', d]
76+
endforeach
77+
foreach d : disabled_external_defines
78+
command += ['-n', d]
79+
endforeach
80+
v8_gn_h = custom_target('v8-gn-header',
81+
output: 'v8-gn.h',
82+
command: command,
83+
install: true,
84+
install_dir: get_option('includedir') / install_header_subdir,
85+
)
86+
87+
subdir('cppgc')
88+
subdir('libplatform')

0 commit comments

Comments
 (0)