Skip to content

Commit

Permalink
Build: configure: run initctl as an upstart detection fallback
Browse files Browse the repository at this point in the history
Understandably, chroot-based build systems do not reliably expose system
message bus, so additional fallback to handle this corner case is added.
The DBus method is kept primary, also to have possible DBus API changes
checked, should the version of the Upstart interface at the target system
differ from what pacemaker uses.
  • Loading branch information
jnpkrn committed Sep 29, 2016
1 parent 416f98a commit 2167bc7
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -1232,10 +1232,11 @@ if test "x${enable_upstart}" != xno; then
# ret is intentionally unenquoted so as to normalize whitespace
ret=$(echo ${ret} | cut -d' ' -f2-)
AC_MSG_RESULT([${ret}])
if test "x${ret}" = xborked; then
enable_upstart=no
else
if test "x${ret}" != xborked \
|| initctl --version 2>/dev/null | grep -q upstart; then
enable_upstart=yes
else
enable_upstart=no
fi
fi
fi
Expand Down

0 comments on commit 2167bc7

Please sign in to comment.