naiveproxy/third_party/minigbm/BUILD.gn

68 lines
1.6 KiB
Plaintext
Raw Normal View History

2018-02-02 13:49:39 +03:00
# Copyright 2015 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/config/linux/pkg_config.gni")
assert(is_linux)
declare_args() {
# Controls whether the build should use the version of minigbm library
# shipped with the system. In release builds of Chrome OS we use the
# system version, but when building on dev workstations or the Chrome
# waterfall we bundle it because Ubuntu doesn't ship a usable version.
use_system_minigbm = false
}
if (!use_system_minigbm) {
config("minigbm_config") {
include_dirs = [ "src" ]
}
shared_library("minigbm") {
sources = [
"src/amdgpu.c",
"src/cirrus.c",
"src/drv.c",
"src/evdi.c",
"src/exynos.c",
"src/gbm.c",
"src/gbm_helpers.c",
"src/gma500.c",
"src/helpers.c",
"src/i915.c",
"src/marvell.c",
"src/mediatek.c",
"src/nouveau.c",
"src/rockchip.c",
"src/tegra.c",
"src/udl.c",
"src/vc4.c",
"src/vgem.c",
"src/virtio_gpu.c",
]
configs -= [ "//build/config/compiler:chromium_code" ]
configs += [ "//build/config/compiler:no_chromium_code" ]
deps = [
"//third_party/libdrm",
]
public_configs = [ ":minigbm_config" ]
# Clients need this to pick up the shared library correctly.
all_dependent_configs =
[ "//build/config/gcc:rpath_for_built_shared_libraries" ]
}
}
if (use_system_minigbm) {
pkg_config("libgbm") {
packages = [ "gbm" ]
}
group("minigbm") {
public_configs = [ ":libgbm" ]
}
}