Changyeon Jo | 8018901 | 2021-10-10 16:34:21 -0700 | [diff] [blame] | 1 | // Copyright (C) 2022 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 | package { |
Aditya Choudhary | 04ef212 | 2024-02-02 14:00:43 +0000 | [diff] [blame] | 16 | default_team: "trendy_team_automotive", |
Changyeon Jo | 8018901 | 2021-10-10 16:34:21 -0700 | [diff] [blame] | 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 "hardware_interfaces_license" |
| 20 | // to get the below license kinds: |
| 21 | // SPDX-license-identifier-Apache-2.0 |
| 22 | default_applicable_licenses: ["hardware_interfaces_license"], |
| 23 | } |
| 24 | |
Hao Chen | 5ed789c | 2023-08-24 20:07:29 +0000 | [diff] [blame] | 25 | cc_defaults { |
| 26 | name: "android.hardware.automotive.evs-aidl-default-service-default", |
Changyeon Jo | 8018901 | 2021-10-10 16:34:21 -0700 | [diff] [blame] | 27 | defaults: ["EvsHalDefaults"], |
Hao Chen | a15abfc | 2023-08-24 21:26:38 +0000 | [diff] [blame] | 28 | header_libs: [ |
| 29 | "libstagefright_headers", |
| 30 | ], |
Changyeon Jo | 7e62631 | 2023-03-13 22:44:01 +0000 | [diff] [blame] | 31 | shared_libs: [ |
| 32 | "android.hardware.graphics.bufferqueue@1.0", |
| 33 | "android.hardware.graphics.bufferqueue@2.0", |
| 34 | "android.hidl.token@1.0-utils", |
| 35 | "libEGL", |
| 36 | "libGLESv2", |
Changyeon Jo | 7e62631 | 2023-03-13 22:44:01 +0000 | [diff] [blame] | 37 | "libbinder_ndk", |
| 38 | "libbufferqueueconverter", |
| 39 | "libcamera_metadata", |
| 40 | "libhardware_legacy", |
| 41 | "libhidlbase", |
Hao Chen | a15abfc | 2023-08-24 21:26:38 +0000 | [diff] [blame] | 42 | "libmediandk", |
Changyeon Jo | 7e62631 | 2023-03-13 22:44:01 +0000 | [diff] [blame] | 43 | "libnativewindow", |
| 44 | "libtinyxml2", |
| 45 | "libui", |
Changyeon Jo | 7e62631 | 2023-03-13 22:44:01 +0000 | [diff] [blame] | 46 | "libyuv", |
| 47 | ], |
Hao Chen | 5ed789c | 2023-08-24 20:07:29 +0000 | [diff] [blame] | 48 | } |
| 49 | |
| 50 | cc_library { |
| 51 | name: "android.hardware.automotive.evs-aidl-default-service-lib", |
| 52 | defaults: ["android.hardware.automotive.evs-aidl-default-service-default"], |
| 53 | vendor: true, |
| 54 | cflags: [ |
| 55 | "-DGL_GLEXT_PROTOTYPES", |
| 56 | "-DEGL_EGLEXT_PROTOTYPES", |
| 57 | ], |
| 58 | srcs: [ |
| 59 | ":libgui_frame_event_aidl", |
| 60 | "src/*.cpp", |
| 61 | ], |
| 62 | exclude_srcs: ["src/service.cpp"], |
| 63 | whole_static_libs: [ |
Changyeon Jo | 130d5a3 | 2023-08-29 14:55:03 -0700 | [diff] [blame] | 64 | "android.frameworks.automotive.display-V2-ndk", |
Hao Chen | ac8e696 | 2023-03-29 11:20:56 -0700 | [diff] [blame] | 65 | "android.hardware.automotive.evs-V2-ndk", |
Changyeon Jo | 7e62631 | 2023-03-13 22:44:01 +0000 | [diff] [blame] | 66 | "android.hardware.common-V2-ndk", |
| 67 | "libaidlcommonsupport", |
| 68 | "libcutils", |
| 69 | ], |
Changyeon Jo | 130d5a3 | 2023-08-29 14:55:03 -0700 | [diff] [blame] | 70 | header_libs: [ |
| 71 | "libgui_aidl_headers", |
| 72 | ], |
Changyeon Jo | 7e62631 | 2023-03-13 22:44:01 +0000 | [diff] [blame] | 73 | local_include_dirs: ["include"], |
| 74 | include_dirs: ["frameworks/native/include/"], |
Hao Chen | 5ed789c | 2023-08-24 20:07:29 +0000 | [diff] [blame] | 75 | export_include_dirs: ["include"], |
| 76 | } |
| 77 | |
| 78 | cc_binary { |
| 79 | name: "android.hardware.automotive.evs-aidl-default-service", |
| 80 | defaults: ["android.hardware.automotive.evs-aidl-default-service-default"], |
| 81 | vintf_fragments: ["manifest_evs-default-service.xml"], |
| 82 | init_rc: ["evs-default-service.rc"], |
| 83 | vendor: true, |
| 84 | relative_install_path: "hw", |
| 85 | cflags: [ |
| 86 | "-DGL_GLEXT_PROTOTYPES", |
| 87 | "-DEGL_EGLEXT_PROTOTYPES", |
| 88 | ], |
| 89 | srcs: ["src/service.cpp"], |
| 90 | static_libs: [ |
| 91 | "android.hardware.automotive.evs-aidl-default-service-lib", |
| 92 | ], |
| 93 | include_dirs: ["frameworks/native/include/"], |
Changyeon Jo | 7e62631 | 2023-03-13 22:44:01 +0000 | [diff] [blame] | 94 | required: ["evs_mock_hal_configuration.xml"], |
| 95 | } |
| 96 | |
| 97 | prebuilt_etc { |
| 98 | name: "evs_mock_hal_configuration.xml", |
| 99 | soc_specific: true, |
| 100 | src: "resources/evs_mock_configuration.xml", |
| 101 | sub_dir: "automotive/evs", |
Changyeon Jo | 8018901 | 2021-10-10 16:34:21 -0700 | [diff] [blame] | 102 | } |
Hao Chen | 5ed789c | 2023-08-24 20:07:29 +0000 | [diff] [blame] | 103 | |
| 104 | cc_test { |
| 105 | name: "android.hardware.automotive.evs-aidl-default-service_cam_buffer_test", |
| 106 | defaults: ["android.hardware.automotive.evs-aidl-default-service-default"], |
| 107 | vendor: true, |
| 108 | srcs: ["tests/EvsCameraBufferTest.cpp"], |
| 109 | static_libs: [ |
| 110 | "android.hardware.automotive.evs-aidl-default-service-lib", |
| 111 | "libgmock", |
| 112 | ], |
Hao Chen | 0d14a82 | 2023-08-29 20:34:08 +0000 | [diff] [blame] | 113 | test_suites: [ |
| 114 | "general-tests", |
| 115 | ], |
| 116 | } |
| 117 | |
| 118 | cc_test { |
| 119 | name: "android.hardware.automotive.evs-aidl-default-service_cam_state_test", |
| 120 | defaults: ["android.hardware.automotive.evs-aidl-default-service-default"], |
| 121 | vendor: true, |
| 122 | srcs: ["tests/EvsCameraStateTest.cpp"], |
| 123 | static_libs: [ |
| 124 | "android.hardware.automotive.evs-aidl-default-service-lib", |
| 125 | "libgmock", |
| 126 | ], |
| 127 | test_suites: [ |
| 128 | "general-tests", |
| 129 | ], |
Hao Chen | 5ed789c | 2023-08-24 20:07:29 +0000 | [diff] [blame] | 130 | } |