<commit_before># golang-armbuilds
Pre-compiled GOLANG tarballs for ARM devices.


## How to create a pre-compiled GOLANG 1.4.x tarball
Unfortunately there are no pre-compiled GOLANG tarballs for ARM officially available yet and
the preferred way to build such a tarball from source isn't well documented at all.

This is a simple approach to compile Go from source and package it as a tarball. This tarball
should work like the official tarballs from the [GOLANG download page](https://golang.org/dl/).
For the sake of simplicity this build steps are meant to be used on a freshly installed Linux
distro on any ARM machine.

Please feel free to use this build recipe and report any issues AND when you could
successfully build Go on a new machine send us this information so we can include this machine
to the list of supported devices!

### 1. Prepare the build machine

   Just install all necessary packages, for details see the official guide
   [Installing Go from source](https://golang.org/doc/install/source).
   At least you'll need `gcc` to compile Go 1.4.x from source.

   For a [Scaleway](https://www.scaleway.com) C1 server (Ubuntu 15.04):
   ```
   apt-get update
   apt-get install -y curl git gcc
   ```

### 2. Clone this repo
```
git clone https://github.com/hypriot/golang-armbuilds.git
cd golang-armbuilds
```

### 3. Run the compile script
```
./make-tarball-1.4.x.sh
```

### 4. Use it directly or upload the created tarball to GitHub releases
```
go1.4.3.linux-armv7.tar.gz
```


## How to create a pre-compiled GOLANG 1.5.x tarball
In order to build Go 1.5.x from source, we need to have at least a Go 1.4 version installed on
our dev machine. For this reason we just install our pre-compiled Go 1.4.x tarball and use it
to bootstrap Go 1.5.x with it.

### 1. Prepare the build machine

   Just install all necessary packages, for details see the official guide
   [Installing Go from source](https://golang.org/doc/install/source).

   For a [Scaleway](https://www.scaleway.com) C1 server (Ubuntu 15.04):
   ```
   apt-get update
   apt-get install -y curl git
   ```

### 2. Clone this repo
```
git clone https://github.com/hypriot/golang-armbuilds.git
cd golang-armbuilds
```

### 3. Run the compile script
```
./make-tarball-1.5.x.sh
```

### 4. Use it directly or upload the created tarball to GitHub releases
```
go1.5.1.linux-armv7.tar.gz
```


## Additional sources for building GOLANG on ARM
- GoArm Wiki, https://github.com/golang/go/wiki/GoArm
- Build from source, http://dave.cheney.net/2015/09/04/building-go-1-5-on-the-raspberry-pi by <NAME>
- Cross compile, http://dave.cheney.net/2015/08/22/cross-compilation-with-go-1-5 by <NAME>
- Unofficial ARM tarballs for Go, http://dave.cheney.net/unofficial-arm-tarballs by <NAME>
- Issue golang/go/#13066: build: provide ARM release binaries?, https://github.com/golang/go/issues/13066


# Acknowledgements
Many thanks to the GOLANG team at Google and all maintainers and contributers.<commit_msg>Add todo list to readme<commit_after># golang-armbuilds
Pre-compiled GOLANG tarballs for ARM devices.


## How to create a pre-compiled GOLANG 1.4.x tarball
Unfortunately there are no pre-compiled GOLANG tarballs for ARM officially available yet and
the preferred way to build such a tarball from source isn't well documented at all.

This is a simple approach to compile Go from source and package it as a tarball. This tarball
should work like the official tarballs from the [GOLANG download page](https://golang.org/dl/).
For the sake of simplicity this build steps are meant to be used on a freshly installed Linux
distro on any ARM machine.

Please feel free to use this build recipe and report any issues AND when you could
successfully build Go on a new machine send us this information so we can include this machine
to the list of supported devices!

### 1. Prepare the build machine

   Just install all necessary packages, for details see the official guide
   [Installing Go from source](https://golang.org/doc/install/source).
   At least you'll need `gcc` to compile Go 1.4.x from source.

   For a [Scaleway](https://www.scaleway.com) C1 server (Ubuntu 15.04):
   ```
   apt-get update
   apt-get install -y curl git gcc
   ```

### 2. Clone this repo
```
git clone https://github.com/hypriot/golang-armbuilds.git
cd golang-armbuilds
```

### 3. Run the compile script
```
./make-tarball-1.4.x.sh
```

### 4. Use it directly or upload the created tarball to GitHub releases
```
go1.4.3.linux-armv7.tar.gz
```


## How to create a pre-compiled GOLANG 1.5.x tarball
In order to build Go 1.5.x from source, we need to have at least a Go 1.4 version installed on
our dev machine. For this reason we just install our pre-compiled Go 1.4.x tarball and use it
to bootstrap Go 1.5.x with it.

### 1. Prepare the build machine

   Just install all necessary packages, for details see the official guide
   [Installing Go from source](https://golang.org/doc/install/source).

   For a [Scaleway](https://www.scaleway.com) C1 server (Ubuntu 15.04):
   ```
   apt-get update
   apt-get install -y curl git
   ```

### 2. Clone this repo
```
git clone https://github.com/hypriot/golang-armbuilds.git
cd golang-armbuilds
```

### 3. Run the compile script
```
./make-tarball-1.5.x.sh
```

### 4. Use it directly or upload the created tarball to GitHub releases
```
go1.5.1.linux-armv7.tar.gz
```


## TODO
- include the standard GOLANG tests for all builds
- run builds for ARMv5, ARMv6 and ARMv7
- automate builds via CI/CD (travis or circle-ci)


## Additional sources for building GOLANG on ARM
- GoArm Wiki, https://github.com/golang/go/wiki/GoArm
- Build from source, http://dave.cheney.net/2015/09/04/building-go-1-5-on-the-raspberry-pi by <NAME>
- Cross compile, http://dave.cheney.net/2015/08/22/cross-compilation-with-go-1-5 by <NAME>
- Unofficial ARM tarballs for Go, http://dave.cheney.net/unofficial-arm-tarballs by <NAME>
- Issue golang/go/#13066: build: provide ARM release binaries?, https://github.com/golang/go/issues/13066


# Acknowledgements
Many thanks to the GOLANG team at Google and all maintainers and contributers.
{'fraction_non_alphanumeric': 0.10390459075314491, 'fraction_numerical': 0.024669171703969938, 'mean_word_length': 3.6343679031037093, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 18, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4163334', 'n_tokens_mistral': 2100, 'n_tokens_neox': 1886, 'n_words': 772}