xref: /aosp_15_r20/external/openscreen/third_party/zlib/BUILD.gn (revision 3f982cf4871df8771c9d4abe6e9a6f8d829b2736)
1# Copyright 2019 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.
4
5config("zlib_config") {
6  include_dirs = [ "src" ]
7}
8
9config("zlib_internal_config") {
10  defines = [ "ZLIB_IMPLEMENTATION" ]
11  cflags = [ "-w" ]  # Disable all warnings.
12}
13
14static_library("zlib") {
15  # Don't stomp on "libzlib"
16  output_name = "chrome_zlib"
17
18  sources = [
19    "src/adler32.c",
20    "src/compress.c",
21    "src/crc32.c",
22    "src/crc32.h",
23    "src/deflate.c",
24    "src/deflate.h",
25    "src/gzclose.c",
26    "src/gzguts.h",
27    "src/gzlib.c",
28    "src/gzread.c",
29    "src/gzwrite.c",
30    "src/infback.c",
31    "src/inffast.c",
32    "src/inffast.h",
33    "src/inffixed.h",
34    "src/inflate.c",
35    "src/inflate.h",
36    "src/inftrees.c",
37    "src/inftrees.h",
38    "src/trees.c",
39    "src/trees.h",
40    "src/uncompr.c",
41    "src/zconf.h",
42    "src/zlib.h",
43    "src/zutil.c",
44    "src/zutil.h",
45  ]
46
47  defines = []
48  deps = []
49
50  include_dirs = [ "." ]
51  configs += [ ":zlib_internal_config" ]
52
53  public_configs = [ ":zlib_config" ]
54
55  allow_circular_includes_from = deps
56}
57