-
%include /usr/lib/rpm/macros.python
-
%define zope_subname CMFCollector
-
-Summary: CMFCollector is an issue collector for Zope.
-Summary(pl): CMFCollector jest dodatkiem do Zope umo¿liwiaj±cy zbieranie wyników
+Summary: An issue collector for Zopei
+Summary(pl): Dodatek do Zope umo¿liwiaj±cy zbieranie wyników
Name: Zope-%{zope_subname}
-Version: 0.9b
+Version: 0.92
Release: 1
-License: GNU
+License: GPL
Group: Development/Tools
-#Source0: http://cvs.zope.org/CMF/%{zope_subname}/%{zope_subname}.tar.gz?tarball=1
-Source0: %{zope_subname}.tar.gz
-# Source0-md5: 151c906d1058115f3f98155ec042f8fe
-URL: http://cvs.zope.org/CMF/%{zope_subname}/
+Source0: http://zope.org/Members/bowerymarc/%{zope_subname}-update/%{version}/%{zope_subname}.%{version}.tgz
+# Source0-md5: e8daa9e88959edc4e6e8cc03ae23abfa
+URL: http://zope.org/Members/bowerymarc/CMFCollector-update/
%pyrequires_eq python-modules
-Requires: Zope
-Requires: CMF
+Requires: Zope-CMF >= 1.2
+Requires: Zope >= 2.4
+Requires(post,postun): /usr/sbin/installzopeproduct
BuildArch: noarch
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
-
-%define product_dir /usr/lib/zope/Products
+Conflicts: CMF
%description
CMFCollector is an issue collector for Zope.
%description -l pl
-CMFCollector jest dodatkiem do Zope umo¿liwiaj±cy zbieranie wyników
+CMFCollector jest dodatkiem do Zope umo¿liwiaj±cym zbieranie wyników.
%prep
-%setup -q -c %{zope_subname}.tar.gz
-
-%build
+%setup -q -n %{zope_subname}
+find . -type f -name .DS_Store | xargs rm -rf
%install
rm -rf $RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT%{_datadir}/%{name}
-install -d $RPM_BUILD_ROOT%{product_dir}
-cp -af * $RPM_BUILD_ROOT%{product_dir}/%{zope_subname}
+cp -af {Extensions,dtml,help,image_sources,skins,tests,*.py,*.zexp,version.txt} $RPM_BUILD_ROOT%{_datadir}/%{name}
-%py_comp $RPM_BUILD_ROOT%{product_dir}/%{zope_subname}
-%py_ocomp $RPM_BUILD_ROOT%{product_dir}/%{zope_subname}
+%py_comp $RPM_BUILD_ROOT%{_datadir}/%{name}
+%py_ocomp $RPM_BUILD_ROOT%{_datadir}/%{name}
-rm -rf $RPM_BUILD_ROOT%{product_dir}/%{zope_subname}/*.txt
-find $RPM_BUILD_ROOT -type f -name "*.py" -exec rm -rf {} \;;
+# find $RPM_BUILD_ROOT -type f -name "*.py" -exec rm -rf {} \;;
%clean
rm -rf $RPM_BUILD_ROOT
%post
+/usr/sbin/installzopeproduct %{_datadir}/%{name} %{zope_subname}
if [ -f /var/lock/subsys/zope ]; then
/etc/rc.d/init.d/zope restart >&2
fi
-%preun
-
%postun
-if [ -f /var/lock/subsys/zope ]; then
- /etc/rc.d/init.d/zope restart >&2
+if [ "$1" = "0" ]; then
+ /usr/sbin/installzopeproduct -d %{zope_subname}
+ if [ -f /var/lock/subsys/zope ]; then
+ /etc/rc.d/init.d/zope restart >&2
+ fi
fi
%files
%defattr(644,root,root,755)
-%doc %{zope_subname}/*.txt
-%{product_dir}/%{zope_subname}
+%doc INSTALL.txt KNOWN_PROBLEMS.txt README.txt TODO.txt RELEASE_NOTES.txt
+%{_datadir}/%{name}