在ubuntu上编译chrome

在ubuntu上编译chrome
红心地瓜
1.获取代码
1)下载tarball,http://chromium-browser-source.commondatastorage.googleapis.com/chromium_tarball.html
2)   解压缩
3)安装dept_tools:
将dept_tools加到PATH里面
export PATH="$PATH":`pwd`/depot_tools或者加到~/.bashrc里面
2.安装dependency
进到chromium/src目录下
./build/install-build-deps.sh
3.同步代码
进到chromium/src目录下
gclient sync --force
如果不想同步,则必须执行
gclient runhooks --force
这一步会调用gyp来长生一些平台特定的代码,只要做一次就可以
4.配置
./build/gyp_chromium -Dflag1=value1 -Dflag2=value2

5.编译
make chrome
碰到问题及解决
1.bison: cannot open file `external/bison/data/m4sugar/m4sugar.m4': No such file or directory
看着像bison没有装好,又重新apt-get remove/install装了bison,还是不行,到网站下载最新的2.5编译安装,还是不行
于是bison -V
发现显示的是
bison (GNU Bison) 2.3
可是我用Whereis bison,显示的又是我刚装的2.5的地址
判断是哪里的bison预先执行了
于是
strace(bison),果然
execve("/home/tom/work/gingerbread/out/host/linux-x86/bin/bison", ["bison"], [/* 51 vars */]) = 0
原因是我将android out 的地址设定在path的前面,于是覆盖了/usr/local/bin,执行了android下面的bison
修改PATH变量,问题得到解决
2.link的时候内存不足退出
解决方法:
1)加大swap,我加到了8G
2)采用gold ld替代ld进行链接
 export
CC="gcc -B/usr/local/gold/bin"
或者将
/usr/local/gold/bin加到PATH变量中/usr/bin的前面
参考:

在ubuntu上编译chrome的更多相关文章

  1. 【转】Ubuntu 上编译Android出现cannot find -lstdc++解决办法

    [转]Ubuntu 上编译Android出现cannot find -lstdc++解决办法 在Ubuntu 12.04 x86_64机器上编译Android出现下面错误,是因为找不到32bit的li ...

  2. (原)ubuntu上编译PANet/Detectron.pytorch时-std=c99的错误

    转载请注明出处: https://www.cnblogs.com/darkknightzh/p/10494787.html 在ubuntu上编译PANet/Detectron.pytorch时,总提示 ...

  3. 在Ubuntu上安装Chrome Driver和Firefox Driver

    在Ubuntu上安装Chrome Driver和Firefox Driver 此文章只介绍Chrome Driver(Firefox Driver和该步骤相同) 下载链接:http://chromed ...

  4. .NET跨平台:在Linux Ubuntu上编译coreclr/corefx/dnx(20150617)

    编译时间:北京2015年6月17日上午 操作系统:Ubuntu 14.04.2 LTS Mono版本:Mono JIT compiler version 4.3.0 (master/3445ac5 T ...

  5. 在Ubuntu上安装Chrome浏览器和ChromeDriver

    启动脚本后报错 selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable may have w ...

  6. Qt+MPlayer音乐播放器开发笔记(一):ubuntu上编译MPlayer以及Demo演示

    前言   在ubuntu上实现MPlayer播放器播放音乐.   Demo                Mplayer   MPlayer是一款开源多媒体播放器,以GNU通用公共许可证发布.此款软件 ...

  7. 在Linux Ubuntu上编译DNX

    DNX是.NET Execution Environment,前身是XRE,XRE的前身是KRuntime,项目网址:https://github.com/aspnet/DNX . 签出DNX的代码: ...

  8. Ubuntu 上编译opencv_contrib模块for Android

    https://blog.csdn.net/ipfpm/article/details/81132144 [ubuntu]Ubuntu中Android SDK下载跟配置 android24的版本 (1 ...

  9. 在Ubuntu上更新Chrome到最新的版本

    本操作只限于已经安装了Chrome的Ubuntu系统: Step 1: sudo apt-get update Step 2: sudo apt-get install google-chrome-s ...

随机推荐

  1. sql server 判断相同值的数据

    举个栗子, 求出相同作者的书 select * from [books]  where author in (select author from [books] group by author ha ...

  2. iOS开发之iPhone通过get和post方式请求asp.net webservice

    .创建一个webservice .在webconfig中启用http get 和http post. 复制代码 <</span> webServices > <</ ...

  3. POJ2230 Watchcow【欧拉回路】

    Watchcow Time Limit: 3000MS Memory Limit: 65536K Total Submissions: 6172Accepted: 2663 Special Judge ...

  4. JDBC batch批处理Statement executeBatch 具体解释

    JDBC提供了数据库batch处理的能力,在数据大批量操作(新增.删除等)的情况下能够大幅度提升系统的性能.我曾经接触的一个项目,在没有採用batch处理时,删除5万条数据大概要半个小时左右,后来对系 ...

  5. [Redux] Reducer Composition with combineReducers()

    Previous, we do composition with objects: const todoApp = (state = {}, action) => { return { todo ...

  6. iOS 在 Xcode 中重命名项目名称

    本教程使用的 Xcode 版本是Xcode 6.3.1,网上有好多的教程,都是在 Xcode 4 上做的讲解,现以本文章讲解一下如何在 Xcode 6.3.1 中重命名你的项目名称,包括你的应用名称. ...

  7. 关于CSS选择器的效率问题

    最近一段时间接触CSS比较多,所以从网上找了写资料,这里做下总结. 以下是CSS选择器的效率排名: id选择器(#myid) 类选择器(.myclassname) 标签选择器(div,h1,p) 相邻 ...

  8. Embedded tomcat 7 servlet 3.0 annotations not working--转

    Question: I have a stripped down test project which contains a Servlet version 3.0, declared with an ...

  9. ViewPage 一次滑动多页

    效果 size是3的倍数时   其他情况下 初始化     private List<HonerUserBean> anchorList;     private ViewPager vp ...

  10. C#App.config的使用

    为什么使用App.config, 在连接数据的时候将连接字符串写在了类中,如果更换数据库地址,则需要修改这个类,然后重新编译才可以重新连接数据库.在这个时候我们就可以将连接信息放到配置文件App.co ...