From 467b1ba352dfd8d677d2973e6fbe13b9a4b63bd3 Mon Sep 17 00:00:00 2001 From: Michal Hlavinka Date: Sep 16 2011 08:37:27 +0000 Subject: nut updated to 2.6.2 --- diff --git a/.gitignore b/.gitignore index 8fccae2..2f16145 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ nut-2.4.3.tar.gz /nut-2.6.0.tar.gz /nut-2.6.1.tar.gz +/nut-2.6.2.tar.gz diff --git a/nut-2.6.1-systemd.patch b/nut-2.6.1-systemd.patch deleted file mode 100644 index 8837195..0000000 --- a/nut-2.6.1-systemd.patch +++ /dev/null @@ -1,143 +0,0 @@ -diff -up trunk/configure.in.systemd trunk/configure.in ---- trunk/configure.in.systemd 2011-05-17 17:29:41.324531001 +0200 -+++ trunk/configure.in 2011-05-17 17:29:59.179678460 +0200 -@@ -26,6 +26,8 @@ dnl Use "./configure --enable-maintainer - dnl in sync after SVN updates. - AM_MAINTAINER_MODE - -+dnl PKG_PROG_PKG_CONFIG -+ - dnl # the following is commented out, because the UPS_VERSION macro now - dnl # resides in include/nut_version.h, which is generated by Makefile.am, - dnl # rather than in include/config.h, which is generated by configure. The -@@ -784,6 +786,31 @@ else - fi - AM_CONDITIONAL(WITH_PKG_CONFIG, test -n "${pkgconfigdir}") - -+PKG_PROG_PKG_CONFIG -+systemdsystemunitdir=`$PKG_CONFIG --variable=systemdsystemunitdir systemd` -+AC_MSG_CHECKING(whether to install systemd files) -+AC_ARG_WITH([systemdsystemunitdir], -+ AS_HELP_STRING([--with-systemdsystemunitdir=DIR], [Directory for systemd service files (auto)]), -+[ -+ case "${withval}" in -+ yes|auto) -+ ;; -+ no) -+ systemdsystemunitdir="" -+ ;; -+ *) -+ systemdsystemunitdir="${withval}" -+ ;; -+ esac -+], []) -+if test -n "${systemdsystemunitdir}"; then -+ systemdsystemshutdowndir="/lib/systemd/system-shutdown" -+ AC_MSG_RESULT(using ${systemdsystemunitdir}) -+else -+ AC_MSG_RESULT(no) -+fi -+AM_CONDITIONAL(HAVE_SYSTEMD, test "$systemdsystemunitdir" != "") -+ - AC_MSG_CHECKING(whether to install hotplug rules) - AC_ARG_WITH(hotplug-dir, - AS_HELP_STRING([--with-hotplug-dir=PATH], [where to install hotplug rules (/etc/hotplug)]), -@@ -903,6 +930,8 @@ AC_SUBST(cgiexecdir) - AC_SUBST(driverexecdir) - AC_SUBST(htmldir) - AC_SUBST(pkgconfigdir) -+AC_SUBST(systemdsystemunitdir) -+AC_SUBST(systemdsystemshutdowndir) - AC_SUBST(hotplugdir) - AC_SUBST(udevdir) - -diff -up trunk/m4/nut_check_os.m4.systemd trunk/m4/nut_check_os.m4 ---- trunk/m4/nut_check_os.m4.systemd 2011-05-17 17:28:58.555176955 +0200 -+++ trunk/m4/nut_check_os.m4 2011-05-17 17:29:59.180678469 +0200 -@@ -44,6 +44,7 @@ AC_DEFUN_ONCE([NUT_OS_FUNCTIONS], - - AC_DEFUN([NUT_CHECK_OS], - [ -+ m4_pattern_allow([^PKG_TARGET$]) - # Look for all possible source of OS name resolution - # 1) we look for a LSB release info file - eval "dist_search_path=\" -diff -up trunk/Makefile.am.systemd trunk/Makefile.am ---- trunk/Makefile.am.systemd 2011-05-17 17:29:41.340531132 +0200 -+++ trunk/Makefile.am 2011-07-22 10:30:46.614970524 +0200 -@@ -52,6 +52,24 @@ website: - @echo "Not building website since 'asciidoc' was not found." - endif !HAVE_ASCIIDOC - -+if HAVE_SYSTEMD -+%.service: %.service.in -+ sed -e 's,@sbindir\@,$(sbindir),g' $< > $@ -+ -+nutshutdown: nutshutdown.in -+ sed -e 's,@sbindir\@,$(sbindir),g' $< > $@ -+ -+systemdsystemunit_DATA = \ -+ nut-driver.service \ -+ nut-monitor.service \ -+ nut-server.service -+ -+systemdsystemshutdown_PROGRAMS = nutshutdown -+ -+else -+EXTRA_DIST += nut-driver.service.in nut-monitor.service.in nut-server.service.in nutshutdown -+endif -+ - # ---------------------------------------------------------------------- - # targets from old build system (pre-automake). - # supported for a period of time for backward "compatibility". -diff -up trunk/nut-driver.service.in.systemd trunk/nut-driver.service.in ---- trunk/nut-driver.service.in.systemd 2011-05-17 17:29:59.181678477 +0200 -+++ trunk/nut-driver.service.in 2011-07-22 10:28:44.783107095 +0200 -@@ -0,0 +1,10 @@ -+[Unit] -+Description=Network UPS Tools - power device driver controller -+After=local-fs.target network.target -+StopWhenUnneeded=yes -+ -+[Service] -+ExecStart=/sbin/upsdrvctl start -+ExecStop=/sbin/upsdrvctl stop -+Type=forking -+ -diff -up trunk/nut-monitor.service.in.systemd trunk/nut-monitor.service.in ---- trunk/nut-monitor.service.in.systemd 2011-05-17 17:29:59.181678477 +0200 -+++ trunk/nut-monitor.service.in 2011-07-22 10:28:14.757894331 +0200 -@@ -0,0 +1,11 @@ -+[Unit] -+Description=Network UPS Tools - power device monitor and shutdown controller -+After=local-fs.target network.target nut-server.service -+ -+[Service] -+ExecStart=/usr/sbin/upsmon -+PIDFile=/var/run/nut/upsmon.pid -+Type=forking -+ -+[Install] -+WantedBy=multi-user.target -diff -up trunk/nut-server.service.in.systemd trunk/nut-server.service.in ---- trunk/nut-server.service.in.systemd 2011-05-17 17:29:59.180678469 +0200 -+++ trunk/nut-server.service.in 2011-07-22 10:27:54.475750633 +0200 -@@ -0,0 +1,12 @@ -+[Unit] -+Description=Network UPS Tools - power devices information server -+After=local-fs.target network.target nut-driver.service -+Requires=nut-driver.service -+Before=nut-monitor.service -+ -+[Service] -+ExecStart=/usr/sbin/upsd -+Type=forking -+ -+[Install] -+WantedBy=multi-user.target -diff -up trunk/nutshutdown.in.systemd trunk/nutshutdown.in ---- trunk/nutshutdown.in.systemd 2011-05-17 17:29:59.182678485 +0200 -+++ trunk/nutshutdown.in 2011-05-17 17:29:59.182678485 +0200 -@@ -0,0 +1,2 @@ -+#!/bin/sh -+upsmon -K >/dev/null 2>&1 && upsdrvctl shutdown diff --git a/nut.spec b/nut.spec index 411c7b6..16b752a 100644 --- a/nut.spec +++ b/nut.spec @@ -13,8 +13,8 @@ Summary: Network UPS Tools Name: nut -Version: 2.6.1 -Release: 4%{?dist} +Version: 2.6.2 +Release: 1%{?dist} Group: Applications/System License: GPLv2+ Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -22,9 +22,6 @@ Url: http://www.networkupstools.org/ Source: http://www.networkupstools.org/source/2.6/%{name}-%{version}.tar.gz Source3: nut-client.tmpfiles -# add systemd support -Patch1: nut-2.6.1-systemd.patch - Requires(pre): shadow-utils udev Requires(post): fileutils chkconfig Requires(postun): fileutils chkconfig @@ -50,6 +47,7 @@ BuildRequires: pkgconfig BuildRequires: powerman-devel BuildRequires: python-devel BuildRequires: desktop-file-utils +BuildRequires: freeipmi-devel %ifnarch s390 s390x BuildRequires: libusb-devel @@ -108,7 +106,6 @@ necessary to develop NUT client applications. %prep %setup -q -%patch1 -p1 -b .systemd sed -i 's|=NUT-Monitor|=nut-monitor|' scripts/python/app/nut-monitor.desktop sed -i "s|sys.argv\[0\]|'%{_datadir}/%{name}/nut-monitor/nut-monitor'|" scripts/python/app/NUT-Monitor sed -i 's|LIBSSL_LDFLAGS|LIBSSL_LIBS|' lib/libupsclient-config.in @@ -171,7 +168,9 @@ do done popd +#fix collision with virtualbox mv %{buildroot}/lib/udev/rules.d/52-nut-usbups.rules %{buildroot}/lib/udev/rules.d/62-nut-usbups.rules +mv %{buildroot}/lib/udev/rules.d/52-nut-ipmipsu.rules %{buildroot}/lib/udev/rules.d/62-nut-ipmipsu.rules #pushd %{buildroot} # fix encoding @@ -339,19 +338,36 @@ rm -rf %{buildroot} %config(noreplace) %attr(640,root,nut) %{_sysconfdir}/ups/upsd.conf %config(noreplace) %attr(640,root,nut) %{_sysconfdir}/ups/upsd.users %attr(644,root,root) /lib/udev/rules.d/62-nut-usbups.rules +%attr(644,root,root) /lib/udev/rules.d/62-nut-ipmipsu.rules %{modeldir}/* %exclude %{modeldir}/netxml-ups /lib/systemd/system/nut-driver.service /lib/systemd/system/nut-server.service %{_sbindir}/upsd +%{_bindir}/nut-scanner %{_bindir}/upslog +%{_libdir}/libnutscan.so.* %{_datadir}/%{name}/cmdvartab %{_datadir}/%{name}/driver.list +%{_mandir}/man3/nutscan_add_device_to_device.3.gz +%{_mandir}/man3/nutscan_add_option_to_device.3.gz +%{_mandir}/man3/nutscan_cidr_to_ip.3.gz +%{_mandir}/man3/nutscan_display_parsable.3.gz +%{_mandir}/man3/nutscan_display_ups_conf.3.gz +%{_mandir}/man3/nutscan_free_device.3.gz +%{_mandir}/man3/nutscan_new_device.3.gz +%{_mandir}/man3/nutscan_scan_avahi.3.gz +%{_mandir}/man3/nutscan_scan_ipmi.3.gz +%{_mandir}/man3/nutscan_scan_nut.3.gz +%{_mandir}/man3/nutscan_scan_snmp.3.gz +%{_mandir}/man3/nutscan_scan_usb.3.gz +%{_mandir}/man3/nutscan_scan_xml_http.3.gz %{_mandir}/man5/nut.conf.5.gz %{_mandir}/man5/ups.conf.5.gz %{_mandir}/man5/upsd.conf.5.gz %{_mandir}/man5/upsd.users.5.gz %{_mandir}/man8/apcsmart.8.gz +%{_mandir}/man8/apcsmart-old.8.gz %{_mandir}/man8/bcmxcp.8* %{_mandir}/man8/bcmxcp_usb.8.gz %{_mandir}/man8/belkin.8.gz @@ -377,6 +393,8 @@ rm -rf %{buildroot} %{_mandir}/man8/mge-utalk.8.gz %{_mandir}/man8/mge-shut.8.gz %{_mandir}/man8/nutupsdrv.8.gz +%{_mandir}/man8/nut-ipmipsu.8.gz +%{_mandir}/man8/nut-scanner.8.gz %{_mandir}/man8/oneac.8.gz %{_mandir}/man8/optiups.8.gz %{_mandir}/man8/powercom.8.gz @@ -454,9 +472,13 @@ rm -rf %{buildroot} %{_includedir}/* %{_mandir}/man3/upscli* %{_libdir}/libupsclient.so +%{_libdir}/libnutscan.so %{_libdir}/pkgconfig/libupsclient.pc %changelog +* Fri Sep 16 2011 Michal Hlavinka - 2.6.2-1 +- nut updated to 2.6.2 + * Tue Aug 16 2011 Michal Hlavinka - 2.6.1-4 - update requirements of packages diff --git a/sources b/sources index 3f392fc..74cedf7 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -89e6405272cc82c53d7b84160945761b nut-2.6.1.tar.gz +f6d0683e51e0fcab06e6a79724685d26 nut-2.6.2.tar.gz