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: I18a2a8f7607bda00fc7ebc8855884fe5f55d9e7d
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/meson.build b/meson.build
index 1c42caf..d9f410c 100644
--- a/meson.build
+++ b/meson.build
@@ -12,15 +12,15 @@
],
)
-if (get_option('libpeci').enabled())
+if (get_option('libpeci').allowed())
add_project_arguments('-DLIBPECI', language: 'cpp')
endif
-if (get_option('crashdump').enabled())
+if (get_option('crashdump').allowed())
add_project_arguments('-DCRASHDUMP', language: 'cpp')
endif
-if (get_option('send-to-logger').enabled())
+if (get_option('send-to-logger').allowed())
add_project_arguments('-DSEND_TO_LOGGING_SERVICE', language: 'cpp')
endif
@@ -60,7 +60,7 @@
phosphor_dbus_interfaces,
]
-if (get_option('libpeci').enabled())
+if (get_option('libpeci').allowed())
peci = dependency('libpeci')
deps += [
peci,