fwupd/snap/hooks/install
Mario Limonciello 96a0dd5606 Add a support for delayed activation
This is intended for devices that it is not safe to immediately activate
the firmware.  It may be called at a more convenient time instead.

Both fwupdmgr and fwupdtool support the feature.

- if called at runtime with fwupdmgr it uses the daemon
- during shutdown fwupdtool uses the pending.db to perform this feature.
2019-02-27 09:04:54 +00:00

16 lines
612 B
Bash
Executable File

#!/bin/sh -e
install_if_missing() {
install -m 644 -C ${SNAP}/${1} ${2}/${1}
}
#install policykit rules and actions
install_if_missing share/polkit-1/actions/org.freedesktop.fwupd.policy /usr
install_if_missing share/polkit-1/rules.d/org.freedesktop.fwupd.rules /usr
#install dbus related items
install_if_missing share/dbus-1/system-services/org.freedesktop.fwupd.service /usr
install_if_missing share/dbus-1/interfaces/org.freedesktop.fwupd.xml /usr
install_if_missing etc/dbus-1/system.d/org.freedesktop.fwupd.conf /
#activation via systemd
install_if_missing /lib/systemd/system-shutdown/fwupd.shutdown /