sensors/var-run-deprecated.patch

70 lines
2.2 KiB
Diff
Raw Normal View History

From: Jean Delvare <jdelvare@suse.de>
Subject: /var/run is deprecated
Patch-mainline: Not yet, will submit later today
References: bsc#1185183
Systemd now wants PID files in /run, not /var/run. Service files have
been updated upstream already, but not the path used by the actual
programs. Change them too so that things don't break when the
/var/run symlink is eventually dropped.
---
prog/pwm/fancontrol | 2 +-
prog/pwm/pwmconfig | 2 +-
prog/sensord/args.c | 4 ++--
prog/sensord/sensord.8 | 2 +-
4 files changed, 5 insertions(+), 5 deletions(-)
--- a/prog/pwm/fancontrol
+++ b/prog/pwm/fancontrol
@@ -38,7 +38,7 @@
#
#
-PIDFILE="/var/run/fancontrol.pid"
+PIDFILE="/run/fancontrol.pid"
#DEBUG=1
MAX=255
--- a/prog/pwm/pwmconfig
+++ b/prog/pwm/pwmconfig
@@ -30,7 +30,7 @@
#
LM_VERSION='3.6.0'
-PIDFILE="/var/run/fancontrol.pid"
+PIDFILE="/run/fancontrol.pid"
if [ -f "$PIDFILE" ]
then
--- a/prog/sensord/args.c
+++ b/prog/sensord/args.c
@@ -33,7 +33,7 @@
#include "version.h"
struct sensord_arguments sensord_args = {
- .pidFile = "/var/run/sensord.pid",
+ .pidFile = "/run/sensord.pid",
.scanTime = 60,
.logTime = 30 * 60,
.rrdTime = 5 * 60,
@@ -97,7 +97,7 @@ static const char *daemonSyntax =
" -T, --rrd-no-average -- switch RRD in non-average mode\n"
" -r, --rrd-file <file> -- RRD file (default <none>)\n"
" -c, --config-file <file> -- configuration file\n"
- " -p, --pid-file <file> -- PID file (default /var/run/sensord.pid)\n"
+ " -p, --pid-file <file> -- PID file (default /run/sensord.pid)\n"
" -f, --syslog-facility <f> -- syslog facility to use (default local4)\n"
" -g, --rrd-cgi <img-dir> -- output an RRD CGI script and exit\n"
" -a, --load-average -- include load average in RRD file\n"
--- a/prog/sensord/sensord.8
+++ b/prog/sensord/sensord.8
@@ -86,7 +86,7 @@ configuration file is used.
.IP "-p, --pid-file file"
Specify what PID file to write; the default is to write the file
-`/var/run/sensord.pid'. You should always specify an absolute path
+`/run/sensord.pid'. You should always specify an absolute path
here. The file is removed when the daemon exits.
.IP "-f, --syslog-facility facility"
Specify the