diff options
Diffstat (limited to 'sys-power/apcupsd')
-rw-r--r-- | sys-power/apcupsd/Manifest | 4 | ||||
-rw-r--r-- | sys-power/apcupsd/apcupsd-3.14.14-r3.ebuild | 158 | ||||
-rw-r--r-- | sys-power/apcupsd/apcupsd-3.14.14-r4.ebuild | 2 | ||||
-rw-r--r-- | sys-power/apcupsd/files/apcupsd.powerfail.init | 17 |
4 files changed, 2 insertions, 179 deletions
diff --git a/sys-power/apcupsd/Manifest b/sys-power/apcupsd/Manifest index 278cbaee2bbb..2ddb35c49dab 100644 --- a/sys-power/apcupsd/Manifest +++ b/sys-power/apcupsd/Manifest @@ -9,10 +9,8 @@ AUX apcupsd-tmpfiles.conf 70 BLAKE2B 6bc5fdff60918a5ccb616e28cc3832053938accd47a AUX apcupsd-udev.rules 328 BLAKE2B be1a8ff2eb09c045137ab2f1e48d3caa5ea9df85f766da5f9ae04786895631503d986cb184c74fd92aa6c229d34fedeab0a61dc5cad4a8fba1a799ade3f01081 SHA512 ba2ebb9f28011548c845a81f17a328b98ec8d79c1e6be33aeab863d77b9d3aa61b4dfbd1bb89a0cae00465387dffe8cc223634a6e9a2f59170846d4bed9e7135 AUX apcupsd.conf 12475 BLAKE2B c7695035887fa4fa867b2588f2ed0e2fee6c6a0086c221fec3019e3de639202287e9a35082334b8801cda38c846a0bcac714b046b1ddc1297f764bb211e42fb9 SHA512 1519d3cd47a2a73ff4148e4f74964ae841d37639616fe5b974b426983f5379db89b8793a6952389c443c56b84d0ef33f6995eccd920f71b4e5efc842a58a04e1 AUX apcupsd.init 804 BLAKE2B 7afd83a6be8b068133f6221cc2396a1fe4cab23f6dec68957b48ef7940730908e7a20e1597a21480eeffdb79314fd02505d4bafdd0b7a6bd1ff2b7c452f847ef SHA512 dd7fcc52b495c3f73bc9b2fe73bbb7c8fe3ec959ea733360d370148d617d98f34de3b48f1cb451f9a8356eb8088b06d3c736bd6cbad2bb5e9e609e37d5f2c53c -AUX apcupsd.powerfail.init 397 BLAKE2B 472512906536753d3054d275707764a98094c14866da63fbc8d2d62e16a9099fdce0b61cf572a4ba862f0be13e1ed3407821ed07ec90f9c77fb8d95f18aafc2f SHA512 cd0ed9d24a8371de7920bf0ce2e89bb63c0bee58da1ac782ed2b929068f95b2af47458529223a33ecea4e8f73ddfe3a7b9591af6f64828de7ed1d91e2edbb6e1 AUX apcupsd.powerfail.init-r1 360 BLAKE2B 87015320928267dc48b1f3c31f588e0c99fac819238b41c2ed6161558d3d384501ca396a62c53b1f198c59b4a09b6ad0ffafd06fb13c7191841f968bc7ef4c40 SHA512 69a0221e5050e32e44ef5145ecd6c7ce113418f3f13a957be72954be396f898705643a2e81f38a9db6d835bc4dc2d2ff901519e75851963aaa8b8eb446da6f5f AUX apcupsd.service 111 BLAKE2B bf2ac8161af5b971642298c30b08ad78d289044bb2452bdef39b31119b60eceb0a14add7c00262132bb80dbf1964103242452cb8d9b815d6ec82c204100ea184 SHA512 011e3e52e7909f36fb73b6064277a69e5db41263cfc72bda07e326172396d5318cd2b050f1fb84c4cc6da7a247c0035c36c55322ffb234a1cfa7bf13ba492889 DIST apcupsd-3.14.14.tar.gz 1843409 BLAKE2B 48a3b249780064d699d86b658584aa222ce9f3b46a81209110b4684bf737cca7492b87b063154864ce76478f29f73cda83ab96b47f4a7aa7aa91e29a8abbf4a8 SHA512 c953bbf3e08f809748a7978a3952604176390d1cd276f187fe096d9bc3c8993b52127e8350c0363387da41318e24b4d1e00ea58df71f3bb8f50c9a5a64cd2d7f -EBUILD apcupsd-3.14.14-r3.ebuild 4557 BLAKE2B c4e278bedd39497ed302fdd928b298d2fa0bb7b5559dcf5e0f58c4c9e1e52509736724c74594ee972e095032e5aca5e431be7b167dcf1ac9a7b644461e1a13e6 SHA512 db4bb4eb0078a4e4a530f3fa49a8da05ee39391c5dca7b0a4a5dd86b7a2d8c95e99d6ff6832a4b9337d602002e38685362010d4dc1131c0795268851ef5103bb -EBUILD apcupsd-3.14.14-r4.ebuild 4399 BLAKE2B fab8dff0a14ec15df358b412edf949d8aeb7429529c5302715c6a771fbaa768be872c651cfa993e378bf31f5a29e46d9a1f91ea88c5ffab0678fb6d240f061d8 SHA512 7760ebf8a2acc7d9af4e8ad19b2179108c8d89a733ded434946c85cfcaab132dc7809314c94d239355854fa1fdaa75afde1cb4c33574092b9afb6d041db41cd6 +EBUILD apcupsd-3.14.14-r4.ebuild 4396 BLAKE2B 9c4c170cc4134d5e20e7ed5faad2ab1bc9ca9c178ceaa21b8ff785c8c50282db95c38185e83bd1e53634dc2029e8e33c36729e40f66d73bb217b4fe147e8c53e SHA512 299ab7d98a8e790aea6cc3b75ff0264e25ba691784e6831463d2a9f4221e9d04e6a33cd3c53c93755ea276592ec211d7d196024d87f91cbb14a9637ed874e0bf MISC metadata.xml 1273 BLAKE2B 1df1dcddcde2814806465b73da094a12f782b5e5ff5368b5b57dfdc290ecc68e817561296e3799d047cd1071656a408b068baf11eb5dc9c9153b5418d0f6ca59 SHA512 297eceae5e520df991f9be3cc8f58436d1b92ce46643fbc46bcc8457931f3fd67cac036e4d7a0e1fa42cbf1705c553596ed9de88b074ee265e152f59b7c6b328 diff --git a/sys-power/apcupsd/apcupsd-3.14.14-r3.ebuild b/sys-power/apcupsd/apcupsd-3.14.14-r3.ebuild deleted file mode 100644 index ba2ab5506de5..000000000000 --- a/sys-power/apcupsd/apcupsd-3.14.14-r3.ebuild +++ /dev/null @@ -1,158 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI="7" - -inherit linux-info systemd udev tmpfiles - -DESCRIPTION="APC UPS daemon with integrated tcp/ip remote shutdown" -HOMEPAGE="http://www.apcupsd.org/" -SRC_URI="https://downloads.sourceforge.net/apcupsd/${P}.tar.gz" - -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="amd64 ~arm ~arm64 ppc ~riscv x86" -IUSE="selinux snmp +usb +modbus cgi" - -DEPEND=">=sys-apps/util-linux-2.23[tty-helpers(-)] - cgi? ( >=media-libs/gd-1.8.4 ) - modbus? ( usb? ( virtual/libusb:0 ) ) - snmp? ( >=net-analyzer/net-snmp-5.7.2 )" - -RDEPEND="${DEPEND} - virtual/mailx - selinux? ( sec-policy/selinux-apcupsd )" - -CONFIG_CHECK="~USB_HIDDEV ~HIDRAW" -ERROR_USB_HIDDEV="CONFIG_USB_HIDDEV: needed to access USB-attached UPSes" -ERROR_HIDRAW="CONFIG_HIDRAW: needed to access USB-attached UPSes" - -DOCS=( ChangeLog ReleaseNotes ) -HTML_DOCS=( doc/manual ) - -PATCHES=( - "${FILESDIR}"/${PN}-3.14.9-aliasing.patch - "${FILESDIR}"/${PN}-3.14.9-close-on-exec.patch - "${FILESDIR}"/${PN}-3.14.9-commfailure.patch - "${FILESDIR}"/${PN}-3.14.9-fix-nologin.patch - "${FILESDIR}"/${PN}-3.14.9-gapcmon.patch - "${FILESDIR}"/${PN}-3.14.9-wall-on-mounted-usr.patch -) - -pkg_setup() { - if use kernel_linux && use usb && linux_config_exists ; then - check_extra_config - fi -} - -src_prepare() { - default - # skip this specific doc step as produced files never installed - # this avoids calling the col command not available on musl based system. - sed -i "/^SUBDIRS/ s/doc//g" Makefile || die -} - -src_configure() { - local myconf - - use cgi && myconf="${myconf} --enable-cgi --with-cgi-bin=/usr/libexec/${PN}/cgi-bin" - - if use usb ; then - myconf="${myconf} --with-upstype=usb --with-upscable=usb --enable-usb --with-dev=" - use modbus && myconf="${myconf} --enable-modbus-usb" - else - myconf="${myconf} --with-upstype=apcsmart --with-upscable=smart --disable-usb" - use modbus || myconf="${myconf} --disable-modbus" - fi - - # We force the DISTNAME to gentoo so it will use gentoo's layout also - # when installed on non-linux systems. - econf \ - --sbindir=/sbin \ - --sysconfdir=/etc/apcupsd \ - --with-pwrfail-dir=/etc/apcupsd \ - --with-lock-dir=/run/apcupsd \ - --with-pid-dir=/run/apcupsd \ - --with-log-dir=/var/log \ - --with-nis-port=3551 \ - --enable-net --enable-pcnet \ - --with-distname=gentoo \ - $(use_enable snmp) \ - --disable-gapcmon \ - ${myconf} \ - APCUPSD_MAIL=$(type -p mail) -} - -src_compile() { - # Workaround for bug #280674; upstream should really just provide - # the text files in the distribution, but I wouldn't count on them - # doing that anytime soon. - MANPAGER=$(type -p cat) \ - emake VERBOSE=2 -} - -src_install() { - emake DESTDIR="${D}" VERBOSE=2 install - rm "${ED}"/etc/init.d/halt || die - - insinto /etc/apcupsd - newins examples/safe.apccontrol safe.apccontrol - doins "${FILESDIR}"/apcupsd.conf - - doman doc/*.8 doc/*.5 - - einstalldocs - - rm "${ED}"/etc/init.d/apcupsd || die - newinitd "${FILESDIR}/${PN}.init" "${PN}" - newinitd "${FILESDIR}/${PN}.powerfail.init" "${PN}".powerfail - - systemd_dounit "${FILESDIR}"/${PN}.service - dotmpfiles "${FILESDIR}"/${PN}-tmpfiles.conf - - # remove hal settings, we don't really want to have it still around. - rm -r "${D}"/usr/share/hal || die - - # replace it with our udev rules if we're in Linux - if use kernel_linux ; then - udev_newrules "${FILESDIR}"/apcupsd-udev.rules 60-${PN}.rules - fi - -} - -pkg_postinst() { - use kernel_linux && udev_reload - - tmpfiles_process ${PN}-tmpfiles.conf - - if use cgi ; then - elog "The cgi-bin directory for ${PN} is /usr/libexec/${PN}/cgi-bin." - elog "Set up your ScriptAlias or symbolic links accordingly." - fi - - elog "" - elog "Since version 3.14.0 you can use multiple apcupsd instances to" - elog "control more than one UPS in a single box with openRC." - elog "To do this, create a link between /etc/init.d/apcupsd to a new" - elog "/etc/init.d/apcupsd.something, and it will then load the" - elog "configuration file at /etc/apcupsd/something.conf." - elog "" - - elog 'If you want apcupsd to power off your UPS when it' - elog 'shuts down your system in a power failure, you must' - elog 'add apcupsd.powerfail to your shutdown runlevel:' - elog '' - elog ' \e[01m rc-update add apcupsd.powerfail shutdown \e[0m' - elog '' - - if use kernel_linux; then - elog "Starting from version 3.14.9-r1, ${PN} installs udev rules" - elog "for persistent device naming. If you have multiple UPS" - elog "connected to the machine, you can point them to the devices" - elog "in /dev/apcups/by-id directory." - fi -} - -pkg_postrm() { - use kernel_linux && udev_reload -} diff --git a/sys-power/apcupsd/apcupsd-3.14.14-r4.ebuild b/sys-power/apcupsd/apcupsd-3.14.14-r4.ebuild index c3bc2dbb2a36..e524435a49b8 100644 --- a/sys-power/apcupsd/apcupsd-3.14.14-r4.ebuild +++ b/sys-power/apcupsd/apcupsd-3.14.14-r4.ebuild @@ -11,7 +11,7 @@ SRC_URI="https://downloads.sourceforge.net/apcupsd/${P}.tar.gz" LICENSE="GPL-2" SLOT="0" -KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~riscv ~x86" +KEYWORDS="amd64 ~arm ~arm64 ppc ~riscv x86" IUSE="cgi +modbus selinux snmp +usb" DEPEND=" diff --git a/sys-power/apcupsd/files/apcupsd.powerfail.init b/sys-power/apcupsd/files/apcupsd.powerfail.init deleted file mode 100644 index be591f86c185..000000000000 --- a/sys-power/apcupsd/files/apcupsd.powerfail.init +++ /dev/null @@ -1,17 +0,0 @@ -#!/sbin/openrc-run -# Copyright 2009 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -description='Signal the UPS to kill power in a power failure condition' - -depend() { - need mount-ro -} - -start() { - if [ "$(runlevel | cut -d' ' -f2)" = "0" -a -f /etc/apcupsd/powerfail ] ; then - ebegin 'Signaling UPS to kill power' - /sbin/apcupsd --killpower - eend $? - fi -} |