There's a couple issues with the current approach: - pkexec is an unusual elevation method, the standard is sudo - it tries to elevate even in automated workflows - the user may not want to automatically rerun as root, that might be badly behaved Do some upfront checks instead, first to make sure it even makes sense to try becoming root, and then to ask the user "do you really want this". Also check for a couple common approaches to root elevation, including doas. Fixes #7345 Fixes #7809pull/11366/head
parent
7884149bf5
commit
a878c38476
3 changed files with 39 additions and 6 deletions
@ -0,0 +1,9 @@ |
||||
## `meson install` now supports user-preferred root elevation tools |
||||
|
||||
Previously, when installing a project, if any files could not be installed due |
||||
to insufficient permissions the install process was automatically re-run using |
||||
polkit. Now it prompts to ask whether that is desirable, and checks for |
||||
CLI-based tools such as sudo or opendoas or `$MESON_ROOT_CMD`, first. |
||||
|
||||
Meson will no longer attempt privilege elevation at all, when not running |
||||
interactively. |
Loading…
Reference in new issue