Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 1 | // Copyright (C) 2009 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 | |
Vijay Venkatraman | 5583be7 | 2017-03-24 16:13:58 -0700 | [diff] [blame] | 15 | cc_library_headers { |
| 16 | name: "libbinder_headers", |
| 17 | export_include_dirs: ["include"], |
Jiyong Park | 172bd72 | 2017-06-21 12:14:18 +0900 | [diff] [blame] | 18 | vendor_available: true, |
Jiyong Park | b7df6cb | 2017-04-13 21:19:48 -0700 | [diff] [blame] | 19 | header_libs: [ |
| 20 | "libbase_headers", |
| 21 | "libcutils_headers", |
| 22 | "libutils_headers", |
| 23 | ], |
| 24 | export_header_lib_headers: [ |
| 25 | "libbase_headers", |
| 26 | "libcutils_headers", |
| 27 | "libutils_headers", |
| 28 | ], |
Vijay Venkatraman | 5583be7 | 2017-03-24 16:13:58 -0700 | [diff] [blame] | 29 | } |
| 30 | |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 31 | cc_library { |
| 32 | name: "libbinder", |
| 33 | |
Steven Moreland | 3aa7616 | 2017-04-13 21:19:48 -0700 | [diff] [blame] | 34 | // for vndbinder |
| 35 | vendor_available: true, |
Justin Yun | b367ff4 | 2017-08-02 17:02:05 +0900 | [diff] [blame] | 36 | vndk: { |
| 37 | enabled: true, |
| 38 | }, |
Jiyong Park | fe0a824 | 2018-04-09 12:16:30 +0900 | [diff] [blame] | 39 | double_loadable: true, |
Steven Moreland | 3aa7616 | 2017-04-13 21:19:48 -0700 | [diff] [blame] | 40 | |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 41 | srcs: [ |
Ganesh Mahendran | 4d85b8c | 2017-11-02 14:43:38 +0000 | [diff] [blame] | 42 | "ActivityManager.cpp", |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 43 | "AppOpsManager.cpp", |
| 44 | "Binder.cpp", |
| 45 | "BpBinder.cpp", |
| 46 | "BufferedTextOutput.cpp", |
| 47 | "Debug.cpp", |
Sudheer Shanka | 6ef26f1 | 2016-11-23 15:52:26 -0800 | [diff] [blame] | 48 | "IActivityManager.cpp", |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 49 | "IAppOpsCallback.cpp", |
| 50 | "IAppOpsService.cpp", |
| 51 | "IBatteryStats.cpp", |
| 52 | "IInterface.cpp", |
| 53 | "IMediaResourceMonitor.cpp", |
| 54 | "IMemory.cpp", |
| 55 | "IPCThreadState.cpp", |
| 56 | "IPermissionController.cpp", |
| 57 | "IProcessInfoService.cpp", |
| 58 | "IResultReceiver.cpp", |
| 59 | "IServiceManager.cpp", |
Dianne Hackborn | 1941a40 | 2016-08-29 12:30:43 -0700 | [diff] [blame] | 60 | "IShellCallback.cpp", |
Ganesh Mahendran | 4d85b8c | 2017-11-02 14:43:38 +0000 | [diff] [blame] | 61 | "IUidObserver.cpp", |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 62 | "MemoryBase.cpp", |
| 63 | "MemoryDealer.cpp", |
| 64 | "MemoryHeapBase.cpp", |
| 65 | "Parcel.cpp", |
Ryo Hashimoto | bf55189 | 2018-05-31 16:58:35 +0900 | [diff] [blame] | 66 | "ParcelFileDescriptor.cpp", |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 67 | "PermissionCache.cpp", |
Svet Ganov | e752a5c | 2018-01-15 17:14:20 -0800 | [diff] [blame] | 68 | "PermissionController.cpp", |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 69 | "PersistableBundle.cpp", |
| 70 | "ProcessInfoService.cpp", |
| 71 | "ProcessState.cpp", |
| 72 | "Static.cpp", |
| 73 | "Status.cpp", |
| 74 | "TextOutput.cpp", |
Robert Quattlebaum | 6316f5b | 2017-01-04 13:25:14 -0800 | [diff] [blame] | 75 | "IpPrefix.cpp", |
| 76 | "Value.cpp", |
Colin Cross | 21c210e | 2017-11-14 13:05:37 -0800 | [diff] [blame] | 77 | ":libbinder_aidl", |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 78 | ], |
| 79 | |
Jiyong Park | 47f876b | 2018-04-17 13:56:46 +0900 | [diff] [blame] | 80 | target: { |
| 81 | vendor: { |
| 82 | exclude_srcs: [ |
| 83 | "ActivityManager.cpp", |
| 84 | "AppOpsManager.cpp", |
| 85 | "IActivityManager.cpp", |
| 86 | "IAppOpsCallback.cpp", |
| 87 | "IAppOpsService.cpp", |
| 88 | "IBatteryStats.cpp", |
| 89 | "IMediaResourceMonitor.cpp", |
| 90 | "IPermissionController.cpp", |
| 91 | "IProcessInfoService.cpp", |
| 92 | "IUidObserver.cpp", |
| 93 | "PermissionCache.cpp", |
| 94 | "PermissionController.cpp", |
| 95 | "ProcessInfoService.cpp", |
| 96 | "IpPrefix.cpp", |
| 97 | ":libbinder_aidl", |
| 98 | ], |
| 99 | }, |
| 100 | }, |
| 101 | |
Todd Kennedy | 757186e | 2017-08-02 07:49:20 -0700 | [diff] [blame] | 102 | aidl: { |
| 103 | export_aidl_headers: true, |
| 104 | }, |
| 105 | |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 106 | cflags: [ |
| 107 | "-Wall", |
| 108 | "-Wextra", |
| 109 | "-Werror", |
Yi Kong | c2376e4 | 2018-07-10 15:12:36 -0700 | [diff] [blame^] | 110 | "-Wzero-as-null-pointer-constant", |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 111 | ], |
| 112 | product_variables: { |
| 113 | binder32bit: { |
| 114 | cflags: ["-DBINDER_IPC_32BIT=1"], |
| 115 | }, |
| 116 | }, |
| 117 | |
| 118 | shared_libs: [ |
| 119 | "libbase", |
| 120 | "liblog", |
| 121 | "libcutils", |
| 122 | "libutils", |
David Sehr | 0756265 | 2018-01-17 17:10:18 -0800 | [diff] [blame] | 123 | "libutilscallstack", |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 124 | ], |
Jiyong Park | 4284205 | 2017-06-20 13:51:22 +0900 | [diff] [blame] | 125 | |
| 126 | header_libs: [ |
| 127 | "libbinder_headers", |
| 128 | ], |
| 129 | |
Jiyong Park | 4284205 | 2017-06-20 13:51:22 +0900 | [diff] [blame] | 130 | export_header_lib_headers: [ |
| 131 | "libbinder_headers", |
Dan Stoza | d630e52 | 2016-12-01 15:16:31 -0800 | [diff] [blame] | 132 | ], |
| 133 | |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 134 | clang: true, |
| 135 | sanitize: { |
| 136 | misc_undefined: ["integer"], |
| 137 | }, |
| 138 | } |
| 139 | |
Colin Cross | 21c210e | 2017-11-14 13:05:37 -0800 | [diff] [blame] | 140 | // AIDL interface between libbinder and framework.jar |
| 141 | filegroup { |
| 142 | name: "libbinder_aidl", |
| 143 | srcs: [ |
| 144 | "aidl/android/content/pm/IPackageManagerNative.aidl", |
| 145 | ], |
| 146 | } |
| 147 | |
Dan Willemsen | e05dc6d | 2016-07-25 17:13:45 -0700 | [diff] [blame] | 148 | subdirs = ["tests"] |