Skip to content

Commit 8b35169

Browse files
committed
build/meson: rename parserless builds to -Dparser
the original is -Ddisable_parser, invert that to make it less confusing
1 parent b61106e commit 8b35169

File tree

2 files changed

+4
-7
lines changed

2 files changed

+4
-7
lines changed

meson.build

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -122,12 +122,6 @@ if get_option('debug')
122122
language: 'c',
123123
)
124124
endif
125-
if get_option('disable_parser')
126-
add_project_arguments(
127-
['-DQJS_DISABLE_PARSER'],
128-
language: 'c',
129-
)
130-
endif
131125

132126
qjs_sys_deps = []
133127

@@ -160,6 +154,9 @@ qjs_c_args = ['-D_GNU_SOURCE']
160154
if host_system == 'windows'
161155
qjs_c_args += ['-DWIN32_LEAN_AND_MEAN', '-D_WIN32_WINNT=0x0601']
162156
endif
157+
158+
if not get_option('parser')
159+
qjs_c_args += ['-DQJS_DISABLE_PARSER']
163160
endif
164161

165162
qjs_libc_lib = static_library(

meson_options.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ option('examples', type: 'feature', description: 'build examples')
33
option('libc', type: 'boolean', value: false, description: 'build qjs standard library modules as part of the library')
44
option('cli_mimalloc', type: 'feature', value: 'disabled', description: 'build qjs cli with mimalloc')
55
option('docdir', type: 'string', description: 'documentation directory')
6-
option('disable_parser', type: 'boolean', value: false, description: 'Disable JS source code parser')
6+
option('parser', type: 'boolean', value: true, description: 'Enable JS source code parser')

0 commit comments

Comments
 (0)