-
Notifications
You must be signed in to change notification settings - Fork 121
Building the ExoBrowser
The ExoBrowser is based on both Chromium (Content API) and Node.JS, two very active opensource projects. To be able to properly integrate these two projects, we have to apply a few modifications to each. To keep track of these modifications, we use a patch for the chromium
repository (as we only alter a few files) and a specific forked branch for node
.
Steps 1 and 2 are identical for all systems (Linux, Mac and Windows).
The source code of the ExoBrowser being valid only in the context of chromium
and node
, for any given version of the ExoBrowser we need to be able to know which commit to checkout in both repositories. The DEPS Directory exists for this reason. It maintains a set of revision and patches needed to build the current state of the source code:
chromium.RELEASE # the release branch used for `chromium`
chromium.patch # the patch to apply on `chromium
node_exo_browser.HEAD # the commit to use for the exo_browser branch of `node`
node.HEAD # used internally to know on which commit of `node` the `exo_browser` branch is based
Whenever working with the ExoBrowser, you must have Chromium and NodeJS checked out at the revisions specified in the DEPS directory of the ExoBrowser revision you're working on.
We need the Chromium depot_tools
to work with Chromium source code. Please refer to Chromium: Install depot_tools for more information.
- create a project directory, say
mkdir exo_browser && cd exo_browser
- git clone
https://chromium.googlesource.com/chromium/tools/depot_tools.git
- add
depot_tools
to yourPATH
:export PATH="$PATH":`pwd`/depot_tools
- you can update your
.bashrc
file to avoid adding it to thePATH
each time you need it - If you haven't already: install git, subversion and git-svn (
apt-get install git subversion git-svn
).
Please refer to Chromium: Get The Code for more information about checking out Chromium. We're using the git workflow. node.patch
mkdir chromium && cd chromium
-
gclient config http://src.chromium.org/chrome/releases/XX.X.XXXX.XX/
(replace with value ofDEPS
, currently 32.0.1700.68) -
svn ls https://src.chromium.org/chrome
to accept permanently the certificate from googlecode -
gclient sync
(this may take some time. SVN read-access not needed)
A new src/
directory should have been checked out in your chromium
directory. In the following src/
refers to the chromium/src
directory.
- clone
[email protected]:breach/exo_browser.git
insrc/
- in
src/third_party/
rungit clone -b exo_browser https://github.com/breach/node.git
- in
src/third_party/node/
,git reset --hard `cat ../../exo_browser/DEPS/node_exo_browser.HEAD`
You must be at the correct revision indicated in exo_browser/DEPS/chromium.HEAD
for this to work.
- in
src/
,patch -p0 -i exo_browser/DEPS/chromium.patch
Your tree is now ready for work!
We rely on Chromium cross-platform build tools (more specifically, gyp
). The following is for Linux. For more information on OS specific information see:
- Chromium: Linux Build Instructions
- Chromium: Mac Build Instructions
- Chromium: Windows Build Instructions
Additionally we use ninja
as our build system. See Chromium: Ninja Build for more information.
- run
src/build/install-build-deps.sh
- add
export GYP_GENERATORS='ninja'
to yourPATH
- you can update your
.bashrc
file to avoid adding it to thePATH
each time you build
- in
src/
, runbuild/gyp_chromium exo_browser/exo_browser.gyp
- in
src/third_party/node
, run./configure --ninja
or./configure --ninja --dest-cpu ia32
on OSX
This generates all the files needed to build the ExoBrowser (ninja, Makefile, XCode, ...) depending on your platform and configuration.
- in
src/
, runninja -C out/Debug exo_browser -j8
(this may take some time) - cd into
src/out/Debug/shell
andnpm install
- You should now be able to run the exo_browser binary in
src/out/Debug
Much more information can be found within the project Chromium itself. One goal is to make this very simple, so please open up an issue if you run into problems.
If you get the message Running without the SUID sandbox!
try exo_browser --no-sandbox or install the sandbox.