The systemd-love overlay is aiming at making openrc and systemd to coexist on the same system by moving the init system detection from build time to runtime. In the systemd-love overlay, I committed a net-dns/openresolv ebuild that features a restartcmd script that is able to work with both openrc and systemd, depending on which one has booted the system. Reproducible: Always
Created attachment 345336 [details] the restartcmd script installed into /lib/openresolv
Seems reasonable to me. Maybe Roy could include similar runtime detection upstream?
Gentle ping ;)
I'm not going to include this upstream right now. For the time being you can pass this to confgiure: --restartcmd="/lib/openresolv/restartcmd \1" Which should make your script work anyway without modifications to openresolv itself.
That is what my ebuild does. If you agree, I can commit the changes to gentoo-x86. We're (some fellow Gentoo developers and I believe also the systemd gentoo team) planning to make systemd less painful for openrc users and vice versa, and these changes are actually needed.
+ 27 Apr 2013; Fabio Erculiani <lxnay@gentoo.org> openresolv-3.5.4.ebuild, + +files/restartcmd: + detect openrc/systemd at runtime, fix bug #465648 +