Skip to content
Snippets Groups Projects
Commit bfa279da authored by Dylan Aïssi's avatar Dylan Aïssi
Browse files

polkit-parsing.sh: fix location of polkitd for Bullseye and Bookworm


Signed-off-by: default avatarDylan Aïssi <dylan.aissi@collabora.com>
parent 4ef7af4d
No related branches found
No related tags found
1 merge request!308polkit-parsing.sh: use the right service name for polkit
......@@ -23,12 +23,17 @@ trap cleanup EXIT
# Restart polkitd to enable debug support (the standard systemd .service file
# starts it with --no-debug)
if [ -e /usr/lib/policykit-1/polkitd ]; then
# Debian jessie; Ubuntu vivid; Apertis 15.03
polkitd=/usr/lib/policykit-1/polkitd
else
# Debian experimental as of 2015-04; Apertis 15.06
if [ -e /usr/libexec/polkitd ]; then
# Debian Bullseye, Apertis v2022 and v2023
polkitd=/usr/libexec/polkitd
elif [ -e /usr/lib/polkit-1/polkitd ]; then
# Debian Bookworm, Apertis v2024+
polkitd=/usr/lib/polkit-1/polkitd
else
# polkitd is called with errexit set to "off", then
# we have to fail before if the binary is not available.
echo "The polkitd binary was not found!"
exit 1
fi
( set +e; sudo ${polkitd} --replace 2>&1 ) | sed 's/^/# /' | tee $TMPFILE &
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment