Changeset 84847


Ignore:
Timestamp:
Oct 3, 2011, 3:56:40 PM (8 years ago)
Author:
jmr@…
Message:

unify py*-pygments (#31422), part 2

Location:
trunk/dports/python/py-pygments
Files:
1 edited
1 moved

Legend:

Unmodified
Added
Removed
  • trunk/dports/python/py-pygments/Portfile

    r78609 r84847  
    22
    33PortSystem          1.0
    4 PortGroup           python32 1.0
     4PortGroup           python 1.0
    55
    6 name                py32-pygments
     6name                py-pygments
    77version             1.4
     8revision            1
    89license             BSD
    910categories-append   devel
    10 maintainers         singingwolfboy openmaintainer
     11maintainers         erickt singingwolfboy openmaintainer
    1112description         Python syntax highlighter
    1213long_description \
     
    1920supported_archs     noarch
    2021
    21 homepage            http://pygments.org
     22homepage            http://pygments.org/
    2223master_sites        http://pypi.python.org/packages/source/P/Pygments
    2324distname            Pygments-${version}
    24 
    25 depends_lib         port:py32-distribute
    2625
    2726checksums           md5     d77ac8c93a7fb27545f2522abe9cc462 \
     
    2928                    rmd160  52775927f5e1b61c4203ae21fa9347c376f59287
    3029
    31 post-destroot {
    32     ln -sf ${python.prefix}/bin/pygmentize \
    33         ${destroot}${prefix}/bin/pygmentize-${python.branch}
     30python.versions     24 25 26 27 31 32
    3431
    35     set docdir ${prefix}/share/doc/${name}
    36     xinstall -d ${destroot}${docdir}
    37     xinstall -m 644 -W ${worksrcpath} AUTHORS CHANGES LICENSE TODO \
    38         ${destroot}${docdir}
    39     copy ${worksrcpath}/docs/build ${destroot}${docdir}/html
     32if {$subport != $name} {
     33    depends_lib     port:py${python.version}-distribute
    4034
    41     set man1 ${python.prefix}/share/man/man1
    42     xinstall -d ${destroot}${man1}
    43     xinstall -m 644 ${worksrcpath}/docs/pygmentize.1 ${destroot}${man1}
    44     ln -sf ${man1}/pygmentize.1 \
    45         ${destroot}${prefix}/share/man/man1/pygmentize-${python.branch}.1
     35    post-destroot {
     36        if {${python.version} >= 26} {
     37            ln -sf ${python.prefix}/bin/pygmentize \
     38                ${destroot}${prefix}/bin/pygmentize-${python.branch}
     39        } else {
     40            move ${destroot}${prefix}/bin/pygmentize \
     41                ${destroot}${prefix}/bin/pygmentize-${python.branch}
     42        }
     43
     44        set docdir ${prefix}/share/doc/${subport}
     45        xinstall -d ${destroot}${docdir}
     46        xinstall -m 644 -W ${worksrcpath} AUTHORS CHANGES LICENSE TODO \
     47            ${destroot}${docdir}
     48        copy ${worksrcpath}/docs/build ${destroot}${docdir}/html
     49
     50        if {${python.version} >= 26} {
     51            set man1 ${python.prefix}/share/man/man1
     52            xinstall -d ${destroot}${man1}
     53            xinstall -m 644 ${worksrcpath}/docs/pygmentize.1 ${destroot}${man1}
     54            ln -sf ${man1}/pygmentize.1 \
     55                ${destroot}${prefix}/share/man/man1/pygmentize-${python.branch}.1
     56        } else {
     57            xinstall -m 644 ${worksrcpath}/docs/pygmentize.1 \
     58                ${destroot}${prefix}/share/man/man1/pygmentize-${python.branch}.1
     59        }
     60    }
     61    livecheck.type  none
     62} else {
     63    livecheck.type  regex
     64    livecheck.url   ${master_sites}
     65    livecheck.regex {Pygments-(\d+(?:\.\d+)*)}
    4666}
    47 
    48 livecheck.type      regex
    49 livecheck.url       ${master_sites}
    50 livecheck.regex     {Pygments-(\d+(?:\.\d+)*)}
Note: See TracChangeset for help on using the changeset viewer.