Ticket #48905: Portfile.2

File Portfile.2, 1.9 KB (added by anatol (Anatol Pomozov), 9 years ago)

Up-to-date port file

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.12.20 v
8revision                0
9categories              net
10platforms               darwin
11maintainers             me.com:link.dupont
12description             Open source continuous file synchronization application
13homepage                https://syncthing.net
14license                 MPL-2
15
16long_description        Syncthing replaces proprietary sync and cloud services \
17                        with something open, trustworthy and decentralized. Your \
18                        data is your data alone and you deserve to choose where \
19                        it is stored, if it is shared with some third party and \
20                        how it's transmitted over the Internet.
21
22
23checksums           rmd160  d9db0b1aa9c785954f279c251357f51ee2b9949a \
24                    sha256  d42bd68934f10cb7448c8d24f100e1a3c5221a9543cb28fc81a2719f58c33024
25
26depends_build   port:go
27
28worksrcdir      src/github.com/syncthing/syncthing
29
30#startupitem.create      yes
31#startupitem.netchange   yes
32#startupitem.executable  ${prefix}/bin/syncthing -no-browser -logflags=0
33
34post-extract {
35        xinstall -d ${workpath}/src/github.com/syncthing
36        move ${workpath}/${name}-${github.version} ${worksrcpath}
37}
38
39use_configure   no
40
41build {
42        system -W ${worksrcpath} "GOPATH=${workpath} go run build.go -no-upgrade -version=v${version} build"
43}
44
45destroot {
46        xinstall -W ${worksrcpath} syncthing ${destroot}${prefix}/bin
47       
48        xinstall -d ${destroot}${prefix}/share/doc/${name}
49        xinstall -m 644 ${worksrcpath}/LICENSE \
50                ${destroot}${prefix}/share/doc/${name}/
51       
52        xinstall -d ${destroot}${prefix}/share/${name}
53        xinstall -m 644 ${worksrcpath}/etc/macosx-launchd/syncthing.plist \
54                ${destroot}${prefix}/share/${name}/
55}
56
57notes {
58        Syncthing ships with a sample launchd plist that must be configured before use.
59        Copy /opt/local/share/syncthing/syncthing.plist to ~/Library/LaunchAgents and replace USERNAME with your username. Then run: launchctl load ~/Library/LaunchAgents/syncthing.plist.
60}