Ticket #52324: Portfile.5

File Portfile.5, 2.5 KB (added by lbschenkel (Leonardo Brondani Schenkel), 8 years ago)

Renamed to syncthing-0.14

Line 
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
2# $Id$
3
4PortSystem          1.0
5PortGroup           github 1.0
6
7github.setup        syncthing syncthing 0.14.7 v
8name                syncthing-0.14
9categories          net
10platforms           darwin
11license             MPL-2
12maintainers         schenkel.net:leonardo
13
14description         Open Source Continuous File Synchronization
15long_description    Syncthing replaces proprietary sync and cloud services \
16                    with something open, trustworthy and decentralized.\
17                    Your data is your data alone and you deserve to choose \
18                    where it is stored, if it is shared with some third party \
19                    and how it's transmitted over the Internet.
20homepage            https://syncthing.net
21
22checksums           rmd160  b098bb9dc6f37884691640ef9b5cdcb128506ba5 \
23                    sha256  1b1d89b9ed2aa102a05fa2552652e3c6fd86d24a460a9b35adc9919b203ee8cf
24
25worksrcdir          src/github.com/syncthing/syncthing
26extract.mkdir       yes
27extract.post_args-append --strip-components=1
28
29depends_build       port:go
30use_configure       no
31use_parallel_build  no
32build.cmd           ${prefix}/bin/go run build.go
33build.target        install syncthing
34build.pre_args      -version v${version} -no-upgrade
35build.post_args     ${build.target}
36build.env           GOPATH=${workpath}
37
38test.run            yes
39
40destroot {
41    xinstall -W ${worksrcpath}/bin syncthing ${destroot}${prefix}/bin
42    xinstall -W ${worksrcpath}/man syncthing.1 ${destroot}${prefix}/share/man/man1
43    xinstall -d ${destroot}${prefix}/share/doc/${name}
44    xinstall -W ${worksrcpath} AUTHORS LICENSE NICKS ${destroot}${prefix}/share/doc/${name}
45    xinstall {*}[glob ${worksrcpath}/*.md] ${destroot}${prefix}/share/doc/${name}
46    xinstall -d ${destroot}${prefix}/share/examples/${name}
47    xinstall -W ${worksrcpath}/etc/macosx-launchd syncthing.plist ${destroot}${prefix}/share/examples/${name}
48    reinplace "s|/Users/USERNAME/bin/|${prefix}/bin/|g" ${destroot}${prefix}/share/examples/${name}/syncthing.plist
49}
50
51notes-append        \
52    "Syncthing provides an example launchd plist. To use it:" \
53    "1. Copy ${prefix}/share/examples/${name}/syncthing.plist to ~/Library/LaunchAgents" \
54    "2. Edit syncthing.plist by replacing USERNAME with your actual username" \
55    "3. Log out and in again, or run: launchctl load ~/Library/LaunchAgents/syncthing.plist"
56