FS#34599 - [gparted] Change dependency on polkit to optdepend
Attached to Project:
Arch Linux
Opened by Philipp (hollunder) - Thursday, 04 April 2013, 11:24 GMT
Last edited by Giovanni Scafora (giovanni) - Monday, 27 May 2013, 19:58 GMT
Opened by Philipp (hollunder) - Thursday, 04 April 2013, 11:24 GMT
Last edited by Giovanni Scafora (giovanni) - Monday, 27 May 2013, 19:58 GMT
|
Details
Description:
The dependency on polkit is not necessary, it's the DEs that need polkit to launch gparted from their menu. Gparted works fine without polkit, so it really is an optional dependency. All the DEs I could think of install polkit (I checked gnome, kde, xfce, e17), so the optdepend won't hurt them, but it would allow non-DE users to keep the system free of polkit. Additional info: * package version(s) gparted 0.15.0-1 * config and/or log files etc. Steps to reproduce: |
This task depends upon
#!/bin/sh
if [ $(which pkexec) ]; then
pkexec --disable-internal-agent "/usr/sbin/gparted.elf" "$@"
else
/usr/sbin/gparted.elf "$@"
fi
Or use guisu as launcher script, which falls back to gksu and then command line if no polkit authentication GUI found. It's created by xyproto and me:
https://github.com/xyproto/guisu/blob/master/guisu.sh
/usr/sbin/gparted: line 2: pkexec: command not found
See my last comment.
for completeness, here's what I wrote to City-busz and giovanni while I couldn't post here:
I have the following proposition:
At the moment, with version 0.16.1-1, gparted can be started without
polkit by executing polkit.elf as root or via sudo. Just executing
gparted (which is a script that does some polkit stuff) does not work
without polkit, as you mentioned.
The solution I propose is simple:
Name the plain gparted executable gparted, for all the CLI and minimal
GUI users out there.
Name the polkit script gparted_polkit and change the desktop file
accordingly, for all the gnomes and other desktop-file/polkit users.
Done. Everyone's happy!(?)
Before closing this bug report, please let me know if it is OK.
I was briefly looking through the files and I have some more minor suggestions. I'm not sure whether the message in gparted.install is still accurate. I personally think the script as file is nicer than the echo-lines.
Anyway, I am happy, thanks a lot :)
1) added launcher script for polkit users (no echo-lines on PKGBUILD)
2) improved gparted.install file
Before closing this bug report, please if you have other suggestions, let me know.