blob: 649e53a8aaeb58c3f9a211a5b19d1d28c49d6a2e [file] [log] [blame]
Yifan Hong85dd3ad2017-01-25 14:20:34 -08001// Copyright (C) 2016 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
Bob Badour3306e492021-02-25 15:35:37 -080015package {
16 // See: http://go/android-license-faq
17 // A large-scale-change added 'default_applicable_licenses' to import
18 // all of the 'license_kinds' from "frameworks_native_license"
19 // to get the below license kinds:
20 // SPDX-license-identifier-Apache-2.0
21 default_applicable_licenses: ["frameworks_native_license"],
22}
23
Steven Morelandb8745de2019-06-25 11:40:37 -070024cc_library_static {
Yifan Hong9881df92017-05-10 14:33:05 -070025 name: "liblshal",
Yifan Hong85dd3ad2017-01-25 14:20:34 -080026 shared_libs: [
Yifan Hongf4bee842017-02-01 15:54:01 -080027 "libbase",
Devin Moorec03e3aa2020-12-11 15:11:17 -080028 "libbinderdebug",
Andreas Huber28d35912017-03-24 13:14:11 -070029 "libcutils",
Yifan Hong85dd3ad2017-01-25 14:20:34 -080030 "libutils",
31 "libhidlbase",
Yifan Hongfee209d2017-09-14 18:23:38 -070032 "libhidl-gen-hash",
Yifan Hong4b865492017-02-28 19:38:24 -080033 "libhidl-gen-utils",
34 "libvintf",
Yifan Hong85dd3ad2017-01-25 14:20:34 -080035 ],
Yifan Hongf31aa052018-02-02 15:17:51 -080036 static_libs: [
37 "libprocpartition",
38 ],
Yifan Hong85dd3ad2017-01-25 14:20:34 -080039 srcs: [
Yifan Hong48dc9f82017-05-09 19:33:08 -070040 "DebugCommand.cpp",
Yifan Honga8bedc62017-09-08 18:00:31 -070041 "HelpCommand.cpp",
Andreas Huber28d35912017-03-24 13:14:11 -070042 "Lshal.cpp",
Yifan Hong443df792017-05-09 18:49:45 -070043 "ListCommand.cpp",
44 "PipeRelay.cpp",
Yifan Hongd4a77e82017-09-06 19:40:24 -070045 "TableEntry.cpp",
Yifan Hong1bc1e9f2017-08-29 17:28:12 -070046 "TextTable.cpp",
Yifan Hong443df792017-05-09 18:49:45 -070047 "utils.cpp",
Steven Moreland552e4072019-06-25 09:33:32 -070048 "WaitCommand.cpp",
Yifan Hong85dd3ad2017-01-25 14:20:34 -080049 ],
Chih-Hung Hsieh734e3782017-10-05 13:44:13 -070050 cflags: [
51 "-Wall",
52 "-Werror",
53 ],
Yifan Hong85dd3ad2017-01-25 14:20:34 -080054}
Yifan Hong9881df92017-05-10 14:33:05 -070055
56cc_defaults {
57 name: "lshal_defaults",
58 shared_libs: [
59 "libbase",
Devin Moorec03e3aa2020-12-11 15:11:17 -080060 "libbinderdebug",
Steven Morelandb8745de2019-06-25 11:40:37 -070061 "libcutils",
Yifan Hong9881df92017-05-10 14:33:05 -070062 "libutils",
Steven Morelandb8745de2019-06-25 11:40:37 -070063 "libhidlbase",
Steven Morelandb8745de2019-06-25 11:40:37 -070064 "libhidl-gen-hash",
65 "libhidl-gen-utils",
66 "libvintf",
Chih-Hung Hsieh734e3782017-10-05 13:44:13 -070067 ],
Yifan Hongf31aa052018-02-02 15:17:51 -080068 static_libs: [
Steven Morelandb8745de2019-06-25 11:40:37 -070069 "liblshal",
Yifan Hongf31aa052018-02-02 15:17:51 -080070 "libprocpartition",
71 ],
Chih-Hung Hsieh734e3782017-10-05 13:44:13 -070072 cflags: ["-Wall", "-Werror"],
Yifan Hong9881df92017-05-10 14:33:05 -070073}
74
75cc_binary {
76 name: "lshal",
77 defaults: ["lshal_defaults"],
78 srcs: [
79 "main.cpp"
80 ]
81}
82
83cc_test {
84 name: "lshal_test",
Steven Morelandeae1a0b2019-06-25 13:01:49 -070085 test_suites: ["device-tests"],
Yifan Hong43101a42020-12-01 11:14:28 -080086 defaults: [
87 "libvintf_static_user_defaults",
88 "lshal_defaults"
89 ],
Yifan Hong9881df92017-05-10 14:33:05 -070090 gtest: true,
91 static_libs: [
Yifan Hong5cceea82020-07-09 19:34:58 -070092 "android.hardware.tests.inheritance@1.0",
Steven Morelandeae1a0b2019-06-25 13:01:49 -070093 "libgmock",
Yifan Hong43101a42020-12-01 11:14:28 -080094 "libvintf",
Yifan Hong9881df92017-05-10 14:33:05 -070095 ],
96 shared_libs: [
Steven Morelandeae1a0b2019-06-25 13:01:49 -070097 "libhidlbase",
Yifan Hong9881df92017-05-10 14:33:05 -070098 ],
99 srcs: [
100 "test.cpp"
101 ]
102}