minio/INSTALLGO.md

65 lines
1.6 KiB
Markdown
Raw Normal View History

## Ubuntu (Kylin) 14.04
2014-11-30 22:55:10 +01:00
### Build Dependencies
2015-05-28 02:43:39 +02:00
This installation document assumes Ubuntu 14.04+ on x86-64 platform.
2014-11-30 22:55:10 +01:00
2015-05-28 02:51:20 +02:00
##### Install Git, GCC, yasm
2014-12-04 10:56:01 +01:00
```sh
2015-05-28 02:51:20 +02:00
$ sudo apt-get install git build-essential yasm
2014-11-30 22:55:10 +01:00
```
##### Install Go 1.5+
Download Go 1.5+ from [https://golang.org/dl/](https://golang.org/dl/).
2015-05-28 02:43:39 +02:00
```sh
$ wget https://storage.googleapis.com/golang/go1.5.linux-amd64.tar.gz
2015-05-28 02:43:39 +02:00
$ mkdir -p ${HOME}/bin/
$ mkdir -p ${HOME}/go/
$ tar -C ${HOME}/bin/ -xzf go1.5.linux-amd64.tar.gz
2015-05-28 02:43:39 +02:00
```
##### Setup GOROOT and GOPATH
2015-05-28 02:43:39 +02:00
Add the following exports to your ``~/.bashrc``. Environment variable GOROOT specifies the location of your golang binaries
and GOPATH specifies the location of your project workspace.
2015-05-28 02:43:39 +02:00
```sh
$ export GOROOT=${HOME}/bin/go
$ export GOPATH=${HOME}/go
$ export PATH=$PATH:${HOME}/bin/go/bin:${GOPATH}/bin
```
2015-05-28 02:43:39 +02:00
## OS X (Yosemite) 10.10
### Build Dependencies
2015-05-28 02:43:39 +02:00
This installation document assumes OS X Yosemite 10.10+ on x86-64 platform.
##### Install brew
```sh
$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
```
##### Install Git, Python
```sh
2015-05-28 02:51:20 +02:00
$ brew install git python yasm
```
##### Install Go 1.5+
2015-05-28 02:43:39 +02:00
Install golang binaries using `brew`
2015-05-28 02:43:39 +02:00
```sh
$ brew install go
2015-05-28 02:43:39 +02:00
$ mkdir -p $HOME/go
```
2015-05-28 02:43:39 +02:00
##### Setup GOROOT and GOPATH
2015-05-28 02:43:39 +02:00
Add the following exports to your ``~/.bashrc``. Environment variable GOROOT specifies the location of your golang binaries
and GOPATH specifies the location of your project workspace.
2015-05-28 02:43:39 +02:00
```sh
$ export GOPATH=${HOME}/go
$ export GOVERSION=$(brew list go | head -n 1 | cut -d '/' -f 6)
$ export GOROOT=$(brew --prefix)/Cellar/go/${GOVERSION}/libexec
$ export PATH=$PATH:${GOPATH}/bin
2014-11-30 22:55:10 +01:00
```