OBS User unknown 2009-07-30 15:01:03 +00:00 committed by Git OBS Bridge
parent aaf670ec6e
commit d67ac087ac
18 changed files with 321 additions and 719 deletions

View File

@ -1,8 +1,6 @@
Index: doc/progs
===================================================================
--- doc/progs.orig
+++ doc/progs
@@ -58,6 +58,8 @@ see http://www.lm-sensors.org/wiki/Usefu
--- lm_sensors-3.1.1.orig/doc/progs
+++ lm_sensors-3.1.1/doc/progs
@@ -53,6 +53,8 @@ see http://www.lm-sensors.org/wiki/Usefu
the sensors hardware to syslog, and to alert (using syslog level ALERT)
when a sensor alarm is signalled; for example, if a fan fails, a temperature
limit is exceeded, etc.

View File

@ -1,17 +1,15 @@
Index: prog/detect/sensors-detect
===================================================================
--- prog/detect/sensors-detect.orig
+++ prog/detect/sensors-detect
@@ -6097,6 +6097,12 @@ sub main
open(local *SYSCONFIG, ">/etc/sysconfig/lm_sensors")
or die "Sorry, can't create /etc/sysconfig/lm_sensors ($!)";
print SYSCONFIG <<'EOT';
--- lm_sensors-3.1.1.orig/prog/detect/sensors-detect
+++ lm_sensors-3.1.1/prog/detect/sensors-detect
@@ -5460,6 +5460,12 @@ sub write_config
or die "Sorry, can't create /etc/sysconfig/lm_sensors ($!)";
print SYSCONFIG "# Generated by sensors-detect on " . scalar localtime() . "\n";
print SYSCONFIG <<'EOT';
+## Path: Hardware/Sensors
+## Description: Defines the modules to used
+## Type: string
+## ServiceRestart: lm_sensors
+## Default: ""
+#
# /etc/sysconfig/lm_sensors - Defines modules loaded by
# /etc/init.d/lm_sensors
# Copyright (c) 1998 - 2001 Frodo Looijaard <frodol@dds.nl>
# This file is sourced by /etc/init.d/lm_sensors and defines the modules to
# be loaded/unloaded.
#

View File

