Ticket #52086: Portfile.diff

File Portfile.diff, 4.9 KB (added by amake (Aaron Madlon-Kay), 8 years ago)
  • sysutils/peco/Portfile

    diff --git a/sysutils/peco/Portfile b/sysutils/peco/Portfile
    index 19fa642..58387ea 100644
    a b  
     1# -*- 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
    12# $Id$
    23
    34PortSystem      1.0
    45PortGroup       github 1.0
    56
    6 github.setup    peco peco 0.3.5 v
    7 revision        1
     7github.setup    peco peco 0.4.2 v
     8github.tarball_from releases
     9supported_archs i386 x86_64
     10set arch        [expr {($tcl_platform(pointerSize) == 8) ? "amd64" : "386"}]
     11distname        ${name}_darwin_${arch}
    812categories      sysutils
    913homepage        http://peco.github.io
    1014description     Simplistic interactive filtering tool
    license MIT 
    1721maintainers     kimuraw openmaintainer
    1822platforms       darwin
    1923
    20 depends_build   port:go
    21 use_configure   no
    22 dist_subdir     go
    23 
    24 # peco
    25 checksums       peco-${version}.tar.gz \
    26                     md5 641848c6767a3a9f98cf39e04f375220 \
    27                     sha1 64aee3c3d58b3cea0a62eba615ad3d06db6ef2e8 \
    28                     sha256 185be39a576de5b4a218e0a54bc1475750e7612341a4877ca80f49b420499476
     24checksums       rmd160  d5fbad598e133c223e9744757f888b03c2a8d448 \
     25                sha256  ef8ffd9f009522d74f8725e651fe0b0aa6ead3dc794f49e753cdd691fa92a6f0
    2926
    30 # dependencies to build. remember revbump when you change version of dependencies.
    31 set go-flags.version        fc93116606d0a71d7e9de0ad5734fdb4b8eae834
    32 set go-runewidth.version    12e0ff74603c9a3209d8bf84f8ab349fe1ad9477
    33 set termbox-go.version      62033d80b58736ea31beaf43348f5147913af30e
    34 set google-btree.version    0c05920fc3d98100a5e3f7fd339865a6e2aaa671
    35 # dependencies
    36 master_sites-append https://github.com/jessevdk/go-flags/tarball/${go-flags.version}:go-flags \
    37                     https://github.com/mattn/go-runewidth/tarball/${go-runewidth.version}:go-runewidth \
    38                     https://github.com/nsf/termbox-go/tarball/${termbox-go.version}:termbox-go \
    39                     https://github.com/google/btree/tarball/${google-btree.version}:google-btree
    40 distfiles-append    jessevdk-go-flags-v${go-flags.version}.tar.gz:go-flags \
    41                     mattn-go-runewidth-${go-runewidth.version}.tar.gz:go-runewidth \
    42                     nsf-termbox-go-${termbox-go.version}.tar.gz:termbox-go \
    43                     google-btree-${google-btree.version}.tar.gz:google-btree
    44 checksums-append    jessevdk-go-flags-v${go-flags.version}.tar.gz \
    45                         md5 9f8181755c1b8cc75c6cb4a02f7df4ad \
    46                         sha1 b2974783c11ffbbcdf4b28fe9be4f58e57cb1b65 \
    47                         sha256 b9ca31c53e8ac4acc6d20cc2fd3e0b4953b7b1302ecbeafaa35b622896f3830d \
    48                     mattn-go-runewidth-${go-runewidth.version}.tar.gz \
    49                         md5 317aa7a94231feaf536f40f9600fd1b1 \
    50                         sha1 7024c1587f064d40d5659c36bca5a3bb672b9f50 \
    51                         sha256 722af0e56e90bd49ae36c7a5eb3bcc322ee9093379e5f03ba849f73cd9dd86eb \
    52                     nsf-termbox-go-${termbox-go.version}.tar.gz \
    53                         md5 3d60a80b309cd38e14ffba977fcc00eb \
    54                         sha1 56b7382f78df5bf2a2fc89ce0586af3ee11d5899 \
    55                         sha256 dae444f8b8920281d3221ff4be1dc8d7c74b37537dc111bddca464c1f9b13c5b \
    56                     google-btree-${google-btree.version}.tar.gz \
    57                         md5 3c20d1ca9728edd0777faf1941022d33 \
    58                         sha1 27ae29bfe84f4dc714f7a3f7cf53d6082b97a1f0 \
    59                         sha256 42ea86dba6bcbc055af6cdfbcfc6303695d2c9d70cf4bb882a27d55aab945d16
    60 # setup build sources like this:
    61 #   workpath/
    62 #       peco-0.1.12/
    63 #       gopath/src/github.com/
    64 #           peco/peco/
    65 #           jessevdk/go-flags-v/
    66 #             :
    67 set gopath      ${workpath}/GOPATH
    68 post-extract {
    69     file mkdir ${gopath}/src/github.com/peco
    70     ln -s ${worksrcpath} ${gopath}/src/github.com/peco/peco
    71     file mkdir ${gopath}/src/github.com/jessevdk
    72     move [glob ${workpath}/jessevdk-go-flags-*] ${gopath}/src/github.com/jessevdk/go-flags
    73     file mkdir ${gopath}/src/github.com/mattn
    74     move [glob ${workpath}/mattn-go-runewidth-*] ${gopath}/src/github.com/mattn/go-runewidth
    75     file mkdir ${gopath}/src/github.com/nsf
    76     move [glob ${workpath}/nsf-termbox-go-*] ${gopath}/src/github.com/nsf/termbox-go
    77     file mkdir ${gopath}/src/github.com/google
    78     move [glob ${workpath}/google-btree-*] ${gopath}/src/github.com/google/btree
    79 }
     27use_configure   no
     28use_zip         yes
     29universal_variant no
    8030
    81 build.cmd       go
    82 build.target    build
    83 build.args      cmd/peco/peco.go
    84 build.env       GOPATH="${gopath}"
     31build           {}
    8532
    8633destroot {
    87     xinstall ${worksrcpath}/peco ${destroot}${prefix}/bin
     34    xinstall -W ${worksrcpath} peco ${destroot}${prefix}/bin
     35    set docdir ${prefix}/share/doc/${name}
     36    xinstall -d ${destroot}${docdir}
     37    xinstall -m 0644 -W ${worksrcpath} Changes README.md ${destroot}${docdir}
    8838}