| Wedson Almeida Filho | ba42dac | 2020-08-13 17:11:18 +0100 | [diff] [blame] | 1 | // | 
 | 2 | // Copyright (C) 2020 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 |  | 
| Bob Badour | 4c7858c | 2021-02-12 15:40:29 -0800 | [diff] [blame] | 17 | package { | 
| Aditya Choudhary | d987e9b | 2024-02-02 14:02:09 +0000 | [diff] [blame] | 18 |     default_team: "trendy_team_foundation_security_rust_pkvm_", | 
| Bob Badour | 4c7858c | 2021-02-12 15:40:29 -0800 | [diff] [blame] | 19 |     // See: http://go/android-license-faq | 
 | 20 |     // A large-scale-change added 'default_applicable_licenses' to import | 
 | 21 |     // all of the 'license_kinds' from "system_security_license" | 
 | 22 |     // to get the below license kinds: | 
 | 23 |     //   SPDX-license-identifier-Apache-2.0 | 
 | 24 |     default_applicable_licenses: ["system_security_license"], | 
 | 25 | } | 
 | 26 |  | 
| Seth Moore | 708da93 | 2022-08-18 14:38:05 -0700 | [diff] [blame] | 27 | cc_defaults { | 
 | 28 |     name: "rkp_factory_extraction_defaults", | 
| Max Bires | d0f7b35 | 2022-01-27 18:30:46 -0800 | [diff] [blame] | 29 |     defaults: [ | 
| Seth Moore | 708da93 | 2022-08-18 14:38:05 -0700 | [diff] [blame] | 30 |         "keymint_use_latest_hal_aidl_ndk_static", | 
| Max Bires | d0f7b35 | 2022-01-27 18:30:46 -0800 | [diff] [blame] | 31 |     ], | 
| Max Bires | f60987e | 2021-04-16 13:35:20 -0700 | [diff] [blame] | 32 |     shared_libs: [ | 
| Max Bires | f60987e | 2021-04-16 13:35:20 -0700 | [diff] [blame] | 33 |         "libbinder_ndk", | 
| Seth Moore | 891d4c5 | 2023-11-08 19:42:44 +0000 | [diff] [blame] | 34 |         "libcrypto", | 
| Seth Moore | 5914625 | 2021-07-02 08:59:23 -0700 | [diff] [blame] | 35 |         "liblog", | 
 | 36 |     ], | 
 | 37 |     static_libs: [ | 
| Robert Shih | d3c1f7c | 2023-07-10 13:07:35 -0700 | [diff] [blame] | 38 |         "android.hardware.common-V2-ndk", | 
 | 39 |         "android.hardware.drm-V1-ndk", | 
| Seth Moore | cd6e918 | 2022-11-04 17:39:05 +0000 | [diff] [blame] | 40 |         "android.hardware.security.rkp-V3-ndk", | 
| Seth Moore | 5914625 | 2021-07-02 08:59:23 -0700 | [diff] [blame] | 41 |         "libbase", | 
| Shawn Willden | 387187d | 2024-03-28 20:42:37 -0600 | [diff] [blame] | 42 |         "libcppbor", | 
| Max Bires | f60987e | 2021-04-16 13:35:20 -0700 | [diff] [blame] | 43 |         "libcppcose_rkp", | 
| Seth Moore | 5914625 | 2021-07-02 08:59:23 -0700 | [diff] [blame] | 44 |         "libjsoncpp", | 
| Seth Moore | 6dfb02a | 2021-06-18 15:43:09 -0700 | [diff] [blame] | 45 |         "libkeymint_remote_prov_support", | 
| Robert Shih | d3c1f7c | 2023-07-10 13:07:35 -0700 | [diff] [blame] | 46 |         "libmediadrmrkp", | 
| Max Bires | f60987e | 2021-04-16 13:35:20 -0700 | [diff] [blame] | 47 |     ], | 
| Max Bires | f60987e | 2021-04-16 13:35:20 -0700 | [diff] [blame] | 48 | } | 
| Seth Moore | 708da93 | 2022-08-18 14:38:05 -0700 | [diff] [blame] | 49 |  | 
 | 50 | cc_library_static { | 
 | 51 |     name: "librkp_factory_extraction", | 
 | 52 |     defaults: [ | 
 | 53 |         "rkp_factory_extraction_defaults", | 
 | 54 |     ], | 
 | 55 |     srcs: ["rkp_factory_extraction_lib.cpp"], | 
 | 56 |     vendor_available: true, | 
 | 57 | } | 
 | 58 |  | 
 | 59 | cc_test { | 
 | 60 |     name: "librkp_factory_extraction_test", | 
 | 61 |     defaults: [ | 
 | 62 |         "rkp_factory_extraction_defaults", | 
 | 63 |     ], | 
 | 64 |     srcs: ["rkp_factory_extraction_lib_test.cpp"], | 
 | 65 |     test_suites: ["device-tests"], | 
 | 66 |     static_libs: [ | 
 | 67 |         "libgmock", | 
 | 68 |         "librkp_factory_extraction", | 
 | 69 |     ], | 
 | 70 | } | 
 | 71 |  | 
 | 72 | cc_binary { | 
 | 73 |     name: "rkp_factory_extraction_tool", | 
| Jerome Gaillard | b6afaff | 2022-11-18 16:32:17 +0000 | [diff] [blame] | 74 |     vendor: true, | 
| Seth Moore | 708da93 | 2022-08-18 14:38:05 -0700 | [diff] [blame] | 75 |     srcs: ["rkp_factory_extraction_tool.cpp"], | 
 | 76 |     defaults: [ | 
 | 77 |         "rkp_factory_extraction_defaults", | 
 | 78 |     ], | 
 | 79 |     static_libs: [ | 
 | 80 |         "libgflags", | 
 | 81 |         "librkp_factory_extraction", | 
 | 82 |     ], | 
| Robert Shih | 5b2d983 | 2023-06-28 15:32:45 -0700 | [diff] [blame] | 83 |     dist: { | 
 | 84 |         targets: [ | 
 | 85 |             "dist_files", | 
 | 86 |             "rkp_factory_extraction_tool", | 
 | 87 |         ], | 
| Aditya Choudhary | d987e9b | 2024-02-02 14:02:09 +0000 | [diff] [blame] | 88 |         dest: "rkp_factory_extraction_tool", | 
| Robert Shih | 5b2d983 | 2023-06-28 15:32:45 -0700 | [diff] [blame] | 89 |     }, | 
 | 90 |     compile_multilib: "both", | 
 | 91 |     multilib: { | 
 | 92 |         lib64: { | 
 | 93 |             suffix: "64", | 
 | 94 |         }, | 
 | 95 |     }, | 
| Robert Shih | 5b2d983 | 2023-06-28 15:32:45 -0700 | [diff] [blame] | 96 |     target: { | 
 | 97 |         android_arm: { | 
 | 98 |             dist: { | 
| Seth Moore | ab49372 | 2023-08-02 13:00:53 -0700 | [diff] [blame] | 99 |                 dir: "rkp/arm", | 
| Robert Shih | 5b2d983 | 2023-06-28 15:32:45 -0700 | [diff] [blame] | 100 |             }, | 
 | 101 |         }, | 
 | 102 |         android_arm64: { | 
 | 103 |             dist: { | 
| Seth Moore | ab49372 | 2023-08-02 13:00:53 -0700 | [diff] [blame] | 104 |                 dir: "rkp/arm64", | 
| Robert Shih | 5b2d983 | 2023-06-28 15:32:45 -0700 | [diff] [blame] | 105 |             }, | 
 | 106 |         }, | 
 | 107 |         android_x86: { | 
 | 108 |             dist: { | 
| Seth Moore | ab49372 | 2023-08-02 13:00:53 -0700 | [diff] [blame] | 109 |                 dir: "rkp/x86", | 
| Robert Shih | 5b2d983 | 2023-06-28 15:32:45 -0700 | [diff] [blame] | 110 |             }, | 
 | 111 |         }, | 
 | 112 |         android_x86_64: { | 
 | 113 |             dist: { | 
| Seth Moore | ab49372 | 2023-08-02 13:00:53 -0700 | [diff] [blame] | 114 |                 dir: "rkp/x86_64", | 
| Robert Shih | 5b2d983 | 2023-06-28 15:32:45 -0700 | [diff] [blame] | 115 |             }, | 
 | 116 |         }, | 
 | 117 |     }, | 
| Seth Moore | 708da93 | 2022-08-18 14:38:05 -0700 | [diff] [blame] | 118 | } |