]> git.pld-linux.org Git - packages/python-sqlalchemy.git/blob - python-SQLAlchemy.spec
c4489e331dd9b6c6d9acd503acc222c71edc8c73
[packages/python-sqlalchemy.git] / python-SQLAlchemy.spec
1 # TODO:
2 # - examples and docs for python3
3 #
4 %bcond_without  python3
5 %bcond_without  python2
6 %define         module  SQLAlchemy
7 #
8 Summary:        Database Abstraction Library
9 Summary(pl.UTF-8):      Biblioteka abstrakcji baz danych
10 Name:           python-%{module}
11 Version:        0.6.1
12 Release:        1
13 License:        MIT
14 Group:          Libraries/Python
15 Source0:        http://downloads.sourceforge.net/sqlalchemy/%{module}-%{version}.tar.gz
16 # Source0-md5:  8b25a820a81469b54b05426705108061
17 URL:            http://www.sqlalchemy.org/
18 %if %{with python2}
19 BuildRequires:  python-devel >= 1:2.4
20 BuildRequires:  python-setuptools >= 0.6-0.a9.1
21 %endif
22 %if %{with python3}
23 BuildRequires:  python3-2to3
24 BuildRequires:  python3-devel
25 BuildRequires:  python3-distribute
26 BuildRequires:  python3-modules
27 %endif
28 BuildRequires:  rpm-pythonprov
29 BuildRequires:  rpmbuild(macros) >= 1.219
30 %if %{with python2}
31 %pyrequires_eq  python-modules
32 %endif
33 BuildArch:      noarch
34 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36 %description
37 The Python SQL toolkit and Object Relational Mapper that gives
38 application developers the full power and flexibility of SQL.
39 SQLAlchemy provides a full suite of well known enterprise-level
40 persistence patterns, designed for efficient and high-performing
41 database access, adapted into a simple and Pythonic domain language.
42
43 Python 2.x version.
44
45 %description -l pl.UTF-8
46 Zestaw narzędzi SQL dla Pythona oraz odwzorowań obiektowo-relacyjnych
47 dających programistom całą potęgę i elastyczność SQL-a. SQLAlchemy
48 udostępnia pełny zbiór dobrze znanych wzorców trwałości,
49 zaprojektowanych do wydajnego dostępu do baz danych, zaadoptowanych do
50 prostej, pythonowej domeny językowej.
51
52 Wersja dla pythona 2.x.
53
54 %package -n python3-%{module}
55 Summary:        Database Abstraction Library
56 Summary(pl.UTF-8):      Biblioteka abstrakcji baz danych
57 Group:          Libraries/Python
58
59 %description -n python3-%{module}
60 The Python SQL toolkit and Object Relational Mapper that gives
61 application developers the full power and flexibility of SQL.
62 SQLAlchemy provides a full suite of well known enterprise-level
63 persistence patterns, designed for efficient and high-performing
64 database access, adapted into a simple and Pythonic domain language.
65
66 Python 3.x version.
67
68 %description -n python3-%{module} -l pl.UTF-8
69 Zestaw narzędzi SQL dla Pythona oraz odwzorowań obiektowo-relacyjnych
70 dających programistom całą potęgę i elastyczność SQL-a. SQLAlchemy
71 udostępnia pełny zbiór dobrze znanych wzorców trwałości,
72 zaprojektowanych do wydajnego dostępu do baz danych, zaadoptowanych do
73 prostej, pythonowej domeny językowej.
74
75 Wersja dla Pythona 3.x.
76
77 %prep
78 %setup -q -n %{module}-%{version}
79
80 %build
81 %if %{with python2}
82 %{__python} setup.py build -b build-2
83 %endif
84 %if %{with python3}
85 %{__python3} setup.py build -b build-3
86 %endif
87
88 %install
89 rm -rf $RPM_BUILD_ROOT
90 %if %{with python2}
91 %{__python} setup.py build -b build-2 \
92         install \
93         --single-version-externally-managed \
94         --optimize=2 \
95         --root=$RPM_BUILD_ROOT
96
97 %py_postclean
98 %endif
99
100 %if %{with python3}
101 %{__python3} setup.py build -b build-3 \
102         install \
103         --single-version-externally-managed \
104         --root=$RPM_BUILD_ROOT \
105         --optimize=2
106
107 %py3_postclean
108 %endif
109
110 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
111 cp -r examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
112
113 %clean
114 rm -rf $RPM_BUILD_ROOT
115
116 %files
117 %defattr(644,root,root,755)
118 %doc CHANGES README* doc/*.html
119 %{py_sitescriptdir}/SQLAlchemy*
120 %{py_sitescriptdir}/sqlalchemy*
121 %{_examplesdir}/%{name}-%{version}
122
123 %files -n python3-%{module}
124 %defattr(644,root,root,755)
125 %{py3_sitescriptdir}/SQLAlchemy*
126 %{py3_sitescriptdir}/sqlalchemy*
This page took 0.034551 seconds and 3 git commands to generate.