Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 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 | |
| 3 # found in the LICENSE file. | |
| 4 | |
| 5 shared_library("libc++") { | |
| 6 sources = [ | |
| 7 "trunk/src/algorithm.cpp", | |
| 8 "trunk/src/bind.cpp", | |
| 9 "trunk/src/chrono.cpp", | |
| 10 "trunk/src/condition_variable.cpp", | |
| 11 "trunk/src/debug.cpp", | |
| 12 "trunk/src/exception.cpp", | |
| 13 "trunk/src/future.cpp", | |
| 14 "trunk/src/hash.cpp", | |
| 15 "trunk/src/ios.cpp", | |
| 16 "trunk/src/iostream.cpp", | |
| 17 "trunk/src/locale.cpp", | |
| 18 "trunk/src/memory.cpp", | |
| 19 "trunk/src/mutex.cpp", | |
| 20 "trunk/src/new.cpp", | |
| 21 "trunk/src/optional.cpp", | |
| 22 "trunk/src/random.cpp", | |
| 23 "trunk/src/regex.cpp", | |
| 24 "trunk/src/shared_mutex.cpp", | |
| 25 "trunk/src/stdexcept.cpp", | |
| 26 "trunk/src/string.cpp", | |
| 27 "trunk/src/strstream.cpp", | |
| 28 "trunk/src/system_error.cpp", | |
| 29 "trunk/src/thread.cpp", | |
| 30 "trunk/src/typeinfo.cpp", | |
| 31 "trunk/src/utility.cpp", | |
| 32 "trunk/src/valarray.cpp", | |
| 33 ] | |
| 34 configs -= [ | |
| 35 "//build/config/compiler:chromium_code", | |
| 36 "//build/config/compiler:no_rtti", | |
| 37 "//build/config/gcc:no_exceptions", | |
| 38 "//build/config/gcc:symbol_visibility_hidden", | |
| 39 ] | |
| 40 configs += [ | |
| 41 "//build/config/compiler:no_chromium_code", | |
| 42 "//build/config/compiler:rtti", | |
| 43 "//build/config/sanitizers:sanitizer_options_link_helper", | |
| 44 "//buildtools/third_party/libc++abi:config", | |
| 45 ] | |
| 46 | |
| 47 # libc++abi is linked statically into libc++.so. This allows us to get both | |
| 48 # libc++ and libc++abi by passing '-stdlib=libc++'. If libc++abi was a | |
| 49 # separate DSO, we'd have to link against it explicitly. | |
| 50 deps = [ | |
| 51 "//buildtools/third_party/libc++abi", | |
| 52 ] | |
| 53 } | |
| 54 | |
| 55 group("libcxx_proxy") { | |
| 56 deps = [ | |
| 57 ":libc++", | |
| 58 ] | |
| 59 public_configs = [ ":link_helper" ] | |
| 60 } | |
| 61 | |
| 62 config("link_helper") { | |
| 63 ldflags = [ | |
| 64 "-stdlib=libc++", | |
| 65 | |
| 66 # Normally the generator takes care of RPATH. Our case is special because | |
| 67 # the generator is unaware of the libc++.so dependency. Note that setting | |
| 68 # RPATH here is a potential security issue. See the following for another | |
| 69 # example of this issue: https://code.google.com/p/gyp/issues/detail?id=315 | |
| 70 "-Wl,-R,\$ORIGIN/", | |
|
earthdok
2015/05/26 16:18:46
$ORIGIN/lib?
Sam McNally
2015/05/27 00:12:09
GN puts shared libraries in out/Foo instead of out
| |
| 71 ] | |
| 72 lib_dirs = [ root_build_dir ] | |
| 73 } | |
| OLD | NEW |