chiark / gitweb /
log: properly return -EINVAL from log_set_max_level_from_string()
[elogind.git] / configure.ac
index d410162462428cf398a9078c0f8c99819a266475..57bbb1d002807bf2bda36598a309046853bc4e3c 100644 (file)
@@ -20,7 +20,7 @@
 AC_PREREQ([2.64])
 
 AC_INIT([elogind],
-        [226.2],
+        [226.5],
         [https://github.com/elogind/elogind/issues],
         [elogind],
         [https://github.com/elogind/elogind])
@@ -113,10 +113,17 @@ fi
 # ------------------------------------------------------------------------------
 # Find running cgroup controller
 with_cgroupctrl=
-AS_IF(  [test -f /proc/self/cgroup],
-        [with_cgroupctrl=`grep "^1:name=" /proc/self/cgroup | cut -d ':' -f 2`])
+AS_IF(  [test -f /proc/self/cgroup], [
+        # If the init system is a cgroup controler, it will be position 1.
+        # Secondary controllers, like cgmanager, do not work.
+        with_cgroupctrl=`grep "^1:name=" /proc/self/cgroup | cut -d ':' -f 2`
+        AS_IF(  [test -z "$with_cgroupctrl"], [
+                # Try to be our own cgroup controller
+                with_cgroupctrl="name=elogind"
+        ])
+])
 AS_IF(  [test -z "$with_cgroupctrl"],
-        [with_cgroupctrl="name=elogind"])
+        AC_MSG_ERROR([No running cgroup controller found]))
 
 
 # ------------------------------------------------------------------------------