automatic version update by autodist [release 2.0.22-1mamba;Tue Mar 18 2014]

This commit is contained in:
Automatic Build System 2024-01-05 20:12:05 +01:00
parent 875c08fb69
commit eb81867256
4 changed files with 302 additions and 0 deletions

View File

@ -1,2 +1,6 @@
# acpid
ACPID is a completely flexible, totally extensible daemon for delivering ACPI events.
It listens on a file (/proc/acpi/event) and when an event occurs, executes programs to handle the event.
The programs it executes are configured through a set of configuration files, which can be dropped into place by packages or by the admin.

15
acpi-sysconfig Normal file
View File

@ -0,0 +1,15 @@
# ACPI configuration file
#
# Node: this file is automatically updated by the acpid initscript
# whenever a module cannot be loaded
#
#AC=yes
#BATTERY=yes
#FAN=yes
#THERMAL=yes
#BUTTON=yes
#PROCESSOR=yes
#VIDEO=yes
#CONTAINER=yes
#CPUFREQ=yes
#

134
acpid-initscript Normal file
View File

@ -0,0 +1,134 @@
#!/bin/bash
#
# /etc/rc.d/init.d/acpid
#
# Starts the acpi daemon
#
# chkconfig: 345 44 01
# description: Listen and dispatch ACPI events from the kernel
# processname: acpid
# Source function library.
. /etc/rc.d/init.d/functions
if [ -f /etc/sysconfig/acpi ]; then
source /etc/sysconfig/acpi
fi
DAEMON=acpi
PROGNAME=${DAEMON}d
test -x /usr/sbin/$PROGNAME || exit 0
RETVAL=0
#
# See how we were called.
#
start() {
# Check if it is already running
if [[ ! -f /var/lock/subsys/$PROGNAME && -e /proc/acpi ]]; then
echo -n "Loading ACPI modules: "
if [ "$AC" != "no" ];then
action "Loading ACPI AC control module" /sbin/modprobe ac 2>/dev/null
fi
if [ "$BATTERY" != "no" ];then
action "Loading ACPI BATTERY control module" /sbin/modprobe battery 2>/dev/null
fi
if [ "$FAN" != "no" ];then
action "Loading ACPI FAN control module" /sbin/modprobe fan 2>/dev/null
fi
if [ "$HOTKEY" != "no" ];then
action "Loading ACPI HOTKEY control module" /sbin/modprobe hotkey 2>/dev/null \
|| echo "HOTKEY=no" >> /etc/sysconfig/acpi
fi
if [ "$THERMAL" != "no" ];then
action "Loading ACPI THERMAL control module" /sbin/modprobe thermal 2>/dev/null
fi
if [ "$BUTTON" != "no" ];then
action "Loading ACPI BUTTON control module" /sbin/modprobe button 2>/dev/null
fi
if [ "$PROCESSOR" != "no" ];then
action "Loading ACPI PROCESSOR control module" /sbin/modprobe processor 2>/dev/null
fi
if [ "$ASUS_ACPI" != "no" ];then
action "Loading ACPI ASUS control module" /sbin/modprobe asus_acpi 2>/dev/null \
|| echo "ASUS_ACPI=no" >> /etc/sysconfig/acpi
fi
if [ "$IBM_ACPI" != "no" ];then
action "Loading ACPI IBM control module" /sbin/modprobe ibm_acpi 2>/dev/null \
|| echo "IBM_ACPI=no" >> /etc/sysconfig/acpi
fi
if [ "$TOSHIBA_ACPI" != "no" ];then
action "Loading ACPI TOSHIBA control module" /sbin/modprobe toshiba_acpi 2>/dev/null\
|| echo "TOSHIBA_ACPI=no" >> /etc/sysconfig/acpi
fi
if [ "$CONTAINER" != "no" ];then
action "Loading ACPI CONTAINER control module" /sbin/modprobe container 2>/dev/null
fi
if [ "$VIDEO" != "no" ];then
action "Loading ACPI VIDEO control module" /sbin/modprobe video 2>/dev/null
fi
if [ "$CPU_FREQ" -a "$CPU_FREQ" != "no" ];then
action "Loading CPUFREQ control module" /sbin/modprobe $CPU_FREQ 2>/dev/null
fi
if [ -e /proc/acpi/event ]; then
echo -n "Starting $DAEMON daemon: "
daemon /usr/sbin/$PROGNAME
RETVAL=$?
[ $RETVAL -eq 0 ] && touch /var/lock/subsys/$PROGNAME
echo
fi
fi
return $RETVAL
}
stop() {
if [[ -f /var/lock/subsys/$PROGNAME && -e /proc/acpi/event ]]; then
echo -n "Stopping $DAEMON daemon: "
killproc /usr/sbin/$PROGNAME
RETVAL=$?
[ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/$PROGNAME
echo
return $RETVAL
fi
}
restart() {
stop
start
}
reload() {
trap "" SIGHUP
killall -HUP $PROGNAME
}
case "$1" in
start)
start
;;
stop)
stop
;;
reload)
reload
;;
restart)
restart
;;
condrestart)
if [ -f /var/lock/subsys/$PROGNAME ]; then
restart
fi
;;
status)
status $PROGNAME
;;
*)
INITNAME=`basename $0`
echo "Usage: $INITNAME {start|stop|restart|condrestart|status}"
exit 1
esac
exit $RETVAL

149
acpid.spec Normal file
View File

