[systemd-devel] gentoo openrc

Reno Reckling e-systemd at wthack.de
Wed Aug 4 07:27:39 PDT 2010


Hi.

I am currently working on a way to extract the dependencies from openrc
init scripts to be able to support the automatic init.d fallbacks in gentoo.

There are a few problems with that, as gentoo don't provide any LSB
headers and uses a different kind of init.d scripts. This makes it
necessary to actually execute the depend function of these scripts
within a bash and provide a set of functions to extract the deps.

The extracting and bash scripting part was fairly easy as it mainly
includes a 100 lines bash script to parse the init script.

The more complex part is integrating the functionality into systemd.

Imho it would be necessary to synchronously start a bash on every
attempt to extract the dependency, read the stdout and parse it.

My questions are:
Is it safe to spawn a bash process to do the extraction and waitpid(pid)
until it returns? Or do i freeze systemd by doing this, because bash
depends on systemds functionality?

Regards,
Reno Reckling


More information about the systemd-devel mailing list