1 | %{!?python3_sitelib: %global python3_sitelib %(python3 -c "from distutils.sysconfig import get_python_lib; print (get_python_lib())")} |
---|
2 | %{!?python3_sitearch: %global python3_sitearch %(python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")} |
---|
3 | |
---|
4 | %define _lxml lxml |
---|
5 | Summary: lxml is a Pythonic binding for the libxml2 and libxslt libraries |
---|
6 | Summary(ja): lxml は libxml2 と libxslt の Python バインディングです |
---|
7 | Name: python-%{_lxml} |
---|
8 | Group: Development/Libraries |
---|
9 | Version: 3.8.0 |
---|
10 | Release: 1%{?_dist_release} |
---|
11 | License: BSD |
---|
12 | URL: http://codespeak.net/lxml |
---|
13 | #URL: http://pypi.python.org/pypi/lxml |
---|
14 | Source: http://pypi.python.org/packages/source/l/%{_lxml}/%{_lxml}-%{version}.tar.gz |
---|
15 | BuildRoot: %{_tmppath}/%{name}-%{version}-root |
---|
16 | Vendor: Project Vine |
---|
17 | Distribution: Vine Linux |
---|
18 | |
---|
19 | BuildRequires: libxml2-devel >= 2.6.21 |
---|
20 | BuildRequires: libxslt-devel >= 1.1.15 |
---|
21 | BuildRequires: python-devel >= 2.3 |
---|
22 | BuildRequires: python3-devel |
---|
23 | BuildRequires: python-pyrex |
---|
24 | |
---|
25 | %description |
---|
26 | lxml is a Pythonic binding for the libxml2_ and libxslt_ libraries. It is |
---|
27 | unique in that it combines the speed and feature completeness of these |
---|
28 | libraries with the simplicity of a native Python API, mostly compatible but |
---|
29 | superior to the well-known ElementTree_ API. See the introduction_ for more |
---|
30 | information about background and goals. |
---|
31 | |
---|
32 | %package -n python3-lxml |
---|
33 | Summary: lxml is a Pythonic binding for the libxml2 and libxslt libraries |
---|
34 | Summary(ja): lxml は libxml2 と libxslt の Python バインディングです |
---|
35 | Group: Development/Libraries |
---|
36 | |
---|
37 | %description -n python3-lxml |
---|
38 | lxml is a Pythonic binding for the libxml2_ and libxslt_ libraries. It is |
---|
39 | unique in that it combines the speed and feature completeness of these |
---|
40 | libraries with the simplicity of a native Python API, mostly compatible but |
---|
41 | superior to the well-known ElementTree_ API. See the introduction_ for more |
---|
42 | information about background and goals. |
---|
43 | |
---|
44 | %prep |
---|
45 | %setup -q -T -c -n %{_lxml}-%{version} |
---|
46 | |
---|
47 | tar xvf %{SOURCE0} |
---|
48 | mv %{_lxml}-%{version} py2 |
---|
49 | |
---|
50 | cp -a py2 py3 |
---|
51 | |
---|
52 | %build |
---|
53 | pushd py2 |
---|
54 | %{__python} setup.py build |
---|
55 | popd |
---|
56 | |
---|
57 | pushd py3 |
---|
58 | python3 setup.py build |
---|
59 | popd |
---|
60 | |
---|
61 | %install |
---|
62 | rm -rf $RPM_BUILD_ROOT |
---|
63 | |
---|
64 | pushd py2 |
---|
65 | %{__python} setup.py install --root=$RPM_BUILD_ROOT |
---|
66 | popd |
---|
67 | |
---|
68 | pushd py3 |
---|
69 | python3 setup.py install --root=$RPM_BUILD_ROOT |
---|
70 | popd |
---|
71 | |
---|
72 | %clean |
---|
73 | rm -rf $RPM_BUILD_ROOT |
---|
74 | |
---|
75 | %files |
---|
76 | %defattr(-,root,root) |
---|
77 | %doc py2/CHANGES.txt py2/CREDITS.txt py2/LICENSES.txt py2/README.* py2/TODO.txt |
---|
78 | %doc py2/doc |
---|
79 | %{python_sitearch}/%{_lxml} |
---|
80 | %{python_sitearch}/%{_lxml}-*-info |
---|
81 | |
---|
82 | %files -n python3-lxml |
---|
83 | %defattr(-,root,root) |
---|
84 | %doc py3/CHANGES.txt py3/CREDITS.txt py3/LICENSES.txt py3/README.* py3/TODO.txt |
---|
85 | %doc py3/doc |
---|
86 | %{python3_sitearch}/%{_lxml} |
---|
87 | %{python3_sitearch}/%{_lxml}-*-info |
---|
88 | |
---|
89 | %changelog |
---|
90 | * Sat Sep 09 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.8.0-1 |
---|
91 | - new upstream release. |
---|
92 | - added python3 support. |
---|
93 | |
---|
94 | * Sun Jan 12 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.2.6-4 |
---|
95 | - rebuild with VineSeed environment |
---|
96 | |
---|
97 | * Sun Feb 19 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.2.6-3 |
---|
98 | - rebuild with python-2.7.2 |
---|
99 | |
---|
100 | * Wed Mar 10 2010 Kazutaka HARADA <kazutaka@vinelinux.org> 2.2.6-2 |
---|
101 | - change required version of libxml2-devel for Vine Plus/5 |
---|
102 | (2.7.2 or later is recomended, but works with 2.6.21 or later) |
---|
103 | |
---|
104 | * Sun Mar 07 2010 Shu KONNO <owa@bg.wakwak.com> 2.2.6-1 |
---|
105 | - initial build for vine linux |
---|
106 | |
---|