aboutsummaryrefslogtreecommitdiff
path: root/rutabaga_gfx/Android.bp
blob: 0c64f2ef2d7ee7348510ee6cf6ca2c5b09b54b10 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
// This file is generated by cargo_embargo.
// Do not modify this file as most changes will be overridden on upgrade.
// Content before the first "rust_*" or "genrule" module is preserved.

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
    default_applicable_licenses: ["external_crosvm_license"],
}

rust_library {
    name: "librutabaga_gfx",
    defaults: ["crosvm_inner_defaults"],
    host_supported: true,
    crate_name: "rutabaga_gfx",
    cargo_env_compat: true,
    cargo_pkg_version: "0.1.3",
    srcs: ["src/lib.rs"],
    edition: "2021",
    features: [
        "gfxstream",
        "virgl_renderer",
    ],
    rustlibs: [
        "libcfg_if",
        "liblibc",
        "liblog_rust",
        "libnix",
        "libthiserror",
        "libzerocopy",
    ],
    proc_macros: ["libremain"],
    cfgs: [
        "gfxstream_unstable",
    ],
    shared_libs: [
        "libc++",
        "libbase",
    ],
    target: {
        android: {
            shared_libs: [
                "libnativewindow",
                "libcutils",
                "liblog",
            ],
        },
    },
    static_libs: [
        "libepoxy",
        "libgbm",
        "libdrm",
        "libgfxstream_backend",
        "libvirglrenderer",
    ],
}

rust_library {
    name: "librutabaga_gfx_gfxstream",
    defaults: ["crosvm_inner_defaults"],
    host_supported: true,
    vendor_available: true,
    crate_name: "rutabaga_gfx",
    cargo_env_compat: true,
    cargo_pkg_version: "0.1.2",
    srcs: ["src/lib.rs"],
    edition: "2021",
    rustlibs: [
        "libcfg_if",
        "liblibc",
        "liblog_rust",
        "libnix",
        "libthiserror",
        "libzerocopy",
    ],
    proc_macros: ["libremain"],
    cfgs: [
        "gfxstream_unstable",
    ],
    features: ["gfxstream"],
    shared_libs: [
        "libgfxstream_backend",
    ],
}

rust_test {
    name: "rutabaga_gfx_test_src_lib",
    defaults: ["crosvm_inner_defaults"],
    host_supported: true,
    crate_name: "rutabaga_gfx",
    cargo_env_compat: true,
    cargo_pkg_version: "0.1.3",
    srcs: ["src/lib.rs"],
    test_suites: ["general-tests"],
    auto_gen_config: true,
    test_options: {
        unit_test: true,
    },
    edition: "2021",
    features: [
        "gfxstream",
        "virgl_renderer",
    ],
    rustlibs: [
        "libcfg_if",
        "liblibc",
        "liblog_rust",
        "libnix",
        "libthiserror",
        "libzerocopy",
    ],
    proc_macros: ["libremain"],
    shared_libs: [
        "libepoxy",
        "libgbm",
        "libgfxstream_backend",
        "libvirglrenderer",
    ],
    static_libs: [
        "libdrm",
    ],
}