Files
android/libwvdrmengine/cdm/Android.bp
Jacob Trimble 95b50d39ba Add SCP support for Android files
SCP uses the JNI headers in generated code, so several targets need
the include path; this will have no effect on non-SCP builds.  Also,
in "protected" builds, there is a generated library that needs to be
linked in the final binary, but this doesn't exist in the "analysis"
step; we create an empty static library if it doesn't exist so it works
on all cases.

Merged from https://widevine-internal-review.googlesource.com/169850

Merged from https://widevine-internal-review.googlesource.com/176177

Bug: 262635528
Change-Id: Ib676d55efbcbec81de9c3123bc70afb570d6caa5
(cherry picked from commit b9482eb23c261788a4432de7566f1b1de1cf9379)
2024-04-16 20:48:35 +00:00

91 lines
3.3 KiB
Plaintext

// ----------------------------------------------------------------
// Builds libcdm.a
//
// *** THIS PACKAGE HAS SPECIAL LICENSING CONDITIONS. PLEASE
// CONSULT THE OWNERS AND opensource-licensing@google.com BEFORE
// DEPENDING ON IT IN YOUR PROJECT. ***
package {
default_team: "trendy_team_media_framework_drm",
// See: http://go/android-license-faq
// A large-scale-change added 'default_applicable_licenses' to import
// all of the 'license_kinds' from "vendor_widevine_license"
// to get the below license kinds:
// legacy_by_exception_only (by exception only)
// legacy_proprietary (by exception only)
default_applicable_licenses: ["vendor_widevine_license"],
}
SRC_DIR = "src"
CORE_SRC_DIR = "core/src"
METRICS_SRC_DIR = "metrics/src"
cc_library_static {
name: "libcdm",
cflags: [
"-DDYNAMIC_ADAPTER",
"-DTEST_OEMCRYPTO_V15",
],
include_dirs: [
"vendor/widevine/libwvdrmengine/cdm/core/include",
"vendor/widevine/libwvdrmengine/cdm/metrics/include",
"vendor/widevine/libwvdrmengine/cdm/util/include",
"vendor/widevine/libwvdrmengine/cdm/include",
"vendor/widevine/libwvdrmengine/oemcrypto/include",
"vendor/widevine/libwvdrmengine/oemcrypto/odk/include",
"external/jsmn",
"external/protobuf/src",
],
header_libs: [
"jni_headers",
"libutils_headers",
],
static_libs: ["libcdm_protos"],
shared_libs: ["libcrypto"],
srcs: [
CORE_SRC_DIR + "/buffer_reader.cpp",
CORE_SRC_DIR + "/cdm_engine.cpp",
CORE_SRC_DIR + "/cdm_engine_factory.cpp",
CORE_SRC_DIR + "/cdm_session.cpp",
CORE_SRC_DIR + "/cdm_session_map.cpp",
CORE_SRC_DIR + "/cdm_usage_table.cpp",
CORE_SRC_DIR + "/certificate_provisioning.cpp",
CORE_SRC_DIR + "/client_identification.cpp",
CORE_SRC_DIR + "/content_key_session.cpp",
CORE_SRC_DIR + "/crypto_session.cpp",
CORE_SRC_DIR + "/device_files.cpp",
CORE_SRC_DIR + "/entitlement_key_session.cpp",
CORE_SRC_DIR + "/initialization_data.cpp",
CORE_SRC_DIR + "/license.cpp",
CORE_SRC_DIR + "/license_key_status.cpp",
CORE_SRC_DIR + "/license_protocol_conversions.cpp",
CORE_SRC_DIR + "/oemcrypto_adapter_dynamic.cpp",
CORE_SRC_DIR + "/okp_fallback_policy.cpp",
CORE_SRC_DIR + "/okp_info.cpp",
CORE_SRC_DIR + "/ota_keybox_provisioner.cpp",
CORE_SRC_DIR + "/policy_engine.cpp",
CORE_SRC_DIR + "/policy_timers.cpp",
CORE_SRC_DIR + "/policy_timers_v16.cpp",
CORE_SRC_DIR + "/policy_timers_v18.cpp",
CORE_SRC_DIR + "/privacy_crypto_boringssl.cpp",
CORE_SRC_DIR + "/service_certificate.cpp",
CORE_SRC_DIR + "/system_id_extractor.cpp",
CORE_SRC_DIR + "/wv_cdm_types.cpp",
SRC_DIR + "/wv_content_decryption_module.cpp",
METRICS_SRC_DIR + "/attribute_handler.cpp",
METRICS_SRC_DIR + "/counter_metric.cpp",
METRICS_SRC_DIR + "/distribution.cpp",
METRICS_SRC_DIR + "/event_metric.cpp",
METRICS_SRC_DIR + "/metrics_collections.cpp",
METRICS_SRC_DIR + "/timer_metric.cpp",
METRICS_SRC_DIR + "/value_metric.cpp",
],
proprietary: true,
min_sdk_version: "34",
}