summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorMatt Spinler <spinler@us.ibm.com>2017-06-02 12:15:59 -0500
committerMatt Spinler <spinler@us.ibm.com>2017-06-02 13:29:43 -0500
commit62b36bd882b12c7eea4e24e2438da05a719c8d97 (patch)
tree531cad5631214ac77bb82e8e2a9bc3c795d325cf /configure.ac
parenta33fbf51b5133d9e984aa9863b75896ee220ef1a (diff)
downloadphosphor-objmgr-62b36bd882b12c7eea4e24e2438da05a719c8d97.tar.gz
phosphor-objmgr-62b36bd882b12c7eea4e24e2438da05a719c8d97.zip
Add phosphor-unit-failure-monitor framework
This application is designed to be called from the OnFailure directive in a systemd unit file. It will stop or start another unit when the current unit fails enough times to exceed its restart policy so it isn't restarted again. To do this, this application will check the ActiveState property of the failing unit. When it is 'failed', the target unit will be started (or stopped). The failing unit name, the target unit name, and if the target should be stopped or started are all passed in on the command line. Change-Id: I93ecccaf1c091abddb769ddad8f43ecd9902210b Signed-off-by: Matt Spinler <spinler@us.ibm.com>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac7
1 files changed, 5 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index bd80240..10ea4af 100644
--- a/configure.ac
+++ b/configure.ac
@@ -5,6 +5,7 @@ AC_CONFIG_HEADERS([libmapper/config.h])
AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE([subdir-objects -Wall -Werror foreign dist-xz])
AM_SILENT_RULES([yes])
+AC_LANG([C++])
# Modify header template
AH_TOP([#pragma once])
@@ -12,6 +13,7 @@ AH_BOTTOM([#include "libmapper/workaround/systemd.h"])
# Checks for programs.
AC_PROG_CC
+AC_PROG_CXX
AM_PROG_AR
AC_PROG_INSTALL
AC_PROG_MAKE_SET
@@ -29,7 +31,8 @@ PKG_CHECK_MODULES([SYSTEMD], [libsystemd >= 221])
AC_CHECK_HEADER(systemd/sd-bus.h, ,[AC_MSG_ERROR([Could not find systemd/sd-bus.h...systemd development package required])])
# Checks for typedefs, structures, and compiler characteristics.
-AX_APPEND_COMPILE_FLAGS([-fpic -Wall -Werror], [CFLAGS])
+AX_CXX_COMPILE_STDCXX_14([noext])
+AX_APPEND_COMPILE_FLAGS([-fpic -Wall -Werror], [CFLAGS CXXFLAGS])
# Checks for library functions.
LT_INIT([disable-static shared])
@@ -72,5 +75,5 @@ AS_IF([test "x$enable_unpatched_systemd" == "xyes"],
)
# Create configured output
-AC_CONFIG_FILES([Makefile setup.py])
+AC_CONFIG_FILES([Makefile setup.py fail-monitor/Makefile])
AC_OUTPUT
OpenPOWER on IntegriCloud