From ef2aa93b7a4c742ae74496566344fd71e411fa72 Mon Sep 17 00:00:00 2001 From: Andy Wingo Date: Sun, 23 Aug 2015 14:54:39 +0200 Subject: Handle suspend/hibernate/hybrid-suspend/shutdown/reboot directly * configure.ac: Get paths of halt and reboot. * Makefile.am (systemsleepdir, systemshutdowndir): New variables. Look in them for hooks to run. * src/login/logind-action.c: Inline the salient bits from systemd's system-sleep.c here. * src/login/logind-dbus.c (execute_shutdown_or_sleep): Call our own shutdown_or_sleep helper instead of invoking a systemd method. * src/login/logind.h: Declare shutdown_or_sleep. --- configure.ac | 2 ++ 1 file changed, 2 insertions(+) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index cfe7c8c61f..734487f757 100644 --- a/configure.ac +++ b/configure.ac @@ -87,6 +87,8 @@ AC_PROG_CC_C99 AC_PATH_PROG([M4], [m4]) AC_PATH_PROG([XSLTPROC], [xsltproc]) +AC_PATH_PROG([HALT], [halt], [halt]) +AC_PATH_PROG([REBOOT], [reboot], [reboot]) AC_PATH_PROG([KEXEC], [kexec], [/usr/sbin/kexec], [$PATH:/usr/sbin:/sbin]) AS_IF([! ln --relative --help > /dev/null 2>&1], [AC_MSG_ERROR([*** ln doesn't support --relative ***])]) -- cgit v1.2.3-54-g00ecf