我运行了以下命令。
# make docker
goshim.tar.bz2
有没有办法避免这种现象?
make:execvp:/ bin / sh:参数列表太长
这可能是由Removing intermediate container fb7423fe5cf7
---> 24c6fdada18f
Successfully built 24c6fdada18f
Successfully tagged hyperledger/fabric-orderer:latest
docker tag hyperledger/fabric-orderer hyperledger/fabric-orderer:arm64-1.4.1-snapshot-e91c57c5f
docker tag hyperledger/fabric-orderer hyperledger/fabric-orderer:arm64-latest
Creating .build/goshim.tar.bz2
make: execvp: /bin/sh: Argument list too long
make: *** [Makefile:315: .build/goshim.tar.bz2] Error 127
生成的源文件列表引起的,这对于$(BUILD_DIR)/goshim.tar.bz2: $(GOSHIM_DEPS)
@echo "Creating $@"
@tar -jhc -C $(GOPATH)/src $(patsubst $(GOPATH)/src/%,%,$(GOSHIM_DEPS)) > $@
来说太长了,这是隐式执行的。
试试这个:用GOSHIM_DEPS
替换sh
线
我没有与您相同的环境,因此上述代码可能有错误,但可以应用基本思路。
编辑:那说,仍然有可能错误可能仍然存在。 @tar
本身是使用@./scripts/goListFiles.sh $(PKGNAME)/core/chaincode/shim | sed “s!$(GOPATH)/src/!!g” |xargs tar -jhc -C $(GOPATH)/src > $@
语法定义的,并且在sh参数长度的上限之下。