DescriptionAdd gomadir for GYP_DEFINES
If gomadir is specified in GYP_DEFINES (and use_goma=1, which is default),
it will start goma compiler_proxy and generates build rules file to use goma,
so no need to fix PATH when running ninja (or make).
Note: gomadir should not be in PATH with this use case.
Currently, it is for ninja (and for make in some cases).
If ANDROID_GOMA_WRAPPER is defined, its directory will be used as
gomadir's default (for backward compatibility).
Example 1
$ GYP_DEFINES=gomadir=/path/to/goma build/gyp_chromium
build.ninja will have
cc = /path/to/goma/gomacc gcc
cxx = /path/to/goma/gomacc g++
user can run ninja without setting PATH or so.
$ ninja -C out/Release -j100
It doesn't generate goma-ready Makefile yet in this case
(because no CC in make_global_settings)
Example 2
$ GYP_DEFINES="clang=1 gomadir=/path/to/goma" build/gyp_chromium
(no need to set CC/CXX at this stage)
build.ninja will have
cc = /path/to/goma/gomacc ../../third_party/llvm-build/Release+Asserts/bin/clang
cxx = /path/to/goma/gomacc ../../third_party/llvm-build/Release+Asserts/bin/clang++
user can run ninja without setting PATH or so.
$ ninja -C out/Release -j100
Makefile will be
ifneq (,$(filter $(origin CC), undefined default))
CC = $(abspath /usr/local/google/home/ukai/src/goma/client/out/Release/gomacc)
$(abspath third_party/llvm-build/Release+Asserts/bin/clang)
endif
ifneq (,$(filter $(origin CXX), undefined default))
CXX = $(abspath /usr/local/google/home/ukai/src/goma/client/out/Release/gomacc)
$(abspath third_party/llvm-build/Release+Asserts/bin/clang++)
endif
..
CC.target = $(CC)
CXX.target = $(CXX)
user can run make without setting PATH or so.
$ make BUILDTYPE=Release -j100
R=iannucci@chromium.org,thakis@chromium.org,michaelbai@google.com,peter@chromium.org
BUG=173686
Patch Set 1 #
Total comments: 6
Patch Set 2 : fix /dev/null -> NUL on Windows #Messages
Total messages: 8 (0 generated)
|