Attempt 1: apt-get
My first attempt was to simply run:- sudo apt-get install cloudprint
- UnboundLocalError: local variable 'auth_response' referenced before assignment
Cleanup:
- sudo apt-get remove cloudprint
Attempt 2: Compile with gccgo
I then found this wiki about installing a newer version: https://github.com/google/cloud-print-connector/wiki/Build-from-sourceSo I then installed:
- go: sudo apt-get install gccgo-go
- dev packages: sudo apt-get install build-essential libcups2-dev libavahi-client-dev git bzr
- export GOPATH=$HOME/workspace/gocode
- go get github.com/google/cloud-print-connector/...
- error: unknown field ‘KeepAlive’ in ‘net.Dialer’
- error: reference to undefined field or method ‘Timeout’
- go version xgcc (Ubuntu 4.9.3-0ubuntu4) 4.9.3 linux/amd64
- which is not greater than or equal to version 1.5.2
Cleanup:
- sudo apt-get remove gcc-go
Attempt 3: The correct way
You will still need the dev packages and gopath from attempt 2:- sudo apt-get install build-essential libcups2-dev libavahi-client-dev git bzr
- export GOPATH=$HOME/workspace/gocode
- Download: https://storage.googleapis.com/golang/go1.8.2.linux-amd64.tar.gz or check for a more recent version: https://golang.org/dl/
- Extract to /usr/local: sudo tar -C /usr/local -xvf go*.linux-amd64.tar.gz
- Add to path: export PATH=$PATH:/usr/local/go/bin
- go get github.com/google/cloud-print-connector/...
No comments:
Post a Comment