1//
2// Copyright (C) 2019 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//
16
17cc_defaults {
18    name: "android.hardware.automotive.can@defaults",
19    cpp_std: "experimental",
20    cflags: [
21        "-Wall",
22        "-Wextra",
23        "-Werror",
24        "-DANDROID_BASE_UNIQUE_FD_DISABLE_IMPLICIT_CONVERSION=1",
25    ],
26    shared_libs: [
27        "libbase",
28        "libutils",
29    ],
30}
31
32cc_binary {
33    name: "[email protected]",
34    init_rc: ["[email protected]"],
35    defaults: ["android.hardware.automotive.can@defaults"],
36    vendor: true,
37    relative_install_path: "hw",
38    srcs: [
39        "CanBus.cpp",
40        "CanBusNative.cpp",
41        "CanBusVirtual.cpp",
42        "CanBusSlcan.cpp",
43        "CanController.cpp",
44        "CanSocket.cpp",
45        "CloseHandle.cpp",
46        "service.cpp",
47    ],
48    shared_libs: [
49        "[email protected]",
50        "libhidlbase",
51    ],
52    static_libs: [
53        "android.hardware.automotive.can@libnetdevice",
54        "android.hardware.automotive@libc++fs",
55    ],
56}
57