1// Use of this source code is governed by a BSD-style license that can be 2// found in the LICENSE file. 3 4cc_defaults { 5 name: "minigbm_defaults", 6 7 srcs: [ 8 "amdgpu.c", 9 "drv.c", 10 "evdi.c", 11 "exynos.c", 12 "helpers_array.c", 13 "helpers.c", 14 "i915.c", 15 "marvell.c", 16 "mediatek.c", 17 "meson.c", 18 "msm.c", 19 "nouveau.c", 20 "radeon.c", 21 "rockchip.c", 22 "tegra.c", 23 "udl.c", 24 "vc4.c", 25 "vgem.c", 26 "virtio_gpu.c", 27 ], 28 29 cflags: [ 30 "-D_GNU_SOURCE=1", 31 "-D_FILE_OFFSET_BITS=64", 32 "-Wall", 33 "-Wsign-compare", 34 "-Wpointer-arith", 35 "-Wcast-qual", 36 "-Wcast-align", 37 "-Wno-unused-parameter", 38 ], 39 cppflags: ["-std=c++14"], 40 41 vendor: true, 42 43 header_libs: [ 44 "libhardware_headers", 45 "libnativebase_headers", 46 "libnativewindow_headers", 47 "libsystem_headers", 48 ], 49 50 export_header_lib_headers: [ 51 "libhardware_headers", 52 "libnativebase_headers", 53 "libnativewindow_headers", 54 "libsystem_headers", 55 ], 56 57 shared_libs: [ 58 "libcutils", 59 "libdrm", 60 "libnativewindow", 61 "libsync", 62 "liblog", 63 ], 64 65 static_libs: ["libarect"], 66 67 export_static_lib_headers: ["libarect"], 68} 69 70cc_defaults { 71 name: "minigbm_cros_gralloc_defaults", 72 73 defaults: ["minigbm_defaults"], 74 75 srcs: [ 76 "cros_gralloc/cros_gralloc_buffer.cc", 77 "cros_gralloc/cros_gralloc_helpers.cc", 78 "cros_gralloc/cros_gralloc_driver.cc", 79 ] 80} 81 82cc_library_static { 83 name: "libminigbm", 84 defaults: ["minigbm_defaults"], 85 shared_libs: ["liblog"], 86 static_libs: ["libdrm"], 87 88 srcs: [ 89 "gbm.c", 90 "gbm_helpers.c", 91 ], 92 93 export_include_dirs: ["."], 94} 95 96cc_library_static { 97 name: "libminigbm_cros_gralloc", 98 defaults: ["minigbm_cros_gralloc_defaults"], 99 shared_libs: ["liblog"], 100 static_libs: ["libdrm"], 101 102 export_include_dirs: ["."], 103} 104 105cc_library_shared { 106 name: "gralloc.minigbm", 107 defaults: ["minigbm_cros_gralloc_defaults"], 108 srcs: ["cros_gralloc/gralloc0/gralloc0.cc"], 109} 110 111cc_library_shared { 112 name: "gralloc.minigbm_intel", 113 defaults: ["minigbm_cros_gralloc_defaults"], 114 enabled: false, 115 arch: { 116 x86: { 117 enabled: true, 118 }, 119 x86_64: { 120 enabled: true, 121 }, 122 }, 123 cflags: ["-DDRV_I915"], 124 srcs: ["cros_gralloc/gralloc0/gralloc0.cc"], 125} 126 127cc_library_shared { 128 name: "gralloc.minigbm_meson", 129 defaults: ["minigbm_cros_gralloc_defaults"], 130 cflags: ["-DDRV_MESON"], 131 srcs: ["cros_gralloc/gralloc0/gralloc0.cc"], 132}