FS#74914 - [mandoc] Broken systemd unit files
Attached to Project:
Community Packages
Opened by Mynacol (mynacol) - Monday, 30 May 2022, 22:11 GMT
Last edited by T.J. Townsend (blakkheim) - Monday, 22 May 2023, 21:50 GMT
Opened by Mynacol (mynacol) - Monday, 30 May 2022, 22:11 GMT
Last edited by T.J. Townsend (blakkheim) - Monday, 22 May 2023, 21:50 GMT
|
Details
I just installed mandoc. On use, mandoc complains about an
"outdated mandoc.db". I found the mandoc.{service,timer}
systemd unit files, which periodically update this
database.
The status of the timer unit did not suggest being enabled, so I tried to enable it myself. Systemd promptly complained `The unit files have no installation config (WantedBy=, [...] settings in the [Install] section, [...]`. I checked the unit files and the timer unit indeed lacks a proper `WantedBy=` directive. Checking the PKGBUILD I see you "enable" the unit by placing it in `multi-user.target.wants`. Normally, timer units should depend on `timers.target`. I hope you fix these two issues. On the other side props for setting the Nice and IPSchedulingClass of the service :+1:. Thanks and Regards! |
This task depends upon
For comparison: the man-db timer unit has the following at the bottom:
[Install]
WantedBy=timers.target
And in the PKGBUILD the timer unit is activated by placing a symlink to timers.target:
ln -s ../man-db.timer ${pkgdir}/usr/lib/systemd/system/timers.target.wants/man-db.timer
Adapted to mandoc, this should be:
ln -s ../mandoc.timer "${pkgdir}"/usr/lib/systemd/system/timers.target.wants/mandoc.timer
For me this seems to be a small and easy change and should be safe from regressions.
I noticed some further sandboxing options in man-db worth evaluating, but they are out of scope for this issue.
I asked alerque for his input on the diff. If there's no objection, I'll commit it and close this task.
I wrote to the upstream mailing list just now :)