/[packages]/cauldron/python-pip/current/SPECS/python-pip.spec
ViewVC logotype

Contents of /cauldron/python-pip/current/SPECS/python-pip.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 739105 - (show annotations) (download)
Tue Oct 14 22:14:55 2014 UTC (8 years, 7 months ago) by umeabot
File size: 2900 byte(s)
Second Mageia 5 Mass Rebuild
1 %define pypi_name pip
2 %define build_wheel 1
3
4 %if 0%{?build_wheel}
5 %define python2_wheelname %{pypi_name}-%{version}-py2.py3-none-any.whl
6 %define python3_wheelname %python2_wheelname
7 %endif
8
9 Name: python-pip
10 Version: 1.5.6
11 Release: %mkrel 7
12 Group: Development/Python
13 Summary: pip installs packages. Python packages. An easy_install replacement
14 License: MIT
15 URL: http://pypi.python.org/pypi/pip
16 Source0: http://pypi.python.org/packages/source/p/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
17 Patch0: pip-1.5.6-allow-stripping-prefix-from-wheel-RECORD-files.patch
18 BuildArch: noarch
19 BuildRequires: pkgconfig(python)
20 BuildRequires: python-setuptools
21 %if 0%{?build_wheel}
22 BuildRequires: python-pip
23 BuildRequires: python-wheel
24 Provides: pythonegg(2)(pip)
25 %endif
26 Requires: python-setuptools
27 Requires: python-pkg-resources
28
29 %description
30 `pip` is a tool for installing and managing Python packages, such as
31 those found in the `Python Package Index`_. It's a replacement for
32 easy_install_.
33
34 %package -n python3-pip
35 Summary: A tool for installing and managing Python3 packages
36 Group: Development/Python
37 BuildRequires: pkgconfig(python3)
38 BuildRequires: python3-setuptools
39 %if 0%{?build_wheel}
40 BuildRequires: python3-pip
41 BuildRequires: python3-wheel
42 Provides: pythonegg(3)(pip)
43 %endif
44 Requires: python3-setuptools
45
46 %description -n python3-pip
47 Pip is a replacement for `easy_install
48 <http://peak.telecommunity.com/DevCenter/EasyInstall>`_. It uses mostly the
49 same techniques for finding packages, so packages that were made
50 easy_installable should be pip-installable as well.
51
52 %prep
53 %setup -q -n %{pypi_name}-%{version}
54 # Remove bundled egg-info
55 rm -rf %{pypi_name}.egg-info
56
57 %apply_patches
58 %{__sed} -i '1d' pip/__init__.py
59
60 cp -a . %{py3dir}
61
62 %build
63 %if 0%{?build_wheel}
64 %{__python} setup.py bdist_wheel
65 %else
66 %{__python} setup.py build
67 %endif
68
69 pushd %{py3dir}
70 %if 0%{?build_wheel}
71 %{__python3} setup.py bdist_wheel
72 %else
73 %{__python3} setup.py build
74 %endif
75 popd
76
77 %install
78 pushd %{py3dir}
79 %if 0%{?build_wheel}
80 pip3 install -I dist/%{python3_wheelname} --root %{buildroot} --strip-file-prefix %{buildroot}
81 # TODO: we have to remove this by hand now, but it'd be nice if we wouldn't have to
82 # (pip install wheel doesn't overwrite)
83 rm %{buildroot}%{_bindir}/pip
84 %else
85 %{__python3} setup.py install --skip-build --root %{buildroot}
86 %endif
87 popd
88
89 %if 0%{?build_wheel}
90 pip2 install -I dist/%{python2_wheelname} --root %{buildroot} --strip-file-prefix %{buildroot}
91 %else
92 %{__python} setup.py install -O1 --skip-build --root %{buildroot}
93 %endif
94
95
96 %files
97 %doc LICENSE.txt PKG-INFO docs
98 %attr(755,root,root) %{_bindir}/pip
99 %attr(755,root,root) %{_bindir}/pip2*
100 %{python_sitelib}/pip*
101
102 %files -n python3-pip
103 %doc LICENSE.txt PKG-INFO docs
104 %attr(755,root,root) %{_bindir}/pip3*
105 %{python3_sitelib}/pip*
106

  ViewVC Help
Powered by ViewVC 1.1.28