xref: /aosp_15_r20/bootable/libbootloader/gbl/libfdt/BUILD.libfdt_c.bazel (revision 5225e6b173e52d2efc6bcf950c27374fd72adabc)
1# Copyright (C) 2023 The Android Open Source Project
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7#     http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14
15package(
16    default_visibility = ["//visibility:public"],
17)
18
19exports_files(glob(["**/*"]))
20
21cc_library(
22    name = "libfdt_c",
23    srcs = [
24        "acpi.c",
25        "fdt.c",
26        "fdt_addresses.c",
27        "fdt_check.c",
28        "fdt_empty_tree.c",
29        "fdt_overlay.c",
30        "fdt_ro.c",
31        "fdt_rw.c",
32        "fdt_strerror.c",
33        "fdt_sw.c",
34        "fdt_wip.c",
35    ],
36    hdrs = [
37        "fdt.h",
38        "libacpi.h",
39        "libfdt.h",
40        "libfdt_env.h",
41        "libfdt_internal.h",
42    ],
43    copts = [
44        "-Wno-int-conversion",
45        "-Wno-implicit-function-declaration",
46        "-Wno-pointer-integer-compare",
47    ],
48    includes = ["."],
49    deps = ["@gbl//libc:headers"],
50)
51