2007-01-15 23:50:50 +01:00
|
|
|
#
|
2011-03-10 12:50:24 +01:00
|
|
|
# spec file for package acpid
|
2007-01-15 23:50:50 +01:00
|
|
|
#
|
2019-03-07 11:34:41 +01:00
|
|
|
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
2007-01-15 23:50:50 +01:00
|
|
|
#
|
2008-08-18 18:16:56 +02:00
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2019-03-07 11:34:41 +01:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2007-01-15 23:50:50 +01:00
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
Name: acpid
|
2019-03-07 11:34:41 +01:00
|
|
|
Version: 2.0.31
|
2011-12-27 14:04:31 +01:00
|
|
|
Release: 0
|
2018-07-31 08:54:23 +02:00
|
|
|
Summary: Daemon to execute actions on ACPI events
|
2018-06-18 09:43:35 +02:00
|
|
|
License: GPL-2.0-or-later
|
2011-12-27 14:04:31 +01:00
|
|
|
Group: System/Daemons
|
2019-03-07 11:34:41 +01:00
|
|
|
URL: http://sourceforge.net/projects/acpid2/
|
2013-08-02 13:57:36 +02:00
|
|
|
Source: http://downloads.sourceforge.net/project/acpid2/%{name}-%{version}.tar.xz
|
2013-12-13 10:41:27 +01:00
|
|
|
Source3: README.SUSE
|
2008-09-01 18:57:51 +02:00
|
|
|
Source5: events.power_button
|
2008-06-23 02:06:29 +02:00
|
|
|
Source6: thinkpad_handler
|
2008-08-18 18:16:56 +02:00
|
|
|
Source7: power_button
|
2010-10-03 22:43:20 +02:00
|
|
|
Source8: acpid.service
|
2013-01-15 16:29:52 +01:00
|
|
|
Source9: events.thinkpad
|
|
|
|
Source10: events.sleep_button
|
|
|
|
Source11: sleep_button
|
2012-01-05 04:59:48 +01:00
|
|
|
# PATCH-MISSING-TAG -- See http://wiki.opensuse.org/openSUSE:Packaging_Patches_guidelines
|
2010-10-03 22:43:20 +02:00
|
|
|
Patch1: acpid-makefile.patch
|
2013-12-13 10:41:27 +01:00
|
|
|
BuildRequires: systemd-rpm-macros
|
2019-03-18 10:01:39 +01:00
|
|
|
%systemd_ordering
|
2007-01-15 23:50:50 +01:00
|
|
|
|
|
|
|
%description
|
2019-03-18 10:01:39 +01:00
|
|
|
ACPID is a flexible, extensible daemon for delivering ACPI events. It
|
|
|
|
listens to a file (/proc/acpi/event) and, when an event occurs,
|
|
|
|
executes programs to handle the event. The start script loads all
|
|
|
|
needed modules.
|
2007-01-15 23:50:50 +01:00
|
|
|
|
|
|
|
%prep
|
2010-10-03 22:43:20 +02:00
|
|
|
%setup -q
|
2011-12-27 14:04:31 +01:00
|
|
|
%patch1
|
|
|
|
|
2013-11-21 10:46:50 +01:00
|
|
|
cp %{SOURCE3} %{SOURCE5} %{SOURCE6} %{SOURCE7} %{SOURCE9} %{SOURCE10} %{SOURCE11} .
|
2007-01-15 23:50:50 +01:00
|
|
|
|
|
|
|
%build
|
2015-09-27 08:39:35 +02:00
|
|
|
export CFLAGS="%{optflags}"
|
2010-11-09 20:11:38 +01:00
|
|
|
export LDFLAGS="-Wl,-z,relro,-z,now"
|
2015-09-27 08:39:35 +02:00
|
|
|
%configure
|
2012-09-24 16:40:47 +02:00
|
|
|
make %{?_smp_mflags}
|
2007-01-15 23:50:50 +01:00
|
|
|
|
|
|
|
%install
|
2019-03-18 10:01:39 +01:00
|
|
|
%make_install BINDIR=%{_sbindir}
|
2015-09-27 08:39:35 +02:00
|
|
|
install -Dm 744 thinkpad_handler %{buildroot}%{_libexecdir}/acpid/thinkpad_handler
|
2012-01-05 04:59:48 +01:00
|
|
|
install -Dm 644 events.thinkpad %{buildroot}%{_sysconfdir}/acpi/events/thinkpad
|
|
|
|
mkdir -p %{buildroot}/%{_unitdir}
|
|
|
|
install -m 644 %{SOURCE8} %{buildroot}/%{_unitdir}
|
2014-08-11 10:31:13 +02:00
|
|
|
ln -sf %{_sbindir}/service %{buildroot}%{_sbindir}/rcacpid
|
2010-10-03 22:43:20 +02:00
|
|
|
|
2013-07-04 17:22:11 +02:00
|
|
|
# formerly installed, but no longer useful with systemd. Keep as documentation.
|
|
|
|
cp -p events.power_button events.sleep_button power_button sleep_button samples/
|
2007-07-05 00:32:31 +02:00
|
|
|
# for the rpmlint fascists
|
2012-01-05 04:59:48 +01:00
|
|
|
mv samples examples
|
2007-06-05 00:44:31 +02:00
|
|
|
# keep the logfile
|
2012-01-05 04:59:48 +01:00
|
|
|
install -dm 755 %{buildroot}%{_localstatedir}/log
|
|
|
|
touch %{buildroot}%{_localstatedir}/log/acpid
|
2007-06-05 00:44:31 +02:00
|
|
|
|
2011-08-24 22:35:10 +02:00
|
|
|
%pre
|
2011-09-27 20:36:59 +02:00
|
|
|
%service_add_pre acpid.service
|
2011-08-24 22:35:10 +02:00
|
|
|
|
2007-01-15 23:50:50 +01:00
|
|
|
%post
|
2011-09-27 20:36:59 +02:00
|
|
|
%service_add_post acpid.service
|
2007-01-15 23:50:50 +01:00
|
|
|
|
|
|
|
%postun
|
2011-08-24 22:35:10 +02:00
|
|
|
%service_del_postun acpid.service
|
2007-01-15 23:50:50 +01:00
|
|
|
|
2011-08-24 22:35:10 +02:00
|
|
|
%preun
|
|
|
|
%service_del_preun acpid.service
|
2007-01-15 23:50:50 +01:00
|
|
|
|
|
|
|
%files
|
2012-01-05 04:59:48 +01:00
|
|
|
%dir %{_sysconfdir}/acpi
|
|
|
|
%dir %{_sysconfdir}/acpi/events
|
|
|
|
%{_sysconfdir}/acpi/events/thinkpad
|
2015-09-27 08:39:35 +02:00
|
|
|
%{_libexecdir}/acpid
|
|
|
|
%{_unitdir}/%{name}.service
|
2012-01-05 04:59:48 +01:00
|
|
|
%{_sbindir}/rcacpid
|
|
|
|
%{_sbindir}/acpid
|
2012-03-19 11:24:53 +01:00
|
|
|
%{_sbindir}/kacpimon
|
2012-01-05 04:59:48 +01:00
|
|
|
%{_bindir}/acpi_listen
|
2013-12-13 10:41:27 +01:00
|
|
|
%doc README.SUSE README Changelog examples
|
2019-03-07 11:34:41 +01:00
|
|
|
%{_mandir}/man8/acpid.8%{?ext_man}
|
|
|
|
%{_mandir}/man8/acpi_listen.8%{?ext_man}
|
|
|
|
%{_mandir}/man8/kacpimon.8%{?ext_man}
|
2012-01-05 04:59:48 +01:00
|
|
|
%ghost %config(noreplace,missingok) %{_localstatedir}/log/acpid
|
2007-01-15 23:50:50 +01:00
|
|
|
|
2007-03-29 15:28:12 +02:00
|
|
|
%changelog
|