Add LastStateChangeTime to chassis manager

This property is set to the timestamp of the last time
the chassis power state changed.  It is persisted
so it survives reboots.

Resolves openbmc/openbmc#3300

Tested:  Various incantations of power cycling, reboots,
         and AC pulls.

Change-Id: I19f244e0490bc9b921454e393989a9cbd283e2dd
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
diff --git a/configure.ac b/configure.ac
index 838aaf2..f1d3a2f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -66,6 +66,12 @@
 AC_DEFINE_UNQUOTED([POH_COUNTER_PERSIST_PATH], ["$POH_COUNTER_PERSIST_PATH"], \
     [Path of file for storing POH counter.])
 
+AC_ARG_VAR(CHASSIS_STATE_CHANGE_PERSIST_PATH, [Path of file for storing the state change time.])
+AS_IF([test "x$CHASSIS_STATE_CHANGE_PERSIST_PATH" == "x"], \
+    [CHASSIS_STATE_CHANGE_PERSIST_PATH="/var/lib/phosphor-state-manager/chassisStateChangeTime"])
+AC_DEFINE_UNQUOTED([CHASSIS_STATE_CHANGE_PERSIST_PATH], ["$CHASSIS_STATE_CHANGE_PERSIST_PATH"], \
+    [Path of file for storing the state change time.])
+
 AC_ARG_VAR(BOOT_COUNT_MAX_ALLOWED, [The maximum allowed reboot count])
 AS_IF([test "x$BOOT_COUNT_MAX_ALLOWED" == "x"], [BOOT_COUNT_MAX_ALLOWED=3])
 AC_DEFINE_UNQUOTED([BOOT_COUNT_MAX_ALLOWED], [$BOOT_COUNT_MAX_ALLOWED], [The maximum allowed reboot count])