Index: build/config/compiler/BUILD.gn |
diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn |
index 1c50195f048741211470d94b49c45a08202d0cee..a2c518fdb0f125ee6057343f177c3adbd951e239 100644 |
--- a/build/config/compiler/BUILD.gn |
+++ b/build/config/compiler/BUILD.gn |
@@ -470,6 +470,8 @@ config("compiler") { |
# TODO(pcc): Make this conditional on is_official_build rather than on gn |
# flags for specific features. |
if (!is_debug && (allow_posix_link_time_opt || is_cfi) && !is_nacl) { |
+ assert(use_lld || is_chromeos, "gold plugin only supported with ChromeOS") |
+ |
if (use_thin_lto) { |
cflags += [ "-flto=thin" ] |
ldflags += [ "-flto=thin" ] |