]> git.pld-linux.org Git - packages/Zope-TimerService.git/blame_incremental - Zope-TimerService.spec
- tabs in preamble
[packages/Zope-TimerService.git] / Zope-TimerService.spec
... / ...
CommitLineData
1
2%define zope_subname TimerService
3%define module timerserver
4Summary: Support module for Zope-Scheduler
5Summary(pl.UTF-8): Moduł wspomagający dla Zope-Scheduler
6Name: Zope-%{zope_subname}
7Version: 0.2
8Release: 4
9License: GPL
10Group: Libraries/Python
11Source0: http://dev.legco.biz/downloads/%{zope_subname}-%{version}.tar.gz
12# Source0-md5: 5fb0fce2b90f69478a9370b313a45aa9
13Source1: Zope-timerserver_remover
14URL: http://dev.legco.biz/products/timerservice/
15BuildRequires: python
16BuildRequires: rpmbuild(macros) >= 1.268
17%pyrequires_eq python-modules
18Requires(post,postun): /usr/sbin/installzopeproduct
19Requires: Zope
20Requires: perl-modules
21BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23%description
24Support module for Zope-Scheduler.
25
26%description -l pl.UTF-8
27Moduł wspomagający dla Zope-Scheduler.
28
29%prep
30%setup -q -c
31
32%build
33CFLAGS="%{rpmcflags}"
34export CFLAGS
35cd %{zope_subname}/timerserver
36rm -rf .#*
37python setup.py build_ext
38
39%install
40rm -rf $RPM_BUILD_ROOT
41
42install -d $RPM_BUILD_ROOT%{_datadir}/%{name}
43install -d $RPM_BUILD_ROOT%{py_sitedir}
44install -d $RPM_BUILD_ROOT%{_sbindir}
45install %{SOURCE1} $RPM_BUILD_ROOT%{_sbindir}/Zope-timerserver_remover
46
47cp -af %{zope_subname}/timerserver $RPM_BUILD_ROOT%{py_sitedir}/%{module}
48cp -af %{zope_subname}/{zpt,*.py,version.txt} $RPM_BUILD_ROOT%{_datadir}/%{name}
49
50%py_comp $RPM_BUILD_ROOT%{_datadir}/%{name}
51%py_ocomp $RPM_BUILD_ROOT%{_datadir}/%{name}
52%py_comp $RPM_BUILD_ROOT%{py_sitedir}/%{module}
53%py_ocomp $RPM_BUILD_ROOT%{py_sitedir}/%{module}
54
55%clean
56rm -rf $RPM_BUILD_ROOT
57
58%post
59/usr/sbin/installzopeproduct %{_datadir}/%{name} %{zope_subname}
60
61# ln -s %{py_sitedir}/%{module} %{_prefix}/lib/zope/lib/python/timerserver
62if [ "$1" = 1 ]; then
63 echo "%import timerserver" >> /etc/zope/main/zope.conf
64 echo "<timer-server>" >> /etc/zope/main/zope.conf
65 echo "</timer-server>" >> /etc/zope/main/zope.conf
66fi
67
68%service -q zope restart
69
70%preun
71/usr/sbin/Zope-timerserver_remover
72
73%postun
74if [ "$1" = "0" ]; then
75 /usr/sbin/installzopeproduct -d %{zope_subname}
76 %service -q zope restart
77fi
78
79%files
80%defattr(644,root,root,755)
81%attr(755,root,root) %{_sbindir}/Zope-timerserver_remover
82%doc %{zope_subname}/{CREDITS.txt,INSTALL.txt}
83%{_datadir}/%{name}
84%{py_sitedir}/%{module}
This page took 0.064331 seconds and 5 git commands to generate.