OLD | NEW |
1 # Copyright 2016 Google Inc. | 1 # Copyright 2016 Google Inc. |
2 # | 2 # |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 declare_args() { | 6 import("third_party.gni") |
7 } | |
8 | 7 |
9 # Most third_party code should disable warnings: if we don't maintain the code,
warnings are noise. | 8 # Most third_party code should disable warnings: if we don't maintain the code,
warnings are noise. |
10 config("no_warnings") { | 9 config("no_warnings") { |
11 cflags = [ "-w" ] | 10 cflags = [ "-w" ] |
12 } | 11 } |
13 third_party_configs = [ ":no_warnings" ] | 12 third_party_configs = [ ":no_warnings" ] |
14 | 13 |
15 # Chrome's GN environment sets up a bunch of default configs we don't need/want
here. | |
16 unwanted_configs = [ | |
17 "//build/config/clang:extra_warnings", | |
18 "//build/config/clang:find_bad_constructs", | |
19 "//build/config/compiler:chromium_code", | |
20 "//build/config:feature_flags", | |
21 ] | |
22 | |
23 config("zlib_public") { | |
24 include_dirs = [ "externals/zlib" ] | |
25 } | |
26 source_set("zlib") { | |
27 public_configs = [ ":zlib_public" ] | |
28 configs += third_party_configs | |
29 configs -= unwanted_configs | |
30 | |
31 sources = [ | |
32 "externals/zlib/adler32.c", | |
33 "externals/zlib/compress.c", | |
34 "externals/zlib/crc32.c", | |
35 "externals/zlib/deflate.c", | |
36 "externals/zlib/gzclose.c", | |
37 "externals/zlib/gzlib.c", | |
38 "externals/zlib/gzread.c", | |
39 "externals/zlib/gzwrite.c", | |
40 "externals/zlib/infback.c", | |
41 "externals/zlib/inffast.c", | |
42 "externals/zlib/inflate.c", | |
43 "externals/zlib/inftrees.c", | |
44 "externals/zlib/simd_stub.c", | |
45 "externals/zlib/trees.c", | |
46 "externals/zlib/uncompr.c", | |
47 "externals/zlib/zutil.c", | |
48 ] | |
49 } | |
50 | |
51 config("libpng_public") { | 14 config("libpng_public") { |
52 include_dirs = [ "libpng" ] | 15 include_dirs = [ "libpng" ] |
53 } | 16 } |
54 source_set("libpng") { | 17 source_set("libpng") { |
55 public_configs = [ ":libpng_public" ] | 18 public_configs = [ ":libpng_public" ] |
56 configs += third_party_configs | 19 configs += third_party_configs |
57 configs -= unwanted_configs | 20 configs -= unwanted_configs |
58 | 21 |
59 deps = [ | 22 deps = [ |
60 ":zlib", | 23 ":zlib", |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
140 group("freetype2") { | 103 group("freetype2") { |
141 public_configs = [ ":system_freetype2" ] | 104 public_configs = [ ":system_freetype2" ] |
142 } | 105 } |
143 | 106 |
144 config("system_fontconfig") { | 107 config("system_fontconfig") { |
145 libs = [ "fontconfig" ] | 108 libs = [ "fontconfig" ] |
146 } | 109 } |
147 group("fontconfig") { | 110 group("fontconfig") { |
148 public_configs = [ ":system_fontconfig" ] | 111 public_configs = [ ":system_fontconfig" ] |
149 } | 112 } |
OLD | NEW |