Allow disabling use of u-boot environment
Not all systems have a writable u-boot environment, so add an autoconf
argument to disable the use of it.
Signed-off-by: Benjamin Fair <benjaminfair@google.com>
Change-Id: I04074c28f81214dd59a974440e51be0da50c5d63
diff --git a/configure.ac b/configure.ac
index 12d6caa..ee783e2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -73,6 +73,12 @@
)
AC_SUBST([dbuspolicydir], [$with_dbuspolicydir])
+AC_ARG_WITH([uboot-env],
+ AS_HELP_STRING([--without-uboot-env], [Disable features that require a u-boot environment]))
+AS_IF([test "x$with_uboot_env" != "xno"], [
+ AC_DEFINE([HAVE_UBOOT_ENV], [1], [u-boot environment is available])
+])
+
# Check/set gtest specific functions.
AX_PTHREAD([GTEST_CPPFLAGS="-DGTEST_HAS_PTHREAD=1"],[GTEST_CPPFLAGS="-GTEST_HAS_PTHREAD=0"])
AC_SUBST(GTEST_CPPFLAGS)