-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Kodi postinst script fails if polkit-1 dir does not exist #153
Comments
I think the deepest source is https://github.com/popcornmix/xbmc |
The package is kindly provided by Rascas of pipplware - I've already left a message here https://www.raspberrypi.org/forums/viewtopic.php?f=66&t=251645&start=125#p1552570 |
Hi, I am rascas, the Kodi packages maintainer. The Kodi 18 Leia source code for the RPi 0/1/2/3 is available here: More info here: So correct me if I am wrong: DietPi for the RPi is based on Raspbian but not on the pre made oficial images. I am asking this because policykit-1 is installed on the pre made images. Anyway, what the polkit rule does is to allow the user who will run Kodi, to be able to reboot and shutdown the Pi and to mount/unmount devices inside Kodi. Maybe the best is to just add policykit-1 as a dependency, but I can do whatever you think is best, |
@diogomsantos We solve Kodi permissions via udev rules (generally for all devices, not just RPi), however Wouldn't it be easiest to make |
If you go with the mkdir route, the nice thing to do in postrm purge would be to remove the pkla file and all created directories if they're empty. |
E.g.
|
If I was doing this I'd probably ship it as a normal file in /var/lib/polkit-1/localauthority/50-local.d |
Putting the rule on a conffile was my first idea, but I use cmake cpack deb for a while now, as it is easier and supported in upstream Kodi, and adding a conffile there didn't look easy, so I ended up using postinst/postrm. |
Are there any updates for this issue? |
To re-activate this. Isn't it possible to simply add a
Now I don't see where the file itself would need to be added, but since As alternative I'd actually second @XECDesign's idea to make it a regular file. I lost track what the reason was to not hardcode it into the package, if there was any? Shipping it statically as |
If you tell me how to do that with cmake cpak deb, I will gladly do it. |
I see you added Out of interest, I was digging a little further. Simply placing the
When I find some more spare time and joy to tinker with this, I'll open a new issue and PR at your repo as a testing and discussion basis. But lacking cpack experience, it would be trial and failure and currently IMO not worth the effort. It's a new issue anyway, not to fix the OP, so I mark this as closed 🙂. |
The issue re-appeared with Bookworm, since the
Checking changelogs, the directory has been obsoleted: https://metadata.ftp-master.debian.org/changelogs//main/p/policykit-1/policykit-1_122-3_changelog
There is a legacy package which should pre-create it instead: https://packages.debian.org/bookworm/polkitd-pkla EDIT: Related notes from Debian: https://www.debian.org/releases/bookworm/arm64/release-notes/ch-information.en.html#changes-to-polkit-configuration EDIT2: Now it is @popcornmix: https://github.com/popcornmix/xbmc/blob/gbm/cmake/cpack/deb/postinst#L22-L38 |
Sorry if this is to wrong place to report this, but I got confused and couldn't find out which "xmbc" fork finally serves as source the the RPi repo package.
However, the package
postinst
scripts contains this:Since
policykit1
is not a dependency of thekodi
package, the required/etc/polkit-1/localauthority/50-local.d
dir does not always exist, hence the install fails.Three possible solutions:
/etc/polkit-1
, before creating the file.mkdir -p /etc/polkit-1/localauthority/50-local.d
required.policykit1
installs,mkdir -p /etc/polkit-1/localauthority/50-local.d
and skip above check.policykit1
must be added as dependency. But I would leave this for user choice, probably add to suggestions or recommends instead.Reference: MichaIng/DietPi#3031 (comment)
The text was updated successfully, but these errors were encountered: