meson: add switch to disable docs

the make build system can do this too.

Change-Id: I8c07d159cab54a8749c50dc33615f60bd251a86d
This commit is contained in:
eldritch horrors
2024-04-01 20:15:28 +00:00
parent efbf5c81bb
commit ed2bb919e7
2 changed files with 9 additions and 1 deletions
+5 -1
View File
@@ -71,6 +71,7 @@ foreach optname : path_opts
endif
endforeach
enable_docs = get_option('enable-docs')
enable_tests = get_option('enable-tests')
@@ -357,7 +358,10 @@ endif
subdir('src')
subdir('scripts')
subdir('misc')
subdir('doc/manual')
if enable_docs
subdir('doc/manual')
endif
if enable_tests
subdir('tests/unit')
+4
View File
@@ -46,3 +46,7 @@ option('state-dir', type : 'string', value : '/nix/var',
option('log-dir', type : 'string', value : '/nix/var/log',
description : 'path to store logs in for Nix',
)
option('enable-docs', type : 'boolean', value : true,
description : 'whether to build documentation',
)