source: projects/specs/trunk/a/anacron/anacron-vl.spec @ 3430

Revision 3430, 7.9 KB checked in by daisuke, 13 years ago (diff)

anacron; rebuild for Vine6

Line 
1Summary: A cron-like program that can run jobs lost during downtime.
2Name: anacron
3Version: 2.3
4Release: 29%{?_dist_release}
5License: GPL
6Group: System Environment/Base
7Source: ftp://ftp.debian.org/debian/pool/main/a/anacron/%{name}_%{version}.orig.tar.gz
8Source1: anacrontab
9Source2: anacron.init
10Patch0: anacron-2.3-mk-incl.patch
11Patch1: anacron-2.3-mail-content-type-77108.patch
12Patch2: anacron-2.3-gregor.patch
13
14BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot
15Requires: /bin/sh
16Requires: crontabs
17Requires(post): chkconfig
18Requires(preun): chkconfig
19Requires(preun): initscript
20Requires(postun): initscript
21
22%description
23Anacron (like `anac(h)ronistic') is a periodic command scheduler.  It
24executes commands at intervals specified in days.  Unlike cron, it
25does not assume that the system is running continuously.  It can
26therefore be used to control the execution of daily, weekly and
27monthly jobs (or anything with a period of n days), on systems that
28don't run 24 hours a day.  When installed and configured properly,
29Anacron will make sure that the commands are run at the specified
30intervals as closely as machine-uptime permits. 
31
32This package is pre-configured to execute the daily jobs of the Red
33Hat Linux system. You should install this program if your system isn't
34powered on 24 hours a day to make sure the maintenance jobs of other
35Red Hat Linux packages are executed each day.
36
37%prep
38%setup -q
39%patch0 -p1 -b .incl
40%patch1 -p1 -b .charset
41%patch2 -p1 -b .gregor
42
43%build
44make CFLAGS="$RPM_OPT_FLAGS"
45
46%install
47mkdir -p $RPM_BUILD_ROOT/{etc/,usr/sbin/,%{_mandir}/man5,%{_mandir}/man8/}
48mkdir -p $RPM_BUILD_ROOT/var/spool/anacron/
49
50#
51cp anacron $RPM_BUILD_ROOT/usr/sbin
52cp anacron.8 $RPM_BUILD_ROOT/%{_mandir}/man8/
53cp anacrontab.5 $RPM_BUILD_ROOT/%{_mandir}/man5/
54cp %SOURCE1 $RPM_BUILD_ROOT/etc
55
56for i in cron.daily cron.weekly cron.monthly;do
57mkdir -p $RPM_BUILD_ROOT/etc/$i/
58cat << EOF > $RPM_BUILD_ROOT/etc/$i/0anacron
59#!/bin/sh
60#
61# anacron's cron script
62#
63# This script updates anacron time stamps. It is called through run-parts
64# either by anacron itself or by cron.
65#
66# The script is called "0anacron" to assure that it will be executed
67# _before_ all other scripts.
68
69anacron -u $i
70
71EOF
72chmod +x $RPM_BUILD_ROOT/etc/$i/0anacron
73done
74
75#
76#for i in `find $RPM_BUILD_ROOT/ -type 'f' -perm '+a=x'`;do
77#       file $i|grep -q "not stripped" && strip $i
78#done
79
80mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d/
81install -c -m755 %SOURCE2 $RPM_BUILD_ROOT/etc/rc.d/init.d/anacron
82
83%clean
84rm -rf $RPM_BUILD_ROOT
85
86
87%post
88/sbin/chkconfig --add anacron
89
90%preun
91if [ "$1" = "0" ]; then
92    service anacron stop >/dev/null 2>&1
93    /sbin/chkconfig --del anacron
94fi
95
96%postun
97if [ "$1" -ge "1" ]; then
98    service anacron condrestart >/dev/null 2>&1
99fi
100
101%files
102%defattr(-,root,root,0755)
103%doc COPYING README
104%config /etc/anacrontab
105%dir /var/spool/anacron/
106%config /etc/rc.d/init.d/*
107/%{_mandir}/man5/*
108/%{_mandir}/man8/*
109/usr/sbin/anacron
110%config /etc/cron.daily/0anacron
111%config /etc/cron.monthly/0anacron
112%config /etc/cron.weekly/0anacron
113
114%changelog
115* Wed Apr 13 2011 Daisuke SUZUKI <daisuke@linux.or.jp> 2.3-30
116- rebuild for Vine 6
117- use Requires({post,preun,postun}) instead of PreReq
118
119* Fri Aug 15 2008 Shu KONNO <owa@bg.wakwak.com> 2.3-29vl5
120- applied new versioning policy
121
122* Sat Jul 08 2006 Shu KONNO <owa@bg.wakwak.com> 2.3-29vl2
123- added anacron-2.3-gregor.patch
124
125* Wed Jul 23 2003 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.3-29vl1
126- rebuild for Vine Linux
127
128* Thu Jul 10 2003 Jens Petersen <petersen@redhat.com> - 2.3-29
129- don't require vixie-cron (#21176) [reported by Gerald Teschl]
130- in init script don't remove /var/lock/subsys/anacron when stopping (#58462)
131- exit init script with actual exit status (#44600) [reported by Enrico Scholz]
132
133* Thu Jul 10 2003 Jens Petersen <petersen@redhat.com> - 2.3-28
134- add a Content-Type header to mails giving the charset encoding (#77108)
135
136* Thu Jul 10 2003 Jens Petersen <petersen@redhat.com> - 2.3-27
137- in init script do not touch /var/lock/subsys/anacron when starting (#58462)
138- require crontabs (#21176)
139- update source url
140
141* Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com>
142- rebuilt
143
144* Wed Jan 22 2003 Tim Powers <timp@redhat.com>
145- rebuilt
146
147* Wed Dec 11 2002 Tim Powers <timp@redhat.com> 2.3-24
148- rebuild on all arches
149
150* Fri Aug 23 2002 Jens Petersen <petersen@redhat.com> 2.3-23
151- delay the start of anacron by 60min to make startup more pleasant (#68304)
152- at startup run jobs serially and nice 19 to reduce load (#65870, #68304)
153- spec file now in utf-8
154- dont install non-existant NEWS file
155- silence make include warnings
156
157* Fri Jul 19 2002 Akira TAGOH <tagoh@redhat.com> 2.3-22
158- fix the stripped binary issue.
159
160* Mon Jul 08 2002 Bill Huang <bhuang@redhat.com>
161- Update "Copyright" to "License" in spec file
162
163* Fri Jun 21 2002 Tim Powers <timp@redhat.com>
164- automated rebuild
165
166* Thu May 23 2002 Tim Powers <timp@redhat.com>
167- automated rebuild
168
169* Wed Jan 09 2002 Tim Powers <timp@redhat.com>
170- automated rebuild
171
172* Sun Jun 24 2001 Elliot Lee <sopwith@redhat.com>
173- Bump release + rebuild.
174
175* Tue Apr  3 2001 Crutcher Dunnavant <crutcher@redhat.com>
176- add dependancy to vixie-cron (for /usr/bin/run-parts)
177
178* Tue Feb 13 2001 Tim Waugh <twaugh@redhat.com>
179- killproc is a shell function and can't be passed as a parameter
180  (bug #27150).
181
182* Mon Feb  5 2001 Bernhard Rosenkraenzer <bero@redhat.com>
183- Fix i18n in initscript ("Stopping anacron" wasn't translated)
184  (#26076)
185
186* Fri Feb  2 2001 Trond Eivind Glomsrød <teg@redhat.com>
187- i18nize initscript
188
189* Thu Dec  7 2000 Crutcher Dunnavant <crutcher@redhat.com>
190- rebuild in rebuild cycle.
191
192* Mon Oct 30 2000 Matt Wilson <msw@redhat.com>
193- touch /var/lock/subsys/anacron to prevent excess startage during
194  init level change
195
196* Wed Aug 30 2000 Bernhard Rosenkraenzer <bero@redhat.com>
197- Shut down earlier to prevent NFS mounted /usr filesystems from causing
198  problems (Bug #16257)
199
200* Fri Aug  4 2000 Bernhard Rosenkraenzer <bero@redhat.com>
201- Start it later so services some cron scripts may depend on are running
202  (Bug #15335)
203
204* Thu Aug  3 2000 Bernhard Rosenkraenzer <bero@redhat.com>
205- Fix up initscript (Bug #15123 and an unreported bug)
206
207* Sat Jul 15 2000 Bill Nottingham <notting@redhat.com>
208- move initscript back
209
210* Wed Jul 12 2000 Prospector <bugzilla@redhat.com>
211- automatic rebuild
212
213* Mon Jul 10 2000 Bernhard Rosenkraenzer <bero@redhat.com>
214- Fix up initscripts (Bug #13625)
215
216* Tue Jul  4 2000 Matt Wilson <msw@redhat.com>
217- Prereq: /sbin/chkconfig
218
219* Mon Jun 26 2000 Preston Brown <pbrown@redhat.com>
220- move initscript to /etc/init.d, fix up post/preun/postun scripts.
221
222* Sun Jun 26 2000 Bernhard Rosenkraenzer <bero@redhat.com>
223- 2.3
224
225* Sun Jun 18 2000 Matt Wilson <msw@redhat.com>
226- use %%{_mandir}
227
228* Fri Mar 03 2000 Tim Powers <timp@redhat.com>
229- fixed startup script so that it doesn't put stuff in /var/lock/subsys.
230        Complains since anacronda turns itself off when it is run, and the file in
231        /var/lock/subsys isn't removed.
232       
233* Mon Feb 28 2000 Tim Powers <timp@redhat.com>
234- fixed startup script, now it actually stops, gives status and restarts.
235        Fixes bug #9835
236
237* Mon Feb  7 2000 Bill Nottingham <notting@redhat.com>
238- handle compressed manpages
239
240* Fri Feb  4 2000 Bernhard Rosenkraenzer <bero@redhat.com>
241- rebuild to get compressed man pages
242- mark /etc/cron.daily/... as config files
243
244* Wed Feb 02 2000 Cristian Gafton <gafton@redhat.com>
245- fix annoying defines
246- rebuild to update description and group
247
248* Thu Jan  6 2000 Bernhard Rosenkränzer <bero@redhat.com>
249- initial Red Hat package
250
251* Wed Dec 29 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
252- Remove cron.hourly check (unusefull).
253
254* Wed Nov 10 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
255- 2.1 from debian.
256- Fix typo in initscripts.
257
258* Thu Jul 22 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
259- Fix wrong entries in anacrontab.
260- Add a /etc/rc.sysinit/ script
261
262* Tue Apr 27 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
263- Fix bug with /var/spool/anacron/
264
265* Sat Apr 10 1999 Chmouel Boudjnah <chmouel@mandrakesoft.com>
266- First version mainly inspired from the Debian package.
Note: See TracBrowser for help on using the repository browser.