Reason for revert:
Apparently this was incorrect.
Original issue's description:
> Move GN grit scripts out of secondary tree.
>
> These build files were in the secondary tree because I thought tools/grit was DEPSed in. However, this directory is in the Chrome tree. The DEPSed-in directory is tools/grit/grit. Moving these files to the expected place will make things more clear.
>
> Committed: https://crrev.com/82d10f697a4268dd9ae0fffd8f3dfb1fb42901e5
> Cr-Commit-Position: refs/heads/master@{#345713}
TBR=thakis@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Review URL: https://codereview.chromium.org/1311133008
Cr-Original-Commit-Position: refs/heads/master@{#345926}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 30327bc319a006e6c89a7b3cdf1fef86f05ec692
These build files were in the secondary tree because I thought tools/grit was DEPSed in. However, this directory is in the Chrome tree. The DEPSed-in directory is tools/grit/grit. Moving these files to the expected place will make things more clear.
Review URL: https://codereview.chromium.org/1317013002
Cr-Original-Commit-Position: refs/heads/master@{#345713}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 82d10f697a4268dd9ae0fffd8f3dfb1fb42901e5
A starting point for doing all of src, and adding a PRESUBMIT.
Includes https://codereview.chromium.org/772663002/ and https://codereview.chromium.org/770053002/.
I haven't pushed new binaries yet.
Generated via:
> cd build
> git ls-files *.gn *.gni | sed -e "s/^/@..\\\\out\\\\Debug\\\\gn format --in-place /" >x.bat && x.bat
The only things that I don't love in the current output are:
1. Turning
args = [
"--depfile", rebase_path(depfile, root_build_dir),
"--android-sdk-tools", rebased_android_sdk_build_tools,
"--dex-path", rebased_output,
]
into:
args = [
"--depfile",
rebase_path(depfile, root_build_dir),
"--android-sdk-tools",
rebased_android_sdk_build_tools,
"--dex-path",
rebased_output,
]
The heuristic for this isn't trivial though, and it also affects e.g. '-Xclang' in cflags, as well
as assignments to temporaries that are later assigned to args.
2. Turning single line
if (defined(invoker.inputs)) { inputs = invoker.inputs }
into
if (defined(invoker.inputs)) {
inputs = invoker.inputs
}
This could be argued to be an improvement, but as it's very boilerplate-y perhaps an exception to
allow single line in this case is worthwhile. I think there was discussion of new syntax for this
case too, something like "inputs ?= invoker.inputs" maybe.
In both cases, I think it's worthwhile to get formatting turned on, and then go back and special
case these if we decide it's worthwhile.
R=brettw@chromium.org
BUG=348474
Review URL: https://codereview.chromium.org/766573003
Cr-Original-Commit-Position: refs/heads/master@{#306305}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: b199254f481c5db36d56e83fce40594b06d2b81f
Pull grit 171 to get the new deps fixes required to implement this.
This removes the call to grit for querying inputs completely, and enables depfile writing to enable automatic rebuilds when things are out-of-date.
Adds a new outputs variable that bypasses querying grit for outputs. This will assert that the given files exist in grit. This version allows outputs to be empty in which case it will revert to the old dynamic behavior. I'm going to land this with just the worst cases fixed to make landing easier. Then followup with converting the rest of the grit targets and removing the dynamic option.
R=viettrungluu@chromium.org
Review URL: https://codereview.chromium.org/407653003
git-svn-id: http://src.chromium.org/svn/trunk/src/build@284705 4ff67af0-8c30-449e-8e8b-ad334ec8d88c