Chromium Code Reviews| Index: docs/clang.md |
| diff --git a/docs/clang.md b/docs/clang.md |
| index 5b5b43f7ada6624b746e7b4b8a1fc7d747ebe57d..7b43eaf644838846d84ac55652d1164d84f80a01 100644 |
| --- a/docs/clang.md |
| +++ b/docs/clang.md |
| @@ -14,12 +14,16 @@ See |
| ## Build instructions |
| -Get clang (happens automatically during `gclient runhooks` on Mac and Linux): |
| +### Ninja |
|
Nico
2016/04/13 00:50:14
(we can probably drop this heading too; all platfo
|
| + |
| +Regenerate the ninja build files with Clang enabled. On Linux or Mac, Clang is |
| +enabled by default. |
| + |
| +If you use gyp: `GYP_DEFINES=clang=1 build/gyp_chromium` |
| - tools/clang/scripts/update.py |
| +If you use gn, run `gn args` and add `is_clang = true` to your args.gn file. |
| -(Only needs to be run once per checkout, and clang will be automatically updated |
| -by `gclient runhooks`.) |
| +Build: `ninja -C out/Debug chrome` |
| ### Reverting to gcc on linux |
| @@ -29,16 +33,6 @@ don't want to build with clang: |
| GYP_DEFINES=clang=0 build/gyp_chromium |
| -### Ninja |
| - |
| -Regenerate the build files (`clang=1` is on by default on Mac and Linux): |
| - |
| -If you use gyp: `GYP_DEFINES=clang=1 build/gyp_chromium` |
| - |
| -If you use gn, run `gn args` and add `is_clang = true` to your args.gn file. |
| - |
| -Build: `ninja -C out/Debug chrome` |
| - |
| ## Mailing List |
| http://groups.google.com/a/chromium.org/group/clang/topics |
| @@ -79,8 +73,6 @@ See [clang_static_analyzer.md](clang_static_analyzer.md). |
| ## Windows |
| -**Experimental!** |
| - |
| clang can be used as compiler on Windows. Clang uses Visual Studio's linker and |
| SDK, so you still need to have Visual Studio installed. |
| @@ -99,7 +91,6 @@ ninja -C out\Debug chrome |
|
Nico
2016/04/13 00:50:14
mention somewhere here that update.py only needs t
Reid Kleckner
2016/04/13 18:11:47
What about simplifying this to `gclient runhooks`
Nico
2016/04/13 18:13:58
It's not enough in a gn build, since runhooks call
|
| Current brokenness: |
| -* Goma doesn't work. |
| * Debug info is very limited. |
| * To get colored diagnostics, you need to be running |
| [ansicon](https://github.com/adoxa/ansicon/releases). |
| @@ -131,3 +122,16 @@ If your clang revision is very different from the one currently used in chromium |
| * Check `tools/clang/scripts/update.py` to find chromium's clang revision |
| * You might have to tweak warning flags. Or you could set `werror=` in the |
| line above to disable warnings as errors (but this only works on Linux). |
| + |
| +## Using LLD |
| + |
| +**Experimental!** |
| + |
| +LLD is a relatively new linker from LLVM. The current focus is on Windows and |
| +Linux support, where it can link Chrome approximately twice as fast as gold and |
| +MSVC's link.exe as of this writing. LLD does not yet support generating PDB |
| +files, which makes it hard to debug Chrome while using LLD. |
| + |
| +If you use gyp, you can enable it with `GYP_DEFINES=lld=1`. If you use gn, set |
| +`use_lld = true` in args.gn. Currently this configuration is only supported on |
| +Windows. |