build: use allowed over enabled or not-disabled
Meson feature options are typically in a tri-state of enabled, disabled,
or auto. The enabled and disabled functions on an option (from
`get_option`) no longer return true for auto features. Instead, the
expectation is to use `allowed()` which is true for both enabled and
auto.
Switch all uses of `enabled` to `allowed`.
Switch all uses of `not disabled` to `allowed`.
Change-Id: Ia942d083f4ddab68acbbb40699ea1971e09db771
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/bmc/firmware-handler/meson.build b/bmc/firmware-handler/meson.build
index 14624d8..2d935a3 100644
--- a/bmc/firmware-handler/meson.build
+++ b/bmc/firmware-handler/meson.build
@@ -64,17 +64,17 @@
'lpc_handler.cpp']
if (get_option('lpc-type') == 'aspeed-lpc' or
- not get_option('tests').disabled())
+ get_option('tests').allowed())
firmware_source += 'lpc_aspeed.cpp'
endif
if (get_option('lpc-type') == 'nuvoton-lpc' or
- not get_option('tests').disabled())
+ get_option('tests').allowed())
firmware_source += 'lpc_nuvoton.cpp'
endif
if (get_option('p2a-type') == 'aspeed-p2a' or
- not get_option('tests').disabled())
+ get_option('tests').allowed())
firmware_source += 'pci_handler.cpp'
endif
@@ -121,6 +121,6 @@
install: true,
install_dir: get_option('libdir') / 'blob-ipmid')
-if not get_option('tests').disabled()
+if get_option('tests').allowed()
subdir('test')
endif