]> git.pld-linux.org Git - packages/python-py.git/blob - python-py.spec
- python3.6
[packages/python-py.git] / python-py.spec
1 #
2 # Conditional build:
3 %bcond_without  doc     # HTML documentation build
4 %bcond_without  python2 # CPython 2.x module
5 %bcond_without  python3 # CPython 3.x module
6
7 %define         module  py
8 Summary:        Library with cross-python path, ini-parsing, io, code, log facilities
9 Summary(pl.UTF-8):      Biblioteka wspierająca obsługę ścieżek, ini, we/wy, kodowania i logowania w wielu Pythonach
10 Name:           python-%{module}
11 Version:        1.4.31
12 Release:        2
13 License:        MIT
14 Group:          Development/Languages/Python
15 #Source0Download: https://pypi.python.org/pypi/py
16 Source0:        https://pypi.python.org/packages/source/p/py/py-%{version}.tar.gz
17 # Source0-md5:  5d2c63c56dc3f2115ec35c066ecd582b
18 Source1:        http://docs.python.org/objects.inv?/python-objects.inv
19 # Source1-md5:  3d3c0b594b2e91d559418c107d973633
20 Patch0:         %{name}-offline.patch
21 URL:            https://pypi.python.org/pypi/py
22 %if %{with python2}
23 BuildRequires:  python-devel >= 1:2.5
24 BuildRequires:  python-setuptools >= 7.0
25 %endif
26 %if %{with python3}
27 BuildRequires:  python3-devel >= 1:3.2
28 BuildRequires:  python3-modules >= 1:3.2
29 BuildRequires:  python3-setuptools >= 7.0
30 %endif
31 BuildRequires:  rpm-pythonprov
32 BuildRequires:  rpmbuild(macros) >= 1.710
33 %{?with_doc:BuildRequires:      sphinx-pdg >= 1.0}
34 %{?with_doc:BuildRequires:      python-devel-tools}
35 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
36
37 %description
38 The py lib is a Python development support library featuring the
39 following tools and modules:
40  - py.path: uniform local and svn path objects
41  - py.apipkg: explicit API control and lazy-importing
42  - py.iniconfig: easy parsing of .ini files
43  - py.code: dynamic code generation and introspection
44
45 %description -l pl.UTF-8
46 Biblioteka py to biblioteka wpierająca tworzenie oprogramowania w
47 Pythonie. Zawiera następujące narzędzia i moduły:
48  - py.path - jednolite obiekty ścieżek lokalnych i svn
49  - py.apipkg - bezpośrednia kontrola API i leniwego importowania
50  - py.iniconfig - łatwa analiza plików .ini
51  - py.code - dynamiczne generowanie kodu i introspekcji
52
53 %package -n python3-py
54 Summary:        Library with cross-python path, ini-parsing, io, code, log facilities
55 Summary(pl.UTF-8):      Biblioteka wspierająca obsługę ścieżek, ini, we/wy, kodowania i logowania w wielu Pythonach
56 Group:          Development/Languages/Python
57
58 %description -n python3-py
59 The py lib is a Python development support library featuring the
60 following tools and modules:
61 - py.path: uniform local and svn path objects
62 - py.apipkg: explicit API control and lazy-importing
63 - py.iniconfig: easy parsing of .ini files
64 - py.code: dynamic code generation and introspection
65
66 %description -n python3-py -l pl.UTF-8
67 Biblioteka py to biblioteka wpierająca tworzenie oprogramowania w
68 Pythonie. Zawiera następujące narzędzia i moduły:
69  - py.path - jednolite obiekty ścieżek lokalnych i svn
70  - py.apipkg - bezpośrednia kontrola API i leniwego importowania
71  - py.iniconfig - łatwa analiza plików .ini
72  - py.code - dynamiczne generowanie kodu i introspekcji
73
74 %prep
75 %setup -q -n %{module}-%{version}
76 %patch0 -p1
77
78 cp -p %{SOURCE1} doc
79
80 %build
81 %if %{with python2}
82 %py_build
83 %endif
84
85 %if %{with python3}
86 %py3_build
87 %endif
88
89 %if %{with doc}
90 PYTHONPATH=$(pwd) \
91 %{__make} -C doc html
92 %endif
93
94 %install
95 rm -rf $RPM_BUILD_ROOT
96
97 %if %{with python2}
98 %py_install
99
100 %py_postclean
101 %endif
102
103 %if %{with python3}
104 %py3_install
105 %endif
106
107 %clean
108 rm -rf $RPM_BUILD_ROOT
109
110 %if %{with python2}
111 %files
112 %defattr(644,root,root,755)
113 %doc CHANGELOG LICENSE README.txt %{?with_doc:doc/_build/html}
114 %{py_sitescriptdir}/%{module}
115 %{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
116 %endif
117
118 %if %{with python3}
119 %files -n python3-py
120 %defattr(644,root,root,755)
121 %doc CHANGELOG LICENSE README.txt %{?with_doc:doc/_build/html}
122 %{py3_sitescriptdir}/%{module}
123 %{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
124 %endif
This page took 0.037683 seconds and 3 git commands to generate.