| // This file is manually copied from old Android.bp |
| |
| // cargo2android.py limitations: |
| // does not handle "-l dylib=wayland-client" yet |
| // does not generate cc_library module yet |
| // does not generate wayland_protocol_codegen module yet |
| |
| package { |
| // See: http://go/android-license-faq |
| // A large-scale-change added 'default_applicable_licenses' to import |
| // all of the 'license_kinds' from "external_crosvm_license" |
| // to get the below license kinds: |
| // SPDX-license-identifier-BSD |
| // SPDX-license-identifier-MIT |
| default_applicable_licenses: ["external_crosvm_license"], |
| } |
| |
| rust_library { |
| name: "libgpu_display", |
| defaults: ["crosvm_defaults"], |
| host_supported: true, |
| crate_name: "gpu_display", |
| srcs: ["src/lib.rs"], |
| edition: "2018", |
| rustlibs: [ |
| "libbase_rust", |
| "libdata_model", |
| "liblibc", |
| "liblinux_input_sys", |
| ], |
| static_libs: [ |
| "libdisplay_wl", |
| ], |
| |
| // added manually |
| target: { |
| host: { |
| shared_libs: ["libwayland_client"], |
| }, |
| android: { |
| static_libs: [ |
| "libwayland_client_static", |
| "libffi" |
| ], |
| }, |
| }, |
| } |
| |
| cc_library_static { |
| name: "libdisplay_wl", |
| host_supported: true, |
| c_std: "c11", |
| srcs: ["src/display_wl.c"], |
| |
| generated_sources: [ |
| "gpu_display_protocol_sources", |
| "wayland_extension_protocol_sources", |
| ], |
| generated_headers: [ |
| "gpu_display_client_protocol_headers", |
| "wayland_extension_client_protocol_headers", |
| ], |
| export_generated_headers: [ |
| "gpu_display_client_protocol_headers", |
| "wayland_extension_client_protocol_headers", |
| ], |
| |
| // added manually |
| target: { |
| host: { |
| shared_libs: ["libwayland_client"], |
| }, |
| android: { |
| static_libs: [ |
| "libwayland_client_static", |
| "libffi" |
| ], |
| }, |
| linux_glibc_x86: { |
| // libffi broken on x86, see b/162610242 |
| enabled: false, |
| }, |
| }, |
| apex_available: [ |
| "//apex_available:platform", |
| "com.android.virt", |
| ], |
| } |
| |
| wayland_protocol_codegen { |
| name: "gpu_display_protocol_sources", |
| cmd: "$(location wayland_scanner) private-code < $(in) > $(out)", |
| suffix: ".c", |
| srcs: [ |
| "protocol/aura-shell.xml", |
| "protocol/linux-dmabuf-unstable-v1.xml", |
| "protocol/viewporter.xml", |
| "protocol/virtio-gpu-metadata-v1.xml", |
| ], |
| tools: ["wayland_scanner"], |
| } |
| |
| wayland_protocol_codegen { |
| name: "gpu_display_client_protocol_headers", |
| cmd: "$(location wayland_scanner) client-header < $(in) > $(out)", |
| suffix: ".h", |
| srcs: [ |
| "protocol/aura-shell.xml", |
| "protocol/linux-dmabuf-unstable-v1.xml", |
| "protocol/viewporter.xml", |
| "protocol/virtio-gpu-metadata-v1.xml", |
| ], |
| tools: ["wayland_scanner"], |
| } |
| |
| wayland_protocol_codegen { |
| name: "gpu_display_server_protocol_headers", |
| cmd: "$(location wayland_scanner) server-header < $(in) > $(out)", |
| suffix: ".h", |
| srcs: [ |
| "protocol/aura-shell.xml", |
| "protocol/linux-dmabuf-unstable-v1.xml", |
| "protocol/viewporter.xml", |
| "protocol/virtio-gpu-metadata-v1.xml", |
| ], |
| tools: ["wayland_scanner"], |
| } |
| |
| cc_library_static { |
| name: "libwayland_crosvm_gpu_display_extension_server_protocols", |
| vendor_available: true, |
| host_supported: true, |
| cflags: [ |
| "-Wall", |
| "-Wextra", |
| "-Werror", |
| "-g", |
| "-fvisibility=hidden", |
| ], |
| static_libs: ["libwayland_server"], |
| generated_sources: ["gpu_display_protocol_sources"], |
| generated_headers: ["gpu_display_server_protocol_headers"], |
| export_generated_headers: ["gpu_display_server_protocol_headers"], |
| } |
| |
| // dependent_library ["feature_list"] |
| // ../assertions/src/lib.rs |
| // ../base/src/lib.rs |
| // ../cros_async/src/lib.rs |
| // ../data_model/src/lib.rs |
| // ../io_uring/src/lib.rs |
| // ../linux_input_sys/src/lib.rs |
| // ../sync/src/lib.rs |
| // ../sys_util/poll_token_derive/poll_token_derive.rs |
| // ../sys_util/src/lib.rs |
| // ../tempfile/src/lib.rs |
| // async-task-4.0.3 "default,std" |
| // async-trait-0.1.50 |
| // autocfg-1.0.1 |
| // cc-1.0.25 |
| // futures-0.3.15 "alloc" |
| // futures-channel-0.3.15 "alloc,futures-sink,sink" |
| // futures-core-0.3.15 "alloc" |
| // futures-io-0.3.15 |
| // futures-sink-0.3.15 "alloc" |
| // futures-task-0.3.15 "alloc" |
| // futures-util-0.3.15 "alloc,futures-sink,sink" |
| // intrusive-collections-0.9.1 "alloc,default" |
| // itoa-0.4.7 |
| // libc-0.2.95 "default,std" |
| // memoffset-0.5.6 "default" |
| // paste-1.0.5 |
| // pin-project-lite-0.2.6 |
| // pin-utils-0.1.0 |
| // pkg-config-0.3.19 |
| // proc-macro2-1.0.27 "default,proc-macro" |
| // quote-1.0.9 "default,proc-macro" |
| // ryu-1.0.5 |
| // serde-1.0.126 "default,derive,serde_derive,std" |
| // serde_derive-1.0.126 "default" |
| // serde_json-1.0.64 "default,std" |
| // slab-0.4.3 "default,std" |
| // smallvec-1.6.1 |
| // syn-1.0.72 "clone-impls,default,derive,full,parsing,printing,proc-macro,quote,visit-mut" |
| // thiserror-1.0.25 |
| // thiserror-impl-1.0.25 |
| // unicode-xid-0.2.2 "default" |