summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--package/samba4/samba4.mk11
1 files changed, 5 insertions, 6 deletions
diff --git a/package/samba4/samba4.mk b/package/samba4/samba4.mk
index d95b4edfa4..e2f8e7de2f 100644
--- a/package/samba4/samba4.mk
+++ b/package/samba4/samba4.mk
@@ -161,13 +161,12 @@ define SAMBA4_INSTALL_INIT_SYSV
$(TARGET_DIR)/etc/init.d/S91smb
endef
+ifeq ($(BR2_INIT_SYSTEMD),y)
+SAMBA4_CONF_OPTS += --systemd-install-services
+SAMBA4_DEPENDENCIES += systemd
+endif
+
define SAMBA4_INSTALL_INIT_SYSTEMD
- $(INSTALL) -D -m 644 $(@D)/packaging/systemd/nmb.service \
- $(TARGET_DIR)/usr/lib/systemd/system/nmb.service
- $(INSTALL) -D -m 644 $(@D)/packaging/systemd/smb.service \
- $(TARGET_DIR)/usr/lib/systemd/system/smb.service
- $(INSTALL) -D -m 644 $(@D)/packaging/systemd/winbind.service \
- $(TARGET_DIR)/usr/lib/systemd/system/winbind.service
mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
ln -sf ../../../../usr/lib/systemd/system/nmb.service \
$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/nmb.service
OpenPOWER on IntegriCloud