如何在命令行中处理空格?如:GOMAKE = $ {GOGO}(此处为空格)构建

时间:2012-07-10 10:08:02

标签: autoconf

我想编译thrift 0.8以支持go1(golang版本1)。在go1之前,有两个命令:goinstall和gomake,所以在configure脚本中的行如下:

GOMAKE=${GOBIN}/gomake
GOINSTALL=${GOBIN}/goinstall

但是从go1开始,“go install”和“go build”取代了“goinstall”和“gomake”,我发现有些人改变了thrift配置脚本:

GOGO=${GOBIN}/go
GOMAKE=${GOGO} build
GOINSTALL=${GOGO} install

但是当我尝试使用以下命令运行脚本:./ configure,我得到了:

./configure: line 18067: build: command not found 
install: missing file operand
Try `install --help' for more information.
checking for 6g... /6g
checking for 6l... /6l

不确定,但我认为

"./configure: line 18067: build: command not found" 

意味着“GOMAKE = $ {GOGO} build”中的空格无法处理,对吧?任何人都可以帮忙完成这项工作吗?谢谢


我尝试从

编辑configure.ac
 GOGO=${GOBIN}/go
 GOMAKE=${GOGO} build
 GOINSTALL=${GOGO} install

GOGO=${GOBIN}/go
GOMAKE="${GOGO} build"
GOINSTALL="${GOGO} install"

然后重新生成配置脚本,并运行它。似乎直接忽略修改后的行:


checking for go... /home/alex/go/bin/go
(*************checking goinstall and gomake should be here,but not)
checking for an ANSI C-conforming const... yes

0 个答案:

没有答案