简体   繁体   English

“提取铬”如何工作? 如何编辑gclient配置

[英]how does 'fetch chromium' work? How to edit gclient config

I am trying to download the chromium code, I am doing it for the first time. 我正在尝试下载铬代码,这是我第一次这样做。 After many hours 'fetch chromium' failed due to OutOfMemory exception. 许多小时后,由于内存不足异常,“获取铬”失败。 Its here on chromium issues 关于铬的问题

My question is: How do I configure my .gclient (where is this located) to ignore some git clones operations? 我的问题是:我该如何配置.gclient(位于此位置)以忽略某些git clone操作? Where can I find the list of actions that gclient does to fetch the code? 在哪里可以找到gclient提取代码的操作列表? Is there some list of dependencies defined somewhere? 在某处定义了一些依赖项列表吗? Can I restart 'fetch' operation skipping already downloaded ones? 我可以重新启动“获取”操作,跳过已下载的操作吗?

thanks in advance. 提前致谢。

Regarding OOM error during fetch: 关于获取期间的OOM错误:

    This should be fixed now: https://codereview.chromium.org/202753003/
    Please make sure your checkout of depot_tools is up to date...

And regarding how fetch works, you can always check fetch script in depot_tools/fetch.py 关于获取的工作方式,您始终可以在depot_tools / fetch.py​​中检查获取脚本

.gclient is present in directory where you're checking out code (hidden file , ctrl+h ?) .gclient存在于您检出代码的目录中(隐藏文件,Ctrl + h吗?)

To ignore syncing some projects you can select custom_deps like this, but strongly advised to not do this anyway.. 要忽略同步某些项目,您可以像这样选择custom_deps,但强烈建议不要这样做。

 "custom_deps": {
  "src/third_party/WebKit": None,   
},

more from here: Advanced_Usage get_the_code 更多信息,请参见Advanced_Usage get_the_code

On a 64 bit OS with <4GB RAM, the gcm_utils.py queries platform bit (32 or 64) and assumes you have enoughy memory, which is >4gb and uses -2g instead of -512m in fetching. 在具有<4GB RAM的64位操作系统上,gcm_utils.py会查询平台位(32或64),并假定您有足够的内存,即> 4gb,并且在获取时使用-2g而不是-512m。

So if you have less memory on a 64bit, you might have to edit the utils file and change it to 512m or equivalent. 因此,如果64位内存较少,则可能必须编辑utils文件并将其更改为512m或等效文件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM