ChildAccountService[Java] delegates everything to native side.
[chromium-blink-merge.git] / third_party / snappy / BUILD.gn
blob7eabb7b19e9bff0edc44f35c9edbb833b6ffffd6
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
3 # found in the LICENSE file.
5 config("snappy_config") {
6   include_dirs = [ "src" ]
8   # These OS-specific generated headers were made by running the configure
9   # script offline.
10   if (is_win) {
11     include_dirs += [ "win32" ]
12   } else if (is_mac) {
13     include_dirs += [ "mac" ]
14   } else {
15     include_dirs += [ "linux" ]
16   }
19 config("snappy_warnings") {
20   if (is_clang) {
21     # ComputeTable is unused,
22     # https://code.google.com/p/snappy/issues/detail?id=96
23     cflags = [ "-Wno-unused-function" ]
24   }
27 static_library("snappy") {
28   sources = [
29     "src/snappy-internal.h",
30     "src/snappy-sinksource.cc",
31     "src/snappy-sinksource.h",
32     "src/snappy-stubs-internal.cc",
33     "src/snappy-stubs-internal.h",
34     "src/snappy.cc",
35     "src/snappy.h",
36   ]
38   configs -= [ "//build/config/compiler:chromium_code" ]
39   configs += [
40     "//build/config/compiler:no_chromium_code",
42     # Must be after no_chromium_code for warning flags to be ordered correctly.
43     ":snappy_warnings",
44   ]
45   public_configs = [ ":snappy_config" ]
47   if (is_win) {
48     cflags = [ "/wd4018" ]  # Signed/unsigned mismatch in comparison.
49   }
51   if (is_clang) {
52     # snappy-stubs-internal.h unapologetically has: using namespace std
53     # https://code.google.com/p/snappy/issues/detail?id=70
54     configs -= [ "//build/config/clang:extra_warnings" ]
55   }