0

build: remove all references to goma

Bug: 41489832
Change-Id: I129e235fe20dcba02e94966d9c3ded8ac3843ec3
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5540874
Commit-Queue: Takuto Ikuta <tikuta@chromium.org>
Reviewed-by: Philipp Wollermann <philwo@chromium.org>
Reviewed-by: Junji Watanabe <jwata@google.com>
Auto-Submit: Takuto Ikuta <tikuta@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1301809}
This commit is contained in:
Takuto Ikuta
2024-05-16 08:19:23 +00:00
committed by Chromium LUCI CQ
parent 8117d5ba0c
commit a03decd8ec
13 changed files with 18 additions and 51 deletions

2
build/.gitignore vendored

@ -11,8 +11,6 @@ ciopfs
/Debug
/Debug_x64
/fuchsia/internal/
/goma
/gomacc.lock
/ipch/
/lacros/prebuilt_ash_chrome/
/Release

@ -505,7 +505,7 @@ def _RunCompiler(changes,
java_srcjars = options.java_srcjars
save_info_file = jar_info_path is not None
# Use jar_path's directory to ensure paths are relative (needed for goma).
# Use jar_path's directory to ensure paths are relative (needed for rbe).
temp_dir = jar_path + '.staging'
build_utils.DeleteDirectory(temp_dir)
os.makedirs(temp_dir)
@ -663,8 +663,6 @@ def _ParseOptions(argv):
type='int',
help='Whether code being compiled should be built with stricter '
'warnings for chromium code.')
parser.add_option(
'--gomacc-path', help='When set, prefix javac command with gomacc')
parser.add_option(
'--errorprone-path', help='Use the Errorprone compiler at this path.')
parser.add_option(
@ -742,10 +740,7 @@ def main(argv):
force=options.use_build_server)):
return
javac_cmd = []
if options.gomacc_path:
javac_cmd.append(options.gomacc_path)
javac_cmd.append(build_utils.JAVAC_PATH)
javac_cmd = [build_utils.JAVAC_PATH]
javac_args = [
'-g',

@ -31,7 +31,7 @@ def _RunCompiler(args,
java_srcjars = args.java_srcjars
# Use jar_path's directory to ensure paths are relative (needed for goma).
# Use jar_path's directory to ensure paths are relative (needed for rbe).
temp_dir = jar_path + '.staging'
build_utils.DeleteDirectory(temp_dir)
os.makedirs(temp_dir)
@ -114,8 +114,6 @@ def _ParseOptions(argv):
action='store_true',
help='Whether code being compiled should be built with stricter '
'warnings for chromium code.')
parser.add_argument('--gomacc-path',
help='When set, prefix kotlinc command with gomacc')
parser.add_argument('--warnings-as-errors',
action='store_true',
help='Treat all warnings as errors.')
@ -146,10 +144,7 @@ def main(argv):
argv = build_utils.ExpandFileArgs(argv)
args, source_files = _ParseOptions(argv)
kotlinc_cmd = []
if args.gomacc_path:
kotlinc_cmd.append(args.gomacc_path)
kotlinc_cmd.append(build_utils.KOTLINC_PATH)
kotlinc_cmd = [build_utils.KOTLINC_PATH]
kotlinc_cmd += [
'-no-jdk', # Avoid depending on the bundled JDK.

@ -108,7 +108,7 @@ def main(argv):
cmd += options.java_srcjars
if java_files:
# Use jar_path to ensure paths are relative (needed for goma).
# Use jar_path to ensure paths are relative (needed for rbe).
files_rsp_path = options.jar_path + '.java_files_list.txt'
with open(files_rsp_path, 'w') as f:
f.write('\n'.join(java_files))

@ -41,7 +41,7 @@ import("//build/args/chromeos/${some_board}.gni")
That will produce a Chrome OS build of Chrome very similar to what is shipped
for that device. You can also supply additional args or even overwrite ones
supplied in the .gni file after the `import()` line. For example, the following
args will produce a debug build of Chrome for board=eve using goma:
args will produce a debug build of Chrome for board=eve using rbe:
```
import("//build/args/chromeos/eve.gni")

@ -534,10 +534,6 @@ done
session="$(schroot -c "${chroot}" -b)"
export CHROOT_SESSION_ID="${session}"
# Set GOMA_TMP_DIR for better handling of goma inside chroot.
export GOMA_TMP_DIR="/tmp/goma_tmp_$CHROOT_SESSION_ID"
mkdir -p "$GOMA_TMP_DIR"
if [ $# -eq 0 ]; then
# Run an interactive shell session
schroot -c "${session}" -r -p
@ -588,8 +584,6 @@ done
# clean up the stale files by invoking us with "--clean" after having killed
# all running processes.
schroot -c "${session}" -e
# Since no goma processes are running, we can remove goma directory.
rm -rf "$GOMA_TMP_DIR"
exit $rc
EOF
sudo chown root:root /usr/local/bin/"${target%bit}"

@ -18,9 +18,6 @@
\|^ /Developer/Library/PrivateFrameworks/DevToolsCore\.framework/|d
\|^ /Developer/Library/Xcode/Plug-ins/CoreBuildTasks\.xcplugin/|d
# Drop any goma command lines as well.
\|^ .*/gomacc |d
# And, if you've overridden something from your own bin directory, remove those
# full command lines, too.
\|^ /Users/[^/]*/bin/|d

@ -6,7 +6,7 @@ import("//build/toolchain/concurrent_links.gni")
import("//build/toolchain/rbe.gni")
declare_args() {
# Pool for non goma tasks.
# Pool for non remote tasks.
action_pool_depth = -1
}

@ -7,7 +7,7 @@ import("//build/toolchain/concurrent_links.gni")
declare_args() {
# Reduce the number of tasks using the copy_bundle_data and compile_xcassets
# tools as they can cause lots of I/O contention when invoking ninja with a
# large number of parallel jobs (e.g. when using distributed build like goma).
# large number of parallel jobs (e.g. when using distributed build like rbe).
bundle_pool_depth = -1
}

@ -25,7 +25,6 @@
# will be necessary to successfully compile a working CrOS Chrome. See
# the definition of GYP_DEFINES inside a sysroot shell.)
#
# goma_dir = "/g/.cros_cache/common/goma+2"
# target_sysroot= /g/.cros_cache/chrome-sdk/tarballs/auron_paine+7644.0.0+sysroot_chromeos-base_chromeos-chrome.tar.xz"
# cros_target_cc = "x86_64-cros-linux-gnu-gcc -B/g/.cros_cache/chrome-sdk/tarballs/auron_paine+7657.0.0+target_toolchain/usr/x86_64-pc-linux-gnu/x86_64-cros-linux-gnu/binutils-bin/2.25.51-gold"
# cros_target_cxx = "x86_64-cros-linux-gnu-g++ -B/g/.cros_cache/chrome-sdk/tarballs/auron_paine+7657.0.0+target_toolchain/usr/x86_64-pc-linux-gnu/x86_64-cros-linux-gnu/binutils-bin/2.25.51-gold"

@ -78,14 +78,10 @@ def _GetDefaultConcurrentLinks(per_link_gb, reserve_gb, thin_lto_type,
cpu_count = 1
# A local LTO links saturate all cores, but only for some amount of the link.
# Goma LTO runs LTO codegen on goma, only run one of these tasks at once.
cpu_cap = cpu_count
if thin_lto_type is not None:
if thin_lto_type == 'goma':
cpu_cap = 1
else:
assert thin_lto_type == 'local'
cpu_cap = min(cpu_count, 6)
assert thin_lto_type == 'local'
cpu_cap = min(cpu_count, 6)
explanation.append(
'cpu_count={} cpu_cap={} mem_total_gb={:.1f}GiB adjusted_mem_total_gb={:.1f}GiB'

@ -161,10 +161,7 @@ nacl_glibc_toolchain("x86") {
toolchain_revision = nacl_x86_glibc_rev
# Rely on the :compiler_cpu_abi config adding the -m32 flag here rather
# than using the i686-nacl binary directly. This is a because i686-nacl-gcc
# is a shell script wrapper around x86_64-nacl-gcc and goma has trouble with
# compiler executables that are shell scripts (so the i686 'compiler' is not
# currently in goma).
# than using the i686-nacl binary directly.
toolchain_tuple = "x86_64-nacl"
}

@ -29,22 +29,21 @@ def _ExtractImportantEnvironment(output_of_set):
"""Extracts environment variables required for the toolchain to run from
a textual dump output by the cmd.exe 'set' command."""
envvars_to_save = (
'cipd_cache_dir', # needed by vpython
'homedrive', # needed by vpython
'homepath', # needed by vpython
'goma_.*', # TODO(scottmg): This is ugly, but needed for goma.
'cipd_cache_dir', # needed by vpython
'homedrive', # needed by vpython
'homepath', # needed by vpython
'include',
'lib',
'libpath',
'luci_context', # needed by vpython
'luci_context', # needed by vpython
'path',
'pathext',
'systemroot',
'temp',
'tmp',
'userprofile', # needed by vpython
'vpython_virtualenv_root' # needed by vpython
)
'userprofile', # needed by vpython
'vpython_virtualenv_root' # needed by vpython
)
env = {}
# This occasionally happens and leads to misleading SYSTEMROOT error messages
# if not caught here.
@ -256,9 +255,6 @@ def main():
include = ''
lib = ''
# TODO(scottmg|goma): Do we need an equivalent of
# ninja_use_custom_environment_files?
def relflag(s): # Make s relative to builddir when cwd and sdk on same drive.
try:
return os.path.relpath(s).replace('\\', '/')