In media-tv/tvheadend-4.2.8, the service file is broken. It reads: > ExecStart=/usr/bin/tvheadend -p /run/tvheadend/tvheadend.pid -c "${TVHEADEND_CONFIG}" ${TVHEADEND_OPTIONS} A ${name} variable will _not_ be split, and the line is _not_ parsed by a shell, so argv becomes `[…]-c\0"/etc/tvheadend"\0--foo --bar --baz`, instead of the intended `[…]-c\0/etc/tvheadend\0--foo\0--bar\0--baz`. Solution: > ExecStart=/usr/bin/tvheadend -p /run/tvheadend/tvheadend.pid -c ${TVHEADEND_CONFIG} $TVHEADEND_OPTIONS This removes the quotes around ${TVHEADEND_CONFIG} (which will be one argument even if one makes the questionable choice to have paths with spaces) and the braces in $TVHEADEND_OPTIONS, so that it will be split on spaces like one would expect.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2b4d221c8a5c4aee7a1330beba243636767d6dfc commit 2b4d221c8a5c4aee7a1330beba243636767d6dfc Author: James Le Cuirot <chewi@gentoo.org> AuthorDate: 2020-05-10 22:17:32 +0000 Commit: James Le Cuirot <chewi@gentoo.org> CommitDate: 2020-05-10 22:17:32 +0000 media-tv/tvheadend: Fix bad quoting in systemd service file Closes: https://bugs.gentoo.org/720720 Package-Manager: Portage-2.3.99, Repoman-2.3.22 Signed-off-by: James Le Cuirot <chewi@gentoo.org> media-tv/tvheadend/files/tvheadend.service | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)