]>
Commit | Line | Data |
---|---|---|
e9fd392d JK |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without python2 # CPython 2.x module | |
4 | %bcond_without python3 # CPython 3.x module | |
5 | ||
6 | Summary: Common dirs for Zope libraries | |
7 | Summary(pl.UTF-8): Katalogi wspólne dla bibliotek Zope | |
8 | Name: python-zope-base | |
9 | Version: 1.0 | |
a4f30b67 | 10 | Release: 8 |
e9fd392d JK |
11 | License: Public Domain |
12 | Group: Libraries/Python | |
13 | BuildRequires: rpm-pythonprov | |
14 | BuildRequires: rpmbuild(macros) >= 1.219 | |
15 | %if %{with python2} | |
16 | BuildRequires: python | |
17 | BuildRequires: python-modules | |
18 | %endif | |
19 | %if %{with python3} | |
20 | BuildRequires: python3 | |
21 | BuildRequires: python3-modules | |
22 | %endif | |
e9fd392d | 23 | Provides: Zope-dirs |
a8959964 | 24 | Obsoletes: Zope-dirs < 1.0-8 |
e9fd392d JK |
25 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
26 | ||
27 | # nothing to put there | |
28 | %define _enable_debug_packages 0 | |
29 | ||
30 | %description | |
31 | Common dirs for Zope libraries. | |
32 | ||
33 | %description -l pl.UTF-8 | |
34 | Katalogi wspólne dla bibliotek Zope. | |
35 | ||
36 | %package -n python3-zope-base | |
37 | Summary: Common dirs for Zope libraries | |
38 | Summary(pl.UTF-8): Katalogi wspólne dla bibliotek Zope | |
39 | Group: Libraries/Python | |
40 | ||
41 | %description -n python3-zope-base | |
42 | Common dirs for Zope libraries. | |
43 | ||
44 | %description -n python3-zope-base -l pl.UTF-8 | |
45 | Katalogi wspólne dla bibliotek Zope. | |
46 | ||
47 | %prep | |
48 | ||
49 | %install | |
50 | rm -rf $RPM_BUILD_ROOT | |
b1389b8b | 51 | install -d $RPM_BUILD_ROOT{%{py_sitescriptdir},%{py3_sitescriptdir},%{py_sitedir},%{py3_sitedir}}/zope |
e9fd392d JK |
52 | |
53 | %if %{with python2} | |
b1389b8b JR |
54 | touch $RPM_BUILD_ROOT{%{py_sitescriptdir},%{py_sitedir}}/zope/__init__.py |
55 | %py_comp $RPM_BUILD_ROOT{%{py_sitescriptdir},%{py_sitedir}}/zope | |
56 | %py_ocomp $RPM_BUILD_ROOT{%{py_sitescriptdir},%{py_sitedir}}/zope | |
e9fd392d JK |
57 | %py_postclean |
58 | %endif | |
59 | ||
60 | %if %{with python3} | |
b1389b8b JR |
61 | touch $RPM_BUILD_ROOT{%{py3_sitescriptdir},%{py3_sitedir}}/zope/__init__.py |
62 | %py3_comp $RPM_BUILD_ROOT{%{py3_sitescriptdir},%{py3_sitedir}}/zope | |
63 | %py3_ocomp $RPM_BUILD_ROOT{%{py3_sitescriptdir},%{py3_sitedir}}/zope | |
e9fd392d JK |
64 | %endif |
65 | ||
66 | %clean | |
67 | rm -rf $RPM_BUILD_ROOT | |
68 | ||
69 | %if %{with python2} | |
70 | %files | |
71 | %defattr(644,root,root,755) | |
b1389b8b | 72 | %{py_sitedir}/zope |
3d9b86ad | 73 | %{py_sitescriptdir}/zope |
e9fd392d JK |
74 | %endif |
75 | ||
76 | %if %{with python3} | |
77 | %files -n python3-zope-base | |
78 | %defattr(644,root,root,755) | |
b1389b8b | 79 | %{py3_sitedir}/zope |
3d9b86ad | 80 | %{py3_sitescriptdir}/zope |
e9fd392d | 81 | %endif |