--- /dev/null
+--- nut-2.7.4/tools/nut-scanner/Makefile.am~ 2015-12-29 13:08:34.000000000 +0100
++++ nut-2.7.4/tools/nut-scanner/Makefile.am 2017-07-28 12:01:22.623458373 +0200
+@@ -15,7 +15,7 @@ libnutscan_la_SOURCES = scan_nut.c scan_
+ ../../drivers/serial.c \
+ ../../drivers/bcmxcp_ser.c \
+- ../../common/common.c
++ ../../common/common.c ../../common/str.c
+ libnutscan_la_LIBADD = $(NETLIBS) $(LIBLTDL_LIBS)
+ libnutscan_la_LDFLAGS = $(SERLIBS) -version-info 1:0:0
+ libnutscan_la_CFLAGS = -I$(top_srcdir)/clients -I$(top_srcdir)/include $(LIBLTDL_CFLAGS) -I$(top_srcdir)/drivers
+
-diff -Nuard nut-2.0.1.orig/conf/upsmon.conf nut-2.0.1/conf/upsmon.conf
---- nut-2.0.1.orig/conf/upsmon.conf 2004-10-26 11:50:12.410074640 +0200
-+++ nut-2.0.1/conf/upsmon.conf.sample 2004-10-26 11:51:12.681911928 +0200
-@@ -27,7 +27,7 @@
- #
- # This user should not have write access to upsmon.conf.
- #
--# RUN_AS_USER nut
-+# RUN_AS_USER ups
-
- # --------------------------------------------------------------------------
- # MONITOR <system> <powervalue> <username> <password> ("master"|"slave")
diff -Nuard nut-2.0.1.orig/conf/upssched.conf nut-2.0.1/conf/upssched.conf
--- nut-2.0.1.orig/conf/upssched.conf 2004-10-26 11:50:12.410074640 +0200
+++ nut-2.0.1/conf/upssched.conf.sample.in 2004-10-26 11:50:23.295419816 +0200
+# AT COMMBAD * START-TIMER upsgone 10
+# AT COMMOK * CANCEL-TIMER upsgone
--- nut-2.2.0/conf/upsmon.conf.sample.orig 2007-07-26 11:15:08.152047877 +0000
-+++ nut-2.2.0/conf/upsmon.conf.sample 2007-07-26 11:17:20.131913520 +0000
++++ nut-2.2.0/conf/upsmon.conf.sample.in 2007-07-26 11:17:20.131913520 +0000
@@ -126,7 +126,7 @@
# information and ideas, see pager.txt in the docs directory.
#
# Example:
--# NOTIFYCMD /usr/local/ups/bin/notifyme
+-# NOTIFYCMD @BINDIR@/notifyme
+# NOTIFYCMD /usr/sbin/upssched
# --------------------------------------------------------------------------
Summary: Network UPS Tools
Summary(pl.UTF-8): Sieciowe narzędzie do UPS-ów
Name: nut
-Version: 2.7.2
-Release: 4
+Version: 2.7.4
+Release: 1
License: GPL
Group: Applications/System
Source0: http://www.networkupstools.org/source/2.7/%{name}-%{version}.tar.gz
-# Source0-md5: c3568b42e058cfc385b46d25140dced4
+# Source0-md5: 3ba53656933d7471f95140b32a5b8d5c
Source1: %{name}.init
Source2: %{name}.sysconfig
Source3: %{name}-upsmon.init
Patch4: %{name}-matrix.patch
Patch5: systemd-sysconfig.patch
Patch6: bcmxcp-off-by-one.patch
+Patch7: %{name}-build.patch
URL: http://www.networkupstools.org/
BuildRequires: autoconf
BuildRequires: automake
%patch4 -p1
%patch5 -p1
%patch6 -p1
+%patch7 -p1
%build
cp -f /usr/share/automake/config.sub .
mv -f $i ${i%.sample}
done
-%{!?with_usb:rm -f $RPM_BUILD_ROOT%{_udevrulesdir}/52-nut-usbups.rules}
+%{!?with_usb:rm -f $RPM_BUILD_ROOT%{_udevrulesdir}/62-nut-usbups.rules}
cat > $RPM_BUILD_ROOT/sbin/poweroff-ups << EOF
#!/bin/sh
%{?with_usb:%{_mandir}/man8/tripplite_usb.8*}
%{?with_usb:%{_mandir}/man8/usbhid-ups.8*}
%{_mandir}/man8/victronups.8*
-%{?with_usb:%config(noreplace) %verify(not md5 mtime size) %{_udevrulesdir}/52-nut-usbups.rules}
+%{?with_usb:%config(noreplace) %verify(not md5 mtime size) %{_udevrulesdir}/62-nut-usbups.rules}
%config(noreplace) %verify(not md5 mtime size) %{_udevrulesdir}/52-nut-ipmipsu.rules
%files common
--- nut-2.6.5/configure.ac~ 2012-08-06 14:37:36.000000000 +0200
+++ nut-2.6.5/configure.ac 2013-01-13 12:42:30.807862312 +0100
-@@ -986,9 +986,8 @@
+@@ -1066,7 +1066,7 @@ dnl Override installation directory, wit
dnl prefix. This is needed for 'distcheck*' targets, otherwise
dnl files will try to get intalled to the actual system directories
if test -n "${systemdsystemunitdir}"; then
- systemdsystemshutdowndir="${libdir}/systemd/system-shutdown"
+ systemdsystemshutdowndir="/lib/systemd/system-shutdown"
AC_MSG_RESULT(using ${systemdsystemunitdir})
-- systemdsystemunitdir="`echo ${systemdsystemunitdir} | sed 's/\/lib/\${libdir}/'`"
else
AC_MSG_RESULT(no)
- fi
+