I'm cleaning up some old scriptlets and have a few questions about whether these are needed anymore:
1) /sbin/ldconfig is no longer needed after installation a shared library in F28+, correct?
2) Is update-mime-database still needed after installing a file in %{_datadir}/mime/packages/ ?
3) Is 'udevadm control --reload-rules' still needed after installing a udev rules file?
Thanks, Scott
"ST" == Scott Talbert swt@techie.net writes:
ST> 1) /sbin/ldconfig is no longer needed after installation a shared ST> library in F28+, correct?
That is correct. It doesn't hurt anything, but can slow down package installation. See https://fedoraproject.org/wiki/Packaging:Scriptlets#Shared_Libraries for a full explanation and description of macros which work across all releases.
ST> 2) Is update-mime-database still needed after installing a file in ST> %{_datadir}/mime/packages/ ?
This has not been needed since... Fedora 24 or 25 I think. No scriptlets for update-mime-database are currently listed in https://fedoraproject.org/wiki/Packaging:Scriptlets
For EPEL, there is https://fedoraproject.org/wiki/EPEL:Packaging#mimeinfo
ST> 3) Is 'udevadm control --reload-rules' still needed after installing ST> a udev rules file?
Not sure at all; the packaging guidelines have never listed any requirement for calling udevadm.
- J<
On mardi 12 juin 2018 19:23:00 CEST Jason L Tibbitts III wrote:
ST> 3) Is 'udevadm control --reload-rules' still needed after installing ST> a udev rules file?
Not sure at all; the packaging guidelines have never listed any requirement for calling udevadm.
This shouldn't be necessary as there is a transfiletrigger in Systemd to handle new rules:
%transfiletriggerin udev -- /usr/lib/udev/rules.d # This script will automatically update udev with new rules if files # have been installed or updated in /usr/lib/udev/rules.d. if test -d /run/systemd/system; then %{_bindir}/udevadm control --reload fi
https://src.fedoraproject.org/rpms/systemd/blob/master/f/triggers.systemd#_9...
On mardi 12 juin 2018 20:21:22 CEST Jason L Tibbitts III wrote:
"RM" == Robert-André Mauchin zebob.m@gmail.com writes:
RM> This shouldn't be necessary as there is a transfiletrigger in RM> Systemd to handle new rules:
Note that this is in F28+ only.
- J<
I've just discovered %udev_rules_update though a review. Equates to %nil in F28 and udevadm control --reload >/dev/null 2>&1 in F27. Pretty neat.
"RM" == Robert-André Mauchin zebob.m@gmail.com writes:
RM> I've just discovered %udev_rules_update though a review. Equates to RM> %nil in F28 and udevadm control --reload >/dev/null 2>&1 in RM> F27. Pretty neat.
Would be really neat if these actually got documented somewhere. And unfortunately having a macro like that doesn't help all that much because you still end up having to conditionalize the scriptlet dependencies and usually the scriptlet itself for the distro version (assuming you insist on keeping the same spec for each branch). But at least most of it will just go away after F27 goes EOL.
Handling the complete set of cases is what makes the ldconfig macros so complicated.
- J<
On Mon, Jun 18, 2018 at 5:37 AM Jason L Tibbitts III tibbs@math.uh.edu wrote:
"RM" == Robert-André Mauchin zebob.m@gmail.com writes:
RM> I've just discovered %udev_rules_update though a review. Equates to RM> %nil in F28 and udevadm control --reload >/dev/null 2>&1 in RM> F27. Pretty neat.
Would be really neat if these actually got documented somewhere. And unfortunately having a macro like that doesn't help all that much because you still end up having to conditionalize the scriptlet dependencies and usually the scriptlet itself for the distro version (assuming you insist on keeping the same spec for each branch). But at least most of it will just go away after F27 goes EOL.
Handling the complete set of cases is what makes the ldconfig macros so complicated.
In most cases, it was not necessary even before, since udev watches the rules directory with inotify and reloads automatically. There are only a couple of special cases where this doesn't kick in (mainly if the rule called another program and that program was updated), and that's where the file trigger helps with it.
packaging@lists.fedoraproject.org