]> git.pld-linux.org Git - packages/python-sqlalchemy.git/blob - python-sqlalchemy.spec
e4b3e5bb9aa42b04aedb62a0ff5883da32112daf
[packages/python-sqlalchemy.git] / python-sqlalchemy.spec
1 #
2 %bcond_without  python2 # CPython 2.x module
3 %bcond_without  python3 # CPython 3.x module
4 %bcond_without  tests   # unit tests
5
6 %define         module  sqlalchemy
7 Summary:        Database Abstraction Library for Python 2
8 Summary(pl.UTF-8):      Biblioteka abstrakcji baz danych dla Pythona 2
9 Name:           python-%{module}
10 Version:        1.2.7
11 Release:        1
12 License:        MIT
13 Group:          Libraries/Python
14 #Source0Download: https://pypi.org/simple/sqlalchemy/
15 Source0:        https://files.pythonhosted.org/packages/source/S/SQLAlchemy/SQLAlchemy-%{version}.tar.gz
16 # Source0-md5:  d228d11a6f41b94cb3a3789b5cdbd111
17 Patch0:         %{name}-tests.patch
18 URL:            http://www.sqlalchemy.org/
19 BuildRequires:  rpm-pythonprov
20 BuildRequires:  rpmbuild(macros) >= 1.714
21 %if %{with python2}
22 BuildRequires:  python-devel >= 1:2.7
23 BuildRequires:  python-modules >= 1:2.7
24 BuildRequires:  python-setuptools >= 0.6-0.a9.1
25 %if %{with tests}
26 BuildRequires:  python-mock
27 BuildRequires:  python-pytest >= 2.5.2
28 BuildRequires:  python-pytest-xdist
29 %endif
30 %endif
31 %if %{with python3}
32 BuildRequires:  python3-devel >= 1:3.2
33 BuildRequires:  python3-modules >= 1:3.2
34 BuildRequires:  python3-setuptools >= 0.6-0.a9.1
35 %if %{with tests}
36 BuildRequires:  python3-pytest >= 2.5.2
37 BuildRequires:  python3-pytest-xdist
38 %endif
39 %endif
40 Requires:       python-modules
41 Provides:       python-SQLAlchemy = %{version}-%{release}
42 Obsoletes:      python-SQLAlchemy < 0.9.8
43 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
44
45 %description
46 The Python SQL toolkit and Object Relational Mapper that gives
47 application developers the full power and flexibility of SQL.
48 SQLAlchemy provides a full suite of well known enterprise-level
49 persistence patterns, designed for efficient and high-performing
50 database access, adapted into a simple and Pythonic domain language.
51
52 Python 2.x version.
53
54 %description -l pl.UTF-8
55 Zestaw narzędzi SQL oraz odwzorowań obiektowo-relacyjnych dla Pythona,
56 dający programistom całą potęgę i elastyczność SQL-a. SQLAlchemy
57 udostępnia pełny zbiór dobrze znanych wzorców trwałości,
58 zaprojektowanych z myślą o efektywny i wydajnym dostępem do baz
59 danych, zaadaptowanych do prostego, pythonowego języka.
60
61 Wersja dla pythona 2.x.
62
63 %package -n python3-%{module}
64 Summary:        Database Abstraction Library for Python 3
65 Summary(pl.UTF-8):      Biblioteka abstrakcji baz danych dla Pythona 3
66 Group:          Libraries/Python
67 Provides:       python3-SQLAlchemy = %{version}-%{release}
68 Obsoletes:      python3-SQLAlchemy < 0.9.8
69
70 %description -n python3-%{module}
71 The Python SQL toolkit and Object Relational Mapper that gives
72 application developers the full power and flexibility of SQL.
73 SQLAlchemy provides a full suite of well known enterprise-level
74 persistence patterns, designed for efficient and high-performing
75 database access, adapted into a simple and Pythonic domain language.
76
77 Python 3.x version.
78
79 %description -n python3-%{module} -l pl.UTF-8
80 Zestaw narzędzi SQL oraz odwzorowań obiektowo-relacyjnych dla Pythona,
81 dający programistom całą potęgę i elastyczność SQL-a. SQLAlchemy
82 udostępnia pełny zbiór dobrze znanych wzorców trwałości,
83 zaprojektowanych z myślą o efektywny i wydajnym dostępem do baz
84 danych, zaadaptowanych do prostego, pythonowego języka.
85
86 Wersja dla Pythona 3.x.
87
88 %package apidocs
89 Summary:        API documentation for Python SQLAlchemy module
90 Summary(pl.UTF-8):      Dokumentacja API modułu Pythona SQLAlchemy
91 Group:          Documentation
92 %if "%{_rpmversion}" >= "5"
93 BuildArch:      noarch
94 %endif
95
96 %description apidocs
97 API documentation for Python SQLAlchemy module.
98
99 %description apidocs -l pl.UTF-8
100 Dokumentacja API modułu Pythona SQLAlchemy.
101
102 %package examples
103 Summary:        Examples for Python SQLAlchemy module
104 Summary(pl.UTF-8):      Przykłady do modułu Pythona SQLAlchemy
105 Group:          Documentation
106 %if "%{_rpmversion}" >= "5"
107 BuildArch:      noarch
108 %endif
109
110 %description examples
111 Examples for Python SQLAlchemy module.
112
113 %description examples -l pl.UTF-8
114 Przykłady do modułu Pythona SQLAlchemy.
115
116 %prep
117 %setup -q -n SQLAlchemy-%{version}
118 %patch0 -p1
119
120 %build
121 %if %{with python2}
122 %py_build %{?with_tests:test}
123 %endif
124
125 %if %{with python3}
126 %py3_build %{?with_tests:test}
127 %endif
128
129 %install
130 rm -rf $RPM_BUILD_ROOT
131 %if %{with python2}
132 %py_install
133
134 %py_postclean
135 %endif
136
137 %if %{with python3}
138 %py3_install
139 %endif
140
141 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
142 cp -pr examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
143
144 %clean
145 rm -rf $RPM_BUILD_ROOT
146
147 %files
148 %defattr(644,root,root,755)
149 %doc AUTHORS CHANGES LICENSE README.rst
150 %dir %{py_sitedir}/sqlalchemy
151 %{py_sitedir}/sqlalchemy/connectors
152 %{py_sitedir}/sqlalchemy/databases
153 %{py_sitedir}/sqlalchemy/dialects
154 %{py_sitedir}/sqlalchemy/engine
155 %{py_sitedir}/sqlalchemy/event
156 %{py_sitedir}/sqlalchemy/ext
157 %{py_sitedir}/sqlalchemy/orm
158 %{py_sitedir}/sqlalchemy/sql
159 %{py_sitedir}/sqlalchemy/testing
160 %{py_sitedir}/sqlalchemy/util
161 %attr(755,root,root) %{py_sitedir}/sqlalchemy/cprocessors.so
162 %attr(755,root,root) %{py_sitedir}/sqlalchemy/cresultproxy.so
163 %attr(755,root,root) %{py_sitedir}/sqlalchemy/cutils.so
164 %{py_sitedir}/sqlalchemy/*.py[co]
165 %{py_sitedir}/SQLAlchemy-%{version}-py*.egg-info
166
167 %if %{with python3}
168 %files -n python3-%{module}
169 %defattr(644,root,root,755)
170 %doc AUTHORS CHANGES LICENSE README.rst
171 %dir %{py3_sitedir}/sqlalchemy
172 %{py3_sitedir}/sqlalchemy/connectors
173 %{py3_sitedir}/sqlalchemy/databases
174 %{py3_sitedir}/sqlalchemy/dialects
175 %{py3_sitedir}/sqlalchemy/engine
176 %{py3_sitedir}/sqlalchemy/event
177 %{py3_sitedir}/sqlalchemy/ext
178 %{py3_sitedir}/sqlalchemy/orm
179 %{py3_sitedir}/sqlalchemy/sql
180 %{py3_sitedir}/sqlalchemy/testing
181 %{py3_sitedir}/sqlalchemy/util
182 %attr(755,root,root) %{py3_sitedir}/sqlalchemy/cprocessors.cpython-*.so
183 %attr(755,root,root) %{py3_sitedir}/sqlalchemy/cresultproxy.cpython-*.so
184 %attr(755,root,root) %{py3_sitedir}/sqlalchemy/cutils.cpython-*.so
185 %{py3_sitedir}/sqlalchemy/*.py
186 %{py3_sitedir}/sqlalchemy/__pycache__
187 %{py3_sitedir}/SQLAlchemy-%{version}-py*.egg-info
188 %endif
189
190 %files apidocs
191 %defattr(644,root,root,755)
192 %doc doc/{_images,_modules,_static,changelog,core,dialects,faq,orm,*.html,*.js}
193
194 %files examples
195 %defattr(644,root,root,755)
196 %{_examplesdir}/%{name}-%{version}
This page took 0.038553 seconds and 2 git commands to generate.