Chromium Code Reviews| Index: breakpad/BUILD.gn |
| diff --git a/breakpad/BUILD.gn b/breakpad/BUILD.gn |
| index 6b1e7795fc9546ce651826042f2cd5d260fa382e..97472124845b419c1f596b40d9c36850f115cb5d 100644 |
| --- a/breakpad/BUILD.gn |
| +++ b/breakpad/BUILD.gn |
| @@ -324,61 +324,64 @@ if (is_linux || is_android) { |
| } |
| } |
| -if (is_linux && current_toolchain == host_toolchain) { |
| - executable("dump_syms") { |
| - sources = [ |
| - "src/common/dwarf/bytereader.cc", |
| - "src/common/dwarf_cfi_to_module.cc", |
| - "src/common/dwarf_cfi_to_module.h", |
| - "src/common/dwarf_cu_to_module.cc", |
| - "src/common/dwarf_cu_to_module.h", |
| - "src/common/dwarf/dwarf2diehandler.cc", |
| - "src/common/dwarf/dwarf2reader.cc", |
| - "src/common/dwarf_line_to_module.cc", |
| - "src/common/dwarf_line_to_module.h", |
| - "src/common/language.cc", |
| - "src/common/language.h", |
| - "src/common/linux/crc32.cc", |
| - "src/common/linux/crc32.h", |
| - "src/common/linux/dump_symbols.cc", |
| - "src/common/linux/dump_symbols.h", |
| - "src/common/linux/elf_symbols_to_module.cc", |
| - "src/common/linux/elf_symbols_to_module.h", |
| - "src/common/linux/elfutils.cc", |
| - "src/common/linux/elfutils.h", |
| - "src/common/linux/file_id.cc", |
| - "src/common/linux/file_id.h", |
| - "src/common/linux/linux_libc_support.cc", |
| - "src/common/linux/linux_libc_support.h", |
| - "src/common/linux/memory_mapped_file.cc", |
| - "src/common/linux/memory_mapped_file.h", |
| - "src/common/linux/guid_creator.h", |
| - "src/common/module.cc", |
| - "src/common/module.h", |
| - "src/common/stabs_reader.cc", |
| - "src/common/stabs_reader.h", |
| - "src/common/stabs_to_module.cc", |
| - "src/common/stabs_to_module.h", |
| - "src/tools/linux/dump_syms/dump_syms.cc", |
| - ] |
| - |
| - # There are some warnings in this code. |
| - configs -= [ "//build/config/compiler:chromium_code" ] |
| - configs += [ "//build/config/compiler:no_chromium_code" ] |
| - |
| - # dwarf2reader.cc uses dynamic_cast. Because we don't typically |
| - # don't support RTTI, we enable it for this single target. Since |
| - # dump_syms doesn't share any object files with anything else, |
| - # this doesn't end up polluting Chrome itself. |
| - configs -= [ "//build/config/compiler:no_rtti" ] |
| - configs += [ "//build/config/compiler:rtti" ] |
| - |
| - # Breakpad rev 583 introduced this flag. |
| - # Using this define, stabs_reader.h will include a.out.h to |
| - # build on Linux. |
| - defines = [ "HAVE_A_OUT_H" ] |
| - |
| - include_dirs = [ "src" ] |
| +if (is_linux) { |
| + if (current_toolchain == host_toolchain) { |
|
jamesr
2014/08/12 18:28:15
sorry i'm think - how does this do something diffe
|
| + # dump_syms is a host tool, so only compile it for the host system. |
| + executable("dump_syms") { |
| + sources = [ |
| + "src/common/dwarf/bytereader.cc", |
| + "src/common/dwarf_cfi_to_module.cc", |
| + "src/common/dwarf_cfi_to_module.h", |
| + "src/common/dwarf_cu_to_module.cc", |
| + "src/common/dwarf_cu_to_module.h", |
| + "src/common/dwarf/dwarf2diehandler.cc", |
| + "src/common/dwarf/dwarf2reader.cc", |
| + "src/common/dwarf_line_to_module.cc", |
| + "src/common/dwarf_line_to_module.h", |
| + "src/common/language.cc", |
| + "src/common/language.h", |
| + "src/common/linux/crc32.cc", |
| + "src/common/linux/crc32.h", |
| + "src/common/linux/dump_symbols.cc", |
| + "src/common/linux/dump_symbols.h", |
| + "src/common/linux/elf_symbols_to_module.cc", |
| + "src/common/linux/elf_symbols_to_module.h", |
| + "src/common/linux/elfutils.cc", |
| + "src/common/linux/elfutils.h", |
| + "src/common/linux/file_id.cc", |
| + "src/common/linux/file_id.h", |
| + "src/common/linux/linux_libc_support.cc", |
| + "src/common/linux/linux_libc_support.h", |
| + "src/common/linux/memory_mapped_file.cc", |
| + "src/common/linux/memory_mapped_file.h", |
| + "src/common/linux/guid_creator.h", |
| + "src/common/module.cc", |
| + "src/common/module.h", |
| + "src/common/stabs_reader.cc", |
| + "src/common/stabs_reader.h", |
| + "src/common/stabs_to_module.cc", |
| + "src/common/stabs_to_module.h", |
| + "src/tools/linux/dump_syms/dump_syms.cc", |
| + ] |
| + |
| + # There are some warnings in this code. |
| + configs -= [ "//build/config/compiler:chromium_code" ] |
| + configs += [ "//build/config/compiler:no_chromium_code" ] |
| + |
| + # dwarf2reader.cc uses dynamic_cast. Because we don't typically |
| + # don't support RTTI, we enable it for this single target. Since |
| + # dump_syms doesn't share any object files with anything else, |
| + # this doesn't end up polluting Chrome itself. |
| + configs -= [ "//build/config/compiler:no_rtti" ] |
| + configs += [ "//build/config/compiler:rtti" ] |
| + |
| + # Breakpad rev 583 introduced this flag. |
| + # Using this define, stabs_reader.h will include a.out.h to |
| + # build on Linux. |
| + defines = [ "HAVE_A_OUT_H" ] |
| + |
| + include_dirs = [ "src" ] |
| + } |
| } |
| static_library("client") { |