OLD | NEW |
(Empty) | |
| 1 # |
| 2 # Copyright 2014 The LibYuv Project Authors. All rights reserved. |
| 3 # |
| 4 # Use of this source code is governed by a BSD-style license |
| 5 # that can be found in the LICENSE file in the root of the source |
| 6 # tree. An additional intellectual property rights grant can be found |
| 7 # in the file PATENTS. All contributing project authors may |
| 8 # be found in the AUTHORS file in the root of the source tree. |
| 9 |
| 10 # This is a copy of WebRTC's BUILD.gn. |
| 11 |
| 12 if (is_win) { |
| 13 gflags_gen_arch_root = "gen/win" |
| 14 } else { |
| 15 gflags_gen_arch_root = "gen/posix" |
| 16 } |
| 17 |
| 18 config("gflags_config") { |
| 19 include_dirs = [ |
| 20 "$gflags_gen_arch_root/include", # For configured files. |
| 21 "src", # For everything else. |
| 22 ] |
| 23 |
| 24 defines = [ |
| 25 # These macros exist so flags and symbols are properly exported when |
| 26 # building DLLs. Since we don't build DLLs, we need to disable them. |
| 27 "GFLAGS_DLL_DECL=", |
| 28 "GFLAGS_DLL_DECLARE_FLAG=", |
| 29 "GFLAGS_DLL_DEFINE_FLAG=", |
| 30 ] |
| 31 } |
| 32 |
| 33 source_set("gflags") { |
| 34 sources = [ |
| 35 "src/gflags.cc", |
| 36 "src/gflags_completions.cc", |
| 37 "src/gflags_reporting.cc", |
| 38 ] |
| 39 if (is_win) { |
| 40 sources += [ "src/windows/port.cc" ] |
| 41 |
| 42 cflags = [ |
| 43 "/wd4005", # WIN32_LEAN_AND_MEAN. |
| 44 "/wd4267", # Conversion from size_t to "type". |
| 45 ] |
| 46 } |
| 47 |
| 48 include_dirs = [ |
| 49 "$gflags_gen_arch_root/include/private", # For config.h |
| 50 ] |
| 51 |
| 52 public_configs = [ ":gflags_config" ] |
| 53 |
| 54 configs -= [ "//build/config/compiler:chromium_code" ] |
| 55 configs += [ "//build/config/compiler:no_chromium_code" ] |
| 56 |
| 57 if (is_clang) { |
| 58 # TODO(andrew): Look into fixing this warning upstream: |
| 59 # http://code.google.com/p/webrtc/issues/detail?id=760 |
| 60 configs -= [ "//build/config/clang:extra_warnings" ] |
| 61 } |
| 62 } |
OLD | NEW |