@ -1,245 +0,0 @@
Index: Makefile
===================================================================
--- Makefile.orig
+++ Makefile
@@ -137,7 +137,7 @@ ifeq ($(DEBUG),1)
ALL_CPPFLAGS += -DDEBUG
ALL_CFLAGS += -O -g
else
-ALL_CFLAGS += -O2
+ALL_CFLAGS += $(RPM_OPT_FLAGS)
endif
ifeq ($(WARN),1)
Index: prog/init/README
===================================================================
--- prog/init/README.orig
+++ prog/init/README
@@ -10,7 +10,7 @@ The script lm_sensors.init is a nice sta
On RH and other RH-based systems (MDK, notably) use this sort of startup
mechanism (i.e. SVR4-based), as opposed to the everything-in-one-script
(/etc/rc or /etc/rc.local) like the BSD-based systems do.
-The lm_sensors.init file should be copied to /etc/rc.d/init.d/lm_sensors.
+The lm_sensors.init file should be copied to /etc/init.d/lm_sensors.
For more information see the top of the file.
It requires the /etc/sysconfig/lm_sensors file, which identifies
the correct modules.
@@ -27,10 +27,10 @@ by Marc Rieffel <marc@paracel.com>.
----------------
The script sensord.init also loads the modules, and then
-starts the sensord daemon. See the directory ../sensord for
+starts the sensord daemon. See the manual page sensord(8) for
more information on the daemon.
-The sensord.init file should be copied to /etc/rc.d/init.d/sensord.
+The sensord.init file should be copied to /etc/init.d/sensord.
For more information see the top of the file.
To configure this service one should put appropriate "alias i2c-bus-0 xxx"
Index: prog/init/lm_sensors.init.suse
===================================================================
--- prog/init/lm_sensors.init.suse.orig
+++ prog/init/lm_sensors.init.suse
@@ -1,19 +1,15 @@
#!/bin/sh
#
### BEGIN INIT INFO
-# Provides: lm_sensors
-# Required-Start: $local_fs
-# X-UnitedLinux-Should-Start:
-# Required-Stop: $local_fs
-# X-UnitedLinux-Should-Stop:
-# Default-Start: 3 4 5
-# Default-Stop: 0 1 2 6
-# Short-Description: LM Sensors
-# Description: LM Sensors for hardware monitoring
+# Provides: sensors
+# Required-Start: $remote_fs
+# Required-Stop: $remote_fs
+# Default-Start: 2 3 5
+# Default-Stop:
+# Short-Description: Load and configure hardware monitoring drivers
+# Description: sensors is used for monitoring motherboard sensor values.
+# Config file is /etc/sysconfig/lm_sensors
### END INIT INFO
-# chkconfig: 2345 26 74
-# description: sensors is used for monitoring motherboard sensor values.
-# config: /etc/sysconfig/lm_sensors
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -40,116 +36,82 @@
# in order as normal shell variables with the special names:
# MODULE_1, MODULE_2, MODULE_3, etc.
-# If sensors isn't supported by the kernel, try loading the module...
-[ -e /proc/sys/dev/sensors ] || /sbin/modprobe i2c-proc &>/dev/null
-
-# Don't bother if /proc/sensors still doesn't exist, kernel doesn't have
-# support for sensors.
-[ -e /proc/sys/dev/sensors ] || exit 0
-
-# If sensors was not already running, unload the module...
-[ -e /var/lock/subsys/lm_sensors ] || /sbin/modprobe -r i2c-proc &>/dev/null
-
CONFIG=/etc/sysconfig/lm_sensors
-PSENSORS=/usr/local/bin/sensors
+PSENSORS=/usr/bin/sensors
+FANCONFIG=/etc/fancontrol
+PFAN=/usr/sbin/fancontrol
# Source function library.
-#. /etc/init.d/functions
-
-# Shell functions sourced from /etc/rc.status:
-# rc_check check and set local and overall rc status
-# rc_status check and set local and overall rc status
-# rc_status -v ditto but be verbose in local rc status
-# rc_status -v -r ditto and clear the local rc status
-# rc_status -s display "skipped" and exit with status 3
-# rc_status -u display "unused" and exit with status 3
-# rc_failed set local and overall rc status to failed
-# rc_failed <num> set local and overall rc status to <num>
-# rc_reset clear local rc status (overall remains)
-# rc_exit exit appropriate to overall rc status
-# rc_active checks whether a service is activated by symlinks
-# rc_splash arg sets the boot splash screen to arg (if active)
. /etc/rc.status
-# Reset status of this service
-rc_reset
-
-# Return values acc. to LSB for all commands but status:
-# 0 - success
-# 1 - generic or unspecified error
-# 2 - invalid or excess argument(s)
-# 3 - unimplemented feature (e.g. "reload")
-# 4 - user had insufficient privileges
-# 5 - program is not installed
-# 6 - program is not configured
-# 7 - program is not running
-# 8--199 - reserved (8--99 LSB, 100--149 distrib, 150--199 appl)
-#
-# Note that starting an already running service, stopping
-# or restarting a not-running service as well as the restart
-# with force-reload (in case signaling is not supported) are
-# considered a success.
-
-RETVAL=0
-
start() {
- echo -n $"Starting up sensors: "
+ echo -n "Starting up sensors"
+ unset ${!MODULE_*}
test -r "$CONFIG" && . "$CONFIG"
- modules=`grep \^MODULE_ $CONFIG | wc -l | tr -d ' '`
- i=0
- while [ $i -lt $modules ] ; do
- module=`eval echo '$'MODULE_$i`
- echo starting module __${module}__
+ for i in ${!MODULE_*} ; do
+ eval module=\$$i
/sbin/modprobe $module &>/dev/null
- i=`expr $i + 1`
+ rc_status
done
- $PSENSORS -s
+ rc_status
+
+ /usr/bin/sensors -s &> /dev/null
+ rc_status
- RETVAL=$?
- if [ $RETVAL -eq 0 ] && touch /var/lock/subsys/lm_sensors ; then
- rc_status -v
+ # Start fan control, if configured
+ if test -s "$FANCONFIG" -a -x "$PFAN" ; then
+ echo -n ", starting fan control: "
+ /sbin/startproc -q "$PFAN"
+ rc_status
else
- rc_status -v
+ echo -n ": "
fi
+
+ rc_status -v && touch /var/lock/subsys/sensors
}
stop() {
- echo -n $"Shutting down sensors: "
+ echo -n "Shutting down sensors"
+ unset ${!MODULE_*}
test -r "$CONFIG" && . "$CONFIG"
- modules=`grep \^MODULE_ $CONFIG | wc -l | tr -d ' '`
- i=`expr $modules`
- while [ $i -ge 0 ] ; do
- module=`eval echo '$'MODULE_$i`
+ # Stop fan control, if it was started
+ if test -s /var/run/fancontrol.pid ; then
+ echo -n ", stopping fan control: "
+ /sbin/killproc -TERM "$PFAN"
+ rc_status
+ else
+ echo -n ": "
+ fi
+
+ for i in ${!MODULE_*} ; do
+ eval module=\$$i
/sbin/modprobe -r $module &>/dev/null
- i=`expr $i - 1`
+ rc_status
done
- /sbin/modprobe -r i2c-proc &>/dev/null
- RETVAL=$?
- if [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/lm_sensors ; then
- rc_status -v
- else
- rc_status -v
- fi
+ rc_status -v && rm -f /var/lock/subsys/sensors
}
dostatus() {
- $PSENSORS
- RETVAL=$?
+ $PSENSORS
+ rc_status
}
restart() {
stop
start
- RETVAL=$?
+ rc_status
}
condrestart() {
[ -e /var/lock/subsys/lm_sensors ] && restart || :
}
+# Reset status of this service
+rc_reset
+
# See how we were called.
case "$1" in
start)
@@ -164,12 +126,12 @@ case "$1" in
restart|reload)
restart
;;
- condrestart)
+ try-restart)
condrestart
;;
*)
- echo "Usage: sensors.init {start|stop|status|restart|reload|condrestart}"
+ echo "Usage: lm_sensors {start|stop|status|restart|reload|try-restart}"
exit 1
esac
-exit $RETVAL
+rc_exit

View File

