diff --git a/net-vpn/openfortivpn/files/systemd_substitute_bin_and_sysconfig_dirs.patch b/net-vpn/openfortivpn/files/systemd_substitute_bin_and_sysconfig_dirs.patch new file mode 100644 index 0000000000000..4cfe57c46545e --- /dev/null +++ b/net-vpn/openfortivpn/files/systemd_substitute_bin_and_sysconfig_dirs.patch @@ -0,0 +1,13 @@ +diff --git a/lib/systemd/system/openfortivpn@.service.in b/lib/systemd/system/openfortivpn@.service.in +index 6c30230..3ff3d7c 100644 +--- a/lib/systemd/system/openfortivpn@.service.in ++++ b/lib/systemd/system/openfortivpn@.service.in +@@ -6,7 +6,7 @@ Documentation=man:openfortivpn(1) + [Service] + Type=simple + PrivateTmp=true +-ExecStart=@BINDIR@/openfortivpn -c @SYSCONFDIR@/openfortivpn/%I.conf ++ExecStart=/usr/bin/openfortivpn -c /etc/openfortivpn/%I.conf + OOMScoreAdjust=-100 + + [Install] diff --git a/net-vpn/openfortivpn/openfortivpn-1.17.1.ebuild b/net-vpn/openfortivpn/openfortivpn-1.17.1.ebuild index 0c64cdfd137fc..634f0884bc80a 100644 --- a/net-vpn/openfortivpn/openfortivpn-1.17.1.ebuild +++ b/net-vpn/openfortivpn/openfortivpn-1.17.1.ebuild @@ -21,6 +21,10 @@ RDEPEND="${DEPEND}" CONFIG_CHECK="~PPP ~PPP_ASYNC" +PATCHES=( + "${FILESDIR}/systemd_substitute_bin_and_sysconfig_dirs.patch" +) + src_prepare() { default