QNAP [ Go ] [ 1.10.0.0 ] The Go Programming Language

QoolBox

Représentant QNAP
2 Janvier 2014
10 599
169
158
50
France
www.qnap.com
e4466adb0bfe4468bce929da938df3d3.jpg

Source : https://golang.org

Download : arm64, arm-x41, arm-x31, x86_64, x86

https://qnapclub.eu/fr/qpkg/407

Note :

install go, godoc , gomft in NAS $PATH
create automatically a share called GO-PROJECT (/share/GO-PROJECT) for the $GOPATH
(this path is assignated to go command line automatically)

Dependency

QGit (not forced) required for go get -t -u github.com...

About :

Go is an open source programming language that makes it easy to build simple, reliable, and efficient software.
 
example

to build chihaya https://github.com/chihaya/chihaya (a bittorrent track)

Code:
# export GOPATH=/share/GO-PROJECT
# cd $GOPATH
[/share/GO-PROJECT] # mkdir chihaya
[/share/GO-PROJECT] # export GOPATH=$PWD/chihaya

[/share/GO-PROJECT] # go get -t -u github.com/chihaya/chihaya/...
go: missing Git command. See https://golang.org/s/gogetcmd
package github.com/chihaya/chihaya/...: exec: "git": executable file not found in $PATH

oooops no git .. i install QGit

Code:
[/share/GO-PROJECT] # go get -t -u github.com/chihaya/chihaya/...

[/share/GO-PROJECT] # cd bin
[/share/GO-PROJECT/bin] # ll
total 12452
drwxr-xr-x    2 admin    administ    4.0K Feb 10 19:44 ./
drwxrwxrwx    6 admin    administ    4.0K Feb 10 19:37 ../
-rwxr-xr-x    1 admin    administ   10.6M Feb 10 19:44 chihaya*
-rwxr-xr-x    1 admin    administ    1.6M Feb 10 19:26 hello*

[/share/GO-PROJECT/bin] # ./chihaya --help
A customizable, multi-protocol BitTorrent Tracker

Usage:
  chihaya [flags]

Flags:
      --config string       location of configuration file (default "/etc/chihaya.yaml")
      --cpuprofile string   location to save a CPU profile
      --debug               enable debug logging