# Install go-bitsong

This guide will explain how to install the bitsongd and bitsongcli entrypoints onto your system. With these installed on a server, you can participate in the testnet as either a Full Node or a Validator.

# Install Go

Install go by following the official docs. Remember to set your $PATH environment variable, for example:

mkdir -p $HOME/go/bin
echo "export PATH=$PATH:$(go env GOPATH)/bin" >> ~/.bash_profile
source ~/.bash_profile


Go 1.13+ is required for go-bitsong.

# Install the binaries

Next, let's install the latest version of go-bitsong. Make sure you git checkout the correct released version.

git clone -b <latest-release-tag> https://github.com/bitsongofficial/go-bitsong
cd go-bitsong && make install

If this command fails due to the following error message, you might have already set LDFLAGS prior to running this step.

# github.com/bitsongoffcial/go-bitsong/cmd/bitsongd
flag provided but not defined: -L
usage: link [options] main.o
make: *** [install] Error 2

Unset this environment variable and try again.

LDFLAGS="" make install

NOTE: If you still have issues at this step, please check that you have the latest stable version of GO installed.

That will install the bitsongd and bitsongcli binaries. Verify that everything is OK:

$ bitsongd version --long
$ bitsongcli version --long

bitsongcli for instance should output something similar to:

name: go-bitsong
server_name: bitsongd
client_name: bitsongcli
version: 0.3.1
commit: 4a2595e9c9308196e2a27ff0c914e0217696cb72
build_tags: netgo,ledger
go: go version go1.13.6 linux/amd64

# Build Tags

Build tags indicate special features that have been enabled in the binary.

Build Tag Description
netgo Name resolution will use pure Go code
ledger Ledger devices are supported (hardware wallets)

# Next

Now you can join the public testnet or create you own testnet