doubiao1734
2012-07-07 00:14
浏览 47

如何在Ubuntu上安装Go and Goisntall以进行Doozer安装

I am using ubuntu 10.04 and 12.04.

I am tryig to install doozer and doozed and I am having a hard time dealing with go isntall. I will need to make a chef recipe for the install.

The directions for installing doozer as follows:

goinstall github.com/ha/doozer

How to I get goinstall?

EDIT: Using Go 1.0.2 and go install, I get the following output:

github.com/ha/doozer
# github.com/ha/doozer
/usr/local/go/src/pkg/github.com/ha/doozer/conn.go:184: cannot use &t.req (type *request) as type proto.Message in function argument:
    *request does not implement proto.Message (missing ProtoMessage method)
/usr/local/go/src/pkg/github.com/ha/doozer/conn.go:198: cannot use &r (type *response) as type proto.Message in function argument:
    *response does not implement proto.Message (missing ProtoMessage method)
/usr/local/go/src/pkg/github.com/ha/doozer/conn.go:294: undefined: proto.GetInt64
/usr/local/go/src/pkg/github.com/ha/doozer/conn.go:326: undefined: proto.GetInt64
/usr/local/go/src/pkg/github.com/ha/doozer/conn.go:412: undefined: proto.GetInt32
/usr/local/go/src/pkg/github.com/ha/doozer/conn.go:412: undefined: proto.GetInt64
/usr/local/go/src/pkg/github.com/ha/doozer/err.go:33: cannot call non-function proto.GetString (type struct {})
/usr/local/go/src/pkg/github.com/ha/doozer/msg.pb.go:127: cannot use this (type *request) as type proto.Message in function argument:
    *request does not implement proto.Message (missing ProtoMessage method)
/usr/local/go/src/pkg/github.com/ha/doozer/msg.pb.go:142: cannot use this (type *response) as type proto.Message in function argument:
    *response does not implement proto.Message (missing ProtoMessage method)
  • 写回答
  • 关注问题
  • 收藏
  • 邀请回答

2条回答 默认 最新

  • doujionggan9570 2012-07-07 01:44
    已采纳

    The doozer and doozerd packages use an old, obsolete version of Go. For the current version, Go 1, get the source code:

    go get -v github.com/ha/doozer
    
    go get -v github.com/ha/doozerd
    

    Upgrade the source code to Go 1 and then use go install:

    go install -v github.com/ha/doozer
    
    go install -v github.com/ha/doozerd
    

    Also, pretty.go has been renamed to pretty:

    See Command go.

    已采纳该答案
    打赏 评论
  • douwen5985 2012-07-14 10:30

    Just for reference (go to prepare)

    $ cd /var/tmp
    $ wget http://go.googlecode.com/files/go1.0.2.linux-386.tar.gz
    $ tar xvfz go1...tar.gz
    $ export GOROOT=/var/tmp/go
    $ export PATH=$PATH:$GOROOT/bin
    $ go
    Go is a tool for managing Go source code.
    
    Usage:
    
        go command [arguments]
    
    The commands are:
    
        build       compile packages and dependencies
        clean       remove object files
        doc         run godoc on package sources
        env         print Go environment information
        fix         run go tool fix on packages
        fmt         run gofmt on package sources
        get         download and install packages and dependencies
        install     compile and install packages and dependencies
        list        list packages
        run         compile and run Go program
        test        test packages
        tool        run specified go tool
        version     print Go version
        vet         run go tool vet on packages
    
    Use "go help [command]" for more information about a command.
    
    Additional help topics:
    
        gopath      GOPATH environment variable
        packages    description of package lists
        remote      remote import path syntax
        testflag    description of testing flags
        testfunc    description of testing functions
    
    Use "go help [topic]" for more information about that topic.
    
    打赏 评论

相关推荐 更多相似问题