udhos / update-golang

update-golang is a script to easily fetch and install new Golang releases with minimum system intrusion
MIT License
1.86k stars 227 forks source link

raspberrypi 3 golang download issue #6

Closed dbcc closed 7 years ago

dbcc commented 7 years ago

doesn't work with a pi3

update-golang.sh: version 0.6
update-golang.sh: user: uid=0(root) gid=0(root) groups=0(root)
update-golang.sh: SOURCE=https://storage.googleapis.com/golang
update-golang.sh: DESTINATION=/usr/local
update-golang.sh: RELEASE=1.8.1
update-golang.sh: OS=linux
update-golang.sh: ARCH=armv7l
update-golang.sh: PROFILED=/etc/profile.d/golang_path.sh
update-golang.sh: CACHE=/usr/local
update-golang.sh: GOPATH=
update-golang.sh: DEBUG=
update-golang.sh: will install golang go1.8.1.linux-armv7l as: /usr/local/go
update-golang.sh: https://storage.googleapis.com/golang/go1.8.1.linux-armv7l.tar.gz is remote
--2017-05-08 10:14:17--  https://storage.googleapis.com/golang/go1.8.1.linux-armv7l.tar.gz
Resolving storage.googleapis.com (storage.googleapis.com)... 2a00:1450:4001:81b::2010, 172.217.22.80
Connecting to storage.googleapis.com (storage.googleapis.com)|2a00:1450:4001:81b::2010|:443... connected.
HTTP request sent, awaiting response... 404 Not Found
2017-05-08 10:14:18 ERROR 404: Not Found.

update-golang.sh: could not download using wget from: https://storage.googleapis.com/golang/go1.8.1.linux-armv7l.tar.gz
udhos commented 7 years ago

It seems the Go project does not provide a binary tarball for armv7l.

Unfortunately, update-golang.sh is unable to build a binary release. It requires the precompiled binary release. Only if you can provide a URL with a prebuilt go1.8.1.linux-armv7l.tar.gz, then update-golang.sh will be able to grab it and install it.

udhos commented 7 years ago

How about forcing ARCH=armv6l ? Does it fix the issue for you?

sudo ARCH=armv6l ./update-golang.sh
subvillion commented 7 years ago

same issue, ARCH=armv6l ./update-golang.sh helped

udhos commented 7 years ago

@x0x01 What does 'uname -m' report on your system?

subvillion commented 7 years ago

@udhos armv7l, rpi3 have new 64bit cpu, in 32bit mode "compatible" with old pi versions armv6l

udhos commented 7 years ago

@x0x01 Thanks. I have added an exception to download armv6l when 'uname -m' reports armv7l. Can you please test how it goes for you?

subvillion commented 7 years ago

@udhos yep, now loads armv6l

udhos commented 7 years ago

Thanks! Work-around added in https://github.com/udhos/update-golang/commit/dc306d9bae0af9cc0682f7243882b7bd30f0032e.