“去建立”安装Go的新版本后变得非常缓慢 [英] "go build" became very slow after installing a new version of Go
本文介绍了“去建立”安装Go的新版本后变得非常缓慢的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
解决方案
您可能每次都重新编译依赖项。试试去安装-a mypackage
来重建所有的依赖关系。
删除 $ GOPATH / pkg
也有助于确保您没有旧的目标文件。
使用 -x
标志构建将显示工具链是否查找不兼容的版本。
After upgrading from Go 1.2.1 to 1.3 (Windows 7 64 bit) "go build" execution time has increased from around 4 to over 45 seconds. There were no other changes except the go version update. Switching off the virus scanner seems to have no effect. Any clues?
解决方案
You probably have dependencies that are being recompiled each time. Try go install -a mypackage
to rebuild all dependencies.
Removing $GOPATH/pkg
also helps to ensure you don't have old object files around.
Building with the -x
flag will show you if the toolchain is finding incompatible versions.
这篇关于“去建立”安装Go的新版本后变得非常缓慢的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文