@ariadne honestly the most realistic thing (IMHO) to do is probably to write (or derive from existing systemd code) a bunch of (dependent) libraries that reimplement parts of systemd. Unit file parser. Constraints manager. Service starter. Hotplug handler.

Some of the design decisions make things difficult to untangle, but a lot of the underlying building blocks are OK. They're just tied together into an undebuggable opinionated monolith…