# -*- 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

PortSystem        1.0
PortGroup         python 1.0

name              py-httplib2
set realversion   0.22.0
revision          0
version           2-${realversion}
categories-append devel net
license           MIT
platforms         {darwin any}
supported_archs   noarch
maintainers       {aronnax @lpsinger} openmaintainer

description       A comprehensive HTTP client library in Python
long_description  A comprehensive HTTP client library that supports \
                  many features left out of other HTTP libraries.

homepage          https://pypi.python.org/pypi/${python.rootname}/
distname          ${python.rootname}-${realversion}

python.versions   27 310 311 312 313 314

checksums         rmd160  5a252f9ae9ff5e2e550d6f2da36b3f97db89466e \
                  sha256  d7a10bc5ef5ab08322488bde8c726eeee5c8618723fdb399597ec58f3d82df81 \
                  size    351116

if {${name} ne ${subport}} {
  # Extracted files do not have correct 'group' and 'other' permissions.
  post-extract {
    system "find ${worksrcpath} -type d -print0 | xargs -0 chmod a+rx"
    system "find ${worksrcpath} -type f -print0 | xargs -0 chmod a+r"
  }

  depends_build-append \
                    port:py${python.version}-setuptools

  depends_lib-append \
                    port:py${python.version}-parsing
}

livecheck.version ${realversion}
