# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
# $Id: Portfile 106911 2013-06-11 14:40:14Z jmr@macports.org $

PortSystem          1.0
PortGroup           python 1.0

name                py-pip
version             1.3.1
categories-append   www
license             MIT
platforms           darwin
supported_archs     noarch

python.versions     25 26 27 31 32 33

maintainers         stromnov openmaintainer

description         A tool for installing and managing Python packages.
long_description    pip is a replacement for easy_install. It uses mostly the \
                    same techniques for finding packages, so packages that \
                    were made easy_installable should be pip-installable as \
                    well.

homepage            http://www.pip-installer.org/
master_sites        http://pypi.python.org/packages/source/p/pip/

distname            pip-${version}

checksums           rmd160  0bfbfbc536abcf20f952b444ee872128406e098e \
                    sha256  145eaa5d1ea1b062663da1f3a97780d7edea4c63c68a37c463b1deedf7bb4957

if {$subport != $name} {
    depends_lib-append  port:py${python.version}-setuptools

    python.link_binaries_suffix
    python.move_binaries no
    post-destroot {
        copy ${worksrcpath}/docs ${destroot}${prefix}/share/doc/${subport}
        delete ${destroot}${prefix}/bin/pip
    }

    livecheck.type      none
} else {
    livecheck.type      regex
    livecheck.url       ${master_sites}
    livecheck.regex     "pip-(\\d+(?:\\.\\d+)*)${extract.suffix}"
}
