1// Copyright (C) 2011 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
15// Make the HAL library
16// ============================================================
17package {
18    // See: http://go/android-license-faq
19    default_applicable_licenses: [
20        "Android-Apache-2.0",
21    ],
22}
23
24soong_config_module_type_import {
25    from: "frameworks/opt/net/wifi/libwifi_hal/Android.bp",
26    module_types: ["wifi_cc_defaults"],
27}
28
29wifi_cc_defaults {
30    name: "libwifi-hal-bcm-defaults",
31    soong_config_variables: {
32        google_wifi_config_lib: {
33            shared_libs: ["google_wifi_firmware_config_version_c_wrapper"],
34            cflags: [
35                "-DGOOGLE_WIFI_FW_CONFIG_VERSION_C_WRAPPER",
36                // only for pixel feature
37                "-DRING_DUMP",
38            ],
39        },
40    },
41}
42
43cc_library_static {
44    name: "libwifi-hal-bcm",
45
46    cflags: [
47        "-Wall",
48        "-Werror",
49        "-Wno-format",
50        "-Wno-reorder",
51        "-Wno-unused-function",
52        "-Wno-unused-parameter",
53        "-Wno-unused-private-field",
54        "-Wno-unused-variable",
55        "-Wno-unused-parameter",
56    ],
57
58    defaults: [
59        "libwifi-hal-bcm-defaults",
60    ],
61
62    header_libs: [
63        "libnetlink_iface_headers",
64        "wifi_legacy_headers",
65    ],
66
67    shared_libs: [
68        // added for libwifi-hal-bcm
69        "libcrypto",
70        // shared_libs in libwifi-hal
71        "liblog",
72        "libnl",
73        "libutils",
74    ],
75
76    srcs: [
77        "wifi_hal.cpp",
78        "rtt.cpp",
79        "common.cpp",
80        "cpp_bindings.cpp",
81        "gscan.cpp",
82        "nan.cpp",
83        "link_layer_stats.cpp",
84        "wifi_logger.cpp",
85        "wifi_offload.cpp",
86        "twt.cpp",
87        "scan.cpp",
88    ],
89
90    proprietary: true,
91}
92