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

Side by Side Diff: third_party/libc++/BUILD.gn

Issue 2977093002: Move libcpp_is_static into //build/config/c++ [buildtools changes] (Closed)
Patch Set: Created 3 years, 5 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2015 The Chromium Authors. All rights reserved. 1 # Copyright 2015 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import("//build/config/c++/c++.gni")
5 import("//build/config/sanitizers/sanitizers.gni") 6 import("//build/config/sanitizers/sanitizers.gni")
6 import("//build/toolchain/toolchain.gni") 7 import("//build/toolchain/toolchain.gni")
7 8
8 # Sanitizer builds need to override operator new, operator delete, and
9 # some exception handling symbols, so libc++ must be a shared library
10 # to prevent duplicate symbol errors when linking.
11 libcpp_is_static = !is_component_build && !using_sanitizer
12
13 # Used by libc++ and libc++abi. 9 # Used by libc++ and libc++abi.
14 config("config") { 10 config("config") {
15 defines = [ "LIBCXX_BUILDING_LIBCXXABI" ] 11 defines = [ "LIBCXX_BUILDING_LIBCXXABI" ]
16 if (libcpp_is_static) { 12 if (libcpp_is_static) {
17 # Don't leak any symbols on a static build. 13 # Don't leak any symbols on a static build.
18 defines += [ 14 defines += [
19 "_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS", 15 "_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS",
20 "_LIBCXXABI_DISABLE_VISIBILITY_ANNOTATIONS", 16 "_LIBCXXABI_DISABLE_VISIBILITY_ANNOTATIONS",
21 17
22 # This resets the visibility to default only for the various 18 # This resets the visibility to default only for the various
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 "//build/config/compiler:no_chromium_code", 85 "//build/config/compiler:no_chromium_code",
90 "//build/config/compiler:rtti", 86 "//build/config/compiler:rtti",
91 "//build/config/sanitizers:sanitizer_options_link_helper", 87 "//build/config/sanitizers:sanitizer_options_link_helper",
92 ] 88 ]
93 defines = [ "_LIBCPP_BUILDING_LIBRARY" ] 89 defines = [ "_LIBCPP_BUILDING_LIBRARY" ]
94 90
95 deps = [ 91 deps = [
96 "//buildtools/third_party/libc++abi", 92 "//buildtools/third_party/libc++abi",
97 ] 93 ]
98 } 94 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698