mirror of
https://github.com/troglobit/finit.git
synced 2026-10-01 21:42:40 +07:00
Finit had no way to answer the question every service manager gets asked: what is running, and change it. D-Bus is how the rest of userspace asks, but linking libdbus, sd-bus or GIO into PID 1 buys a dependency, an allocator and a main loop we do not control. So libink: the wire format, an object tree, and a bus of Finit's own at /run/finit/bus, gated like INIT_SOCKET. It speaks the standard org.freedesktop.DBus, .Peer, .Introspectable interfaces, and Finit's own Manager1, Service1 and Cond1 on top. Methods that change something are marked privileged and answered only for a caller the kernel vouched for, via SO_PEERCRED. Server and client both, since initctl is the first thing that needs to talk to it, and its Start/Stop/Restart/Reload now go over the bus rather than the legacy socket. Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
35 lines
687 B
Bash
Executable File
35 lines
687 B
Bash
Executable File
#!/bin/sh
|
|
# Run test suite with the correct configure params
|
|
run_make=1
|
|
jobs=17
|
|
|
|
while [ $# -gt 0 ]; do
|
|
case "$1" in
|
|
-n|--no-make)
|
|
run_make=0
|
|
;;
|
|
-j|--jobs)
|
|
shift
|
|
jobs="$1"
|
|
;;
|
|
*)
|
|
echo "Usage: $0 [--no-make] [-j N]"
|
|
exit 1
|
|
;;
|
|
esac
|
|
shift
|
|
done
|
|
|
|
if [ "$run_make" -eq 1 ]; then
|
|
make distclean
|
|
fi
|
|
|
|
./configure --prefix=/usr --exec-prefix= --sysconfdir=/etc --localstatedir=/var \
|
|
--enable-dbus --enable-x11-common-plugin --enable-testserv-plugin \
|
|
--with-watchdog --with-keventd --with-libsystemd \
|
|
CFLAGS='-fsanitize=address -ggdb'
|
|
|
|
if [ "$run_make" -eq 1 ]; then
|
|
make -j"$jobs" clean check
|
|
fi
|