]> git.pld-linux.org Git - packages/Zope3.git/blob - Zope3.spec
- /usr/share/zope3/lib/python directory added to the package (so external
[packages/Zope3.git] / Zope3.spec
1 Summary:        An application server and portal toolkit for building Web sites
2 Summary(es):    Un servidor de aplicaciones y un conjunto de herramientas para la construcción de sitios Web
3 Summary(pl):    Serwer aplikacji i toolkit portalowy do tworzenia serwisów WWW
4 Summary(pt_BR): Um servidor de aplicações e um conjunto de ferramentas para construção de sites Web
5 Name:           Zope3
6 Version:        3.1.0
7 %define         sub_ver c1
8 Release:        0.%{sub_ver}.0.2
9 License:        Zope Public License (ZPL)
10 Group:          Networking/Daemons
11 Source0:        http://www.zope.org/Products/Zope3/%{version}%{sub_ver}/%{name}-%{version}%{sub_ver}.tgz
12 # Source0-md5:  e22eeeae5de89c0eea9edabe3f2c3c4d
13 Source1:        %{name}.init
14 Source2:        %{name}.sysconfig
15 Source3:        %{name}.logrotate
16 Source4:        mkzope3instance
17 Source5:        installzope3package
18 Patch0:         %{name}-skeleton_path.patch
19 URL:            http://dev.zope.org/Zope3
20 BuildRequires:  python-devel >= 1:2.4.1
21 BuildRequires:  perl-base
22 BuildRequires:  rpmbuild(macros) >= 1.213
23 Requires(post,preun):   rc-scripts
24 Requires(pre):  /bin/id
25 Requires(pre):  /usr/bin/getgid
26 Requires(pre):  /usr/sbin/groupadd
27 Requires(pre):  /usr/sbin/useradd
28 Requires(postun):       /usr/sbin/groupdel
29 Requires(postun):       /usr/sbin/userdel
30 Requires(post,preun):   /sbin/chkconfig
31 Requires:       expat >= 1.95.7
32 Requires:       logrotate
33 Requires:       python >= 2.4.1
34 Requires:       python-modules >= 2.4.1
35 Requires:       python-libs >= 2.4.1
36 Requires:       python-zope = %{epoch}:%{version}-%{release}
37 %pyrequires_eq  python
38 Provides:       group(zope)
39 Provides:       user(zope)
40 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41
42 %define         zope_libdir /usr/lib/zope3
43 %define         zope_datadir /usr/share/zope3
44
45 %description
46 The Z Object Programming Environment (Zope) is a free, Open Source
47 Python-based application server for building high-performance, dynamic
48 web sites, using a powerful and simple scripting object model and
49 high-performance, integrated object database.
50
51 This project is a redesign of Zope 2 and seeks to improve the Zope
52 development experience through the use of Interfaces and Components.
53
54 %description -l es
55 Zope es una aplicación basada en Python, Open Source[tm], para la
56 construcción de sitios dinámicos, usa un modelo de escritura de
57 guiones poderoso y sencillo. Para instalar la aplicación Zope, instale
58 ese paquete y después, Zope-server, para un servidor HTTP integrado
59 simple, Zope-pcgi, para uso con el servidor Apache. Si desea instalar
60 solamente algunas partes de la aplicación Zope, están diponibles otros
61 subpaquetes, usted debe instalar éstos en vez de ese RPM.
62
63 %description -l pl
64 Zope (Z Object Programming Environment - Obiektowe ¦rodowisko
65 Programistyczne Z) jest opartym o Pythona serwerem aplikacji do
66 tworzenia wysoko wydajnych, dynamicznych serwisów WWW, przy u¿yciu
67 u¿ytecznego i prostego modelu obiektowego skryptów oraz wysoko
68 wydajnej zintegrowanej obiektowej bazy danych.
69
70 %description -l pt_BR
71 Zope é uma aplicação baseada em Python, Open Source[tm], para
72 construção de sites dinâmicos, usando um modelo de scripting poderoso
73 e simples Para instalar o Zope, instale esse pacote e depois, ou o
74 Zope-server, para um servidor HTTP integrado simples, ou Zope-pcgi,
75 para uso com o Apache. Se você quiser instalar apenas algumas partes
76 do Zope, outros sub-pacotes estão disponíveis, e você deveria instalar
77 eles ao invés desse RPM.
78
79 %package -n python-zope
80 Summary:        Python packages developed as part of the Zope 3 project
81 Summary(pl):    Modu³y Pythona rozwijane w projekcie Zope 3
82 Group:          Development/Tools
83 Provides:       ZopeInterface
84 Provides:       python-zope-cachedescriptors = %{epoch}:%{version}-%{release}
85 Provides:       python-zope-component = %{epoch}:%{version}-%{release}
86 Provides:       python-zope-configuration = %{epoch}:%{version}-%{release}
87 Provides:       python-zope-deprecation = %{epoch}:%{version}-%{release}
88 Provides:       python-zope-documenttemplate = %{epoch}:%{version}-%{release}
89 Provides:       python-zope-event = %{epoch}:%{version}-%{release}
90 Provides:       python-zope-exceptions = %{epoch}:%{version}-%{release}
91 Provides:       python-zope-hookable = %{epoch}:%{version}-%{release}
92 Provides:       python-zope-i18n = %{epoch}:%{version}-%{release}
93 Provides:       python-zope-i18nmessageid = %{epoch}:%{version}-%{release}
94 Provides:       python-zope-index = %{epoch}:%{version}-%{release}
95 Provides:       python-zope-interface = %{epoch}:%{version}-%{release}
96 Provides:       python-zope-modulealias = %{epoch}:%{version}-%{release}
97 Provides:       python-zope-pagetemplate = %{epoch}:%{version}-%{release}
98 Provides:       python-zope-proxy = %{epoch}:%{version}-%{release}
99 Provides:       python-zope-publisher = %{epoch}:%{version}-%{release}
100 Provides:       python-zope-schema = %{epoch}:%{version}-%{release}
101 Provides:       python-zope-security = %{epoch}:%{version}-%{release}
102 Provides:       python-zope-server = %{epoch}:%{version}-%{release}
103 Provides:       python-zope-structuredtext = %{epoch}:%{version}-%{release}
104 Provides:       python-zope-tal = %{epoch}:%{version}-%{release}
105 Provides:       python-zope-tales = %{epoch}:%{version}-%{release}
106 Provides:       python-zope-testing = %{epoch}:%{version}-%{release}
107 Provides:       python-zope-thread = %{epoch}:%{version}-%{release}
108 Obsoletes:      ZopeInterface
109
110 %description -n python-zope
111 The "zope" package is a pure namespace package holding packages
112 developed as part of the Zope 3 project.
113
114 Generally, the immediate subpackages of the "zope" package should be
115 useful and usable outside of the Zope application server. Subpackages
116 of the "zope" package should have minimal interdependencies, although
117 most depend on "zope.interface".
118
119 %description -n python-zope -l pl
120 Pakiet "zope" to pakiet czystej przestrzeni nazw przechowuj±cej
121 pakiety tworzone jako czê¶æ projektu Zope 3.
122
123 Ogólnie bezpo¶rednie podpakiety pakietu "zope" powinny byæ przydatne i
124 u¿ywalne poza serwerem aplikacji Zope. Podpakiety pakietu "zope"
125 powinny mieæ minimalne zale¿no¶ci wzajemne, chocia¿ wiêkszo¶æ zale¿y
126 od "zope.interface".
127
128 %prep
129 %setup -q -n Zope-%{version}%{sub_ver}
130 %patch0 -p1
131
132 cp %{SOURCE4} ./mkzope3instance
133 chmod a+x ./mkzope3instance
134
135 %build
136 ./configure \
137         --prefix=%{zope_libdir} \
138         --force
139 %{__make}
140
141 %install
142 rm -rf $RPM_BUILD_ROOT
143
144 install -d $RPM_BUILD_ROOT{%{py_sitedir},%{_sbindir},%{zope_datadir}/lib/python} \
145         $RPM_BUILD_ROOT{/etc/logrotate.d,/etc/sysconfig,/etc/rc.d/init.d} \
146         $RPM_BUILD_ROOT{/var/lib/zope3/main,/var/run/zope3,/var/log/zope3/main} \
147 $RPM_BUILD_ROOT%{_sysconfdir}/zope3/main
148
149 python install.py -q install --skip-build --home "%{zope_libdir}" --root "$RPM_BUILD_ROOT"
150 mv $RPM_BUILD_ROOT%{zope_libdir}/lib/python/zope  $RPM_BUILD_ROOT%{py_sitedir}
151 rm $RPM_BUILD_ROOT%{zope_libdir}/zopeskel/bin/{*.bat.in,zopeservice*}
152 mv $RPM_BUILD_ROOT%{zope_libdir}/zopeskel $RPM_BUILD_ROOT%{_sysconfdir}/zope3
153
154 cat >$RPM_BUILD_ROOT%{zope_libdir}/bin/mkzopeinstance <<EOF
155 #!/usr/bin/python
156 import sys
157 from zope.app.server.mkzopeinstance import main
158 sys.exit(main(from_checkout=False))
159 EOF
160
161 PYTHONPATH="$RPM_BUILD_ROOT%{py_sitedir}:$RPM_BUILD_ROOT%{zope_libdir}/lib/python" \
162         DESTDIR="$RPM_BUILD_ROOT" ./mkzope3instance main \
163 -u zope:zope -s $RPM_BUILD_ROOT%{_sysconfdir}/zope3/zopeskel
164
165 cat >> $RPM_BUILD_ROOT%{py_sitedir}/zope/app/__init__.py <<EOF
166 import sys
167 sys.path.insert(0,"%{zope_libdir}/lib/python")
168 sys.path.insert(0,"%{zope_datadir}/lib/python")
169 EOF
170
171 %py_comp $RPM_BUILD_ROOT%{py_sitedir}/zope
172 %py_ocomp $RPM_BUILD_ROOT%{py_sitedir}/zope
173 %py_postclean
174
175 for f in zconfig zconfig_schema2html zopetest; do
176         ln -sf %{zope_libdir}/bin/"$f" $RPM_BUILD_ROOT%{_sbindir}/"$f"
177 done
178 for f in mkzeoinst runzeo zdctl zdrun zeoctl zeopasswd ; do
179         ln -sf %{zope_libdir}/bin/"$f".py $RPM_BUILD_ROOT%{_sbindir}/"$f"
180 done
181
182 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/zope3
183 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/zope3
184 install %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/zope3
185 install %{SOURCE4} $RPM_BUILD_ROOT%{_sbindir}/mkzope3instance
186 install %{SOURCE5} $RPM_BUILD_ROOT%{_sbindir}/installzope3package
187
188 touch $RPM_BUILD_ROOT/var/log/zope3/main/access.log
189 touch $RPM_BUILD_ROOT/var/log/zope3/main/transcript.log
190 touch $RPM_BUILD_ROOT/var/log/zope3/main/z3.log
191
192 %clean
193 rm -rf $RPM_BUILD_ROOT
194
195 %pre
196 %groupadd -g 112 zope
197 %useradd -u 112 -d /var/lib/zope/main -s /bin/false -c "Zope User" -g zope zope
198
199 %post
200 /sbin/chkconfig --add zope3
201 if [ -f /var/lock/subsys/zope3-main ]; then
202         /etc/rc.d/init.d/zope3 restart 1>&2
203 else
204         echo "Run \"/etc/rc.d/init.d/zopew start\" to start Zope 3 daemon."
205 fi
206
207 %preun
208 if [ "$1" = "0" ]; then
209         if [ -f /var/lock/subsys/zope3 ]; then
210                 /etc/rc.d/init.d/zope3 stop
211         fi
212         /sbin/chkconfig --del zope3
213 fi
214
215 %postun
216 if [ "$1" = "0" ] ; then
217         %userremove zope
218         %groupremove zope
219 fi
220
221 %files
222 %defattr(644,root,root,755)
223 %doc Zope/doc/*
224 %attr(754,root,root) /etc/rc.d/init.d/zope3
225 %attr(755,root,root) %{_sbindir}/*
226 %dir %{zope_libdir}
227 %dir %{zope_libdir}/bin
228 %attr(755,root,root) %{zope_libdir}/bin/*
229 %{zope_libdir}/include
230 %{zope_libdir}/lib
231 %{zope_datadir}
232 %{py_sitedir}/zope/app
233 %attr(775,root,zope) %dir /var/run/zope3
234 %attr(755,root,root) %dir /var/lib/zope3
235 %attr(775,root,root) %dir /var/lib/zope3/main
236 %dir /var/lib/zope3/main/bin
237 %attr(755,root,root) %dir /var/lib/zope3/main/bin/*
238 /var/lib/zope3/main%{_sysconfdir}
239 /var/lib/zope3/main/lib
240 /var/lib/zope3/main/log
241 %attr(775,root,zope) %dir /var/lib/zope3/main/var
242 /var/lib/zope3/main/var/README.txt
243 /var/lib/zope3/main/README.txt
244 %attr(755,root,zope) %dir /var/log/zope3
245 %attr(775,root,zope) %dir /var/log/zope3/main
246 %attr(751,root,zope) %dir %{_sysconfdir}/zope3
247 %attr(751,root,zope) %dir %{_sysconfdir}/zope3/main
248 %attr(751,root,zope) %dir %{_sysconfdir}/zope3/main/package-includes
249 %attr(640,root,zope) %dir %{_sysconfdir}/zope3/main/*.conf
250 %{_sysconfdir}/zope3/main/*.zcml
251 %{_sysconfdir}/zope3/main/package-includes/*.zcml
252 %{_sysconfdir}/zope3/main/package-includes/README.txt
253 %dir %{_sysconfdir}/zope3/zopeskel
254 %dir %{_sysconfdir}/zope3/zopeskel/bin
255 %attr(755,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/zope3/zopeskel/bin/*
256 %config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/zope3/zopeskel%{_sysconfdir}
257 %config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/zope3/zopeskel/lib
258 %config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/zope3/zopeskel/log
259 %config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/zope3/zopeskel/var
260 %config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/zope3/zopeskel/README.txt
261 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/zope3
262 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/zope3
263 %ghost /var/log/zope3/main/access.log
264 %ghost /var/log/zope3/main/transcript.log
265 %ghost /var/log/zope3/main/z3.log
266
267 %files -n python-zope
268 %defattr(644,root,root,755)
269 %{py_sitedir}/zope
270 %exclude %{py_sitedir}/zope/app
This page took 0.08637 seconds and 3 git commands to generate.