package/polkit: install service file
authorAdam Duskett <Aduskett@gmail.com>
Sat, 18 Apr 2020 02:58:13 +0000 (19:58 -0700)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>
Sat, 18 Apr 2020 12:45:50 +0000 (14:45 +0200)
The default installed service file is missing a target, which causes preset-all
to not enable the service.

Add the service file to package/polkit with the addition of:

[Install]
WantedBy=multi-user.target

Signed-off-by: Adam Duskett <Aduskett@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
package/polkit/polkit.mk
package/polkit/polkit.service [new file with mode: 0644]

index 8572d8b9ba9e887f9ec02d96fdd171ec0ba4aea0..ee0b3674de8d4cf29d450076f8548b14692a1a58 100644 (file)
@@ -43,4 +43,10 @@ define POLKIT_PERMISSIONS
        /usr/bin/pkexec f 4755 root root - - - - -
 endef
 
+define POLKIT_INSTALL_INIT_SYSTEMD
+       $(INSTALL) -D -m 644 $(POLKIT_PKGDIR)/polkit.service \
+               $(TARGET_DIR)/usr/lib/systemd/system/polkit.service
+
+endef
+
 $(eval $(autotools-package))
diff --git a/package/polkit/polkit.service b/package/polkit/polkit.service
new file mode 100644 (file)
index 0000000..a69b28c
--- /dev/null
@@ -0,0 +1,12 @@
+[Unit]
+
+Description=Authorization Manager
+Documentation=man:polkit(8)
+
+[Service]
+Type=dbus
+BusName=org.freedesktop.PolicyKit1
+ExecStart=/usr/lib/polkit-1/polkitd --no-debug
+
+[Install]
+WantedBy=multi-user.target