]> git.pld-linux.org Git - packages/laptop-mode-tools.git/commitdiff
- initial pld release
authorArkadiusz Miśkiewicz <arekm@maven.pl>
Tue, 1 Feb 2005 19:42:22 +0000 (19:42 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    laptop-mode-tools.spec -> 1.1

laptop-mode-tools.spec [new file with mode: 0644]

diff --git a/laptop-mode-tools.spec b/laptop-mode-tools.spec
new file mode 100644 (file)
index 0000000..de8a3f2
--- /dev/null
@@ -0,0 +1,106 @@
+Summary:       Laptop Mode Tools
+Name:          laptop-mode-tools
+Version:       1.04
+Release:       0.1
+Epoch:         0
+License:       GPL
+Group:         Applications/System
+Source0:       http://www.xs4all.nl/~bsamwel/laptop_mode/tools/downloads/%{name}_%{version}.tar.gz
+# Source0-md5: b1e6309e8331e0f4e6efd311c2d97fa8
+Source1:       %{name}.init
+URL:           http://www.xs4all.nl/~bsamwel/laptop_mode/
+PreReq:                rc-scripts
+Requires(post,preun):  /sbin/chkconfig
+Requires:      %{name}-scripts = %{epoch}:%{version}-%{release}
+BuildArch:     noarch
+BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+Laptop mode (also known as laptopmode, laptop-mode and laptop_mode,
+for search engine purposes :) ) is a kernel "mode" that allows you to
+extend the battery life of your laptop. It does this by intelligently
+grouping write activity on your disks, so that only reads of uncached
+data result in a disk spinup. It causes a significant improvement in
+battery life (for usage patterns that allow it).
+
+%package acpi
+Summary:       ACPI scripts for laptop mode tools
+Group:         Applications/System
+Provides:      %{name}-scripts = %{epoch}:%{version}-%{release}
+Requires:      %{name} = %{epoch}:%{version}-%{release}
+Requires:      acpid
+
+%description acpi
+ACPI scripts for laptop mode tools.
+
+%package apm
+Summary:       APM scripts for laptop mode tools
+Group:         Applications/System
+Provides:      %{name}-scripts = %{epoch}:%{version}-%{release}
+Requires:      %{name} = %{epoch}:%{version}-%{release}
+Requires:      apmd
+
+%description apm
+APM scripts for laptop mode tools.
+
+%prep
+%setup -q
+
+%build
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+install -d $RPM_BUILD_ROOT/etc/{sysconfig,rc.d/init.d,laptop-mode}
+install -d $RPM_BUILD_ROOT/etc/apm/event.d
+install -d $RPM_BUILD_ROOT/etc/acpi/{actions,events}
+install -d $RPM_BUILD_ROOT/{%{_mandir}/man8,%{_sbindir}}
+
+install man/*.8 $RPM_BUILD_ROOT%{_mandir}/man8
+
+install etc/laptop-mode/laptop-mode.conf $RPM_BUILD_ROOT%{_sysconfdir}/laptop-mode
+install usr/sbin/laptop_mode usr/sbin/lm-syslog-setup $RPM_BUILD_ROOT/%{_sbindir}
+
+install etc/acpi/actions/* $RPM_BUILD_ROOT%{_sysconfdir}/acpi/actions
+install etc/acpi/events/* $RPM_BUILD_ROOT%{_sysconfdir}/acpi/events
+
+install etc/apm/event.d/* $RPM_BUILD_ROOT%{_sysconfdir}/apm/event.d/
+
+install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/laptop-mode
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post
+/sbin/chkconfig --add laptop-mode
+if [ -f /var/lock/subsys/laptop-mode ]; then
+       /etc/rc.d/init.d/laptop-mode restart 1>&2
+else
+       echo "Run \"/etc/rc.d/init.d/laptop-mode start\" to start laptop-mode."
+fi
+
+%preun
+if [ "$1" = "0" ]; then
+       if [ -f /var/lock/subsys/laptop-mode ]; then
+               /etc/rc.d/init.d/laptop-mode stop 1>&2
+       fi
+       /sbin/chkconfig --del laptop-mode
+fi
+
+%files
+%defattr(644,root,root,755)
+%doc README Documentation/*
+%attr(754,root,root) /etc/rc.d/init.d/laptop-mode
+%attr(755,root,root) %{_sbindir}/*
+%dir %{_sysconfdir}/laptop-mode
+%config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/laptop-mode/*.*
+
+%{_mandir}/man8/*.8*
+
+%files acpi
+%defattr(644,root,root,755)
+%attr(750,root,root) %{_sysconfdir}/acpi/*/*
+
+%files apm
+%defattr(644,root,root,755)
+%attr(750,root,root) %{_sysconfdir}/apm/event.d/*
This page took 0.250785 seconds and 4 git commands to generate.