Skip to content

Commit

Permalink
Port chromevox build to GN.
Browse files Browse the repository at this point in the history
This ports the chromevox build: chromevox and chromevox_tests targets to
gn.  Liblouis is still missing since it requires native client which is
not enabled for Chrome OS.

BUG=None

Review URL: https://codereview.chromium.org/1145243006

Cr-Commit-Position: refs/heads/master@{#338002}
  • Loading branch information
plundblad authored and Commit bot committed Jul 9, 2015
1 parent 991e92d commit 70028e5
Show file tree
Hide file tree
Showing 25 changed files with 1,264 additions and 326 deletions.
1 change: 1 addition & 0 deletions .gn
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ exec_script_whitelist = [
"//chrome/browser/BUILD.gn",
"//chrome/browser/chromeos/BUILD.gn",
"//chrome/browser/extensions/BUILD.gn",
"//chrome/browser/resources/chromeos/chromevox/BUILD.gn",
"//chrome/browser/media/router/BUILD.gn",
"//chrome/browser/ui/BUILD.gn",
"//chrome/chrome_tests.gni",
Expand Down
21 changes: 15 additions & 6 deletions build/secondary/tools/grit/grit_rule.gni
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,10 @@
# Path to .grd file.
#
# outputs (required)
# List of outputs from grit, relative to the target_gen_dir. If supplied,
# a call to Grit to compute the outputs can be skipped which will make
# GN run faster. Grit will verify at build time that this list is correct
# and will fail if there is a mismatch between the outputs specified by
# the .grd file and the outputs list here.
# List of outputs from grit, relative to the target_gen_dir. Grit will
# verify at build time that this list is correct and will fail if there
# is a mismatch between the outputs specified by the .grd file and the
# outputs list here.
#
# To get this list, you can look in the .grd file for
# <output filename="..." and put those filename here. The base directory
Expand Down Expand Up @@ -50,6 +49,10 @@
# output_dir, but if multiple targets with the same name end up in
# the same output_dir, they can collide.
#
# depfile_dir (optional)
# If set, used to store the depfile and corresponding stamp file.
# Defaults to output_dir
#
# use_qualified_include (optional)
# If set, output_dir is not added to include_dirs.
#
Expand Down Expand Up @@ -331,6 +334,12 @@ template("grit") {
grit_output_name = target_name
}

if (defined(invoker.depfile_dir)) {
depfile_dir = invoker.depfile_dir
} else {
depfile_dir = output_dir
}

# These are all passed as arguments to the script so have to be relative to
# the build directory.
if (resource_ids != "") {
Expand Down Expand Up @@ -383,7 +392,7 @@ template("grit") {
script = "//tools/grit/grit.py"
inputs = grit_inputs

depfile = "$output_dir/${grit_output_name}_stamp.d"
depfile = "$depfile_dir/${grit_output_name}_stamp.d"
outputs = [ "${depfile}.stamp" ] + grit_outputs

args = [
Expand Down
13 changes: 4 additions & 9 deletions chrome/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -425,14 +425,8 @@ group("extra_resources") {
]
}

if (enable_chromevox_next) {
deps += [
#'browser/resources/chromeos/chromevox2/chromevox.gyp:chromevox2', TODO(GYP)
]
} else {
deps += [
#'browser/resources/chromeos/chromevox/chromevox.gyp:chromevox', TODO(GYP)
]
if (is_chromeos) {
deps += [ "//chrome/browser/resources/chromeos/chromevox" ]
}

if (enable_extensions) {
Expand Down Expand Up @@ -715,7 +709,8 @@ template("chrome_repack_material_percent") {
percent = invoker.percent

repack_name = "${target_name}_repack"
repack_output_file = "$root_gen_dir/repack/chrome_material_${percent}_percent.pak"
repack_output_file =
"$root_gen_dir/repack/chrome_material_${percent}_percent.pak"

copy_name = target_name

Expand Down
14 changes: 14 additions & 0 deletions chrome/browser/resources/chromeos/braille_ime/BUILD.gn
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# 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.

assert(is_chromeos)

copy("braille_ime_manifest") {
sources = [
"manifest.json",
]
outputs = [
"$root_out_dir/resources/chromeos/braille_ime/manifest.json",
]
}
Loading

0 comments on commit 70028e5

Please sign in to comment.