安装GO-1.2的QML包在Xubuntu上找不到。

huangapple go评论89阅读模式
英文:

Installing the QML Package for GO-1.2 Cannot Be Found - Xubuntu

问题

一些背景信息: 我对GO和QML非常陌生。我一直在浏览关于它们的互联网信息,是因为我正在尝试构建Sublime Text克隆版Lime Text。我使用Xubuntu 13.10操作系统。我按照GO官方网站上“入门指南”部分的说明安装了GO。我下载并解压了go1.2.1.linux-amd64.tar.gz压缩包到/usr/local/文件夹中。我在我的.bashrc文件中添加了export PATH=$PATH:/usr/local/go/binexport GOROOT=/usr/local/goexport GOBIN=/usr/local/go/binexport GOPATH=$HOME/gocode

然后,我成功地按照Lime Text的GitHub Wiki上的说明进行构建,并执行了go get github.com/limetext/lime/frontend/termbox命令。我按照其余的Wiki页面上的说明进行操作,一切似乎都执行成功了。

我的问题 是Lime Text需要安装GO QML包。所以我去了他们的GitHub页面,并安装了ppa:ubuntu-sdk-team/ppa存储库中建议的所有QT依赖项。我已经安装了GO,所以不需要使用godeb程序重新安装GO。然后我在终端中执行了go get gopkg.in/qml.v0命令。终端没有显示任何消息,我认为一切都进行得很顺利。然后我回到Lime Text的构建说明,尝试构建QML前端。我进入cd $GOPATH/src/github.com/limetext/lime/frontend/qml目录,并运行go build命令。终端输出如下:

main.go:18:2: cannot find package "github.com/niemeyer/qml" in any of:
    /usr/local/go/src/pkg/github.com/niemeyer/qml (from $GOROOT)
    /home/jesse/gocode/src/github.com/niemeyer/qml (from $GOPATH)

我尝试使用Catfish在整个系统中搜索关键词"niemeyer",看看它是否安装在其他地方,但搜索结果为空。我尝试多次运行go get gopkg.in/qml.v0命令,结果都一样。我不知道我在安装包时是否做错了什么,或者对GO有一些其他基本的误解。

如果有任何建议,我将不胜感激。对于在这里使用任何不正确的术语,我表示歉意。

英文:

A Little Background: I am extremely new to GO and QML. The main reason I have been perusing the internet about them is because I am trying to build the Sublime Text clone Lime Text. I am on Xubuntu 13.10. I installed GO from the instructions under their 'Getting Started Section' on their website. I downloaded and unpacked the go1.2.1.linux-amd64.tar.gz tarball to my /usr/local/ folder. I added export PATH=$PATH:/usr/local/go/bin, export GOROOT=/usr/local/go, export GOBIN=/usr/local/go/bin, and export GOPATH=$HOME/gocode to my .bashrc file.

I then could successfully follow the directions on the Lime Text github wiki for building and perform go get github.com/limetext/lime/frontend/termbox. I followed the rest of the instructions on their wiki page and everything seemed to execute sucessfully.

My problem is Lime Text requires that the GO QML package be installed. So I went to their git hub page and installed all of the QT dependencies that are suggested from the ppa:ubuntu-sdk-team/ppa repository. I have already installed GO so I don't re-install GO with the godeb program. I then perform go get gopkg.in/qml.v0 in my terminal. I don't get any messages to my terminal and assume that everything went fine. I then go back to the Lime Text build instructions and try to build the QML front end. I cd to cd $GOPATH/src/github.com/limetext/lime/frontend/qml and run the go build command. The output to my terminal is:

main.go:18:2: cannot find package "github.com/niemeyer/qml" in any of:
    /usr/local/go/src/pkg/github.com/niemeyer/qml (from $GOROOT)
    /home/jesse/gocode/src/github.com/niemeyer/qml (from $GOPATH)

I tried to use Catfish to search my whole system for the word 'niemeyer' to see if it was installed somewhere else but the search turned up nothing. I have tried running go get gopkg.in/qml.v0 a few more times and I get the same results. I don't know if I am doing something wrong with installing a package or have some other fundamental misunderstandings about GO.

Any suggestions would be appreciated. I apologize for using any incorrect terminology here as well.

答案1

得分: 2

在你运行go build的同一个位置,运行go get命令,不带任何参数。它会搜索代码库中的所有依赖项并下载它们。如果你愿意,你也可以使用go get -v命令,其中-v表示详细模式。它会告诉你正在下载和构建的具体内容。

之后,你应该能够成功运行go build命令。

英文:

In the same place where you ran go build, run go get, no parameters. It will search the code base for all dependencies and download them. If you want, you can instead do go get -v, where -v stands for verbose. It will tell you exactly what it is downloading and building.

After that you should be able to go build successfully.

huangapple
  • 本文由 发表于 2014年4月18日 02:13:55
  • 转载请务必保留本文链接:https://go.coder-hub.com/23140467.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定