| 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 # HOW TO WRITE CONDITIONALS IN THIS FILE | 5 # HOW TO WRITE CONDITIONALS IN THIS FILE |
| 6 # ====================================== | 6 # ====================================== |
| 7 # | 7 # |
| 8 # In many other places, one would write a conditional that expresses all the | 8 # In many other places, one would write a conditional that expresses all the |
| 9 # cases when a source file is used or unused, and then either add or subtract | 9 # cases when a source file is used or unused, and then either add or subtract |
| 10 # it from the sources list in that case | 10 # it from the sources list in that case |
| 11 # | 11 # |
| 12 # Since base includes so many low-level things that vary widely and | 12 # Since base includes so many low-level things that vary widely and |
| 13 # unpredictably for the various build types, we prefer a slightly different | 13 # unpredictably for the various build types, we prefer a slightly different |
| 14 # style. Instead, there are big per-platform blocks of inclusions and | 14 # style. Instead, there are big per-platform blocks of inclusions and |
| 15 # exclusions. If a given file has an inclusion or exclusion rule that applies | 15 # exclusions. If a given file has an inclusion or exclusion rule that applies |
| 16 # for multiple conditions, perfer to duplicate it in both lists. This makes it | 16 # for multiple conditions, perfer to duplicate it in both lists. This makes it |
| 17 # a bit easier to see which files apply in which cases rather than having a | 17 # a bit easier to see which files apply in which cases rather than having a |
| 18 # huge sequence of random-looking conditionals. | 18 # huge sequence of random-looking conditionals. |
| 19 | 19 |
| 20 import("//build/buildflag_header.gni") | 20 import("//build/buildflag_header.gni") |
| 21 import("//build/config/allocator.gni") |
| 21 import("//build/config/compiler/compiler.gni") | 22 import("//build/config/compiler/compiler.gni") |
| 22 import("//build/config/nacl/config.gni") | 23 import("//build/config/nacl/config.gni") |
| 23 import("//build/config/sysroot.gni") | 24 import("//build/config/sysroot.gni") |
| 24 import("//build/config/ui.gni") | 25 import("//build/config/ui.gni") |
| 25 import("//build/nocompile.gni") | 26 import("//build/nocompile.gni") |
| 26 import("//testing/test.gni") | 27 import("//testing/test.gni") |
| 27 | 28 |
| 28 declare_args() { | 29 declare_args() { |
| 29 # Override this value to give a specific build date. | 30 # Override this value to give a specific build date. |
| 30 # See //base/build_time.cc for more details. | 31 # See //base/build_time.cc for more details. |
| (...skipping 932 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 963 | 964 |
| 964 configs += [ | 965 configs += [ |
| 965 ":base_flags", | 966 ":base_flags", |
| 966 ":base_implementation", | 967 ":base_implementation", |
| 967 "//base/allocator:allocator_shim_define", # for allocator_check.cc. | 968 "//base/allocator:allocator_shim_define", # for allocator_check.cc. |
| 968 "//build/config:precompiled_headers", | 969 "//build/config:precompiled_headers", |
| 969 ] | 970 ] |
| 970 | 971 |
| 971 deps = [ | 972 deps = [ |
| 972 "//base/allocator", | 973 "//base/allocator", |
| 974 "//base/allocator:features", |
| 973 "//base/third_party/dynamic_annotations", | 975 "//base/third_party/dynamic_annotations", |
| 974 "//third_party/modp_b64", | 976 "//third_party/modp_b64", |
| 975 ] | 977 ] |
| 976 | 978 |
| 977 public_deps = [ | 979 public_deps = [ |
| 978 ":base_paths", | 980 ":base_paths", |
| 979 ":base_static", | 981 ":base_static", |
| 980 ":build_date", | 982 ":build_date", |
| 981 ":debugging_flags", | 983 ":debugging_flags", |
| 982 ] | 984 ] |
| 983 | 985 |
| 984 # Needed for <atomic> if using newer C++ library than sysroot | 986 # Needed for <atomic> if using newer C++ library than sysroot |
| 985 if (!use_sysroot && (is_android || is_linux)) { | 987 if (!use_sysroot && (is_android || is_linux)) { |
| 986 libs = [ "atomic" ] | 988 libs = [ "atomic" ] |
| 987 } | 989 } |
| 988 | 990 |
| 991 if (use_experimental_allocator_shim) { |
| 992 # The allocator shim is part of the base API. This is to allow clients of |
| 993 # base should to install hooks into the allocator path. |
| 994 public_deps += [ "//base/allocator:unified_allocator_shim" ] |
| 995 } |
| 996 |
| 989 # Allow more direct string conversions on platforms with native utf8 | 997 # Allow more direct string conversions on platforms with native utf8 |
| 990 # strings | 998 # strings |
| 991 if (is_mac || is_ios || is_chromeos) { | 999 if (is_mac || is_ios || is_chromeos) { |
| 992 defines += [ "SYSTEM_NATIVE_UTF8" ] | 1000 defines += [ "SYSTEM_NATIVE_UTF8" ] |
| 993 } | 1001 } |
| 994 | 1002 |
| 995 # Android. | 1003 # Android. |
| 996 if (is_android) { | 1004 if (is_android) { |
| 997 sources -= [ | 1005 sources -= [ |
| 998 "debug/stack_trace_posix.cc", | 1006 "debug/stack_trace_posix.cc", |
| (...skipping 881 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1880 "trace_event/trace_event_android_unittest.cc", | 1888 "trace_event/trace_event_android_unittest.cc", |
| 1881 ] | 1889 ] |
| 1882 set_sources_assignment_filter(sources_assignment_filter) | 1890 set_sources_assignment_filter(sources_assignment_filter) |
| 1883 } | 1891 } |
| 1884 | 1892 |
| 1885 if (is_win && target_cpu == "x64") { | 1893 if (is_win && target_cpu == "x64") { |
| 1886 sources += [ "profiler/win32_stack_frame_unwinder_unittest.cc" ] | 1894 sources += [ "profiler/win32_stack_frame_unwinder_unittest.cc" ] |
| 1887 deps += [ ":base_profiler_test_support_library" ] | 1895 deps += [ ":base_profiler_test_support_library" ] |
| 1888 } | 1896 } |
| 1889 | 1897 |
| 1898 if (use_experimental_allocator_shim) { |
| 1899 sources += [ "allocator/allocator_shim_unittest.cc" ] |
| 1900 } |
| 1901 |
| 1890 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations. | 1902 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations. |
| 1891 configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] | 1903 configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] |
| 1892 | 1904 |
| 1893 # Symbols for crashes when running tests on swarming. | 1905 # Symbols for crashes when running tests on swarming. |
| 1894 if (symbol_level > 0) { | 1906 if (symbol_level > 0) { |
| 1895 if (is_win) { | 1907 if (is_win) { |
| 1896 data += [ "$root_out_dir/base_unittests.exe.pdb" ] | 1908 data += [ "$root_out_dir/base_unittests.exe.pdb" ] |
| 1897 } else if (is_mac) { | 1909 } else if (is_mac) { |
| 1898 data += [ "$root_out_dir/base_unittests.dSYM/" ] | 1910 data += [ "$root_out_dir/base_unittests.dSYM/" ] |
| 1899 } | 1911 } |
| (...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2088 | 2100 |
| 2089 # GYP: //base.gyp:base_java_unittest_support | 2101 # GYP: //base.gyp:base_java_unittest_support |
| 2090 android_library("base_java_unittest_support") { | 2102 android_library("base_java_unittest_support") { |
| 2091 deps = [ | 2103 deps = [ |
| 2092 ":base_java", | 2104 ":base_java", |
| 2093 ] | 2105 ] |
| 2094 java_files = | 2106 java_files = |
| 2095 [ "test/android/java/src/org/chromium/base/ContentUriTestUtils.java" ] | 2107 [ "test/android/java/src/org/chromium/base/ContentUriTestUtils.java" ] |
| 2096 } | 2108 } |
| 2097 } | 2109 } |
| OLD | NEW |