Skip to content

Commit 740d926

Browse files
committed
docs: add meson option to use the unsafe loader
1 parent 9de07ff commit 740d926

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

docs/meson.build

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ docs_gen = custom_target(
1717

1818
sitemap = files('sitemap.txt')
1919

20+
yaml_loader = get_option('unsafe_yaml') ? 'fastyaml' : 'yaml'
2021
genrefman = find_program('./genrefman.py')
2122
refman_binary = custom_target(
2223
'gen_refman_bin',
@@ -25,7 +26,7 @@ refman_binary = custom_target(
2526
depfile: 'reman_dep.d',
2627
command: [
2728
genrefman,
28-
'-l', 'yaml',
29+
'-l', yaml_loader,
2930
'-g', 'pickle',
3031
'-o', '@OUTPUT@',
3132
'--depfile', '@DEPFILE@',

docs/meson_options.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
option('unsafe_yaml', type: 'boolean', value: false,
2+
description: 'disable safety checks and use a faster, but less correct YAML loader')

0 commit comments

Comments
 (0)