]> git.pld-linux.org Git - packages/apmd.git/blob - apmd.spec
- two typos.
[packages/apmd.git] / apmd.spec
1 Summary:        Advanced Power Management (APM) utilities for notebooks
2 Summary(pl):    Obs³uga zarz±dzania enerig± (APM) dla notebooków
3 Name:           apmd
4 Version:        3.0
5 Release:        4
6 License:        GPL
7 Group:          Utilities/System
8 Group(pl):      Narzêdzia/System
9 Source0:        http://www.worldvisions.ca/~apenwarr/apmd/%{name}-%{version}.tar.gz
10 Source1:        apmd.init
11 URL:            http://www.worldvisions.ca/~apenwarr/apmd/
12 Requires:       procps
13 Prereq:         chkconfig
14 BuildRequires:  XFree86-devel
15 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
16 ExclusiveArch:  %{ix86}
17
18 %description
19 Advanced Power Management daemon and utilities allows you to watch
20 your notebook's power state and warn all users when the battery is
21 low. It can also handle some power state events automatically.
22
23 %description -l pl
24 Demon zadz±dzania energi± APM (Advanced Power Management) wraz z
25 programami pomocniczymi. Dziêki nim mo¿liwe jest monitorowanie stanu
26 zasilania Twojego notebooka i ostrzeganie wszystkich u¿ytkowników o
27 koñcz±cej siê baterii, jak równie¿ automatyczne reagowanie na zmiany.
28
29 %package devel
30 Summary:        Header files for developing APM applications
31 Summary(pl):    Pliki nag³ówkowe do tworzenia aplikacji korzystaj±cych z APM
32 Group:          Development/Libraries
33 Group(pl):      Programowanie/Biblioteki
34 Group(fr):      Development/Librairies
35 Requires:       %{name} = %{version}
36
37 %description devel
38 Header files necessary for developing APM applications
39
40 %description devel -l pl
41 Pliki nag³ówkowe niezbêdne do tworzenia aplikacji korzystaj±cych z APM
42
43 %package -n xapm
44 Summary:        XFree86 APM monitoring and management tool
45 Summary(pl):    Narzêdzie do monitorowania i zarz±dzania APMem pod XFree86
46 Group:          X11/Utilities/System
47 Group(pl):      X11/Narzêdzia/System
48
49 %description -n xapm
50 xapm is an XFree86 version of console APM client - "apm".
51
52 %description -n xapm -l pl
53 xapm jest wersj± konsolowego klienta APM - "apm", przenaczon± dla
54 XFree86
55
56 %prep
57 %setup -q -n apmd
58
59 %build
60 make CFLAGS="$RPM_OPT_FLAGS" LDFLAGS=-s APMD_PROXY_DIR=%{_sbindir}
61 make -C xbattery clean
62 make CCOPTIONS="$RPM_OPT_FLAGS" LOCAL_LDFLAGS="-s" -C xbattery
63
64 %install
65 rm -rf $RPM_BUILD_ROOT
66 install -d $RPM_BUILD_ROOT{%{_bindir},%{_includedir},%{_libdir},%{_sbindir}} \
67         $RPM_BUILD_ROOT%{_prefix}/X11R6/{bin,man/man1} \
68         $RPM_BUILD_ROOT{%{_mandir}/man{1,8},/etc/{rc.d/init.d,sysconfig}}
69
70 install apm apmsleep tailf on_ac_power $RPM_BUILD_ROOT%{_bindir}
71 install apmd apmd_proxy $RPM_BUILD_ROOT%{_sbindir}
72
73 install xapm $RPM_BUILD_ROOT%{_prefix}/X11R6/bin
74
75 install apm.1 apmsleep.1 tailf.1 $RPM_BUILD_ROOT%{_mandir}/man1/
76 install apmd.8 $RPM_BUILD_ROOT%{_mandir}/man8/
77 install xapm.1 $RPM_BUILD_ROOT%{_prefix}/X11R6/man/man1/xapm.1x
78 install xbattery/xbattery.man $RPM_BUILD_ROOT%{_prefix}/X11R6/man/man1/xbattery.1x
79
80 install libapm.a $RPM_BUILD_ROOT%{_libdir}
81 install apm.h $RPM_BUILD_ROOT%{_includedir}
82
83 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/apmd
84 install xbattery/xbattery $RPM_BUILD_ROOT%{_prefix}/X11R6/bin
85
86 cat << EOF > $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/apmd
87 APMD_OPTIONS="-p 10 -w 5 -W -P %{_sbindir}/apmd_proxy"
88 EOF
89
90 gzip -9nf $RPM_BUILD_ROOT%{_mandir}/man*/* \
91         $RPM_BUILD_ROOT%{_prefix}/X11R6/man/man*/* \
92         README README.transfer ChangeLog ANNOUNCE
93  
94 %clean
95 rm -rf $RPM_BUILD_ROOT
96
97 %post
98 /sbin/chkconfig --add apmd
99 if [ -f /var/lock/subsys/apmd ]; then
100         /etc/rc.d/init.d/apmd restart 1>&2
101 else
102         echo "Run \"/etc/rc.d/init.d/apmd start\" to start apmd daemon."
103 fi
104
105 %preun
106 if [ "$1" = "0" ]; then
107         if [ -f /var/lock/subsys/apmd ]; then
108                 /etc/rc.d/init.d/apmd stop 1>&2
109         fi
110         /sbin/chkconfig --del apmd
111 fi
112
113 %files
114 %defattr(644,root,root,755)
115 %doc ANNOUNCE.gz ChangeLog.gz README.gz README.transfer.gz
116 %{_mandir}/man*/*
117 %attr(755,root,root) %{_bindir}/*
118 %attr(755,root,root) %{_sbindir}/*
119 %attr(754,root,root) /etc/rc.d/init.d/apmd
120 %config(noreplace) /etc/sysconfig/apmd
121
122 %files devel
123 %defattr(644,root,root,755)
124 %{_includedir}/*
125 %{_libdir}/*.a
126
127 %files -n xapm
128 %defattr(644,root,root,755)
129 %{_prefix}/X11R6/man/man*/*
130 %attr(755,root,root) %{_prefix}/X11R6/bin/*
This page took 0.066114 seconds and 3 git commands to generate.