]> git.pld-linux.org Git - packages/python-pyicu.git/blame - python-pyicu.spec
- run tests
[packages/python-pyicu.git] / python-pyicu.spec
CommitLineData
cc11606c
JB
1#
2# Conditional build:
3%bcond_without python2 # CPython 2.x module
4%bcond_without python3 # CPython 3.x module
6e490d5e 5%bcond_without tests # unit tests
cc11606c
JB
6#
7Summary: PyICU - Python 2 extension wrapping IBM's ICU C++ API
8Summary(pl.UTF-8): PyICU - rozszerzenie Pythona 2 obudowujące API C++ biblioteki ICU firmy IBM
01cab8ba 9Name: python-pyicu
77896448
JR
10Version: 1.9.5
11Release: 1
01cab8ba 12License: MIT-like
bf26a09a 13Group: Development/Languages/Python
77896448
JR
14Source0: https://pypi.python.org/packages/a2/9f/1947f288143191b903e58633ee597cb98bc284de28dafb1231b6f8b67b99/PyICU-%{version}.tar.gz
15# Source0-md5: 30f85b7272f15b26c110c9f3e3a9e7a0
16URL: http://site.icu-project.org/
a64306b6
ER
17BuildRequires: libicu-devel >= 3.6
18BuildRequires: libstdc++-devel
cc11606c 19%if %{with python2}
a64306b6 20BuildRequires: python-devel >= 1:2.3
cc11606c
JB
21BuildRequires: python-modules >= 1:2.3
22%endif
23%if %{with python3}
6e490d5e
JB
24BuildRequires: python3-devel >= 1:3.2
25BuildRequires: python3-modules >= 1:3.2
cc11606c 26%endif
2a710a52 27BuildRequires: rpm-pythonprov
bc6615bb 28BuildRequires: rpmbuild(macros) >= 1.714
a64306b6
ER
29BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
31%description
01cab8ba
JB
32PyICU is a Python extension wrapping IBM's ICU C++ API.
33
cc11606c
JB
34This package contains Python 2 module.
35
01cab8ba
JB
36%description -l pl.UTF-8
37PyICU to rozszerzenie Pythona obudowujące API C++ biblioteki ICU firmy
38IBM.
a64306b6 39
cc11606c
JB
40Ten pakiet zawiera moduł Pythona 2.
41
42%package -n python3-pyicu
43Summary: PyICU - Python 3 extension wrapping IBM's ICU C++ API
44Summary(pl.UTF-8): PyICU - rozszerzenie Pythona 3 obudowujące API C++ biblioteki ICU firmy IBM
45Group: Development/Languages/Python
46
47%description -n python3-pyicu
48PyICU is a Python extension wrapping IBM's ICU C++ API.
49
50This package contains Python 3 module.
51
52%description -n python3-pyicu -l pl.UTF-8
53PyICU to rozszerzenie Pythona obudowujące API C++ biblioteki ICU firmy
54IBM.
55
56Ten pakiet zawiera moduł Pythona 3.
57
a64306b6
ER
58%prep
59%setup -q -n PyICU-%{version}
60
61%build
cc11606c 62%if %{with python2}
6e490d5e 63%py_build %{?with_tests:test}
cc11606c
JB
64%endif
65
66%if %{with python3}
bc6615bb 67%py3_build
6e490d5e
JB
68
69# tests are 2to3'ed after setup()
70%{?with_tests:%py3_build test}
cc11606c 71%endif
a64306b6
ER
72
73%install
74rm -rf $RPM_BUILD_ROOT
cc11606c
JB
75
76%if %{with python2}
bc6615bb 77%py_install
a64306b6 78%py_postclean
cc11606c
JB
79%endif
80
81%if %{with python3}
bc6615bb 82%py3_install
cc11606c 83%endif
a64306b6
ER
84
85%clean
86rm -rf $RPM_BUILD_ROOT
87
cc11606c 88%if %{with python2}
a64306b6
ER
89%files
90%defattr(644,root,root,755)
77896448 91%doc CHANGES CREDITS LICENSE README.md
a64306b6 92%{py_sitedir}/PyICU.py[co]
bf26a09a
ER
93%{py_sitedir}/docs.py[co]
94%{py_sitedir}/icu.py[co]
95%attr(755,root,root) %{py_sitedir}/_icu.so
a64306b6 96%if "%{py_ver}" > "2.4"
01cab8ba 97%{py_sitedir}/PyICU-%{version}-py*.egg-info
a64306b6 98%endif
cc11606c
JB
99%endif
100
101%if %{with python3}
102%files -n python3-pyicu
103%defattr(644,root,root,755)
77896448 104%doc CHANGES CREDITS LICENSE README.md
cc11606c
JB
105%{py3_sitedir}/PyICU.py
106%{py3_sitedir}/docs.py
107%{py3_sitedir}/icu.py
108%{py3_sitedir}/__pycache__/PyICU.*.py[co]
109%{py3_sitedir}/__pycache__/docs.*.py[co]
110%{py3_sitedir}/__pycache__/icu.*.py[co]
111%attr(755,root,root) %{py3_sitedir}/_icu.cpython-*.so
112%{py3_sitedir}/PyICU-%{version}-py*.egg-info
113%endif
This page took 0.054843 seconds and 4 git commands to generate.