aboutsummaryrefslogtreecommitdiff
path: root/net/nut/Makefile
Commit message (Collapse)AuthorAge
* nut: avoid picking up libi2c dependencyEneas U de Queiroz2022-09-17
| | | | | | | | | Add --without-linux-i2c to configure arguments to avoid using i2c if found in the staging dir. Switch to AUTORELEASE. Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
* nut: update to 2.8.0Eric Luehrsen2022-09-10
| | | | | | | | | | -- Release Message Snippet https://networkupstools.org/ -- After a long and windy trip since the last official release v2.7.4 half a dozen years ago ... NUT v2.8.0! ... the new release includes numerous new drivers, sub-drivers, protocols and bug-fixes, with many companies and individuals chipping in with contributions of code. ... Signed-off-by: Eric Luehrsen <ericluehrsen@gmail.com>
* nut: add cable type nut driver configRob J. Epping2022-05-13
| | | | | | | | | | at least driver apcsmart-old (maybe more) allow for specifying the type of cable used. My old UPS does will not function when cable type is not specified. This will add support for configuration option 'cable' Signed-off-by: Rob J. Epping <epping@renf.us>
* nut: fix build on macosSergey V. Lobanov2022-01-31
| | | | | | | | | | | | | | | | | | | | | nut build fails on macos due to: 1. configure script can not use AR env var due to OpenWrt build system provides only executable name (e.g. aarch64-openwrt-linux-musl-gcc-ar) but configure script checks if AR has '/'. As a result, configure script ignores AR env var and uses system `ar` but macos `ar` is not compatible with the objects generated by OpenWrt GCC toolchain. This commit explicitly sets ac_cv_path_AR=$(TARGET_AR) to use OpenWrt toolchain AR. 2. configure script detects if build host is macos and adds macosx_ups driver as a build target, but this driver can not be build with OpenWrt toolchain because OpenWrt is Linux. This commit explicitly disables macosx_ups driver using configure flag --without-macosx_ups Signed-off-by: Sergey V. Lobanov <sergey@lobanov.in>
* nut: refactor upssched uci-defaults scriptPascal Coudurier2022-01-11
| | | | | | | | | Add checks not to overwrite defaultnotify options in the nut-sendmail-notify fashion. Use lists for defaultnotify instead of option. Add check not to overwrite notifycmd if already defined. upssched-cmd script must not be called directly, it is called by the upssched binary with needed arguments. Signed-off-by: Pascal Coudurier <coudu@wanadoo.fr>
* nut: refactor nut-monitor uci config filePascal Coudurier2022-01-11
| | | | | | | | Convert notifyflags options to lists as supported by the init script, so multiple options can be chosen. Add SYSLOG default option to individuals notifyflags instead of deprecated flag 1|0. Add comment for defaultnotify and individuals notifyflags about possible values. Signed-off-by: Pascal Coudurier <coudu@wanadoo.fr>
* nut: fix typo in nut-monitor init scriptPascal Coudurier2022-01-11
| | | | | | This fixes a typo in the nut-monitor init script when building config file from uci config. Signed-off-by: Pascal Coudurier <coudu@wanadoo.fr>
* nut: Add the option to compile Nut NetXML drivers with the Nut package.Seb Belcher2021-09-23
| | | | | | Also modifies the nut-server init script to include options specific to the netxml driver. Signed-off-by: Seb Belcher <sdjbelcher@gmail.com>
* nut: fix compilation with GCC11Rosen Penev2021-07-07
| | | | | | | nut is a C++98 project which does not compile with GCC11's default of C++17. Signed-off-by: Rosen Penev <rosenp@gmail.com>
* nut: fix typo in nutshutdown scriptSven Roederer2021-04-03
| | | | | | | | Even it's only cosmetic and should not affect the function of regular system, fix the name of the IPKG_INSTROOT variable. Typo was added long ago with 8400c9a6ec799. Signed-off-by: Sven Roederer <devel-sven@geroedel.de>
* nut: fix _ handlingRosen Penev2020-09-19
| | | | | | Taken from https://github.com/openwrt/packages/issues/13359 Signed-off-by: Rosen Penev <rosenp@gmail.com>
* treewide: Remove myself as maintainerDaniel F. Dickinson2020-03-20
| | | | | | | | | | Life changes, I'm no longer avaiable to be an sufficiently active OpenWrt developer. Therefore removing myself from maintainer from all packages I maintained in OpenWrt. All the best for those who keep up the good work! Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: fix other/otherflag custom variables in nut-server.initMatt Merhar2020-01-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows custom config parameters to be added to the generated config files, enabling the original intended functionality per https://openwrt.org/docs/guide-user/services/ups/software.nut. Example usage from /etc/config/nut_server: config driver 'apc' option driver 'snmp-ups' option snmp_version 'v3' option port '172.16.100.5' list other 'secLevel' list other 'secName' list other 'authPassword' list otherflag 'notransferoids' config other 'other_secLevel' option value 'authNoPriv' config other 'other_secName' option value 'some_username' config other 'other_authPassword' option value 'some_password' config other 'otherflag_notransferoids' option value '1' Signed-off-by: Matt Merhar <mattmerhar@protonmail.com>
* nut: update OpenSSL 1.1.0 patchSebastian Kemper2019-11-27
| | | | | | | | Replaces OpenWrt patch with upstream patch. Also removes 0002-Fix-check-for-empty-string.patch as this is included in upstream OpenSSL 1.1.0 patch. Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
* nut: fix CGI setupSebastian Kemper2019-11-27
| | | | | | | | | | | | | | | This commit makes - the libgd dependency (as well as specifying libs and includes) - the configure argument "--with-cgi" dependant on whether the package nut-web-cgi is selected. nut-web-cgi is also added to PKG_CONFIG_DEPENDS. Resolves: #10641 Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net>
* treewide: Use default PKG_BUILD_DIR when possibleJeffery To2019-10-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This removes lines that set PKG_BUILD_DIR when the set value is no different from the default value. Specifically, the line is removed if the assigned value is: * $(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION) The default PKG_BUILD_DIR was updated[1] to incorporate BUILD_VARIANT if it is set, so now this is identical to the default value. * $(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_SOURCE_SUBDIR) if PKG_SOURCE_SUBDIR is set to $(PKG_NAME)-$(PKG_VERSION), making it the same as the previous case * $(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) This is the same as the default PKG_BUILD_DIR when there is no BUILD_VARIANT. * $(BUILD_DIR)/[name]-$(PKG_VERSION) where [name] is a string that is identical to PKG_NAME [1]: https://git.openwrt.org/?p=openwrt/openwrt.git;a=commit;h=e545fac8d968864a965edb9e50c6f90940b0a6c9 Signed-off-by: Jeffery To <jeffery.to@gmail.com>
* nut: Switch to pkgconfig for finding libgdRosen Penev2019-09-13
| | | | | | | | nut uses gdlib-config to find libgd, which happens to be deprecated. This switches it to use pkgconfig and allows a fallback to gdlib-config, same as the libusb check. Signed-off-by: Rosen Penev <rosenp@gmail.com>
* treewide: Change .*GPL.*+ licenses to SPDX compatible identifierSven Eckelmann2019-09-10
| | | | | | | | The CONTRIBUTING.md requests an (or multiple) SPDX identifier for GPL licenses. But a lot of packages did use a different, non-SPDX style with a "+" at the end instead of "-or-later". Signed-off-by: Sven Eckelmann <sven@narfation.org>
* nut: Actually do FSD when requiredDaniel F. Dickinson2019-04-28
| | | | | | | | The code was all there but the call do the function containing it was missing, so call the function so that forced (UPS) shutdown occurs on a battery critical or manually requested FSD situation. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: initscripts hotplug: Fix many small semantic issuesDaniel F. Dickinson2019-01-20
| | | | | | | | Small but important tweaks to fix the operation of the nut initscripts and hotplug scripts. All hail shellcheck and proofreading and dogfooding. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Fix procd crashloop no interfacesDaniel F. Dickinson2019-01-07
| | | | | | | Fix a crashloop under procd when attempting to bind to any address when no interfaces are yet available. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Bump PKG_RELEASEDaniel F. Dickinson2018-12-23
| | | | Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Optionally set serial USB to NUT userDaniel F. Dickinson2018-12-06
| | | | | | | | | When using serial-port based UPSes with NUT, it is handy to be able to configure a USB serial port to have be set tot the NUT runas user, so that NUT can access the serial port automagically. Closes #6997 Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Fix upsd runs as rootDaniel F. Dickinson2018-12-06
| | | | | | | | | | Closes #6997 - Allows upsd to runas a non-privileged user. If any driver is running as non-privileged user, the last driver's user will be used as the server non-privileged user, otherwise the user specified in config upsd, otherwise nut. Previously the localisation of RUNAS variable was in the wrong locations. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Fix a typo in setting a driver parameterDaniel F. Dickinson2018-12-06
| | | | | | synchronous would not get set due to typo. Fixed. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Bump PKG_RELEASEDaniel F. Dickinson2018-11-19
| | | | Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Fix undetected UPS hardwareDaniel F. Dickinson2018-11-19
| | | | | | | | Leading zeroes left in ProductId results in some UPS hardware not being matched by the hotplug script lead to bad permissions and driver not starting. Closes: #6966 Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: bump PKG_RELEASEDaniel F. Dickinson2018-08-29
| | | | Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Remove duplicate/extraneous linesDaniel F. Dickinson2018-08-29
| | | | | | Removes a duplicate directory creation and a stray newline. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Makefile: Fix typo in descriptionDaniel F. Dickinson2018-08-29
| | | | | | Cosmetic edit. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Fix license informationDaniel F. Dickinson2018-08-29
| | | | | | | | | | The source code has multiple licenses so update SPD-X header. NB: The previously unlisted licenses are not applicable to parts actually built in any configuration for OpenWrt, but rather to unused (by us) source code. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Avoid building docsDaniel F. Dickinson2018-08-29
| | | | | | | Reduce compilation time and complexity by not building documentation we don't use. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Drop unnecessary dependency on libwrapDaniel F. Dickinson2018-08-29
| | | | | | | We're using --without-wrap unconditionally anyway, so this legacy dependency needs to be removed. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Use diff non-privileged user for upsmonDaniel F. Dickinson2018-08-29
| | | | | | | | By default use a non-privileged user that is different than the server or driver (when they are running non-privileged). This is recommended by upstream. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: nut-cgi: Add support for upssetDaniel F. Dickinson2018-08-29
| | | | | | | This allows config for setting variables and/or running commands from the CGI. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Make FSD really workDaniel F. Dickinson2018-08-29
| | | | | | | | Forced shutdown of the UPS was not actually happening before due to lack of specific commands doing the shutdown. This (and the nut-driver initscript) fix that. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Add USB hotplug supportDaniel F. Dickinson2018-08-29
| | | | | | | | usbhid-ups has the necessary information in the source, so let's support USB hotplugging out of the box. Takes advantage of the procd support now in nut-server initscript. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Reorganize nut-server to clarify nut-driverDaniel F. Dickinson2018-08-29
| | | | | | | | | | | | | | | | | | Clarify the different between the common nut-driver portions of nut-server and the nut-server (upsd) proper. nut-driver can't be used without nut-server so there is no compelling reason to split into a separate package, but the reorganization makes such a move easier and makes it clear what each bit is for. While we continue to use a single initscript, it's a properly procdified one which handles the upsd daemon as a different instance than the driver instances. This resolves a race condition in which upsd and drivers fail to start do to a degree of interdepedence. Also properly 'procd'ifies the nut-server initscript. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Add missing conffilesDaniel F. Dickinson2018-08-28
| | | | | | | | We want to include the symlinks to the generated configurations in conffiles so that if the user replaces them symlinks with traditional NUT configuration it is preserved across sysupgrade. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Fix for nut-upsmon without nut-serverDaniel F. Dickinson2018-08-02
| | | | | | | | | nut-monitor failed to create required dir /var/etc/nut, as well as failing to set appropriate user on the directory and conf files. Fixing this closes https://github.com/openwrt/packages/issues/6644 Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Update my emailDaniel F. Dickinson2018-07-04
| | | | Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* nut: Add PKG_FIXUP:=autoreconfEneas U de Queiroz2018-06-13
| | | | | | We need to force this since a *.m4 file is patched. Signed-off-by: Eneas U de Queiroz <cote2004-github@yahoo.com>
* nut: added compatibility with openssl-1.1Eneas U de Queiroz2018-06-01
| | | | | | Also added a fix in a check for empty string. Signed-off-by: Eneas U de Queiroz <cote2004-github@yahoo.com>
* net/nut: Fix typo is serial config optionKarl Palsson2017-09-11
| | | | | | Fixes: 5503dac80676 "Add back serial support" Reported-by: Znevna on irc Signed-off-by: Karl Palsson <karlp@tweak.net.au>
* treewide: run "make check FIXUP=1"Etienne Champetier2017-08-29
| | | | | | | | | | fix Makefile chmod (644) replace MD5SUM with HASH add PKG_MIRROR_HASH when PKG_SOURCE_PROTO:=git (PKG_SOURCE_PROTO:=svn tarballs are not reproducible for now) Signed-off-by: Etienne Champetier <champetier.etienne@gmail.com>
* net/nut: Ship upsset.conf for nut-cgiDaniel Dickinson2017-01-11
| | | | | | | Per user request ship the sample upsset.conf file so that upsset functionality can be used with nut-cgi Signed-off-by: Daniel Dickinson <lede@cshore.thecshore.com>
* net/nut: Avoid building with libwrap when presentDaniel Dickinson2017-01-11
| | | | | | | We don't want non-deterministic builds do turn off libwrap in configure options. Signed-off-by: Daniel Dickinson <lede@cshore.thecshore.com>
* net/nut: Make myself maintainer per private mailDaniel Dickinson2017-01-11
| | | | | | | | | | Current maintainer (Martin Rowe) offered to hand over maintership because I'm interested in doing more with the package than he requires for his own use, so he felt it made sense for me to maintain the package. I accepted, hence this commit. Signed-off-by: Daniel Dickinson <lede@cshore.thecshore.com>
* net/nut: Fix '/var/run' world readable warningDaniel Dickinson2017-01-11
| | | | | | | | Use /var/run/nut as statepath and set appropriate owner and permissions on /var/run/nut in order to avoid pidfile for nut being world-readable. Signed-off-by: Daniel Dickinson <lede@cshore.thecshore.com>
* net-nut: Add UPS notifications via sendmailDaniel Dickinson2017-01-11
| | | | | | | Add option to send email notification via sendmail (or replacement). Signed-off-by: Daniel Dickinson <lede@cshore.thecshore.com>