Revert "[build] Enable external flag header with defines"

This reverts commit 1370b29e75.

Reason for revert: Breaks some targets that lack a dependency onto v8-gn.h, see https://crbug.com/1178409.

Original change's description:
> [build] Enable external flag header with defines
>
> Due to some unusual build failures on some trybots,
> v8_generate_external_defines_header was reverted to false. This turns it
> back on but changes the behaviour so that defines are added to the
> command line as well as to the header. Because the generated header
> checks that flags that should be unset are actually unset and flags that
> should be set are either unset or set to 1, this will cause build
> failures on many types of mismatches, although it will not detect where a
> flag is not set on the command line when it is set by the header.
>
> If no further failures show up with this, the hybrid part can be removed
> and the v8-gn.h header can stand on its own.
>
> Bug: v8:11292, v8:11341
> Change-Id: I1deeeebec58f79607e68a28f808649e884810923
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2649041
> Commit-Queue: Dan Elphick <delphick@chromium.org>
> Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#72327}

TBR=mlippautz@chromium.org,delphick@chromium.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: v8:11292
Bug: v8:11341
Change-Id: I6cf57014ef8be73c286ad9c5ebf597915f183717
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2695400
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72748}
This commit is contained in:
Ross McIlroy 2021-02-15 13:26:12 +00:00 committed by Commit Bot
parent 48aa80185d
commit f9366e7689

View File

@ -288,7 +288,7 @@ declare_args() {
# If enabled then macro definitions that are used in externally visible
# header files are placed in a separate header file v8-gn.h.
v8_generate_external_defines_header = true
v8_generate_external_defines_header = false
# Include support for WebAssembly. If disabled, the 'WebAssembly' global
# will not be available, and embedder APIs to generate WebAssembly modules
@ -575,12 +575,10 @@ disabled_external_v8_defines = external_v8_defines - enabled_external_v8_defines
config("v8_header_features") {
visibility = [ ":*" ]
# TODO(v8:11292): Set defines as well as including the header. This is a short
# term change to check that the header doesn't get stale and fail to get
# updated.
defines = enabled_external_v8_defines
if (v8_generate_external_defines_header) {
defines += [ "V8_GN_HEADER" ]
defines = [ "V8_GN_HEADER" ]
} else {
defines = enabled_external_v8_defines
}
}
@ -610,12 +608,10 @@ disabled_external_cppgc_defines =
config("cppgc_header_features") {
visibility = [ ":*" ]
# TODO(v8:11292): Set defines as well as including the header. This is a short
# term change to check that the header doesn't get stale and fail to get
# updated.
defines = enabled_external_cppgc_defines
if (v8_generate_external_defines_header) {
defines += [ "V8_GN_HEADER" ]
defines = [ "V8_GN_HEADER" ]
} else {
defines = enabled_external_cppgc_defines
}
}