Tuesday, March 24, 2015

Upgrading GoLang on a (Linux ARM) Rasperry Pi to 1.4.2, Git Edition

You may have seen my previous post where I chronicled the debacle of upgrading GoLang on my ARM-Linux Raspberry Pi only to have it roll back to a previous version, so I had to force it to upgrade with a little more manual elbow grease. Not much, fortunately, but enough to be confusing if you're not accustomed to the procedure.

At one point someone suggested that problem was because 1.4 was in git and not mercurial. That was incorrect, as I was still able to convince Mercurial to grab the proper release version. But it was an omen of what was to come.

Time had passed, updates were released, and I tried the upgrade again only to have it hilariously backpedal to version 1.3.3 again. Time to move to the latest "true" way of updating, I guess.

First, fix the damage of a Go install with the wrong version. My home directory had a ./go directory with the source in it. Make it go away...

rm -fr go

Next, grab the source.

git clone https://go.googlesource.com/go
cd go
git checkout go1.4.2

Now to compile it.

cd src
./all.bash

Wait a long time, then all set!

go version
-> go version go1.4.2 linux/arm

No comments:

Post a Comment