skia2/gn/BUILD.gn

458 lines
12 KiB
Plaintext
Raw Normal View History

# Copyright 2016 Google Inc.
#
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
declare_args() {
extra_asmflags = []
extra_cflags = []
extra_cflags_c = []
extra_cflags_cc = []
extra_ldflags = []
malloc = ""
}
if (is_ios) {
if (is_tvos) {
sdk = "appletvos"
if (target_cpu == "x86" || target_cpu == "x64") {
sdk = "appletvsimulator"
}
} else {
sdk = "iphoneos"
if (target_cpu == "x86" || target_cpu == "x64") {
sdk = "iphonesimulator"
}
}
ios_sysroot = exec_script("find_ios_sysroot.py", [ sdk ], "trim string")
}
config("default") {
asmflags = []
cflags = []
cflags_c = []
cflags_cc = []
defines = []
ldflags = []
libs = []
if (is_win) {
cflags += [
"/FS", # Preserve previous PDB behavior.
"/bigobj", # Some of our files are bigger than the regular limits.
"/WX", # Treat warnings as errors.
"/utf-8", # Set Source and Executable character sets to UTF-8.
]
if (is_clang) {
cflags += [ "-fms-compatibility-version=19" ] # 2015
}
defines += [
"_CRT_SECURE_NO_WARNINGS", # Disables warnings about sscanf().
"_HAS_EXCEPTIONS=0", # Disables exceptions in MSVC STL.
"WIN32_LEAN_AND_MEAN",
"NOMINMAX",
]
_include_dirs = [
#2017
"$windk/VC/Tools/MSVC/14.10.25017/include",
#2015
"$windk/VC/include",
# For local builds.
# 2017
"$windk/../../../Windows Kits/10/Include/10.0.14393.0/shared",
"$windk/../../../Windows Kits/10/Include/10.0.14393.0/ucrt",
"$windk/../../../Windows Kits/10/Include/10.0.14393.0/um",
"$windk/../../../Windows Kits/10/Include/10.0.14393.0/winrt",
# 2015
"$windk/../Windows Kits/8.1/Include/shared",
"$windk/../Windows Kits/10/Include/10.0.10150.0/ucrt",
"$windk/../Windows Kits/8.1/Include/um",
"$windk/../Windows Kits/8.1/Include/winrt",
# For builds using win_toolchain asset.
"$windk/win_sdk/Include/10.0.14393.0/shared",
"$windk/win_sdk/Include/10.0.14393.0/ucrt",
"$windk/win_sdk/Include/10.0.14393.0/um",
"$windk/win_sdk/Include/10.0.14393.0/winrt",
]
if (is_clang) {
foreach(dir, _include_dirs) {
cflags += [
"-imsvc",
dir,
]
}
} else {
include_dirs = _include_dirs
}
lib_dirs = [
# For local builds.
# 2017
"$windk/../../../Windows Kits/10/Lib/10.0.14393.0/ucrt/$target_cpu",
"$windk/../../../Windows Kits/10/Lib/10.0.14393.0/um/$target_cpu",
#2015
"$windk/../Windows Kits/10/Lib/10.0.10150.0/ucrt/$target_cpu",
"$windk/../Windows Kits/8.1/Lib/winv6.3/um/$target_cpu",
# For builds using win_toolchain asset.
"$windk/win_sdk/Lib/10.0.14393.0/ucrt/$target_cpu",
"$windk/win_sdk/Lib/10.0.14393.0/um/$target_cpu",
]
#2017
lib_dirs += [ "$windk/VC/Tools/MSVC/14.10.25017/lib/$target_cpu" ]
#2015
if (target_cpu == "x86") {
lib_dirs += [ "$windk/VC/lib" ]
} else {
lib_dirs += [ "$windk/VC/lib/amd64" ]
}
} else {
cflags += [
"-fstrict-aliasing",
"-fPIC",
"-Werror",
]
cflags_cc += [ "-std=c++11" ]
# The main idea is to slim the exported API, but these flags also improve link time on Mac.
# These would make stack traces worse on Linux, so we don't just set them willy-nilly.
if (is_component_build || is_ios || is_mac) {
cflags += [ "-fvisibility=hidden" ]
cflags_cc += [ "-fvisibility-inlines-hidden" ]
}
}
if (current_cpu == "arm") {
cflags += [
"-march=armv7-a",
"-mfpu=neon",
"-mthumb",
]
} else if (current_cpu == "mipsel") {
cflags += [ "-march=mips32r2" ]
} else if (current_cpu == "mips64el") {
asmflags += [ "-integrated-as" ]
cflags += [ "-integrated-as" ]
} else if (current_cpu == "x86" && !is_win) {
asmflags += [ "-m32" ]
cflags += [
"-m32",
"-msse2",
"-mfpmath=sse",
]
ldflags += [ "-m32" ]
}
if (malloc != "" && !is_win) {
cflags += [
"-fno-builtin-malloc",
"-fno-builtin-calloc",
"-fno-builtin-realloc",
"-fno-builtin-free",
]
libs += [ malloc ]
}
if (is_android) {
asmflags += [ "--target=$ndk_target" ]
cflags += [
"--sysroot=$ndk/sysroot",
"-isystem$ndk/sysroot/usr/include/$ndk_target",
"-D__ANDROID_API__=$ndk_api",
"--target=$ndk_target",
]
cflags_cc += [
"-isystem$ndk/sources/android/support/include",
"-isystem$ndk/sources/cxx-stl/gnu-libstdc++/4.9/include",
"-isystem$ndk/sources/cxx-stl/gnu-libstdc++/4.9/libs/$ndk_stdlib/include",
]
ldflags += [
"--sysroot=$ndk/platforms/$ndk_platform",
"--target=$ndk_target",
"-B$ndk/toolchains/$ndk_gccdir-4.9/prebuilt/$ndk_host/$ndk_target/bin",
]
lib_dirs = [
"$ndk/sources/cxx-stl/gnu-libstdc++/4.9/libs/$ndk_stdlib",
"$ndk/toolchains/$ndk_gccdir-4.9/prebuilt/$ndk_host/lib/gcc/$ndk_target/4.9.x",
]
Update to Android NDK r13. The libc++ include paths have changed very slightly. I've left GN compatible with both older r12 NDKs and the new r13 to smooth the transition. The libc++ in r13 depends on long-double math.h functions (cosl, atanl, etc.) only available in Android API v21 (Lollipop) and up. That's what the 64-bit bots were already on, so we just pull the 32-bit bots up to the same target. Conveniently, the oldest bots we have (N7 and N10) are on Lollipop. The r13 MIPS64 sysroots are a little weird... /usr/include and /usr/lib64 but no /usr/lib. That'd be fine---we only want 64-bit builds---but Clang searches for /usr/lib64 via its path to /usr/lib, and without at least an empty /usr/lib, it can't find /usr/lib64. So you'll see a special mips64el section in the GN config where we do this all manually (other platforms pick this all up correctly from --sysroot). I've chosen to do this rather than fix it up in the asset create.py scripts so that we stay compatible with vanilla NDKs, which is convenient for developers. CQ_INCLUDE_TRYBOTS=master.client.skia.compile:Build-Mac-Clang-arm64-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-arm-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-arm-Release-GN_Android-Trybot,Build-Ubuntu-Clang-arm64-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-arm64-Debug-GN_Android_FrameworkDefs-Trybot,Build-Ubuntu-Clang-arm64-Debug-GN_Android_Vulkan-Trybot,Build-Ubuntu-Clang-arm64-Release-GN_Android-Trybot,Build-Ubuntu-Clang-mips64el-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-mips64el-Release-GN_Android-Trybot,Build-Ubuntu-Clang-mips64el-Release-GN_Android-Trybot,Build-Ubuntu-Clang-mipsel-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-mipsel-Release-GN_Android-Trybot,Build-Ubuntu-Clang-x64-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-x64-Release-GN_Android-Trybot,Build-Ubuntu-Clang-x86-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-x86-Release-GN_Android-Trybot BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=3180 Change-Id: I6f3b5d9411ded0ee49c1099490f41fa86a8736f8 Reviewed-on: https://skia-review.googlesource.com/3180 Reviewed-by: Eric Boren <borenet@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
2016-10-11 15:21:36 +00:00
if (current_cpu == "mips64el") {
# The r15b NDK deployed on our bots fails to find /usr/lib64 in the
# MIPS64 sysroots, so we must point Clang at /usr/lib64 manually.
Update to Android NDK r13. The libc++ include paths have changed very slightly. I've left GN compatible with both older r12 NDKs and the new r13 to smooth the transition. The libc++ in r13 depends on long-double math.h functions (cosl, atanl, etc.) only available in Android API v21 (Lollipop) and up. That's what the 64-bit bots were already on, so we just pull the 32-bit bots up to the same target. Conveniently, the oldest bots we have (N7 and N10) are on Lollipop. The r13 MIPS64 sysroots are a little weird... /usr/include and /usr/lib64 but no /usr/lib. That'd be fine---we only want 64-bit builds---but Clang searches for /usr/lib64 via its path to /usr/lib, and without at least an empty /usr/lib, it can't find /usr/lib64. So you'll see a special mips64el section in the GN config where we do this all manually (other platforms pick this all up correctly from --sysroot). I've chosen to do this rather than fix it up in the asset create.py scripts so that we stay compatible with vanilla NDKs, which is convenient for developers. CQ_INCLUDE_TRYBOTS=master.client.skia.compile:Build-Mac-Clang-arm64-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-arm-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-arm-Release-GN_Android-Trybot,Build-Ubuntu-Clang-arm64-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-arm64-Debug-GN_Android_FrameworkDefs-Trybot,Build-Ubuntu-Clang-arm64-Debug-GN_Android_Vulkan-Trybot,Build-Ubuntu-Clang-arm64-Release-GN_Android-Trybot,Build-Ubuntu-Clang-mips64el-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-mips64el-Release-GN_Android-Trybot,Build-Ubuntu-Clang-mips64el-Release-GN_Android-Trybot,Build-Ubuntu-Clang-mipsel-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-mipsel-Release-GN_Android-Trybot,Build-Ubuntu-Clang-x64-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-x64-Release-GN_Android-Trybot,Build-Ubuntu-Clang-x86-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-x86-Release-GN_Android-Trybot BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=3180 Change-Id: I6f3b5d9411ded0ee49c1099490f41fa86a8736f8 Reviewed-on: https://skia-review.googlesource.com/3180 Reviewed-by: Eric Boren <borenet@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
2016-10-11 15:21:36 +00:00
lib_dirs += [ "$ndk/platforms/$ndk_platform/usr/lib64" ]
ldflags += [ "-B$ndk/platforms/$ndk_platform/usr/lib64" ]
Update to Android NDK r13. The libc++ include paths have changed very slightly. I've left GN compatible with both older r12 NDKs and the new r13 to smooth the transition. The libc++ in r13 depends on long-double math.h functions (cosl, atanl, etc.) only available in Android API v21 (Lollipop) and up. That's what the 64-bit bots were already on, so we just pull the 32-bit bots up to the same target. Conveniently, the oldest bots we have (N7 and N10) are on Lollipop. The r13 MIPS64 sysroots are a little weird... /usr/include and /usr/lib64 but no /usr/lib. That'd be fine---we only want 64-bit builds---but Clang searches for /usr/lib64 via its path to /usr/lib, and without at least an empty /usr/lib, it can't find /usr/lib64. So you'll see a special mips64el section in the GN config where we do this all manually (other platforms pick this all up correctly from --sysroot). I've chosen to do this rather than fix it up in the asset create.py scripts so that we stay compatible with vanilla NDKs, which is convenient for developers. CQ_INCLUDE_TRYBOTS=master.client.skia.compile:Build-Mac-Clang-arm64-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-arm-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-arm-Release-GN_Android-Trybot,Build-Ubuntu-Clang-arm64-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-arm64-Debug-GN_Android_FrameworkDefs-Trybot,Build-Ubuntu-Clang-arm64-Debug-GN_Android_Vulkan-Trybot,Build-Ubuntu-Clang-arm64-Release-GN_Android-Trybot,Build-Ubuntu-Clang-mips64el-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-mips64el-Release-GN_Android-Trybot,Build-Ubuntu-Clang-mips64el-Release-GN_Android-Trybot,Build-Ubuntu-Clang-mipsel-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-mipsel-Release-GN_Android-Trybot,Build-Ubuntu-Clang-x64-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-x64-Release-GN_Android-Trybot,Build-Ubuntu-Clang-x86-Debug-GN_Android-Trybot,Build-Ubuntu-Clang-x86-Release-GN_Android-Trybot BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=3180 Change-Id: I6f3b5d9411ded0ee49c1099490f41fa86a8736f8 Reviewed-on: https://skia-review.googlesource.com/3180 Reviewed-by: Eric Boren <borenet@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
2016-10-11 15:21:36 +00:00
}
libs += [ "gnustl_static" ]
}
if (is_ios) {
_target = target_cpu
if (target_cpu == "arm") {
_target = "armv7"
} else if (target_cpu == "x86") {
_target = "i386"
} else if (target_cpu == "x64") {
_target = "x86_64"
}
asmflags += [
"-isysroot",
ios_sysroot,
"-arch",
_target,
]
cflags += [
"-isysroot",
ios_sysroot,
"-arch",
_target,
]
cflags_cc += [ "-stdlib=libc++" ]
ldflags += [
"-isysroot",
ios_sysroot,
"-arch",
_target,
"-stdlib=libc++",
]
libs += [ "objc" ]
}
if (is_linux) {
libs += [ "pthread" ]
}
if (sanitize != "") {
# You can either pass the sanitizers directly, e.g. "address,undefined",
# or pass one of the couple common aliases used by the bots.
sanitizers = sanitize
if (sanitize == "ASAN") {
sanitizers = "address,bool,function,integer-divide-by-zero,nonnull-attribute,null,object-size,return,returns-nonnull-attribute,shift,signed-integer-overflow,unreachable,vla-bound,vptr"
} else if (sanitize == "TSAN") {
sanitizers = "thread"
} else if (sanitize == "MSAN") {
sanitizers = "memory"
}
cflags += [
"-fsanitize=$sanitizers",
"-fno-sanitize-recover=$sanitizers",
"-fsanitize-blacklist=" + rebase_path("../tools/xsan.blacklist"),
]
ldflags += [ "-fsanitize=$sanitizers" ]
if (sanitizers == "memory") {
cflags += [ "-fsanitize-memory-track-origins" ]
cflags_cc += [ "-stdlib=libc++" ]
ldflags += [ "-stdlib=libc++" ]
}
}
}
config("no_exceptions") {
# Exceptions are disabled by default on Windows. (Use /EHsc to enable them.)
if (!is_win) {
cflags_cc = [ "-fno-exceptions" ]
}
}
config("warnings") {
cflags = []
cflags_cc = []
cflags_objc = []
cflags_objcc = []
if (is_win) {
cflags += [
"/W3", # Turn on lots of warnings.
# Disable a bunch of warnings:
"/wd4244", # conversion from 'float' to 'int', possible loss of data
"/wd4267", # conversion from 'size_t' to 'int', possible loss of data
"/wd4800", # forcing value to bool 'true' or 'false' (performance warning)
# Probably only triggers when /EHsc is enabled.
"/wd4291", # no matching operator delete found;
# memory will not be freed if initialization throws an exception
]
} else {
cflags += [
"-Wall",
"-Wextra",
"-Winit-self",
"-Wpointer-arith",
"-Wsign-compare",
"-Wvla",
"-Wno-deprecated-declarations",
"-Wno-maybe-uninitialized",
]
cflags_cc += [ "-Wnon-virtual-dtor" ]
if (is_clang) {
cflags += [
"-Weverything",
"-Wno-unknown-warning-option", # Let older Clangs ignore newer Clangs' warnings.
]
if ((target_cpu == "x86" && is_android) ||
(target_cpu == "arm" && is_ios)) {
# Clang seems to think new/malloc will only be 4-byte aligned on x86 Android and 32-bit iOS.
# We're pretty sure it's actually 8-byte alignment.
cflags += [ "-Wno-over-aligned" ]
}
cflags += [
"-Wno-cast-align",
"-Wno-conditional-uninitialized",
"-Wno-conversion",
"-Wno-disabled-macro-expansion",
"-Wno-documentation",
"-Wno-documentation-unknown-command",
"-Wno-double-promotion",
"-Wno-exit-time-destructors", # TODO: OK outside libskia
"-Wno-float-conversion",
"-Wno-float-equal",
"-Wno-format-nonliteral",
"-Wno-global-constructors", # TODO: OK outside libskia
"-Wno-gnu-zero-variadic-macro-arguments",
"-Wno-missing-prototypes",
"-Wno-missing-variable-declarations",
"-Wno-pedantic",
"-Wno-reserved-id-macro",
"-Wno-shadow",
"-Wno-shift-sign-overflow",
"-Wno-sign-conversion",
"-Wno-signed-enum-bitfield",
"-Wno-switch-enum",
"-Wno-undef",
"-Wno-unreachable-code",
"-Wno-unreachable-code-break",
"-Wno-unreachable-code-return",
"-Wno-unused-macros",
"-Wno-unused-member-function",
]
cflags_cc += [
"-Wno-abstract-vbase-init",
"-Wno-weak-vtables",
]
# We are unlikely to want to fix these.
cflags += [
"-Wno-covered-switch-default",
"-Wno-deprecated",
"-Wno-implicit-fallthrough",
"-Wno-missing-noreturn",
"-Wno-old-style-cast",
"-Wno-padded",
]
cflags_cc += [
"-Wno-c++98-compat",
"-Wno-c++98-compat-pedantic",
"-Wno-undefined-func-template",
]
cflags_objc += [
"-Wno-direct-ivar-access",
"-Wno-objc-interface-ivars",
]
cflags_objcc += [
"-Wno-direct-ivar-access",
"-Wno-objcc-interface-ivars",
]
}
}
}
config("warnings_except_public_headers") {
if (!is_win) {
cflags = [ "-Wno-unused-parameter" ]
}
}
config("extra_flags") {
asmflags = extra_asmflags
cflags = extra_cflags
cflags_c = extra_cflags_c
cflags_cc = extra_cflags_cc
ldflags = extra_ldflags
}
config("debug_symbols") {
# It's annoying to wait for full debug symbols to push over
# to Android devices. -gline-tables-only is a lot slimmer.
if (is_android) {
ok, backtrace support on Android This adds a fallback backtracer for use on Android where <execinfo.h> ins't present, instead using <unwind.h> to unwind and <dlfcn.h> to lookup function names and addresses. lockf() wasn't available until NDK API 24, so I've just no-op'd file locking on older targets. I tried switching from lockf() to flock(), but flock() didn't see to _do_ anything, neither on Android nor on my Mac laptop. I think I should be able to use the lower-level fcntl() APIs to restore file locking uniformly in a follow-up. The upshot is until then, we'll have interlaced logs and stack traces on Android devices unless you set ndk_api=24 in GN. We need to add a couple build flags to make backtraces useful: * -funwind-tables makes the call to _Unwind_Backtrace() actually traverse the call stack. This is a small extra binary size cost. * -rdynamic makes symbols linked into the main executable visible to dladdr(). We do this on Linux already for the same reason. Here's an example where I made aaxfermodes call SK_ABORT(): 650 ok, 1 crashed caught signal SIGABRT while running 'aaxfermodes' 0x76ed936288 [unknown]+308 0x76eec014e0 [unknown]+510811706592 0x76ed367b2c tgkill+8 0x76ed364f50 pthread_kill+68 0x76ed31ff5c raise+28 0x76ed318814 abort+56 0x76edebd070 sk_out_of_memory()+12 0x76ed99f664 AAXfermodesGM::draw_pass(SkCanvas*, AAXfermodesGM::DrawingPass)+96 0x76ed99f4e4 AAXfermodesGM::onDraw(SkCanvas*)+36 0x76ed9e8550 skiagm::GM::drawContent(SkCanvas*)+224 0x76ed9e82ac skiagm::GM::draw(SkCanvas*)+288 0x76ed93b10c GMStream::GMSrc::draw(SkCanvas*)+96 0x76ed937b08 SWDst::draw(Src*)+284 0x76ed936ca0 [unknown]+112 0x76ed939b4c ForkEngine::spawn(std::function<Status ()>)+88 0x76ed934d00 main+2200 0x76ed316598 __libc_init+92 0x76ed93434c [unknown]+510791992140 Change-Id: Ica4849d99a3b97f48d778f4c15a7fa36275b8133 Reviewed-on: https://skia-review.googlesource.com/40802 Reviewed-by: Herb Derby <herb@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-08-30 14:23:01 +00:00
cflags = [
"-gline-tables-only",
"-funwind-tables", # Helps make in-process backtraces fuller.
]
} else if (is_win) {
cflags = [ "/Zi" ]
ldflags = [ "/DEBUG" ]
} else {
cflags = [ "-g" ]
}
}
config("no_rtti") {
if (sanitize != "ASAN") { # -fsanitize=vptr requires RTTI
if (is_win) {
cflags_cc = [ "/GR-" ]
} else {
cflags_cc = [ "-fno-rtti" ]
}
}
}
config("release") {
if (is_win) {
cflags = [
"/O2",
"/Zc:inline",
"/GS-",
]
ldflags = [
"/OPT:ICF",
"/OPT:REF",
]
} else {
cflags = [
"-O3",
"-fdata-sections",
"-ffunction-sections",
]
if (is_mac || is_ios) {
ldflags = [ "-dead_strip" ]
} else {
ldflags = [ "-Wl,--gc-sections" ]
}
}
defines = [ "NDEBUG" ]
}
config("executable") {
if (is_android) {
ok, backtrace support on Android This adds a fallback backtracer for use on Android where <execinfo.h> ins't present, instead using <unwind.h> to unwind and <dlfcn.h> to lookup function names and addresses. lockf() wasn't available until NDK API 24, so I've just no-op'd file locking on older targets. I tried switching from lockf() to flock(), but flock() didn't see to _do_ anything, neither on Android nor on my Mac laptop. I think I should be able to use the lower-level fcntl() APIs to restore file locking uniformly in a follow-up. The upshot is until then, we'll have interlaced logs and stack traces on Android devices unless you set ndk_api=24 in GN. We need to add a couple build flags to make backtraces useful: * -funwind-tables makes the call to _Unwind_Backtrace() actually traverse the call stack. This is a small extra binary size cost. * -rdynamic makes symbols linked into the main executable visible to dladdr(). We do this on Linux already for the same reason. Here's an example where I made aaxfermodes call SK_ABORT(): 650 ok, 1 crashed caught signal SIGABRT while running 'aaxfermodes' 0x76ed936288 [unknown]+308 0x76eec014e0 [unknown]+510811706592 0x76ed367b2c tgkill+8 0x76ed364f50 pthread_kill+68 0x76ed31ff5c raise+28 0x76ed318814 abort+56 0x76edebd070 sk_out_of_memory()+12 0x76ed99f664 AAXfermodesGM::draw_pass(SkCanvas*, AAXfermodesGM::DrawingPass)+96 0x76ed99f4e4 AAXfermodesGM::onDraw(SkCanvas*)+36 0x76ed9e8550 skiagm::GM::drawContent(SkCanvas*)+224 0x76ed9e82ac skiagm::GM::draw(SkCanvas*)+288 0x76ed93b10c GMStream::GMSrc::draw(SkCanvas*)+96 0x76ed937b08 SWDst::draw(Src*)+284 0x76ed936ca0 [unknown]+112 0x76ed939b4c ForkEngine::spawn(std::function<Status ()>)+88 0x76ed934d00 main+2200 0x76ed316598 __libc_init+92 0x76ed93434c [unknown]+510791992140 Change-Id: Ica4849d99a3b97f48d778f4c15a7fa36275b8133 Reviewed-on: https://skia-review.googlesource.com/40802 Reviewed-by: Herb Derby <herb@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-08-30 14:23:01 +00:00
ldflags = [
"-pie",
"-rdynamic",
]
} else if (is_mac) {
ldflags = [ "-Wl,-rpath,@loader_path/." ]
} else if (is_linux) {
ldflags = [
"-rdynamic",
"-Wl,-rpath,\$ORIGIN",
]
} else if (is_win) {
ldflags = [
"/SUBSYSTEM:CONSOLE", # Quiet "no subsystem specified; CONSOLE assumed".
"/INCREMENTAL:NO", # Quiet warnings about failing to incrementally link by never trying to.
]
}
}