summaryrefslogtreecommitdiff
path: root/Zope-LocalFS.spec
blob: 44f834e0edde1af4131fe4623abd77f827a2dbf2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59

%define		zope_subname	LocalFS
Summary:	This product allows you to store Zope objects as human-readable files
Summary(pl):	Dodatek umożliwiający praktyczniejsze przetrzymywanie obiektów Zope
Name:		Zope-%{zope_subname}
Version:	1.6
Release:	1
License:	Distributable
Group:		Development/Tools
Source0:	http://www.easyleading.org/Downloads/%{zope_subname}-%{version}-andreas.tar.gz
# Source0-md5:	0196bdc5df0797cd33f5297b5a52c2f8
URL:		http://www.easyleading.org/Members/Eddy/LocalFS-1.6-andreas/
BuildRequires:	python
BuildRequires:	rpmbuild(macros) >= 1.268
%pyrequires_eq	python-modules
Requires(post,postun):	/usr/sbin/installzopeproduct
Requires:	Zope
BuildArch:	noarch
BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)

%description
This product allows you to store Zope objects as human-readable files
in the local file system.

%description -l pl
Dodatek dla Zope umożliwiający przetrzymywanie obiektów Zope w
lokalnym systemie plików.

%prep
%setup -q -n %{zope_subname}

%install
rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT%{_datadir}/%{name}

cp -af {Extensions,dtml,help,www,*.py,version.txt,refresh.txt} $RPM_BUILD_ROOT%{_datadir}/%{name}

%py_comp $RPM_BUILD_ROOT%{_datadir}/%{name}
%py_ocomp $RPM_BUILD_ROOT%{_datadir}/%{name}

# 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}
%service -q zope restart

%postun
if [ "$1" = "0" ]; then
	/usr/sbin/installzopeproduct -d %{zope_subname}
	%service -q zope restart
fi

%files
%defattr(644,root,root,755)
%doc CHANGES LICENSE README TODO
%{_datadir}/%{name}