Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(103)

Unified Diff: build/config/BUILDCONFIG.gn

Issue 2031903002: Update GN files w/ changes needed to make sanitizers work. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rework to add comments, drop the symbolized config Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: build/config/BUILDCONFIG.gn
diff --git a/build/config/BUILDCONFIG.gn b/build/config/BUILDCONFIG.gn
index 86fceae3a3b4f7ce5fcbc8551387a359919faf82..84109073f8c0c8f105c54e6bd737b7ed71cf723b 100644
--- a/build/config/BUILDCONFIG.gn
+++ b/build/config/BUILDCONFIG.gn
@@ -511,13 +511,22 @@ if (is_win) {
}
# Executable defaults.
-_executable_configs = _native_compiler_configs + [
- "//build/config:default_libs",
- "//build/config:executable_config",
- ]
+_executable_configs =
+ _native_compiler_configs + [
+ "//build/config:default_libs",
+ "//build/config:executable_config",
+
+ # If we're using the prebuilt instrumented libraries with the
+ # sanitizers, we need to add ldflags to every binary to make sure
+ # they are picked up. We can't check for using_sanitizer in BUILDCONFIG,
+ # so we add the config unconditionally and have it be empty when not
+ # using the libraries.
+ "//third_party/instrumented_libraries:prebuilt_instrumented_libraries_ldflags",
+ ]
if (is_win) {
_executable_configs += _windows_linker_configs
}
+
set_defaults("executable") {
configs = _executable_configs
}
@@ -529,10 +538,12 @@ set_defaults("static_library") {
# Shared library and loadable module defaults (also for components in component
# mode).
-_shared_library_configs = _native_compiler_configs + [
- "//build/config:default_libs",
- "//build/config:shared_library_config",
- ]
+_shared_library_configs =
+ _native_compiler_configs + [
+ "//build/config:default_libs",
+ "//build/config:shared_library_config",
+ "//third_party/instrumented_libraries:prebuilt_link_helper",
+ ]
if (is_win) {
_shared_library_configs += _windows_linker_configs
} else if (is_android) {
« build/common.gypi ('K') | « build/common.gypi ('k') | build/config/sanitizers/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698