Skip to content

Commit

Permalink
[vm] Fix ASAN build.
Browse files Browse the repository at this point in the history
Change-Id: I6e5c40412493933a0a21f4df880f367840fd68cf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/115710
Reviewed-by: Samir Jindel <sjindel@google.com>
  • Loading branch information
sjindel-google committed Sep 5, 2019
1 parent 8ee3f31 commit 75374b8
Showing 1 changed file with 13 additions and 9 deletions.
22 changes: 13 additions & 9 deletions build/config/linux/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,19 @@
import("//build/config/sysroot.gni")

config("sdk") {
# Don't allow visible symbols from libc++ to be re-exported.
ldflags = [
"-nodefaultlibs",
"-lc++",
"-lc",
"-lm",
"-lclang_rt.builtins",
"-Wl,--exclude-libs=libc++.a",
]
ldflags = []

if (!is_asan) {
# Don't allow visible symbols from libc++ to be re-exported.
ldflags = [
"-nodefaultlibs",
"-lc++",
"-lc",
"-lm",
"-lclang_rt.builtins",
"-Wl,--exclude-libs=libc++.a",
]
}

if (sysroot != "") {
cflags = [ "--sysroot=" + sysroot ]
Expand Down

0 comments on commit 75374b8

Please sign in to comment.