| OLD | NEW |
| 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2013 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/android/config.gni") | 5 import("//build/config/android/config.gni") |
| 6 if (cpu_arch == "arm") { | 6 if (cpu_arch == "arm") { |
| 7 import("//build/config/arm.gni") | 7 import("//build/config/arm.gni") |
| 8 } | 8 } |
| 9 | 9 |
| 10 # compiler --------------------------------------------------------------------- | 10 # compiler --------------------------------------------------------------------- |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 | 73 |
| 74 cflags += common_mac_flags | 74 cflags += common_mac_flags |
| 75 | 75 |
| 76 # Without this, the constructors and destructors of a C++ object inside | 76 # Without this, the constructors and destructors of a C++ object inside |
| 77 # an Objective C struct won't be called, which is very bad. | 77 # an Objective C struct won't be called, which is very bad. |
| 78 cflags_objcc = [ "-fobjc-call-cxx-cdtors", ] | 78 cflags_objcc = [ "-fobjc-call-cxx-cdtors", ] |
| 79 | 79 |
| 80 cflags_c += [ "-std=c99" ] | 80 cflags_c += [ "-std=c99" ] |
| 81 cflags_cc += [ "-std=gnu++11" ] | 81 cflags_cc += [ "-std=gnu++11" ] |
| 82 | 82 |
| 83 ldflags += common_mac_flags + [ | 83 ldflags += common_mac_flags |
| 84 "-L.", | |
| 85 | |
| 86 # TODO(brettW) I don't understand these options. | |
| 87 "-Wl,-rpath,@loader_path/.", | |
| 88 "-Wl,-rpath,@loader_path/../../..", | |
| 89 ] | |
| 90 } else if (is_posix) { | 84 } else if (is_posix) { |
| 91 # Non-Mac Posix compiler flags setup. | 85 # Non-Mac Posix compiler flags setup. |
| 92 # ----------------------------------- | 86 # ----------------------------------- |
| 93 | 87 |
| 94 # CPU architecture. We may or may not be doing a cross compile now, so for | 88 # CPU architecture. We may or may not be doing a cross compile now, so for |
| 95 # simplicity we always explicitly set the architecture. | 89 # simplicity we always explicitly set the architecture. |
| 96 if (cpu_arch == "x64") { | 90 if (cpu_arch == "x64") { |
| 97 cflags += [ "-m64" ] | 91 cflags += [ "-m64" ] |
| 98 ldflags += [ "-m64" ] | 92 ldflags += [ "-m64" ] |
| 99 } else if (cpu_arch == "x86") { | 93 } else if (cpu_arch == "x86") { |
| (...skipping 578 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 678 cflags = [ "-g1" ] | 672 cflags = [ "-g1" ] |
| 679 } | 673 } |
| 680 } | 674 } |
| 681 | 675 |
| 682 config("no_symbols") { | 676 config("no_symbols") { |
| 683 if (!is_win) { | 677 if (!is_win) { |
| 684 cflags = [ "-g0" ] | 678 cflags = [ "-g0" ] |
| 685 } | 679 } |
| 686 } | 680 } |
| 687 | 681 |
| OLD | NEW |