• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1//
2// Copyright (C) 2018 The Android Open Source Project
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8//      http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15
16package {
17    // See: http://go/android-license-faq
18    // A large-scale-change added 'default_applicable_licenses' to import
19    // all of the 'license_kinds' from "system_netd_license"
20    // to get the below license kinds:
21    //   SPDX-license-identifier-Apache-2.0
22    default_applicable_licenses: ["system_netd_license"],
23}
24
25cc_test_library {
26    name: "libnetd_test_tun_interface",
27    defaults: ["netd_defaults"],
28    srcs: [
29        "tun_interface.cpp"
30    ],
31    export_include_dirs: ["."],
32    shared_libs: [
33        "libbase",
34        "libnetutils",
35    ],
36}
37
38cc_test_library {
39    name: "libnetd_test_unsol_service",
40    defaults: [
41        "netd_aidl_interface_lateststable_cpp_shared",
42        "netd_defaults",
43    ],
44    srcs: [
45        "TestUnsolService.cpp"
46    ],
47    include_dirs: [
48        "system/netd/include",
49    ],
50    shared_libs: [
51        "libbase",
52        "libbinder",
53        "libcutils",
54        "liblog",
55        "libnetutils",
56        "libsysutils",
57        "libutils",
58    ],
59}
60
61cc_test_library {
62    name: "libnetd_test_utils",
63    srcs: [
64        "test_utils.cpp"
65    ],
66    export_include_dirs: ["."],
67    shared_libs: [
68        "libbase",
69    ],
70}
71
72cc_test {
73    name: "netd_integration_test",
74    test_suites: [
75        "device-tests",
76        "vts"
77    ],
78    require_root: true,
79    defaults: [
80        "netd_aidl_interface_lateststable_cpp_static",
81        "netd_defaults",
82    ],
83    tidy: false,  // cuts test build time by almost 1 minute
84    srcs: [
85        ":netd_integration_test_shared",
86        "binder_test.cpp",
87        "bpf_base_test.cpp",
88        "kernel_test.cpp",
89        "netd_client_test.cpp",
90        "netd_test.cpp",
91    ],
92    include_dirs: ["system/netd/server"],
93    header_libs: ["bpf_connectivity_headers"],
94    shared_libs: [
95        "libbase",
96        "libbinder",
97        "libcrypto",
98        "libcutils",
99        "liblog",
100        "libnetd_client",
101        "libnetutils",
102        "libprocessgroup",
103        "libssl",
104        "libsysutils",
105        "libutils",
106        "libvintf",
107    ],
108    static_libs: [
109        "libcap",
110        "libnetd_test_tun_interface",
111        "libnetd_test_unsol_service",
112        "libnetd_test_utils",
113        "libnetdutils",
114        "libnettestutils",
115        "libtcutils",
116        "mdns_aidl_interface-V1-cpp",
117        "netd_event_listener_interface-V1-cpp",
118        "oemnetd_aidl_interface-cpp",
119    ],
120    compile_multilib: "both",
121    multilib: {
122        lib32: {
123            suffix: "32",
124        },
125        lib64: {
126            suffix: "64",
127        },
128    },
129    sanitize: {
130        address: false,
131        recover: [ "all" ],
132    },
133}
134