1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-29 13:41:00 +01:00

meson: Add option for controlling PCH

In practice it turns out that turning off PCH is pretty
useful when debugging incorrect includes. I didn't want
to add this option initially because of the sheer amount
of copy-pasta that meson requires. But considering that
this is useful and the cost of copying the option a single
time is not too high this seems acceptable.
This commit is contained in:
Sergei Zimmerman 2025-10-08 02:51:19 +03:00
parent fb117e0cac
commit c105846646
No known key found for this signature in database
11 changed files with 106 additions and 2 deletions

View file

@ -27,3 +27,13 @@ option(
value : false,
description : 'Build benchmarks (requires gbenchmark)',
)
# Emulating 'auto' options, since we don't want auto_features to affect this
# and there's no other way of conditionally defaulting the value.
option(
'pch',
type : 'combo',
choices : [ 'auto', 'enabled', 'disabled' ],
value : 'auto',
description : 'Use C++ Precompiled Headers to speed up compilation',
)