blob: 47e6099a23a23bb37a7c6ea46ac465e53f460c50 [file] [log] [blame]
# Copyright 2018 The Chromium OS 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("//common-mk/pkg_config.gni")
group("all") {
deps = [
":kmsvnc",
":screenshot",
]
if (use.test) {
deps += [ ":run_kmsvnc_test" ]
}
}
pkg_config("target_defaults") {
pkg_deps = [
"egl",
"gbm",
"glesv2",
"libchrome",
"libdrm",
"libpng",
]
}
static_library("libscreen-capture") {
sources = [
"bo_import_capture.cc",
"crtc.cc",
"egl_capture.cc",
"kmsvnc_utils.cc",
]
configs += [ ":target_defaults" ]
}
pkg_config("libvncserver") {
pkg_deps = [ "libvncserver" ]
}
executable("screenshot") {
sources = [
"png.cc",
"screenshot.cc",
]
configs += [ ":target_defaults" ]
deps = [ ":libscreen-capture" ]
}
executable("kmsvnc") {
sources = [
"kmsvnc.cc",
"uinput.cc",
]
configs += [
":target_defaults",
":libvncserver",
]
deps = [ ":libscreen-capture" ]
pkg_deps = [ "libmetrics" ]
}
if (use.test) {
pkg_config("test_config") {
pkg_deps = [ "gtest_main" ]
}
executable("run_kmsvnc_test") {
sources = [ "kmsvnc_utils_test.cc" ]
run_test = true
configs += [
"//common-mk:test",
":target_defaults",
":test_config",
]
deps = [
":libscreen-capture",
"//common-mk/testrunner",
]
}
}