build: use allowed over enabled
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`.
Change-Id: Ia7640469aa92a6fac3a11dd55a2d3b9eea0e637a
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/meson.build b/meson.build
index 0011fba..c8590f7 100644
--- a/meson.build
+++ b/meson.build
@@ -30,9 +30,9 @@
extra_unit_files = []
extra_scripts = []
-build_vpnor = get_option('vpnor').enabled()
-build_pldm = get_option('pldm').enabled()
-build_verify_signature = get_option('verify-signature').enabled()
+build_vpnor = get_option('vpnor').allowed()
+build_pldm = get_option('pldm').allowed()
+build_verify_signature = get_option('verify-signature').allowed()
if not cxx.has_header('CLI/CLI.hpp')
error('Could not find CLI.hpp')
@@ -240,7 +240,7 @@
if not get_option('tests').disabled()
oe_sdk = get_option('oe-sdk')
- if oe_sdk.enabled()
+ if oe_sdk.allowed()
# Setup OE SYSROOT
OECORE_TARGET_SYSROOT = run_command('sh', '-c', 'echo $OECORE_TARGET_SYSROOT').stdout().strip()
if OECORE_TARGET_SYSROOT == ''