| Index: build/config/compiler/BUILD.gn
|
| diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
|
| index 255a2cd0a9750e5c3b514cb59f6383d577fb2857..f6947e4a45e1e0e127e8e87887a58a04386d2fc5 100644
|
| --- a/build/config/compiler/BUILD.gn
|
| +++ b/build/config/compiler/BUILD.gn
|
| @@ -948,9 +948,15 @@ if (is_win) {
|
| # Specifically tell the linker to perform optimizations.
|
| # See http://lwn.net/Articles/192624/ .
|
| "-Wl,-O1",
|
| - "-Wl,--as-needed",
|
| "-Wl,--gc-sections",
|
| ]
|
| +
|
| + if (!using_sanitizer) {
|
| + # Functions interposed by the sanitizers can make ld think
|
| + # that some libraries aren't needed when they actually are,
|
| + # http://crbug.com/234010. As workaround, disable --as-needed.
|
| + common_optimize_on_ldflags += [ "-Wl,--as-needed" ]
|
| + }
|
| }
|
| }
|
|
|
|
|