blob: 8e3c73263bade787e2b0e1edbd43e441ccbd2d77 [file] [log] [blame]
# Copyright 2018 The ChromiumOS Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//common-mk/proto_library.gni")
group("all") {
deps = [
":libsystem_api",
":system_api-anomaly_detector-protos",
":system_api-arc-goprotos",
":system_api-arc-protos",
":system_api-arcvm_data_migrator-protos",
":system_api-attestation-goprotos",
":system_api-attestation-protos",
":system_api-authpolicy-protos",
":system_api-biod-protos",
":system_api-bootlockbox-goprotos",
":system_api-bootlockbox-protos",
":system_api-cdm_oemcrypto-protos",
":system_api-chaps-protos",
":system_api-chunneld-protos",
":system_api-cryptohome-goprotos",
":system_api-dlcservice-goprotos",
":system_api-dlcservice-protos",
":system_api-dlp-protos",
":system_api-fusebox-protos",
":system_api-hps-goprotos",
":system_api-hps-protos",
":system_api-imageloader-goprotos",
":system_api-imageloader-protos",
":system_api-kerberos-goprotos",
":system_api-kerberos-protos",
":system_api-login_manager-goprotos",
":system_api-login_manager-protos",
":system_api-lorgnette-goprotos",
":system_api-lorgnette-protos",
":system_api-lvmd-goprotos",
":system_api-lvmd-protos",
":system_api-metrics_event-goprotos",
":system_api-metrics_event-protos",
":system_api-minios-protos",
":system_api-ml-goprotos",
":system_api-ml-protos",
":system_api-oobe_config-protos",
":system_api-patchpanel-goprotos",
":system_api-patchpanel-protos",
":system_api-plugin_vm_service-goprotos",
":system_api-plugin_vm_service-protos",
":system_api-power_manager-goprotos",
":system_api-power_manager-protos",
":system_api-privacy_screen-protos",
":system_api-private_computing-protos",
":system_api-protos",
":system_api-rmad-protos",
":system_api-runtime_probe-goprotos",
":system_api-runtime_probe-protos",
":system_api-seneschal-goprotos",
":system_api-seneschal-protos",
":system_api-shadercached-goprotos",
":system_api-shadercached-protos",
":system_api-smbprovider-protos",
":system_api-spaced-protos",
":system_api-system_proxy-protos",
":system_api-tpm_manager-goprotos",
":system_api-tpm_manager-protos",
":system_api-u2f-protos",
":system_api-update_engine-goprotos",
":system_api-update_engine-protos",
":system_api-vm_applications-protos",
":system_api-vm_cicerone-goprotos",
":system_api-vm_cicerone-protos",
":system_api-vm_concierge-goprotos",
":system_api-vm_concierge-protos",
":system_api-vm_disk_management-protos",
":system_api-vm_launch-protos",
":system_api-vm_permission_service-protos",
":system_api-vm_plugin_dispatcher-goprotos",
":system_api-vm_plugin_dispatcher-protos",
":system_api-vm_sk_forwarding-protos",
]
}
shared_library("libsystem_api") {
deps = [
":system_api-attestation-protos",
":system_api-bootlockbox-protos",
":system_api-chaps-protos",
":system_api-cryptohome-protos",
":system_api-patchpanel-protos",
":system_api-tpm_manager-protos",
]
if (use.fuzzer) {
pkg_deps = [ "protobuf" ]
} else {
pkg_deps = [ "protobuf-lite" ]
}
}
proto_library("system_api-protos") {
proto_in_dir = "dbus"
proto_out_dir = "include/system_api/proto_bindings"
sources = [
"${proto_in_dir}/field_trial_list.proto",
"${proto_in_dir}/mtp_file_entry.proto",
"${proto_in_dir}/mtp_storage_info.proto",
]
standalone = true
}
proto_library("system_api-power_manager-protos") {
proto_in_dir = "dbus/power_manager"
proto_out_dir = "include/power_manager/proto_bindings"
sources = [
"${proto_in_dir}/backlight.proto",
"${proto_in_dir}/charge_history_state.proto",
"${proto_in_dir}/idle.proto",
"${proto_in_dir}/input_event.proto",
"${proto_in_dir}/peripheral_battery_status.proto",
"${proto_in_dir}/policy.proto",
"${proto_in_dir}/power_supply_properties.proto",
"${proto_in_dir}/suspend.proto",
"${proto_in_dir}/switch_states.proto",
"${proto_in_dir}/thermal.proto",
"${proto_in_dir}/user_charging_event.proto",
]
standalone = true
}
goproto_library("system_api-power_manager-goprotos") {
proto_in_dir = "dbus/power_manager"
proto_out_dir = "go/src/"
sources = [
"${proto_in_dir}/backlight.proto",
"${proto_in_dir}/charge_history_state.proto",
"${proto_in_dir}/idle.proto",
"${proto_in_dir}/input_event.proto",
"${proto_in_dir}/peripheral_battery_status.proto",
"${proto_in_dir}/policy.proto",
"${proto_in_dir}/power_supply_properties.proto",
"${proto_in_dir}/suspend.proto",
"${proto_in_dir}/switch_states.proto",
"${proto_in_dir}/thermal.proto",
"${proto_in_dir}/user_charging_event.proto",
]
}
proto_library("system_api-cryptohome-protos") {
proto_in_dir = "dbus/cryptohome"
proto_out_dir = "include/cryptohome/proto_bindings"
sources = [
"${proto_in_dir}/UserDataAuth.proto",
"${proto_in_dir}/auth_factor.proto",
"${proto_in_dir}/fido.proto",
"${proto_in_dir}/key.proto",
"${proto_in_dir}/rpc.proto",
]
standalone = true
# system_api-cryptohome-protos is used by a shared_library
# object, so we need to build it with "-fPIC" instead of "-fPIE".
use_pic = true
}
goproto_library("system_api-cryptohome-goprotos") {
proto_in_dir = "dbus/cryptohome"
proto_out_dir = "go/src/"
sources = [
"${proto_in_dir}/UserDataAuth.proto",
"${proto_in_dir}/auth_factor.proto",
"${proto_in_dir}/fido.proto",
"${proto_in_dir}/key.proto",
"${proto_in_dir}/rpc.proto",
]
}
proto_library("system_api-authpolicy-protos") {
proto_in_dir = "dbus/authpolicy"
proto_out_dir = "include/authpolicy/proto_bindings"
sources = [ "${proto_in_dir}/active_directory_info.proto" ]
standalone = true
}
proto_library("system_api-biod-protos") {
proto_in_dir = "dbus/biod"
proto_out_dir = "include/biod/proto_bindings"
sources = [
"${proto_in_dir}/constants.proto",
"${proto_in_dir}/messages.proto",
]
standalone = true
}
proto_library("system_api-kerberos-protos") {
proto_in_dir = "dbus/kerberos"
proto_out_dir = "include/kerberos/proto_bindings"
sources = [ "${proto_in_dir}/kerberos_service.proto" ]
standalone = true
}
goproto_library("system_api-kerberos-goprotos") {
proto_in_dir = "dbus/kerberos"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/kerberos_service.proto" ]
}
proto_library("system_api-login_manager-protos") {
proto_in_dir = "dbus/login_manager"
proto_out_dir = "include/login_manager/proto_bindings"
sources = [
"${proto_in_dir}/login_screen_storage.proto",
"${proto_in_dir}/policy_descriptor.proto",
]
standalone = true
# Override optimize_for option in proto file.
# Needed for fuzz targets using libprotobuf-mutator.
if (use.fuzzer) {
gen_cpp_mode = "speed"
}
}
goproto_library("system_api-login_manager-goprotos") {
proto_in_dir = "dbus/login_manager"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/policy_descriptor.proto" ]
}
proto_library("system_api-lorgnette-protos") {
proto_in_dir = "dbus/lorgnette"
proto_out_dir = "include/lorgnette/proto_bindings"
sources = [ "${proto_in_dir}/lorgnette_service.proto" ]
standalone = true
}
goproto_library("system_api-lorgnette-goprotos") {
proto_in_dir = "dbus/lorgnette"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/lorgnette_service.proto" ]
}
goproto_library("system_api-lvmd-goprotos") {
proto_in_dir = "dbus/lvmd"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/lvmd.proto" ]
}
proto_library("system_api-lvmd-protos") {
proto_in_dir = "dbus/lvmd"
proto_out_dir = "include/lvmd/proto_bindings"
sources = [ "${proto_in_dir}/lvmd.proto" ]
standalone = true
}
proto_library("system_api-chaps-protos") {
proto_in_dir = "dbus/chaps"
proto_out_dir = "include/chaps/proto_bindings"
sources = [
"${proto_in_dir}/ck_structs.proto",
"${proto_in_dir}/key_permissions.proto",
]
standalone = true
# system_api-chaps-protos is used by a shared_library
# object, so we need to build it with "-fPIC" instead of "-fPIE".
use_pic = true
}
proto_library("system_api-attestation-protos") {
proto_in_dir = "dbus/attestation"
proto_out_dir = "include/attestation/proto_bindings"
sources = [
"${proto_in_dir}/attestation_ca.proto",
"${proto_in_dir}/google_key.proto",
"${proto_in_dir}/interface.proto",
"${proto_in_dir}/keystore.proto",
"${proto_in_dir}/pca_agent.proto",
]
standalone = true
# system_api-attestation-protos" is used by a shared_library
# object, so we need to build it with "-fPIC" instead of "-fPIE".
use_pic = true
}
goproto_library("system_api-attestation-goprotos") {
proto_in_dir = "dbus/attestation"
proto_out_dir = "go/src/"
sources = [
"${proto_in_dir}/attestation_ca.proto",
"${proto_in_dir}/interface.proto",
"${proto_in_dir}/keystore.proto",
]
}
proto_library("system_api-tpm_manager-protos") {
proto_in_dir = "dbus/tpm_manager"
proto_out_dir = "include/tpm_manager/proto_bindings"
sources = [ "${proto_in_dir}/tpm_manager.proto" ]
standalone = true
# system_api-tpm_manager-protos is used by a shared_library
# object, so we need to build it with "-fPIC" instead of "-fPIE".
use_pic = true
}
goproto_library("system_api-tpm_manager-goprotos") {
proto_in_dir = "dbus/tpm_manager"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/tpm_manager.proto" ]
}
proto_library("system_api-metrics_event-protos") {
proto_in_dir = "dbus/metrics_event"
proto_out_dir = "include/metrics_event/proto_bindings"
sources = [ "${proto_in_dir}/metrics_event.proto" ]
standalone = true
}
goproto_library("system_api-metrics_event-goprotos") {
proto_in_dir = "dbus/metrics_event"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/metrics_event.proto" ]
}
proto_library("system_api-plugin_vm_service-protos") {
proto_in_dir = "dbus/plugin_vm_service"
proto_out_dir = "include/plugin_vm_service/proto_bindings"
sources = [ "${proto_in_dir}/plugin_vm_service.proto" ]
standalone = true
}
goproto_library("system_api-plugin_vm_service-goprotos") {
proto_in_dir = "dbus/plugin_vm_service"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/plugin_vm_service.proto" ]
}
proto_library("system_api-smbprovider-protos") {
proto_in_dir = "dbus/smbprovider"
proto_out_dir = "include/smbprovider/proto_bindings"
sources = [ "${proto_in_dir}/directory_entry.proto" ]
standalone = true
}
proto_library("system_api-vm_cicerone-protos") {
proto_in_dir = "dbus/vm_cicerone"
proto_out_dir = "include/vm_cicerone/proto_bindings"
sources = [ "${proto_in_dir}/cicerone_service.proto" ]
standalone = true
}
goproto_library("system_api-vm_cicerone-goprotos") {
proto_in_dir = "dbus/vm_cicerone"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/cicerone_service.proto" ]
}
proto_library("system_api-vm_concierge-protos") {
proto_in_dir = "dbus/vm_concierge"
proto_out_dir = "include/vm_concierge/proto_bindings"
proto_lib_dirs = [ "dbus" ]
sources = [ "${proto_in_dir}/concierge_service.proto" ]
deps = [ ":system_api-arc-protos" ]
standalone = true
}
goproto_library("system_api-vm_concierge-goprotos") {
proto_in_dir = "dbus/vm_concierge"
proto_out_dir = "go/src/"
proto_lib_dirs = [ "dbus" ]
sources = [ "${proto_in_dir}/concierge_service.proto" ]
}
proto_library("system_api-vm_applications-protos") {
proto_in_dir = "dbus/vm_applications"
proto_out_dir = "include/vm_applications/proto_bindings"
sources = [ "${proto_in_dir}/apps.proto" ]
standalone = true
}
proto_library("system_api-vm_sk_forwarding-protos") {
proto_in_dir = "dbus/vm_sk_forwarding"
proto_out_dir = "include/vm_sk_forwarding/proto_bindings"
sources = [ "${proto_in_dir}/sk_forwarding.proto" ]
standalone = true
}
proto_library("system_api-vm_launch-protos") {
proto_in_dir = "dbus/vm_launch"
proto_out_dir = "include/vm_launch/proto_bindings"
sources = [ "${proto_in_dir}/launch.proto" ]
standalone = true
}
proto_library("system_api-vm_disk_management-protos") {
proto_in_dir = "dbus/vm_disk_management"
proto_out_dir = "include/vm_disk_management/proto_bindings"
sources = [ "${proto_in_dir}/disk_management.proto" ]
standalone = true
}
proto_library("system_api-seneschal-protos") {
proto_in_dir = "dbus/seneschal"
proto_out_dir = "include/seneschal/proto_bindings"
sources = [ "${proto_in_dir}/seneschal_service.proto" ]
standalone = true
}
goproto_library("system_api-seneschal-goprotos") {
proto_in_dir = "dbus/seneschal"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/seneschal_service.proto" ]
}
proto_library("system_api-oobe_config-protos") {
proto_in_dir = "dbus/oobe_config"
proto_out_dir = "include/oobe_config/proto_bindings"
sources = [ "${proto_in_dir}/oobe_config.proto" ]
standalone = true
}
proto_library("system_api-runtime_probe-protos") {
proto_in_dir = "dbus/runtime_probe"
proto_out_dir = "include/runtime_probe/proto_bindings"
sources = [ "${proto_in_dir}/runtime_probe.proto" ]
standalone = true
}
goproto_library("system_api-runtime_probe-goprotos") {
proto_in_dir = "dbus/runtime_probe"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/runtime_probe.proto" ]
}
proto_library("system_api-bootlockbox-protos") {
proto_in_dir = "dbus/bootlockbox"
proto_out_dir = "include/bootlockbox/proto_bindings"
sources = [ "${proto_in_dir}/boot_lockbox_rpc.proto" ]
standalone = true
# system_api-bootlockbox-protos is used by a shared_library
# object, so we need to build it with "-fPIC" instead of "-fPIE".
use_pic = true
}
goproto_library("system_api-bootlockbox-goprotos") {
proto_in_dir = "dbus/bootlockbox"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/boot_lockbox_rpc.proto" ]
}
proto_library("system_api-dlcservice-protos") {
proto_in_dir = "dbus/dlcservice"
proto_out_dir = "include/dlcservice/proto_bindings"
sources = [ "${proto_in_dir}/dlcservice.proto" ]
standalone = true
}
goproto_library("system_api-dlcservice-goprotos") {
proto_in_dir = "dbus/dlcservice"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/dlcservice.proto" ]
}
proto_library("system_api-imageloader-protos") {
proto_in_dir = "dbus/imageloader"
proto_out_dir = "include/imageloader/proto_bindings"
sources = [ "${proto_in_dir}/imageloader.proto" ]
standalone = true
}
goproto_library("system_api-imageloader-goprotos") {
proto_in_dir = "dbus/imageloader"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/imageloader.proto" ]
}
proto_library("system_api-update_engine-protos") {
proto_in_dir = "dbus/update_engine"
proto_out_dir = "include/update_engine/proto_bindings"
sources = [ "${proto_in_dir}/update_engine.proto" ]
standalone = true
}
goproto_library("system_api-update_engine-goprotos") {
proto_in_dir = "dbus/update_engine"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/update_engine.proto" ]
}
proto_library("system_api-vm_plugin_dispatcher-protos") {
proto_in_dir = "dbus/vm_plugin_dispatcher"
proto_out_dir = "include/vm_plugin_dispatcher/proto_bindings"
sources = [ "${proto_in_dir}/vm_plugin_dispatcher.proto" ]
standalone = true
}
goproto_library("system_api-vm_plugin_dispatcher-goprotos") {
proto_in_dir = "dbus/vm_plugin_dispatcher"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/vm_plugin_dispatcher.proto" ]
}
proto_library("system_api-u2f-protos") {
proto_in_dir = "dbus/u2f"
proto_out_dir = "include/u2f/proto_bindings"
sources = [ "${proto_in_dir}/u2f_interface.proto" ]
standalone = true
}
proto_library("system_api-chunneld-protos") {
proto_in_dir = "dbus/chunneld"
proto_out_dir = "include/chunneld/proto_bindings"
sources = [ "${proto_in_dir}/chunneld_service.proto" ]
standalone = true
}
proto_library("system_api-patchpanel-protos") {
proto_in_dir = "dbus/patchpanel"
proto_out_dir = "include/patchpanel/proto_bindings"
sources = [ "${proto_in_dir}/patchpanel_service.proto" ]
standalone = true
use_pic = true
}
goproto_library("system_api-patchpanel-goprotos") {
proto_in_dir = "dbus/patchpanel"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/patchpanel_service.proto" ]
}
proto_library("system_api-anomaly_detector-protos") {
proto_in_dir = "dbus/anomaly_detector"
proto_out_dir = "include/anomaly_detector/proto_bindings"
sources = [ "${proto_in_dir}/anomaly_detector.proto" ]
standalone = true
}
proto_library("system_api-spaced-protos") {
proto_in_dir = "dbus/spaced"
proto_out_dir = "include/spaced/proto_bindings"
sources = [ "${proto_in_dir}/spaced.proto" ]
standalone = true
# system_api-spaced-protos is used by a shared_library
# object, so we need to build it with "-fPIC" instead of "-fPIE".
use_pic = true
}
proto_library("system_api-system_proxy-protos") {
proto_in_dir = "dbus/system_proxy"
proto_out_dir = "include/system_proxy/proto_bindings"
sources = [ "${proto_in_dir}/system_proxy_service.proto" ]
standalone = true
}
proto_library("system_api-vm_permission_service-protos") {
proto_in_dir = "dbus/vm_permission_service"
proto_out_dir = "include/vm_permission_service/proto_bindings"
sources = [ "${proto_in_dir}/vm_permission_service.proto" ]
standalone = true
}
proto_library("system_api-minios-protos") {
proto_in_dir = "dbus/minios"
proto_out_dir = "include/minios/proto_bindings"
sources = [ "${proto_in_dir}/minios.proto" ]
standalone = true
}
proto_library("system_api-dlp-protos") {
proto_in_dir = "dbus/dlp"
proto_out_dir = "include/dlp/proto_bindings"
sources = [ "${proto_in_dir}/dlp_service.proto" ]
standalone = true
}
proto_library("system_api-hps-protos") {
proto_in_dir = "dbus/hps"
proto_out_dir = "include/hps/proto_bindings"
sources = [ "${proto_in_dir}/hps_service.proto" ]
standalone = true
}
goproto_library("system_api-hps-goprotos") {
proto_in_dir = "dbus/hps"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/hps_service.proto" ]
}
proto_library("system_api-rmad-protos") {
proto_in_dir = "dbus/rmad"
proto_out_dir = "include/rmad/proto_bindings"
sources = [ "${proto_in_dir}/rmad.proto" ]
standalone = true
}
proto_library("system_api-fusebox-protos") {
proto_in_dir = "dbus/fusebox"
proto_out_dir = "include/fusebox/proto_bindings"
sources = [ "${proto_in_dir}/fusebox.proto" ]
standalone = true
}
proto_library("system_api-privacy_screen-protos") {
proto_in_dir = "dbus/privacy_screen"
proto_out_dir = "include/privacy_screen/proto_bindings"
sources = [ "${proto_in_dir}/privacy_screen.proto" ]
standalone = true
}
proto_library("system_api-cdm_oemcrypto-protos") {
proto_in_dir = "dbus/cdm_oemcrypto"
proto_out_dir = "include/cdm_oemcrypto/proto_bindings"
sources = [
"${proto_in_dir}/client_information.proto",
"${proto_in_dir}/secure_buffer.proto",
]
standalone = true
# system_api-cdm_oemcrypto-protos is used by a shared_library
# object, so we need to build it with "-fPIC" instead of "-fPIE".
use_pic = true
}
proto_library("system_api-ml-protos") {
proto_in_dir = "dbus/ml"
proto_out_dir = "include/ml/proto_bindings"
sources = [ "${proto_in_dir}/ranker_example.proto" ]
standalone = true
}
goproto_library("system_api-ml-goprotos") {
proto_in_dir = "dbus/ml"
proto_out_dir = "go/src"
sources = [ "${proto_in_dir}/ranker_example.proto" ]
}
proto_library("system_api-shadercached-protos") {
proto_in_dir = "dbus/shadercached"
proto_out_dir = "include/shadercached/proto_bindings"
sources = [ "${proto_in_dir}/shadercached.proto" ]
standalone = true
}
goproto_library("system_api-shadercached-goprotos") {
proto_in_dir = "dbus/shadercached"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/shadercached.proto" ]
}
proto_library("system_api-arc-protos") {
proto_in_dir = "dbus"
proto_out_dir = "include"
sources = [ "${proto_in_dir}/arc/arc.proto" ]
standalone = true
}
goproto_library("system_api-arc-goprotos") {
proto_in_dir = "dbus/arc"
proto_out_dir = "go/src/"
sources = [ "${proto_in_dir}/arc.proto" ]
}
proto_library("system_api-private_computing-protos") {
proto_in_dir = "dbus/private_computing"
proto_out_dir = "include/private_computing/proto_bindings"
sources = [ "${proto_in_dir}/private_computing_service.proto" ]
standalone = true
}
proto_library("system_api-arcvm_data_migrator-protos") {
proto_in_dir = "dbus/arcvm_data_migrator"
proto_out_dir = "include/arcvm_data_migrator/proto_bindings"
sources = [ "${proto_in_dir}/arcvm_data_migrator.proto" ]
standalone = true
}