]> git.pld-linux.org Git - packages/python-apsw.git/blame - python-apsw.spec
automatic change: use py_build/py_install macros
[packages/python-apsw.git] / python-apsw.spec
CommitLineData
b3b3252f
AM
1#
2# Conditional build:
3%bcond_with tests # do not perform "make test"
4%bcond_without python2 # CPython 2.x module
5%bcond_without python3 # CPython 3.x module
61b31c29
AM
6
7%define module apsw
b3b3252f 8%define sqlite_ver 3.8.5
61b31c29
AM
9
10Summary: Another Python SQLite Wrapper
10dcd257 11Summary(pl.UTF-8): Another Python SQLite Wrapper - jeszcze jeden pythonowy wrapper dla SQLite
61b31c29 12Name: python-%{module}
b3b3252f 13Version: 3.8.5
5fe6239b 14Release: 6
61b31c29 15License: Free
b3b3252f
AM
16Group: Libraries/Python
17Source0: https://github.com/rogerbinns/apsw/archive/%{version}-r1.tar.gz
18# Source0-md5: 09eb9f39d7cf9d320ee8e89f9e9ab7ea
19URL: http://rogerbinns.github.io/apsw/
31293ab1 20BuildRequires: rpm-pythonprov
f8bb72a1 21BuildRequires: sqlite3-devel >= %{sqlite_ver}
4809cf98 22BuildRequires: unzip
b3b3252f
AM
23%if %{with python2}
24BuildRequires: python-devel
25BuildRequires: python-distribute
26%endif
27%if %{with python3}
28BuildRequires: python3-devel
29BuildRequires: python3-distribute
30BuildRequires: python3-modules
31%endif
32Requires: python-modules
f8bb72a1 33Requires: sqlite3 >= %{sqlite_ver}
61b31c29
AM
34BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36%description
37APSW provides an SQLite 3 wrapper that provides the thinnest layer
38over SQLite 3 possible. Everything you can do from the C API to SQLite
393, you can do from Python. Although APSW looks vaguely similar to the
40DBAPI, it is not compliant with that API and instead works the way
41SQLite 3 does.
42
30b51d00
JR
43%description -l pl.UTF-8
44APSW udostępnia wrapper SQLite 3 dostarczający najcieńszą jak to tylko
45możliwe warstwę ponad SQLite 3. Wszystko co można zrobić z poziomu API
46C SQLite 3 można zrobić także z poziomu Pythona. Chociaż APSQ wygląda
47dosyć podobnie do DBAPI, nie jest kompatybilne z tym API, natomiast
48działa tak, jak SQLite 3.
f174cdd6 49
b3b3252f
AM
50%package -n python3-%{module}
51Summary: -
52Summary(pl.UTF-8): -
53Group: Libraries/Python
54Requires: sqlite3 >= %{sqlite_ver}
55
56%description -n python3-%{module}
57APSW provides an SQLite 3 wrapper that provides the thinnest layer
58over SQLite 3 possible. Everything you can do from the C API to SQLite
593, you can do from Python. Although APSW looks vaguely similar to the
60DBAPI, it is not compliant with that API and instead works the way
61SQLite 3 does.
62
63%description -n python3-%{module} -l pl.UTF-8
64APSW udostępnia wrapper SQLite 3 dostarczający najcieńszą jak to tylko
65możliwe warstwę ponad SQLite 3. Wszystko co można zrobić z poziomu API
66C SQLite 3 można zrobić także z poziomu Pythona. Chociaż APSQ wygląda
67dosyć podobnie do DBAPI, nie jest kompatybilne z tym API, natomiast
68działa tak, jak SQLite 3.
69
70%package apidocs
71Summary: %{module} API documentation
72Summary(pl.UTF-8): Dokumentacja API %{module}
73Group: Documentation
74
75%description apidocs
76API documentation for %{module}.
77
78%description apidocs -l pl.UTF-8
79Dokumentacja API %{module}.
80
61b31c29
AM
81%prep
82%setup -q -n %{module}-%{version}-r1
83
84%build
b3b3252f 85%if %{with python2}
6541522c 86%py_build %{?with_tests:test}
b3b3252f
AM
87%endif
88
89%if %{with python3}
6541522c 90%py3_build %{?with_tests:test}
b3b3252f
AM
91%endif
92
93%if %{with doc}
94cd docs
95%{__make} -j1 html
96rm -rf _build/html/_sources
97%endif
61b31c29
AM
98
99%install
100rm -rf $RPM_BUILD_ROOT
101
b3b3252f 102%if %{with python2}
6541522c 103%py_install
b3b3252f
AM
104
105%py_postclean
106%endif
107
108%if %{with python3}
6541522c 109%py3_install
b3b3252f 110%endif
61b31c29
AM
111
112%clean
113rm -rf $RPM_BUILD_ROOT
114
b3b3252f 115%if %{with python2}
61b31c29
AM
116%files
117%defattr(644,root,root,755)
b3b3252f
AM
118%doc LICENSE README.rst
119%attr(755,root,root) %{py_sitedir}/*.so
120%if "%{py_ver}" > "2.4"
967a04f7 121%{py_sitedir}/%{module}-*.egg-info
b3b3252f
AM
122%endif
123%endif
124
125%if %{with python3}
126%files -n python3-%{module}
127%defattr(644,root,root,755)
128%doc LICENSE README.rst
129%{py3_sitedir}/%{module}*.so
130%{py3_sitedir}/%{module}-%{version}*-py*.egg-info
131%endif
132
133%if %{with doc}
134%files apidocs
135%defattr(644,root,root,755)
136%doc docs/_build/html/*
137%endif
This page took 0.093815 seconds and 4 git commands to generate.