gpt4 book ai didi

linux - 构建 cf-cli : go build runtime: linux/386 must be bootstrapped using make. bash 时出错

转载 作者:数据小太阳 更新时间:2023-10-29 03:28:34 28 4
gpt4 key购买 nike

Cloud Foundry 的 CLI 工具位于 cloudfoundry/cli是用围棋写的。我正在尝试构建 CLI 工具但出现此错误:

go build runtime: linux/386 必须使用 make.bash 引导

如何解决这个问题?

下面是 cli/bin/build-all.sh 脚本的内容:

#!/bin/bash

set -e
set -x

OUTDIR=$(dirname $0)/../out

GOARCH=amd64 GOOS=windows $(dirname $0)/build && cp $OUTDIR/cf $OUTDIR/cf-windows-amd64.exe
GOARCH=386 GOOS=windows $(dirname $0)/build && cp $OUTDIR/cf $OUTDIR/cf-windows-386.exe
GOARCH=amd64 GOOS=linux $(dirname $0)/build && cp $OUTDIR/cf $OUTDIR/cf-linux-amd64
GOARCH=386 GOOS=linux $(dirname $0)/build && cp $OUTDIR/cf $OUTDIR/cf-linux-386
GOARCH=amd64 GOOS=darwin $(dirname $0)/build && cp $OUTDIR/cf $OUTDIR/cf-darwin-amd64

GOARCH=386 GOOS=linux 行外,一切正常并得到交叉编译,它会产生此错误:

go build runtime: linux/386 必须使用 make.bash 引导

我在 Ubuntu 14.04 上运行,我的 go 版本是 go1.3.3

如何解决这个问题?

最佳答案

请确保您已安装 golang-go-linux-386。

sudo apt-get install golang-go-linux-386

关于linux - 构建 cf-cli : go build runtime: linux/386 must be bootstrapped using make. bash 时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30424567/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com