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
8 License: Zope Public License (ZPL)
9 Group: Networking/Daemons
10 Source0: http://www.zope.org/Products/%{name}/%{version}/%{version}/%{name}-%{version}-src.tgz
11 # Source0-md5: 60ddbd685febb73e10ecdb5da6eda895
13 Source2: %{name}.logrotate
14 Source3: %{name}.sysconfig
15 Source4: %{name}-start.sh
16 Source5: %{name}.instance
17 Source6: http://zope.org/Documentation/Guides/ZCMG/Tarred%20HTML%202.1.1/ZCMG.html.tgz
18 # Source6-md5: 4c52eebc2e874a0590ac9c04e222e9f1
19 Source7: http://www.zope.org/Documentation/Guides/DTML/Compressed%20html%202.1.1/DTML.html.tgz
20 # Source7-md5: 10f363dd061a1af8d472c51c32fa0a0e
21 Source8: http://www.zope.org/Documentation/Guides/ZSQL/2.1.1/ZSQL.html.tgz
22 # Source8-md5: 0cddb5688fc0f886db468da08251fb81
23 Source9: http://www.zope.org/Documentation/Guides/ZDG/HTML%201.2/ZDG.html.tgz
24 # Source-md5: 0344ca88acb8a71688d2925975a55443
25 Source10: http://www.zope.org/Documentation/Guides/ZAG/HTML%201.0/ZAG.html.tgz
26 # Source10-md5: b28bfc4ba4bee880767fcf89d79532d2
27 Source11: http://openbsd.secsup.org/distfiles/zopebook-2.5/ZopeBook.tgz
28 # Source11-md5: 268c38a4c7d9f7334cdc98b0a152f8da
29 Patch0: %{name}-http-virtual-cache.patch
30 URL: http://www.zope.org/
31 BuildRequires: python-devel >= 2.3
34 Requires(pre): /usr/bin/getgid
35 Requires(pre): /bin/id
36 Requires(pre): /usr/sbin/groupadd
37 Requires(pre): /usr/sbin/useradd
38 Requires(postun): /usr/sbin/userdel
39 Requires(postun): /usr/sbin/groupdel
40 Requires(post,preun): /sbin/chkconfig
42 Requires: python >= 2.3
43 Requires: python-modules >= 2.3
44 Requires: python-libs >= 2.3
45 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
47 %define python_prefix %(echo `python -c "import sys; print sys.prefix"`)
48 %define python_version %(echo `python -c "import sys; print sys.version[:3]"`)
49 %define python_libdir %{python_prefix}/lib/python%{python_version}
50 %define python_includedir %{python_prefix}/include/python%{python_version}
51 %define python_sitedir %{python_libdir}/site-packages
52 %define python_configdir %{python_libdir}/config
54 %define python_compile python -c "import compileall; compileall.compile_dir('.')"
55 %define python_compile_opt python -O -c "import compileall; compileall.compile_dir('.')"
58 The Z Object Programming Environment (Zope) is a free, Open Source
59 Python-based application server for building high-performance, dynamic
60 web sites, using a powerful and simple scripting object model and
61 high-performance, integrated object database.
64 Zope es una aplicación basada en Python, Open Source[tm], para la
65 construcción de sitios dinámicos, usa un modelo de escritura de
66 guiones poderoso y sencillo. Para instalar la aplicación Zope, instale
67 ese paquete y después, Zope-server, para un servidor HTTP integrado
68 simple, Zope-pcgi, para uso con el servidor Apache. Si desea instalar
69 solamente algunas partes de la aplicación Zope, están diponibles otros
70 subpaquetes, usted debe instalar éstos en vez de ese RPM.
73 Zope (Z Object Programming Environment - Obiektowe ¦rodowisko
74 Programistyczne Z) jest opartym o Pythona serwerem aplikacji do
75 tworzenia wysoko wydajnych, dynamicznych serwisów WWW, przy u¿yciu
76 u¿ytecznego i prostego modelu obiektowego skryptów oraz wysoko
77 wydajnej zintegrowanej obiektowej bazy danych.
80 Zope é uma aplicação baseada em Python, Open Source[tm], para
81 construção de sites dinâmicos, usando um modelo de scripting poderoso
82 e simples Para instalar o Zope, instale esse pacote e depois, ou o
83 Zope-server, para um servidor HTTP integrado simples, ou Zope-pcgi,
84 para uso com o Apache. Se você quiser instalar apenas algumas partes
85 do Zope, outros sub-pacotes estão disponíveis, e você deveria instalar
86 eles ao invés desse RPM.
89 %setup -q -n %{name}-%{version}-src -a6
91 mkdir ZopeContentManagersGuide GuideToDTML GuideToZSQL ZopeDevelopersGuide
92 mkdir ZopeAdminGuide ZopeBook
93 tar xzf %{SOURCE6} -C ZopeContentManagersGuide
94 tar xzf %{SOURCE7} -C GuideToDTML
95 tar xzf %{SOURCE8} -C GuideToZSQL
96 tar xzf %{SOURCE9} -C ZopeDevelopersGuide
97 tar xzf %{SOURCE10} -C ZopeAdminGuide
98 tar xzf %{SOURCE11} -C ZopeBook
101 perl -pi -e "s|data_dir\s+=\s+.*?join\(INSTANCE_HOME, 'var'\)|data_dir=INSTANCE_HOME|" lib/python/Globals.py
104 find lib/python -type f -and \( -name 'Setup' -or -name '.cvsignore' \) -exec rm -f \{\} \;
105 find -type f -and \( -name '*.c' -or -name '*.h' -or -name 'Makefile*' \) -exec rm -f \{\} \;
106 rm -f ZServer/medusa/monitor_client_win32.py
109 rm -rf $RPM_BUILD_ROOT
110 install -d $RPM_BUILD_ROOT{%{_bindir},%{_sbindir},%{_libdir}/zope} \
111 $RPM_BUILD_ROOT{/etc/{rc.d/init.d,zope/instances,logrotate.d,sysconfig}} \
112 $RPM_BUILD_ROOT{/var/log/zope,/var/lib/zope/main}
114 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/zope
115 install %{SOURCE2} $RPM_BUILD_ROOT/etc/logrotate.d/zope
116 install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/zope
117 install %{SOURCE4} $RPM_BUILD_ROOT%{_sbindir}/zope-start
118 install %{SOURCE5} $RPM_BUILD_ROOT/etc/zope/instances/main
120 cp -a lib/python/* $RPM_BUILD_ROOT%{_libdir}/zope
121 cp -a ZServer/ utilities/ import/ $RPM_BUILD_ROOT%{_libdir}/zope
122 find $RPM_BUILD_ROOT%{_libdir}/zope -type f -name '*.py' -or -name '*.txt' | xargs -r rm -f
123 cp -a ZServer/medusa/test/* $RPM_BUILD_ROOT%{_libdir}/zope/ZServer/medusa/test/
125 install zpasswd.py $RPM_BUILD_ROOT%{_bindir}/zpasswd
126 install z2.py $RPM_BUILD_ROOT%{_libdir}/zope
127 install var/Data.fs $RPM_BUILD_ROOT/var/lib/zope/main/Data.fs
129 python $RPM_BUILD_ROOT%{_bindir}/zpasswd -u zope -p zope -d localhost \
130 $RPM_BUILD_ROOT/var/lib/zope/main/access
132 touch $RPM_BUILD_ROOT/var/log/zope/main.log
133 touch $RPM_BUILD_ROOT/var/log/zope/main-detailed.log
136 rm -rf $RPM_BUILD_ROOT
139 if [ -z "`getgid zope`" ]; then
140 echo "Making group zope"
141 /usr/sbin/groupadd -r -f zope
143 if [ -z "`id -u zope 2>/dev/null`" ]; then
144 echo "Making user zope"
145 /usr/sbin/useradd -r -d /var/lib/zope/main -s /bin/false -c "Zope User" -g zope zope
149 /sbin/chkconfig --add zope
150 if [ -f /var/lib/zope/Data.fs ]; then
151 echo "Found the database in old location. Migrating..."
152 if [ -f /var/lock/subsys/zope ]; then
153 /etc/rc.d/init.d/zope stop >&2
156 [ -d /var/lib/zope/main ] && cd /var/lib/zope && mv -r * ./main
157 if [ "x$was_stopped" = "x1" ]; then
158 /etc/rc.d/init.d/zope start
160 echo "Migration completed (new db location is /var/lib/zope/main)"
161 elif [ -f /var/lock/subsys/zope ]; then
162 /etc/rc.d/init.d/zope restart >&2
164 echo "Create inituser using \"zpasswd inituser\" in directory \"/var/lib/zope/main\"" >&2
165 echo "Run then \"/etc/rc.d/init.d/zope start\" to start Zope." >&2
169 if [ "$1" = "0" ]; then
170 if [ -f /var/lock/subsys/zope ]; then
171 /etc/rc.d/init.d/zope stop
173 /sbin/chkconfig --del zope
177 if [ "$1" = "0" ] ; then
178 echo "Removing user zope"
179 /usr/sbin/userdel zope >/dev/null 2>&1 || :
180 echo "Removing group zope"
181 /usr/sbin/groupdel zope >/dev/null 2>&1 || :
185 %defattr(644,root,root,755)
186 %doc doc/*.txt *.txt ZopeContentManagersGuide GuideToZSQL ZopeDevelopersGuide ZopeAdminGuide ZopeBook
187 %attr(755,root,root) /etc/rc.d/init.d/zope
188 %attr(755,root,root) %{_bindir}/*
189 %attr(755,root,root) %{_sbindir}/*
191 %attr(640,root,root) %dir /var/lib/zope
192 %attr(1771,root,zope) %dir /var/lib/zope/main
193 %attr(660,root,zope) %config(noreplace) %verify(not md5 size mtime) /var/lib/zope/main/*
194 %attr(640,root,root) %config(noreplace) %verify(not md5 size mtime) /etc/zope/instances/*
195 %attr(640,root,root) /etc/logrotate.d/zope
196 %attr(640,root,root) /etc/sysconfig/zope
197 %attr(640,root,root) /etc/zope
198 %attr(640,root,root) /etc/zope/instances
199 %ghost /var/log/zope/main.log
200 %ghost /var/log/zope/main-detailed.log