Add usage of main from chromium when part of a chromium build
BUG=tint:123 Change-Id: Ic7a8694cefd0dbee2a1855e84f4ffaaf75ad6e7a Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/25520 Reviewed-by: Ryan Harrison <rharrison@chromium.org>
This commit is contained in:
parent
9a2b692b1c
commit
433670b576
19
BUILD.gn
19
BUILD.gn
|
@ -638,6 +638,20 @@ if (!build_with_chromium) {
|
|||
}
|
||||
}
|
||||
|
||||
###############################################################################
|
||||
# Wrapping of Chromium targets
|
||||
###############################################################################
|
||||
# These targets are separated because they are Chromium sources files that
|
||||
# can't use the tint_internal config, otherwise Tint's warning flags get
|
||||
# applied while compiling a bunch of Chromium's //base (via header inclusion)
|
||||
if (build_with_chromium) {
|
||||
source_set("tint_unittests_main") {
|
||||
testonly = true
|
||||
deps = [ ":gmock_and_gtest" ]
|
||||
sources = [ "//gpu/tint_unittests_main.cc" ]
|
||||
}
|
||||
}
|
||||
|
||||
###############################################################################
|
||||
# Tests - For libtint core and optional modules
|
||||
###############################################################################
|
||||
|
@ -1089,8 +1103,9 @@ test("tint_unittests") {
|
|||
"${tint_spirv_tools_dir}/:spvtools_val",
|
||||
]
|
||||
|
||||
# TODO(rharrison): Use main() from chromium for chromium tree builds. This
|
||||
# requires adding a file to //gpu like Dawn has done.
|
||||
if (build_with_chromium) {
|
||||
deps += [ ":tint_unittests_main" ]
|
||||
}
|
||||
|
||||
configs += [
|
||||
":tint_common_config",
|
||||
|
|
Loading…
Reference in New Issue