People sometimes nest targets or configs, usually with the assumption that this limits the visibility of a config to within a target. But this nesting provides no visibility restrictions over declaring it outside of a block.
Un-nest for clarity.
Re-land of http://crrev.com/1318823008 while preserving config ordering.
Review URL: https://codereview.chromium.org/1307223010
Cr-Original-Commit-Position: refs/heads/master@{#346964}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 6dd952c77209619a445205998173fc40fb817be1
Reason for revert:
This breaks why these configs exist in the first place and seriously breaks the clang/win gn build (which is what these configs exist for).
Original issue's description:
> Un-nest configs in GN files.
>
> People sometimes nest targets or configs, usually with the assumption that this limits the visibility of a config to within a target. But this nesting provides no visibility restrictions over declaring it outside of a block.
>
> Un-nest for clarity.
>
> Committed: https://crrev.com/4af2eac8e84692d94f88504ab6e0b244b88dddcb
> Cr-Commit-Position: refs/heads/master@{#346461}
TBR=dpranke@chromium.org,brettw@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Review URL: https://codereview.chromium.org/1316843006
Cr-Original-Commit-Position: refs/heads/master@{#346695}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 0cb5abbf230f3c30e3499d4e787f059ed723dd3c
People sometimes nest targets or configs, usually with the assumption that this limits the visibility of a config to within a target. But this nesting provides no visibility restrictions over declaring it outside of a block.
Un-nest for clarity.
Review URL: https://codereview.chromium.org/1318823008
Cr-Original-Commit-Position: refs/heads/master@{#346461}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 4af2eac8e84692d94f88504ab6e0b244b88dddcb
I've taken ad591c629a
and merged it onto Chromium ToT, with a few lint and other cleanups,
and one fix to make sure that Mac still compiled (which may have broken
iOS, haven't tested yet).
R=brettw@chromium.org, sdfresne@chromium.org
BUG=459705
CQ_EXTRA_TRYBOTS=tryserver.chromium.mac:mac_chromium_gn_rel,mac_chromium_gn_dbg
Review URL: https://codereview.chromium.org/1250913002
Cr-Original-Commit-Position: refs/heads/master@{#342297}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 2a29462a04dabad3fc20dc922227c46b36459912
This changes constructor initializer list ordering to match field
declaration ordering, except for gtest and breakpad, where the warning
is disabled.
BUG=505304
NOPRESUBMIT=true
Review URL: https://codereview.chromium.org/1210013007
Cr-Original-Commit-Position: refs/heads/master@{#337152}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 5648c8598f20bc9756a82cf90cee204db44ea269
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
This is the new name. It has the same meaning but additionally with a "you can use the headers" permission.
Rename direct_dependent_configs to public_configs. This is the new name with identical meaning.
TBR=jamesr
Review URL: https://codereview.chromium.org/595073002
Cr-Original-Commit-Position: refs/heads/master@{#296302}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: e5389527466d390b5653724a069008b9f1edcd5c
Currently this is either a list or a string. However, this is causing some problems because templates can't add to the invoker's visibility list without knowing if the original is a string or a list.
In an effort to make this consistent, I'm converting all visibiltiy to be lists, and will remove support for strings in a future build.
This exempts cld from header checking since it was confusing GN's header checker. It adds a ppapi header target as well that will be used by libyuv (that requires a roll).
TBR=scottmg
Review URL: https://codereview.chromium.org/544423002
Cr-Original-Commit-Position: refs/heads/master@{#293638}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 9af4262ad8020658ee04c07d13a2617af64147b1
This matches the gyp build and is important for parts of the code that
guard their API with UNIT_TEST. For instance,
chrome/browser/ui/views/omnibox/omnibox_view_views.h has a GetRenderText
function guarded by #if UNIT_TEST that shadows a protected function
GetRenderText from its parent class views::Textfield, but with different
const-ness. If c/b/u/v/o/omnibox_view_views.cc is compiled with UNIT_TEST
set, it attempts to use the guarded member function instead of the base
class which fails to compile.
R=brettw@chromium.org
Review URL: https://codereview.chromium.org/464503003
git-svn-id: http://src.chromium.org/svn/trunk/src/build@288988 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
These DEPS have not been updated for ~2 years, so there is a good chance
something will blow up. Due to interdependancy between the repos,
rolling gtest required gmock also be rolled.
This CL was originally landed as 288164 and reverted as 288239 because it allows
more aggressive LTO in MSVS. This resulted in the compiler noticing an
intentional arithmetic overflow and warning about it.
BUG=401761
Review URL: https://codereview.chromium.org/425333002
git-svn-id: http://src.chromium.org/svn/trunk/src/build@288505 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
Suspected to have broken the Chrome Win build:
c:\b\build\slave\google-chrome-rel-win\build\src\base\numerics\safe_numerics_unittest.cc(577) : error C2220: warning treated as error - no 'object' file generated
c:\b\build\slave\google-chrome-rel-win\build\src\base\numerics\safe_numerics_unittest.cc(577) : warning C4756: overflow in constant arithmetic
> Roll gtest and gmock DEPS.
>
> These DEPS have not been updated for ~2 years, so there is a good chance
> something will blow up. Due to interdependancy between the repos,
> rolling gtest required gmock also be rolled.
>
> BUG=none
>
> Review URL: https://codereview.chromium.org/425333002TBR=ncbray@chromium.org
Review URL: https://codereview.chromium.org/454823002
git-svn-id: http://src.chromium.org/svn/trunk/src/build@288239 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
It's a goodness to sequester build configuration in the build/
directory. The gn secondary_source stuff was under tools/gn for
historical reasons, so move it to a more appropriate place.
BUG=None
TEST=do a gn build of base_unittests, run said unittests.
Review URL: https://codereview.chromium.org/340153004
git-svn-id: http://src.chromium.org/svn/trunk/src/build@278355 4ff67af0-8c30-449e-8e8b-ad334ec8d88c