Skip to content

Commit

Permalink
iiod: Add default env var to service file
Browse files Browse the repository at this point in the history
Systemd now gives a warning when IIOD_EXTRA_OPTS is unset.

This change sets it to an empty string by default while still allowing
it be overridden by /etc/default/iiod.

Fixes #1142.

Signed-off-by: Dennis Jusufovic <[email protected]>
  • Loading branch information
dennis-ju authored and mhennerich committed Feb 20, 2024
1 parent 7ae4836 commit 7ba23c8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion iiod/init/iiod.service.cmakein
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#
# iiod - Systemd init script
#
# Copyright (C) 2016-2021 Analog Devices Inc.
# Copyright (C) 2016-2024 Analog Devices Inc.

[Unit]
Description=IIO Daemon
Expand All @@ -12,6 +12,7 @@ ConditionPathExists=/sys/bus/iio
Documentation=man:iiod(8)

[Service]
Environment=$IIOD_EXTRA_OPTS=''
EnvironmentFile=-/etc/default/iiod
ExecStart=@CMAKE_INSTALL_FULL_SBINDIR@/iiod $IIOD_EXTRA_OPTS
KillMode=process
Expand Down

0 comments on commit 7ba23c8

Please sign in to comment.