英文:
can't make juju charm-store server?
问题
我正在尝试在我的本地机器上运行juju charm-server。我按照这些步骤进行操作(https://github.com/juju/charmstore),但是出现了以下错误。当我输入make命令时,它会给出以下错误信息。
Makefile:49: *** Cannot build; /home/sajith/Projects/Backup/charm-store-server/charmstore is not on GOPATH. Stop
在我的bash文件中,我添加了以下内容:
GOROOT=/home/sajith/install/go/go
GOPATH=/home/sajith/Projects/Backup/charm-store-server/charmstore
然后导出GOROOT和GOPATH:
PATH=$PATH:$HOME/bin:$GOROOT/bin
export GOROOT
export GOPATH
我想知道如何设置这些Go变量以运行juju charm-store服务器。
英文:
I am trying to run juju charm-server in my local machine.I followed these steps.(https://github.com/juju/charmstore) but it gives this error.When i enter make command it gives this one.
Makefile:49: *** Cannot build; /home/sajith/Projects/Backup/charm-store-server/charmstore is not on GOPATH. Stop
In my bash file I have added
GOROOT=/home/sajith/install/go/go
GOPATH=/home/sajith/Projects/Backup/charm-store-server/charmstore
and then export GOROOT and GOPATH
PATH=$PATH:$HOME/bin:$GOROOT/bin
export GOROOT
export GOPATH
I want to know how to setup these Go variable for run juju charm-store server.
答案1
得分: 3
你的GOPATH
应该是:
GOPATH=/home/sajith/Projects/Backup
然后使用go get
命令将项目放在以下位置:
/home/sajith/Projects/Backup/src/github.com/juju/charmstore
GOPATH
定义了一个**工作空间**,其中go将创建src
、pkg
和bin
文件夹。
go get
将获取$GOPATH/src
中的源代码。
英文:
Your GOPATH
should be:
GOPATH=/home/sajith/Projects/Backup
Then a go get would put the project in
/home/sajith/Projects/Backup/src/github.com/juju/charmstore
A GOPATH
defines a workspace in which go will create src
, pkg
and bin
folders.
go get
will get sources in $GOPATH/src
.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论