Chromium Code Reviews| Index: native_client_sdk/src/tools/common.mk |
| diff --git a/native_client_sdk/src/tools/common.mk b/native_client_sdk/src/tools/common.mk |
| index 1a340fb72bf38ed3e896ad6bca33184461e90df8..909fcf6f674ccc22e02af421e960ab38449e13b5 100644 |
| --- a/native_client_sdk/src/tools/common.mk |
| +++ b/native_client_sdk/src/tools/common.mk |
| @@ -69,6 +69,7 @@ CP:=python $(NACL_SDK_ROOT)/tools/oshelpers.py cp |
| MKDIR:=python $(NACL_SDK_ROOT)/tools/oshelpers.py mkdir |
| MV:=python $(NACL_SDK_ROOT)/tools/oshelpers.py mv |
| RM:=python $(NACL_SDK_ROOT)/tools/oshelpers.py rm |
| +WHICH:=python $(NACL_SDK_ROOT)/tools/oshelpers.py which |
| # |
| @@ -107,8 +108,25 @@ endef |
| # The target for all versions |
| # |
| USABLE_TOOLCHAINS=$(filter $(OSNAME) newlib glibc pnacl,$(VALID_TOOLCHAINS)) |
| + |
| +ifeq (1,$(NO_HOST_BUILDS)) |
| +USABLE_TOOLCHAINS:=$(filter-out $(OSNAME),$(USABLE_TOOLCHAINS)) |
|
noelallen_use_chromium
2013/02/09 00:55:57
$(warning Skipping host builds)
|
| +endif |
| + |
| +.PHONY: CHECK_FOR_CL_EXE |
| +CHECK_FOR_CL_EXE: |
| +ifneq (,$(findstring win,$(USABLE_TOOLCHAINS))) |
| +ifeq (,$(findstring cl.exe,$(shell $(WHICH) cl.exe))) |
| + $(warning To skip the host build use:) |
| + $(warning "make all_versions NO_HOST_BUILDS=1") |
| + $(error Unable to find cl.exe in PATH while building Windows host build) |
| +endif |
| +endif |
|
noelallen_use_chromium
2013/02/09 00:55:57
Won't this generate an empty target warning/error
|
| + |
| $(foreach tool,$(USABLE_TOOLCHAINS),$(eval $(call TOOLCHAIN_RULE,$(tool),$(dep)))) |
| -all_versions: $(TOOLCHAIN_LIST) |
| + |
| +.PHONY: all_versions |
| +all_versions: CHECK_FOR_CL_EXE $(TOOLCHAIN_LIST) |
| # |
| # Target to remove temporary files |