squid: systemd support

squid comes with a .service file, but does not install it.

[Thomas: use relative path for symlink instead of absolute path.]

Signed-off-by: Alex Suykov <alex.suykov@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
This commit is contained in:
Alex Suykov 2015-05-23 13:07:42 +03:00 committed by Thomas Petazzoni
parent 2154063a38
commit b8aa3d5166

View File

@ -81,4 +81,12 @@ define SQUID_INSTALL_INIT_SYSV
$(TARGET_DIR)/etc/init.d/S97squid
endef
define SQUID_INSTALL_INIT_SYSTEMD
$(INSTALL) -D -m 0644 $(@D)/tools/squid.service \
$(TARGET_DIR)/usr/lib/systemd/system/squid.service
mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
ln -sf ../../../..//usr/lib/systemd/system/squid.service \
$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/squid.service
endef
$(eval $(autotools-package))