@ -0,0 +1,149 @@
Name: acpid
Version: 2.0.22
Release: 1mamba
Summary: The ACPI event daemon
Group: System/Kernel and Hardware
Vendor: openmamba
Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: http://sourceforge.net/projects/acpid2
Source0: http://downloads.sourceforge.net/project/acpid2/acpid-%{version}.tar.xz
Source1: acpid-initscript
Source2: acpi-sysconfig
License: GPL
## AUTOBUILDREQ-BEGIN
BuildRequires: glibc-devel
## AUTOBUILDREQ-END
BuildRoot: %{_tmppath}/%{name}-%{version}-root
Requires(pre): chkconfig
Requires(pre): sed
%description
ACPID is a completely flexible, totally extensible daemon for delivering ACPI events.
It listens on a file (/proc/acpi/event) and when an event occurs, executes programs to handle the event.
The programs it executes are configured through a set of configuration files, which can be dropped into place by packages or by the admin.
%prep
%setup -q
%build
%configure
%make
%install
%makeinstall
install -D -m 755 %{SOURCE1} %{buildroot}%{_initrddir}/acpid
install -D -m 644 %{SOURCE2} %{buildroot}%{_sysconfdir}/sysconfig/acpi
install -d -m 755 %{buildroot}/etc/acpi/events
#install -m 644 samples/sample.conf %{buildroot}/etc/acpi/events
#
install -d -m 755 %{buildroot}%{_sysconfdir}/acpi/actions
install -d %{buildroot}/var/log
touch %{buildroot}/var/log/acpid
chmod 640 %{buildroot}/var/log/acpid
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%post
if [ $1 -eq 1 ]; then
# new install
chkconfig --add acpid
fi
[ -e %{_sysconfdir}/sysconfig/acpi ] && sed -i "/CPU_FREQ=.*/d" %{_sysconfdir}/sysconfig/acpi
exit 0
%preun
if [ $1 -eq 0 ]; then
# erase
chkconfig --del acpid
service acpid stop
fi
exit 0
%files
%defattr(-,root,root)
%dir %{_sysconfdir}/acpi
%dir %{_sysconfdir}/acpi/events
%dir %{_sysconfdir}/acpi/actions
#%attr(0644,root,root) %{_sysconfdir}/acpi/events/sample.conf
%attr(0755,root,root) %{_initrddir}/acpid
%config(noreplace) %{_sysconfdir}/sysconfig/acpi
%{_bindir}/acpi_listen
%{_sbindir}/acpid
%{_sbindir}/kacpimon
%{_localstatedir}/log/acpid
%{_mandir}/man8/acpi_listen.8*
%{_mandir}/man8/acpid.8*
%{_mandir}/man8/kacpimon.8*
%dir %{_datadir}/doc/acpid
%{_datadir}/doc/acpid/*
%changelog
* Tue Mar 18 2014 Automatic Build System <autodist@mambasoft.it> 2.0.22-1mamba
- automatic version update by autodist
* Fri Jan 17 2014 Automatic Build System <autodist@mambasoft.it> 2.0.21-1mamba
- automatic version update by autodist
* Mon Sep 16 2013 Automatic Build System <autodist@mambasoft.it> 2.0.20-1mamba
- automatic version update by autodist
* Thu May 30 2013 Automatic Build System <autodist@mambasoft.it> 2.0.19-1mamba
- automatic version update by autodist
* Sun Feb 24 2013 Automatic Build System <autodist@mambasoft.it> 2.0.18-1mamba
- update to 2.0.18
* Thu Jan 31 2013 Automatic Build System <autodist@mambasoft.it> 2.0.17-1mamba
- update to 2.0.17
* Wed Jul 15 2009 Automatic Build System <autodist@mambasoft.it> 1.0.10-1mamba
- automatic update by autodist
* Mon Jun 29 2009 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.8-2mamba
- launch acpid if /proc/acpi/event exists (see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=462467
* Mon Mar 23 2009 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.8-1mamba
- update to 1.0.8
* Mon Jan 12 2009 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.6-4mamba
- initscript: load module set in CPU_FREQ in /etc/sysconfig/acpi
* Tue Apr 01 2008 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.6-3mamba
- initscript: make probing errors silent; fix cpufreq variable
* Wed Jan 23 2008 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.6-2mamba
- add support for acpi_cpufreq module loading
* Sun Jul 08 2007 Tiziana Ferro <tiziana.ferro@email.it> 1.0.6-1mamba
- update to 1.0.6
* Fri Dec 01 2006 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.4-7qilnx
- initscript: don't unload modules on stop
- initscript: start stop script with priority 01 so daemon is stopped sooner
* Wed Oct 18 2006 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.4-6qilnx
- add prereq for chkconfig
* Tue Feb 28 2006 Davide Madrisan <davide.madrisan@qilinux.it> 1.0.4-5qilnx
- always exit successfully from the specfile scripts
* Mon Feb 27 2006 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.4-4qilnx
- don't restart service on update
* Tue Feb 21 2006 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.4-3qilnx
- initscript: load acpi video module
* Mon Nov 29 2004 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.4-2qilnx
- don't start service on install
* Thu Nov 11 2004 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.4-1qilnx
- new version build
- added check for /proc/acpi on system in initscripts
* Thu Jul 10 2003 Silvan Calarco <silvan.calarco@qinet.it> 1.0.2-1qilnx
- first build for acpid