prevent going through systemd/upstart code, except on Linux

Fixes #809 (build issue on MacOSX)

NB: in case one day upstart is used on non-Linux platforms, this could
be relaxed to only skip systemd.