feat(profiles): add support for distribution that use /usr/libexec.

This commit is contained in:
Alexandre Pujol 2022-05-07 11:35:21 +01:00
parent 7377aed016
commit 6aadd82293
No known key found for this signature in database
GPG key ID: C5469996F0DF68EC
57 changed files with 75 additions and 62 deletions

View file

@ -8,6 +8,7 @@ abi <abi/3.0>,
include <tunables/global>
@{exec_path} = /{usr/,}lib/polkit-[0-9]/polkit-agent-helper-[0-9]
@{exec_path} += @{libexec}/polkit-agent-helper-[0-9]
profile polkit-agent-helper @{exec_path} {
include <abstractions/base>
include <abstractions/authentication>

View file

@ -8,6 +8,7 @@ abi <abi/3.0>,
include <tunables/global>
@{exec_path} = /{usr/,}lib/polkit-1/polkitd
@{exec_path} += @{libexec}/polkitd
profile polkitd @{exec_path} {
include <abstractions/base>
include <abstractions/nameservice-strict>

View file

@ -6,7 +6,7 @@ abi <abi/3.0>,
include <tunables/global>
@{exec_path} = /{usr/,}lib/power-profiles-daemon
@{exec_path} = @{libexec}/power-profiles-daemon
profile power-profiles-daemon @{exec_path} {
include <abstractions/base>
include <abstractions/nameservice-strict>
@ -25,8 +25,10 @@ profile power-profiles-daemon @{exec_path} {
@{sys}/class/power_supply/ r,
@{sys}/devices/**/power_supply/*/uevent r,
@{sys}/devices/system/cpu/*_pstate/{no_turbo,turbo_pct} r,
@{sys}/devices/system/cpu/*_pstate/status r,
@{sys}/devices/system/cpu/cpufreq/ r,
@{sys}/devices/system/cpu/cpufreq/policy[0-9]*/energy_performance_preference rw,
@{sys}/devices/system/cpu/cpufreq/policy[0-9]*/scaling_governor rw,
include if exists <local/power-profiles-daemon>
}