package/network-manager: Enable service under systemd

Previously NetworkManager had to be enabled and started on the
first boot manually or by a script.

Add install define with the commands to setup the required
service files for automatic start.

Signed-off-by: Nathaniel Roach <nroach44@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
This commit is contained in:
Nathaniel Roach 2014-12-02 16:53:39 +08:00 committed by Thomas Petazzoni
parent 848ef692ae
commit cb719a907a
1 changed files with 13 additions and 0 deletions

View File

@ -72,4 +72,17 @@ define NETWORK_MANAGER_INSTALL_INIT_SYSV
$(INSTALL) -m 0755 -D package/network-manager/S45network-manager $(TARGET_DIR)/etc/init.d/S45network-manager
endef
define NETWORK_MANAGER_INSTALL_INIT_SYSTEMD
mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
ln -sf /usr/lib/systemd/system/NetworkManager.service \
$(TARGET_DIR)/etc/systemd/system/dbus-org.freedesktop.NetworkManager.service
ln -sf /usr/lib/systemd/system/NetworkManager.service \
$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/NetworkManager.service
ln -sf /usr/lib/systemd/system/NetworkManager-dispatcher.service \
$(TARGET_DIR)/etc/systemd/system/dbus-org.freedesktop.nm-dispatcher.service
endef
$(eval $(autotools-package))