@ -6,11 +6,9 @@ package if drivers are found to be missing.
prog/detect/sensors-detect | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
Index: lm_sensors-3.0.3/prog/detect/sensors-detect
===================================================================
--- lm_sensors-3.0.3.orig/prog/detect/sensors-detect
+++ lm_sensors-3.0.3/prog/detect/sensors-detect
@@ -2368,12 +2368,15 @@ sub initialize_conf
--- lm_sensors-3.1.1.orig/prog/detect/sensors-detect
+++ lm_sensors-3.1.1/prog/detect/sensors-detect
@@ -2052,12 +2052,15 @@ sub initialize_conf
# [2] -> SUBLEVEL
# [3] -> EXTRAVERSION
#
@ -19,23 +17,24 @@ Index: lm_sensors-3.0.3/prog/detect/sensors-detect
sub initialize_kernel_version
{
`uname -r` =~ /(\d+)\.(\d+)\.(\d+)(.*)/;
@kernel_version = ($1, $2, $3, $4);
+ if ($kernel_version[3] =~ /-([a-z]+)$/) {
+ chomp($kernel_flavor = $1);
+ }
chomp($kernel_arch = `uname -m`);
}
`uname -r` =~ /(\d+)\.(\d+)\.(\d+)(.*)/;
@kernel_version = ($1, $2, $3, $4);
+ if ($kernel_version[3] =~ /-([a-z]+)$/) {
+ chomp($kernel_flavor = $1);
+ }
chomp($kernel_arch = `uname -m`);
@@ -5819,6 +5822,11 @@ sub generate_modprobes
"# on your system. For status of 2.6 kernel ports check\n".
"# http://www.lm-sensors.org/wiki/Devices. If driver is built\n".
"# into the kernel, or unavailable, comment out the following line.\n";
+ if ($kernel_flavor) {
+ print "WARNING! The required module $chip->{driver} is not currently installed\n".
+ "on your system. You may need to install package kernel-$kernel_flavor-extra\n".
+ "for lm-sensors to work properly.\n\n";
+ }
}
$modprobes .= "modprobe $chip->{driver}\n";
}
# We only support kernels >= 2.6.5
@@ -5402,7 +5405,11 @@ sub generate_modprobes
# isn't supported
if ((($? >> 8) == 0) && ! $modulefound) {
print "Warning: the required module $driver is not currently installed\n".
- "on your system. If it is built into the kernel then it's OK.\n".
+ "on your system. ".
+ ($kernel_flavor ?
+ "You may need to install package\n".
+ "kernel-$kernel_flavor-extra for lm-sensors to work properly.\n" :
+ "If it is built into the kernel then it's OK.\n").
"Otherwise, check http://www.lm-sensors.org/wiki/Devices for\n".
"driver availability.\n\n";
} else {

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b45661f4c3a7f19d67ee4783e8270f462e874d7c909c8f4228692de97aad0ec6
size 152900

View File

@ -0,0 +1,11 @@
--- lm_sensors-3.1.1.orig/Makefile
+++ lm_sensors-3.1.1/Makefile
@@ -140,7 +140,7 @@ ifeq ($(DEBUG),1)
ALL_CPPFLAGS += -DDEBUG
ALL_CFLAGS += -O -g
else
-ALL_CFLAGS += -O2
+ALL_CFLAGS += $(RPM_OPT_FLAGS)
endif
ifeq ($(WARN),1)

3
lm_sensors-3.1.1.tar.bz2 Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:d95a3f2a6526f4da2ae145b7bbf45d16f0fb17bfe0d2017c7e02964199d059ef
size 154551

Binary file not shown.

View File

@ -1,20 +0,0 @@
--- lm_sensors-3.0.3.orig/prog/detect/sensors-detect
+++ lm_sensors-3.0.3/prog/detect/sensors-detect
@@ -4522,13 +4522,15 @@ sub lm85_detect
&& $verstep != 0x62; # LM85 B
} elsif ($chip == 1) {
return if $vendor != 0x01; # National Semiconductor
- return if $verstep != 0x68; # LM96000
+ return if $verstep != 0x68 # LM96000
+ && $verstep != 0x69; # LM96000
} elsif ($chip == 2) {
return if $vendor != 0x41; # Analog Devices
return if $verstep != 0x60; # ADM1027
} elsif ($chip == 3) {
return if $vendor != 0x41; # Analog Devices
- return if $verstep != 0x62; # ADT7463
+ return if $verstep != 0x62 # ADT7463
+ && $verstep != 0x6a; # ADT7463 C
} elsif ($chip == 4) {
return if $vendor != 0x5c; # SMSC
return if $verstep != 0x60 # EMC6D100/101 A0

View File

@ -1,26 +0,0 @@
--- lm_sensors-3.0.3.orig/prog/detect/sensors-detect
+++ lm_sensors-3.0.3/prog/detect/sensors-detect
@@ -2146,7 +2146,7 @@ use vars qw(@chip_kern24_ids @chip_kern2
},
{
name => "Intel AMB FB-DIMM thermal sensor",
- driver => "to-be-written",
+ driver => "i5k_amb",
detect => sub { intel_amb_detect(); },
},
{
@@ -5647,12 +5647,10 @@ sub k10temp_pci_detect
}
# Returns: undef if not detected, (9) if detected.
-# the device 0xa620 should not be visible on host PCI bus, gateway
-# must be used
sub intel_amb_detect
{
- if ((exists $pci_list{'8086:a620'}) ||
- (exists $pci_list{'8086:25f0'})) {
+ if ((exists $pci_list{'8086:25f0'}) || # Intel 5000
+ (exists $pci_list{'8086:4030'})) { # Intel 5400
return 9;
}
return;

View File

@ -1,9 +0,0 @@
--- lm-sensors-3.0.0/prog/sensord/rrd.c (revision 5252)
+++ lm-sensors-3.0.0/prog/sensord/rrd.c (revision 5473)
@@ -202,5 +202,5 @@
break;
case DataType_temperature:
- min = "0";
+ min = "-100";
max = "250";
break;

View File

@ -1,54 +0,0 @@
--- lm-sensors-3.0.0/prog/sensord/sensord.c (revision 5163)
+++ lm-sensors-3.0.0/prog/sensord/sensord.c (revision 5580)
@@ -91,20 +91,24 @@
sensorLog (LOG_INFO, "sensord started");
- while (!done && (ret == 0)) {
+ while (!done) {
if (reload) {
ret = reloadLib (sensorsCfgFile);
+ if (ret)
+ sensorLog (LOG_NOTICE, "config reload error (%d)", ret);
reload = 0;
}
- if ((ret == 0) && scanTime) { /* should I scan on the read cycle? */
- ret = scanChips ();
- if (scanValue <= 0)
- scanValue += scanTime;
- }
- if ((ret == 0) && logTime && (logValue <= 0)) {
- ret = readChips ();
+ if (scanTime && (scanValue <= 0)) {
+ if ((ret = scanChips ()))
+ sensorLog (LOG_NOTICE, "sensor scan error (%d)", ret);
+ scanValue += scanTime;
+ }
+ if (logTime && (logValue <= 0)) {
+ if ((ret = readChips ()))
+ sensorLog (LOG_NOTICE, "sensor read error (%d)", ret);
logValue += logTime;
}
- if ((ret == 0) && rrdTime && rrdFile && (rrdValue <= 0)) {
- ret = rrdUpdate ();
+ if (rrdTime && rrdFile && (rrdValue <= 0)) {
+ if ((ret = rrdUpdate ()))
+ sensorLog (LOG_NOTICE, "rrd update error (%d)", ret);
/*
* The amount of time to wait is computed using the same method as
@@ -113,5 +117,5 @@
rrdValue = rrdTime - time(NULL) % rrdTime;
}
- if (!done && (ret == 0)) {
+ if (!done) {
int a = logTime ? logValue : INT_MAX;
int b = scanTime ? scanValue : INT_MAX;
@@ -125,8 +129,5 @@
}
- if (ret)
- sensorLog (LOG_INFO, "sensord failed (%d)", ret);
- else
- sensorLog (LOG_INFO, "sensord stopped");
+ sensorLog (LOG_INFO, "sensord stopped");
return ret;

View File

@ -1,13 +0,0 @@
--- lm-sensors-3.0.0/lib/access.c (revision 5176)
+++ lm-sensors-3.0.0/lib/access.c (revision 5581)
@@ -438,8 +438,6 @@
expr->data.var)))
return -SENSORS_ERR_NO_ENTRY;
- if (!(res = sensors_get_value(&chip_features->chip,
- subfeature->number, result)))
- return res;
- return 0;
+ return sensors_get_value(&chip_features->chip,
+ subfeature->number, result);
}
if ((res = sensors_eval_expr(chip_features, expr->data.subexpr.sub1,

View File

@ -0,0 +1,16 @@
Upstream commit: http://www.lm-sensors.org/changeset/5757
The SMSC LPC47M233 isn't currently supported. If it ever is, it will most
probably not be by the smsc47m1 driver.
--- lm_sensors-3.1.1.orig/prog/detect/sensors-detect
+++ lm_sensors-3.1.1/prog/detect/sensors-detect
@@ -1415,7 +1415,7 @@ use constant FEAT_SMBUS => (1 << 7);
features => FEAT_FAN,
}, {
name => "SMSC LPC47M233 Super IO Sensors",
- driver => "smsc47m1",
+ driver => "to-be-written",
devid => 0x6b80,
devid_mask => 0xff80,
logdev => 0x0a,

View File

@ -0,0 +1,53 @@
Upstream commit: http://www.lm-sensors.org/changeset/5760
Recent versions of module-init-tools only want *.conf files under
/etc/modprobe.d. So rename our configuration file to lm_sensors.conf
there. Also let "make install" rename the file if it already exists.
--- lm_sensors-3.1.1.orig/Makefile
+++ lm_sensors-3.1.1/Makefile
@@ -118,6 +118,7 @@ SRCDIRS += lib/test
MKDIR := mkdir -p
RMDIR := rmdir
RM := rm -f
+MV := mv -f
BISON := bison
FLEX := flex
AR := ar
--- lm_sensors-3.1.1.orig/etc/Module.mk
+++ lm_sensors-3.1.1/etc/Module.mk
@@ -28,6 +28,10 @@ install-etc:
fi
$(MKDIR) $(DESTDIR)$(BINDIR)
$(INSTALL) -m 755 $(ETC_DIR)/sensors-conf-convert $(DESTDIR)$(BINDIR)
+ if [ -e $(DESTDIR)$(ETCDIR)/modprobe.d/lm_sensors \
+ -a ! -e $(DESTDIR)$(ETCDIR)/modprobe.d/lm_sensors.conf ] ; then \
+ $(MV) $(DESTDIR)$(ETCDIR)/modprobe.d/lm_sensors $(DESTDIR)$(ETCDIR)/modprobe.d/lm_sensors.conf ; \
+ fi
user_install :: install-etc
--- lm_sensors-3.1.1.orig/prog/detect/sensors-detect
+++ lm_sensors-3.1.1/prog/detect/sensors-detect
@@ -5430,8 +5430,8 @@ sub write_config
if (defined $configfile) {
my $have_modprobe_d = -d '/etc/modprobe.d';
- printf "Do you want to \%s /etc/modprobe.d/lm_sensors? (\%s): ",
- (-e '/etc/modprobe.d/lm_sensors' ? 'overwrite' : 'generate'),
+ printf "Do you want to \%s /etc/modprobe.d/lm_sensors.conf? (\%s): ",
+ (-e '/etc/modprobe.d/lm_sensors.conf' ? 'overwrite' : 'generate'),
($have_modprobe_d ? 'YES/no' : 'yes/NO');
$_ = <STDIN>;
if (($have_modprobe_d and not m/^\s*n/i) or m/^\s*y/i) {
@@ -5439,8 +5439,8 @@ sub write_config
mkdir('/etc/modprobe.d', 0777)
or die "Sorry, can't create /etc/modprobe.d ($!)";
}
- open(local *MODPROBE_D, ">/etc/modprobe.d/lm_sensors")
- or die "Sorry, can't create /etc/modprobe.d/lm_sensors ($!)";
+ open(local *MODPROBE_D, ">/etc/modprobe.d/lm_sensors.conf")
+ or die "Sorry, can't create /etc/modprobe.d/lm_sensors.conf ($!)";
print MODPROBE_D "# Generated by sensors-detect on " . scalar localtime() . "\n";
print MODPROBE_D $configfile;
close(MODPROBE_D);

138
lm_sensors.init Normal file
View File

@ -0,0 +1,138 @@
#!/bin/sh
#
### BEGIN INIT INFO
# Provides: lm_sensors
# Required-Start: $remote_fs
# Required-Stop: $remote_fs
# Default-Start: 2 3 5
# Default-Stop:
# Short-Description: Load and configure hardware monitoring drivers
# Description: sensors is used for monitoring motherboard sensor values.
# Config file is /etc/sysconfig/lm_sensors
### END INIT INFO
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
# MA 02110-1301 USA.
# See also the lm_sensors homepage at:
# http://www.lm-sensors.org
# It uses a config file /etc/sysconfig/lm_sensors that contains the modules
# to be loaded/unloaded. That file is sourced into this one.
# The format of that file a shell script that simply defines the modules
# in order as normal shell variables with the special names:
# MODULE_1, MODULE_2, MODULE_3, etc.
CONFIG=/etc/sysconfig/lm_sensors
LOCK=/var/lock/subsys/lm_sensors
PSENSORS=/usr/bin/sensors
FANCONFIG=/etc/fancontrol
PFAN=/usr/sbin/fancontrol
# Source function library.
. /etc/rc.status
start() {
echo -n "Starting up sensors"
unset ${!MODULE_*}
test -r "$CONFIG" && . "$CONFIG"
for i in ${!MODULE_*} ; do
eval module=\$$i
/sbin/modprobe $module &>/dev/null
rc_status
done
rc_status
/usr/bin/sensors -s &> /dev/null
rc_status
# Start fan control, if configured
if test -s "$FANCONFIG" -a -x "$PFAN" ; then
echo -n ", starting fan control: "
/sbin/startproc -q "$PFAN"
rc_status
else
echo -n ": "
fi
rc_status -v && touch $LOCK
}
stop() {
echo -n "Shutting down sensors"
unset ${!MODULE_*}
test -r "$CONFIG" && . "$CONFIG"
# Stop fan control, if it was started
if test -s /var/run/fancontrol.pid ; then
echo -n ", stopping fan control: "
/sbin/killproc -TERM "$PFAN"
rc_status
else
echo -n ": "
fi
for i in ${!MODULE_*} ; do
eval module=\$$i
/sbin/modprobe -r $module &>/dev/null
rc_status
done
rc_status -v && rm -f $LOCK
}
dostatus() {
$PSENSORS
rc_status
}
restart() {
stop
start
rc_status
}
condrestart() {
[ -e $LOCK ] && restart || :
}
# Reset status of this service
rc_reset
# See how we were called.
case "$1" in
start)
start
;;
stop)
stop
;;
status)
dostatus
;;
restart|reload)
restart
;;
try-restart)
condrestart
;;
*)
echo "Usage: lm_sensors {start|stop|status|restart|reload|try-restart}"
exit 1
esac
rc_exit

View File

@ -1,3 +1,27 @@
-------------------------------------------------------------------
Fri Jul 24 16:14:47 CEST 2009 - jdelvare@suse.de
- lm_sensors-r5757-LPC47M233-not-supported.patch: Don't point the
user at a driver which will not work.
- lm_sensors-r5760-rename-modprobe-conf.patch: Properly name
the modprobe configuration file.
-------------------------------------------------------------------
Mon Jul 20 09:59:32 CEST 2009 - jdelvare@suse.de
- Update to lm_sensors 3.1.1
* Completely reworked sensors-detect
* Support for multiple configuration files
* New default sensors.conf file
- Include our own init script instead of patching upstream's to no
end.
- Fix init script Provides (lm_sensors instead of sensors.)
(bnc#487479)
- Fix init script lock file name.
- Stop patching prog/init/README, we no longer distribute it.
- /etc/sensors3.conf can be updated, user changes should no longer
go there.
-------------------------------------------------------------------
Sat Apr 18 22:28:52 CEST 2009 - crrodriguez@suse.de

View File

@ -1,5 +1,5 @@
#
# spec file for package sensors (Version 3.0.3)
# spec file for package sensors (Version 3.1.1)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@ -21,23 +21,21 @@
Name: sensors
BuildRequires: bison flex rrdtool-devel
Url: http://www.lm-sensors.org/
Version: 3.0.3
Release: 6
Version: 3.1.1
Release: 1
Summary: Hardware health monitoring for Linux
License: GPL v2 or later
Group: System/Monitoring
Requires: modules
AutoReqProv: on
Source0: lm_sensors-%{version}.tar.bz2
Patch: lm_sensors-3.0.2.dif
Patch1: lm_sensors-3.0.0-sensord-separate.dif
Patch2: lm_sensors-3.0.0-sysconfig_metadata.patch
Patch3: lm_sensors-r5352-fix-detection-of-ADT7463-and-LM96000.patch
Source1: lm_sensors.init
Patch1: lm_sensors-3.1.1-build.patch
Patch2: lm_sensors-3.0.0-sensord-separate.patch
Patch3: lm_sensors-3.0.0-sysconfig_metadata.patch
Patch4: lm_sensors-3.0.3-hint-at-kernel-extra-package.patch
Patch5: lm_sensors-r5366-fix-detection-of-Intel-AMB.patch
Patch6: lm_sensors-r5473-sensord-negative-temperatures-in-RRD.patch
Patch7: lm_sensors-r5580-sensord-survive-transient-errors.patch
Patch8: lm_sensors-r5581-fix-libsensors-error-propagation.patch
Patch5: lm_sensors-r5757-LPC47M233-not-supported.patch
Patch6: lm_sensors-r5760-rename-modprobe-conf.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
ExcludeArch: s390 s390x
@ -135,15 +133,12 @@ Authors:
%prep
%setup -q -n lm_sensors-%{version}
%patch
%patch1
%patch2
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch6 -p1
%patch7 -p1
%patch8 -p1
%patch5 -p1
%patch6 -p1
%build
RPM_OPT_FLAGS="$RPM_OPT_FLAGS"
@ -162,9 +157,9 @@ RPM_OPT_FLAGS="$RPM_OPT_FLAGS"
chmod -R u+rwX,g+rX,o+rX $RPM_BUILD_ROOT/%{_docdir}/sensors/
cd ../
chmod 0755 $RPM_BUILD_ROOT/%{_libdir}/libsensors.so.*
mkdir -p $RPM_BUILD_ROOT/etc/init.d
install -m 0755 prog/init/lm_sensors.init.suse $RPM_BUILD_ROOT/etc/init.d/lm_sensors
ln -sf /etc/init.d/lm_sensors $RPM_BUILD_ROOT/usr/sbin/rclm_sensors
mkdir -p $RPM_BUILD_ROOT/etc/init.d
install -m 0755 %{S:1} $RPM_BUILD_ROOT/etc/init.d/lm_sensors
ln -sf /etc/init.d/lm_sensors $RPM_BUILD_ROOT/usr/sbin/rclm_sensors
# cleanup
rm -f $RPM_BUILD_ROOT/usr/src/linux/include/sensors.h
rm -f %{buildroot}%{_libdir}/libsensors.a
@ -172,6 +167,30 @@ rm -f %{buildroot}%{_libdir}/libsensors.a
%clean
rm -rf $RPM_BUILD_ROOT
%post
sh -c '
CONFIG=/etc/sysconfig/lm_sensors
test -r "$CONFIG" || exit 0
unset ${!MODULE_*} $HWMON_MODULES
. "$CONFIG"
test -n "$HWMON_MODULES" && exit 0
for i in ${!MODULE_*} ; do
eval module=\$$i
if test -z "$HWMON_MODULES" ; then
HWMON_MODULES="$module"
else
HWMON_MODULES="$HWMON_MODULES $module"
fi
done
test -z "$HWMON_MODULES" && exit 0
echo >> "$CONFIG"
echo "# New configuration format generated by rpm post-install script" >> "$CONFIG"
echo "HWMON_MODULES=\"$HWMON_MODULES\"" >> "$CONFIG"
'
if test -e /etc/modprobe.d/lm_sensors -a ! -e /etc/modprobe.d/lm_sensors.conf ; then
mv -f /etc/modprobe.d/lm_sensors /etc/modprobe.d/lm_sensors.conf
fi
%preun
%{stop_on_removal lm_sensors}
@ -211,7 +230,7 @@ rm -rf $RPM_BUILD_ROOT
%files -n libsensors4
%defattr(-,root,root)
%config(noreplace) /etc/sensors3.conf
%config /etc/sensors3.conf
%{_libdir}/libsensors.so.4*
%doc /usr/share/man/man5/*.5.gz
@ -222,290 +241,3 @@ rm -rf $RPM_BUILD_ROOT
%doc /usr/share/man/man3/*.3.gz
%changelog
* Sat Apr 18 2009 crrodriguez@suse.de
- remove static libraries
* Sun Jan 11 2009 jdelvare@suse.de
- lm_sensors-r5473-sensord-negative-temperatures-in-RRD.patch:
Accept negative temperatures in RRD database.
- lm_sensors-r5580-sensord-survive-transient-errors.patch: Don't
bail out on transient errors.
- lm_sensors-r5581-fix-libsensors-error-propagation.patch: Fix
error propagation during expression evaluation.
- Add %%stop_on_removal to the %%preun script (fixes an RPMlint
warning.)
* Wed Oct 22 2008 jdelvare@suse.de
- lm_sensors-r5366-fix-detection-of-Intel-AMB.patch: Fix detection
of Intel 5000 series FB-DIMM AMB.
* Tue Oct 14 2008 jdelvare@suse.de
- lm_sensors-r5352-fix-detection-of-ADT7463-and-LM96000.patch: Fix
detection of ADT7463 and LM96000.
- lm_sensors-3.0.3-hint-at-kernel-extra-package.patch: Now that the
kernel package is split into 3 parts, it is possible that not all
required hwmon drivers are installed on the system when
sensors-detect is being run. Point the user to the kernel-*-extra
package if drivers are found to be missing. (bnc#431555)
* Sun Sep 28 2008 jdelvare@suse.de
- Update to lm_sensors 3.0.3
* Many improvements to pwmconfig
* sensors-detect knows of a dozen additional devices and was made
more reliable for another half dozen
* Sun May 18 2008 jdelvare@suse.de
- Update to lm_sensors 3.0.2
* Support for virtual hardware monitoring devices
* Support for power and energy sensors
* Safer sensors-detect
* FAQ is gone
* Mon May 12 2008 jdelvare@suse.de
- lm_sensors-r5235-dont-probe-I2C-addr-40-47.patch: Don't probe I2C
addresses 0x40-0x47.
- lm_sensors-r5245-skip-1-reg-only-I2C-devs.patch: Detect and skip
1-register-only I2C devices.
* Sun May 11 2008 coolo@suse.de
- fix rename of xxbit packages
* Tue Apr 29 2008 cthiel@suse.de
- fix baselibs.conf
- obsolete sensors-<arch> via baselibs.conf
* Wed Apr 16 2008 jdelvare@suse.de
- lm_sensors-r5169-parse-config-in-C-locale.patch: Parse the
configuration file in C locale.
- lm_sensors-r5175-compute-statements-override.patch: Late compute
statements should override early ones.
- lm_sensors-ignore-missing-device-link.patch: Don't choke on
hwmon devices with no device link. The new thermal zone code that
went into kernel 2.6.25-rc5-git4 creates one such hwmon device.
* Thu Apr 10 2008 ro@suse.de
- added baselibs.conf file to build xxbit packages
for multilib support
* Thu Mar 13 2008 werner@suse.de
- Remove hard coded loading of i2c-dev or better i2c-core as it
should happen due auto dependcies (bnc#369798)
* Mon Feb 04 2008 jdelvare@suse.de
- Update to lm_sensors 3.0.1
* Library no longer depends on libsysfs
* Library initialization is much faster
* Better service integration in sensors-detect
* Sat Jan 19 2008 jdelvare@suse.de
- Pass PREFIX and MANDIR on the command line from the spec file
rather than patching the Makefile. This is easier to maintain.
* Tue Dec 18 2007 jdelvare@suse.de
- Fix voltage references in sensors.conf. Fixed upstream in:
http://www.lm-sensors.org/changeset/5076
* Tue Dec 11 2007 jdelvare@suse.de
- Fix rrd support in sensord. Fixed upstream in:
http://www.lm-sensors.org/changeset/5069
* Fri Nov 30 2007 jdelvare@suse.de
- Remove obsolete Requires tags. Since version 3.0.0, it is no
longer mandatory to provide a configuration file to libsensors.
* Thu Nov 29 2007 jdelvare@suse.de
- Add missing Conflicts tag.
* Tue Nov 27 2007 jdelvare@suse.de
- Add a link to the init script.
* Mon Nov 26 2007 jdelvare@suse.de
- Update to lm_sensors version 3.0.0
* Completely rewritten library, much smaller
* Supports all devices supported by the kernel (contains no
device-specific code)
* libsensors has a new SONAME (libsensors.so.4)
* fancontrol.pl is gone
* Thu Nov 22 2007 jdelvare@suse.de
- Drop local changes to sensors-detect that are no longer relevant.
- Drop local changes to sensord.init: we no longer package it.
* Wed Nov 21 2007 jdelvare@suse.de
- Add missing Requires to libsensors3-devel. This is a cosmetic
change only, as the requirement was already drawn indirectly.
* Mon Nov 05 2007 jdelvare@suse.de
- Add split provides to subpackages libsensors3-devel and sensord
so that an update will work as designed.
* Fri Nov 02 2007 jdelvare@suse.de
- Fix two rpmlint warnings. One of them was about a missing
dependency between libsensors3-devel and libsensors3, which was
breaking the build of other packages.
* Fri Nov 02 2007 jdelvare@suse.de
- Package libsensors separately. I've named the package
"libsensors3" because it is going to fade out quickly in favor
of the new, incompatible version from lm-sensors 3.
- Don't remove the build root before installing. rpmlint was
compaining about that.
* Thu Nov 01 2007 jdelvare@suse.de
- Fix packaging breakage introduced by the following change:
ppc and ia64 packages do not include isadump nor isaset.
* Wed Oct 31 2007 jdelvare@suse.de
- Package sensord separately.
- Don't include redundant or outdated initalization scripts in
the documentation tree.
* Sun Oct 28 2007 jdelvare@suse.de
- Update to lm_sensors version 2.10.5
* Support for the SMSC SCH3112, SCH3114, SCH3116
* libsensors fixes for the thmc50, bmcsensors, lm93, adm1026
drivers
* sensord support for the w83793 and lm87 drivers
* sensors fixes for the dme1737, thmc50 and adm1021 drivers
* Detect new Winbond chips
- useful_addresses.html is no longer part of the package.
- lm_sensors-dont-probe-i2c-isa.dif: Drop, bug fixed upstream.
* Mon Oct 15 2007 jdelvare@suse.de
- Do not include i2c tools, they have their own package now.
* Mon Sep 03 2007 jdelvare@suse.de
- Run ldconfig in %%post and %%postun. rpmlint was complaining
that this was missing.
* Tue Aug 28 2007 werner@suse.de
- Remove hard coded modules introduced by last change
* Tue Aug 14 2007 hvogel@suse.de
- Add sysconfig metadata [#300069]
* Mon Aug 13 2007 jdelvare@suse.de
- Don't probe i2c-isa as a regular i2c bus. This regression was
introduced in lm_sensors 2.10.4. Fixed upstream in:
http://www.lm-sensors.org/changeset/4649
* Wed Aug 01 2007 werner@suse.de
- Update to lm_sensors version 2.10.4
* added support for recent devices and cips like
dme1737, applesmc, abituguru3, f71882fg, w83627ehf (kernel 2.4)
support for the w83627ehf VID function
support for the w83627ehf thermal sensor types
support for it87 fan4 and fan5
* support block reads with specified length of I2C devices
* A lot of fixes and enhancements
* Add both patches form us for fancontrol and pwmconfig
* Wed Jun 27 2007 jdelvare@suse.de
- Don't package the decode-edid.pl script. It requires parse-edid
from the read-edid package, which isn't included in Suse.
* Thu Jun 21 2007 dmueller@suse.de
- adjust buildrequires
* Mon Jun 04 2007 jdelvare@suse.de
- Don't build on s390 nor s390x.
* Mon May 28 2007 jdelvare@suse.de
- Fix two rpmlint errors: /etc/init.d/lm_sensors shouldn't be
marked as a config file, and was missing a Short-Description
tag.
* Wed May 09 2007 jdelvare@suse.de
- lm_sensors-no-xeon-script.patch: The decode-xeon.pl script is
outdated. It was never ported to work with 2.6 kernels, so it is
of no use on recent Suse distributions. Stop shipping it.
- Drop a legacy patch to sensors/main.c related to the
configuration file name, which is no longer needed.
* Fri May 04 2007 jdelvare@suse.de
- Don't package outdated driver documentation. The up-to-date
driver documentation is in the kernel-source package.
(bug #271302)
- Two minor cleanups to the spec file.
* Thu Apr 12 2007 jdelvare@suse.de
- lm_sensors-2.8.3-nodump.patch: Removed, should no longer be
needed. Since lm_sensors 2.8.6, isadump is only compiled on i386
and x86_64.
- Likewise, no need to patch prog/dump/isadump.c for powerpc,
as it won't be compiled for these architectures anyway.
* Thu Apr 05 2007 werner@suse.de
- Update to lm_sensors version 2.10.3 which added support for
recent devices and support for kernel 2.6.22.
* Thu Mar 29 2007 ro@suse.de
- added bison,flex to buildreq
* Mon Feb 19 2007 werner@suse.de
- Make README.SuSE encoding independend (bug #246130)
* Tue Jan 30 2007 werner@suse.de
- Update to lm_sensors version 2.10.2 which added support for
recent devices.
* Mon Nov 13 2006 werner@suse.de
- Update to lm_sensors version 2.10.1 which also includes the
fix for bug #192092 by not overwriting chip settings
- Remove notify warn message from pdb about overwriting settings
* Mon Jun 26 2006 werner@suse.de
- Load i2c-dev kernel module instead of i2c-sensor (bug #188126)
* Tue Feb 28 2006 werner@suse.de
- Update to version 2.10.0 for better udev support (bug #151931)
- Add i2c-0 to static device list for udev (bug #151931)
* Wed Jan 25 2006 mls@suse.de
- converted neededforbuild to BuildRequires
* Wed Jan 11 2006 werner@suse.de
- Include fan control in lm_sensors service script (bug #141958)
* Tue Dec 13 2005 werner@suse.de
- Do not to handle module variables from package Modules (#137963)
* Thu Nov 10 2005 werner@suse.de
- Add postun section to run insserv_clean (bug #132934)
* Fri Oct 14 2005 werner@suse.de
- Update to lm_sensors version 2.9.2
* Thu Aug 25 2005 werner@suse.de
- Security fix in pwmconfig (bug #112925)
* Wed May 11 2005 schwab@suse.de
- Add freetype2 and libart_lgpl to nfb, needed by rrdtool.
* Mon May 09 2005 werner@suse.de
- Update to lm_sensors-2.9.1
- Use insserv to enable rc script (bug #76174)
* Thu Feb 17 2005 werner@suse.de
- Update to lm_sensors-2.9.0 (bug #50681)
* Mon Aug 30 2004 werner@suse.de
- Update to newest lm_sensors-2.8.7 to be compatible to the current
kernel version.
* Tue May 04 2004 werner@suse.de
- Fix bug #35502 (missing w83627hf entries) by updating to
lm_sensors-2.8.6 which includes a better parser for sysfs
* Tue Apr 13 2004 ro@suse.de
- remove kernel-source from neededforbuild
(not needed any longer)
* Wed Mar 10 2004 werner@suse.de
- Add workaround for missing w83627hf chip driver (bug #35501)
* Tue Mar 09 2004 werner@suse.de
- A few changes for kernel 2.6 (bug #35500)
* Fri Mar 05 2004 pth@suse.de
- Remove no-strict-aliasing and fix the code instead. Patch
was also sent to upstream maintainers for inclusion.
* Fri Mar 05 2004 ro@suse.de
- added libpng to neededforbuild (for rrdtool)
- use no-strict-aliasing
* Wed Jan 28 2004 ro@suse.de
- update to 2.8.3
- use buildroot and build as user
* Fri Sep 12 2003 ro@suse.de
- configure kernel-source if needed
* Mon Jul 21 2003 werner@suse.de
- Update to lm_sensors 2.8.0
* Thu Jun 05 2003 ro@suse.de
- compile using headers from kernel-source not glibc
* Wed Mar 19 2003 olh@suse.de
- add lm_sensors-2.7.0-nodump.patch to fix dependency tree
* Thu Feb 27 2003 werner@suse.de
- Fix location of sensors program in boot script
* Tue Feb 11 2003 werner@suse.de
- Update due to kernel interface update (anything else is a bug)
* Mon Dec 02 2002 werner@suse.de
- Update to lm_sensors 2.4.6
* Wed Nov 06 2002 werner@suse.de
- Fix bug # 21583: sensors shouldn't segfault on missing argument.
* Wed Sep 04 2002 werner@suse.de
- Fix boot scripts to be usable (bug #18868)
- Install some progs which are described in FAQ
* Wed Aug 28 2002 fehr@suse.de
- updated to current version 2.6.4 of lm_sensors
* Thu Aug 01 2002 werner@suse.de
- Use _libdir macro for 64bit architectures
* Wed Jul 31 2002 werner@suse.de
- Install sensord daemon for logging (bug #17316)
* Tue Jun 18 2002 ke@suse.de
- Fix typo in README.SuSE [# 14790].
* Mon Aug 06 2001 uli@suse.de
- fixed to build on PPC
* Wed Jul 04 2001 werner@suse.de
- update to 2.6.0
* Mon Apr 16 2001 werner@suse.de
- update to 2.5.5
* Thu Apr 05 2001 uli@suse.de
- removed lx_suse from neededforbuild
* Thu Dec 14 2000 werner@suse.de
- Group tag
* Mon Jun 19 2000 ro@suse.de
- update to 2.5.0
* Wed Jun 07 2000 uli@suse.de
- moved docs to %%{_docdir}
* Fri Feb 11 2000 ro@suse.de
- removed requires kernmod (package eliminated)
* Wed Feb 02 2000 werner@suse.de
- No asm/io.h if sys/io.h is included
* Wed Feb 02 2000 werner@suse.de
- No sys/perm.h or sys/io.h on ppc and sparc
* Tue Feb 01 2000 werner@suse.de
- New package sensors (version 2.4.3 corresponds with
current used kernel i2c patch)
- Prefix is /usr, mandir is /usr/share/man, and kernel
includes i2c
- Be reentrant
- Use RPM_OPT_FLAGS
- Install docs of busses, chips and the FAQ