On a systemd-only system (openrc is not installed) during build net-vpn/libreswan-4.1-r1 (USE="networkmanager pam seccomp systemd -caps -curl -dnssec -ldap -selinux -test") records `openrc` as the initsystem in use and that results in the following error later when activating a VPN NetworkManager[1977932]: whack: Pluto is not running (no "/run/pluto/pluto.ctl") NetworkManager[1977935]: Redirecting to: rc-service ipsec restart NetworkManager[1977935]: /usr/libexec/ipsec/setup: line 217: exec: rc-service: not found This did not happen in 3.32-r1 because it does the initsystem detection at runtime. Reproducible: Always
Ping. This is still the case in libreswan-4.3. Is any additional information from me needed to fix this problem?
Same issue here. To make things work, I have to patch /usr/libexec/ipsec/setup and replace line 30 to: initsystem="systemd" How's this was supposed to work? The script has huge switch with commands for different init systems, but no code to detect them.
Some more details: the problem script source is programs/setup/setup.in running simple 'make -C programs/setup/' command produces expected result in 'OBJ.linux.x86_64/programs/setup/setup' where initsystem="systemd" (all this using unmodified tarball) However, emerge 'emerge -v net-vpn/libreswan' produces 'setup' script with 'initsystem="openrc"' in it.
Created attachment 704541 [details] emerge --info output
Created attachment 704544 [details] output of emerge build log
also, I have openrc still installed
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b5c7c9a782224f592c9f2521d766cf31322656c7 commit b5c7c9a782224f592c9f2521d766cf31322656c7 Author: Hans de Graaff <graaff@gentoo.org> AuthorDate: 2021-05-01 07:12:11 +0000 Commit: Hans de Graaff <graaff@gentoo.org> CommitDate: 2021-05-01 07:12:11 +0000 net-vpn/libreswan: set INITSYSTEM correctly INITSYSTEM was hardcoded to always be openrc. This was ignored in libreswan 3.x where runtime detection was used, but in 4.x the INITSYSTEM is hardcoded in the setup script at installation time. Set INITSYSTEM based on the systemd USE flag instead. Closes: https://bugs.gentoo.org/756121 Package-Manager: Portage-3.0.18, Repoman-3.0.2 Signed-off-by: Hans de Graaff <graaff@gentoo.org> net-vpn/libreswan/libreswan-4.4-r1.ebuild | 120 ++++++++++++++++++++++++++++++ 1 file changed, 120 insertions(+)