Build Chromium from source
Inspired by this thread try the following
Pre-condition
VM with 4GB Memory + 40GB harddrive
Workflow
1. mkdir -pv ~/chromium
2. cd ~/chromium
3. git config --global user.name "You Name"
4. git config --global user.email “[email protected]”
5. git config --global core.autocrlf false
6. git config --global core.filemode false
7. git config --global color.ui true
8. git clone https://chromium.googlesource.com/chromium/tools/depot_tools
9. export PATH=$PATH:~/chromium/depot_tools See Update Notes 1
10. mkdir -v ~/chromium/buildhost
11. cd ../buildhost
12. fetch --nohooks chromium
13. cd src && ./build/install-build-deps.sh
14. gclient sync (this also does runhooks)
15. gclient runhooks
16. ninja -C out/Release chrome
I have found that having 4GB memory and a large disk was important. The chromium project is ~15GB and the builds out/Release
will be ~2GB and out/Debug
>8GB
Related videos on Youtube
Jeremy Rea
Updated on September 18, 2022Comments
-
Jeremy Rea over 1 year
I'm using Fedora 16 and I've successfully compiled Chromium from source (the first time I compiled something from source) a while back following these instructions:
http://code.google.com/p/chromium/wiki/LinuxBuildInstructions
At the end of the process, everything worked. However, after multiple attempts, I have had no luck in compiling a newer version of the program. I am stuck with Version 20.0.1100.0 custom (132047). Before re-building, I follow the steps to syncing my sources. But after all of the steps, build 132047 is still what I have.
Can someone help me please to building newer builds and using them as I can't seem to find anything on the internet.
Thanks!
-
Mat almost 12 yearsWhen you update the source, do you see what version your snapshot is at?
-
Jeremy Rea almost 12 years@Mat yes, it shows a newer version (higher number) of the snapshot.
-
Mat almost 12 yearsAre you certain you're running your newly-compiled executable(s)? (Make sure you don't have any "old" chrome windows open.)
-
Jeremy Rea almost 12 yearsI would think so. I closed chromium, and deleted my old output folder for the build. Once I finished building, I would run chromium from the new executable but the build version remains that of the previous one instead of the newer one.
-
Sparhawk about 9 yearsThis is how the Arch package builds the development version from source. Seems pretty complicated, but it might be useful.
-
Benjamin B. almost 9 yearsAre you building Chromium from source because you want to add/fix something or just for fun? If there's another reason, it might be handy to post that as a question as well, since there might be a way around compiling from source.. It's a total pain to compile such a huge project ;)
-
Jeremy Rea almost 9 yearsIt was 3 years ago so the issue isn't relevant to me anymore. At the time though it was just for fun to learn a thing or two.
-
Kusalananda almost 8 yearsYou're probably just executing an already installed version of Chrome that is found in your
$PATH
. Give the absolute path to the compiled version that you made and/or add the directory where it lives to yourPATH
.
-