update pip to 1.0.2 and add python3 package
This commit is contained in:
parent
c20efaebc1
commit
aded0dc96c
1
.gitignore
vendored
1
.gitignore
vendored
@ -2,3 +2,4 @@ pip-0.7.2.tar.gz
|
||||
/pip-0.8.tar.gz
|
||||
/pip-0.8.2.tar.gz
|
||||
/pip-0.8.3.tar.gz
|
||||
/pip-1.0.2.tar.gz
|
||||
|
@ -1,11 +1,16 @@
|
||||
%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
|
||||
%if (! 0%{?rhel}) || 0%{?rhel} > 6
|
||||
%global with_python3 1
|
||||
%endif
|
||||
%if 0%{?rhel} && 0%{?rhel} < 6
|
||||
%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
|
||||
%endif
|
||||
|
||||
%global srcname pip
|
||||
|
||||
Name: python-%{srcname}
|
||||
Version: 0.8.3
|
||||
Version: 1.0.2
|
||||
Release: 1%{?dist}
|
||||
Summary: Pip installs packages. Python packages. An easy_install replacement
|
||||
Summary: Pip installs packages. Python3 packages. An easy_install replacement
|
||||
|
||||
Group: Development/Libraries
|
||||
License: MIT
|
||||
@ -15,43 +20,102 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
|
||||
BuildArch: noarch
|
||||
BuildRequires: python-devel
|
||||
BuildRequires: python-setuptools-devel
|
||||
BuildRequires: python-setuptools
|
||||
Requires: python-setuptools
|
||||
|
||||
%description
|
||||
|
||||
Pip is a replacement for `easy_install
|
||||
<http://peak.telecommunity.com/DevCenter/EasyInstall>`_. It uses mostly the
|
||||
same techniques for finding packages, so packages that were made
|
||||
easy_installable should be pip-installable as well.
|
||||
|
||||
pip is meant to improve on easy_install.bulletin boards, etc.).
|
||||
|
||||
%if 0%{?with_python3}
|
||||
%package -n python3-pip
|
||||
Summary: Pip installs packages. Python3 packages. An easy_install replacement
|
||||
Group: Development/Libraries
|
||||
|
||||
BuildRequires: python3-devel
|
||||
BuildRequires: python3-setuptools
|
||||
Requires: python3-setuptools
|
||||
|
||||
%description -n python3-pip
|
||||
Pip is a replacement for `easy_install
|
||||
<http://peak.telecommunity.com/DevCenter/EasyInstall>`_. It uses mostly the
|
||||
same techniques for finding packages, so packages that were made
|
||||
easy_installable should be pip-installable as well.
|
||||
%endif # with_python3
|
||||
|
||||
%prep
|
||||
%setup -q -n %{srcname}-%{version}
|
||||
%{__sed} -i '1d' pip/__init__.py
|
||||
|
||||
%if 0%{?with_python3}
|
||||
cp -a . %{py3dir}
|
||||
%endif # with_python3
|
||||
|
||||
%build
|
||||
%{__python} setup.py build
|
||||
|
||||
%if 0%{?with_python3}
|
||||
pushd %{py3dir}
|
||||
%{__python3} setup.py build
|
||||
popd
|
||||
%endif # with_python3
|
||||
|
||||
%install
|
||||
%{__rm} -rf %{buildroot}
|
||||
|
||||
%if 0%{?with_python3}
|
||||
pushd %{py3dir}
|
||||
%{__python3} setup.py install -O1 --skip-build --root %{buildroot}
|
||||
|
||||
# Change the name of the pip executable in order to not conflict with perl-pip
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=616399
|
||||
mv %{buildroot}%{_bindir}/pip %{buildroot}%{_bindir}/pip-python3
|
||||
|
||||
# The install process creates both pip and pip-<python_abiversion> that seem to
|
||||
# be the same. Remove the extra script
|
||||
rm %{buildroot}%{_bindir}/pip-3*
|
||||
|
||||
popd
|
||||
%endif # with_python3
|
||||
|
||||
%{__python} setup.py install -O1 --skip-build --root %{buildroot}
|
||||
%{__rm} -rf %{buildroot}%{_bindir}/pip-*
|
||||
|
||||
# The install process creates both pip and pip-<python_abiversion> that seem to
|
||||
# be the same. Since removing pip-* also clobbers pip-python3, just remove pip-2*
|
||||
%{__rm} -rf %{buildroot}%{_bindir}/pip-2*
|
||||
|
||||
# Change the name of the pip executable in order to not conflict with perl-pip
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=616399
|
||||
mv %{buildroot}%{_bindir}/pip %{buildroot}%{_bindir}/pip-python
|
||||
|
||||
|
||||
%clean
|
||||
%{__rm} -rf %{buildroot}
|
||||
|
||||
# unfortunately, pip's test suite requires virtualenv >= 1.6 which isn't in
|
||||
# fedora yet. Once it is, check can be implemented
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%doc PKG-INFO docs
|
||||
%attr(755,root,root) %{_bindir}/pip-python
|
||||
%{python_sitelib}/pip*
|
||||
|
||||
%if 0%{?with_python3}
|
||||
%files -n python3-pip
|
||||
%defattr(-,root,root,-)
|
||||
%doc PKG-INFO docs
|
||||
%attr(755,root,root) %{_bindir}/pip-python3
|
||||
%{python3_sitelib}/pip*
|
||||
%endif # with_python3
|
||||
|
||||
%changelog
|
||||
* Sat Oct 22 2011 Tim Flink <tflink@fedoraproject.org> - 1.0.2-1
|
||||
- update to 1.0.2 and added python3 subpackage
|
||||
|
||||
* Wed Jun 22 2011 Tim Flink <tflink@fedoraproject.org> - 0.8.3-1
|
||||
- update to 0.8.3 and project home page
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user