package/openvpn: adds target install of systemd unit files
authorEdmundo Ferreira <fc.edmundo@gmail.com>
Tue, 15 Dec 2020 16:36:10 +0000 (17:36 +0100)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>
Thu, 31 Dec 2020 14:41:32 +0000 (15:41 +0100)
Signed-off-by: Edmundo Ferreira <fc.edmundo@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
package/openvpn/openvpn.mk

index 3efc9e2354216a7581673ecef15a9da203541ec7..741da9784ca9e68917bf88901f8f0a337fb45d40 100644 (file)
@@ -79,4 +79,11 @@ define OPENVPN_INSTALL_INIT_SYSV
                $(TARGET_DIR)/etc/init.d/S60openvpn
 endef
 
+define OPENVPN_INSTALL_INIT_SYSTEMD
+       $(INSTALL) -D -m 0644 $(@D)/distro/systemd/openvpn-client@.service \
+               $(TARGET_DIR)/usr/lib/systemd/system/openvpn-client@.service
+       $(INSTALL) -D -m 0644 $(@D)/distro/systemd/openvpn-server@.service \
+               $(TARGET_DIR)/usr/lib/systemd/system/openvpn-server@.service
+endef
+
 $(eval $(autotools-package))