Dist only if the goal is to be built

Change-Id: I1b794f36a6dc39ce68cc990b967d2d55118c92ca
http://b/issue?id=2635603
This commit is contained in:
Ying Wang 2010-04-28 12:59:51 -07:00
parent 19f5d7db96
commit a37a2cb231
2 changed files with 11 additions and 2 deletions

View File

@ -986,8 +986,12 @@ $(INSTALLED_FILES_FILE): $(INSTALLED_SYSTEMIMAGE)
.PHONY: installed-file-list
installed-file-list: $(INSTALLED_FILES_FILE)
ifneq ($(filter sdk,$(MAKECMDGOALS)),)
$(call dist-for-goals, sdk, $(INSTALLED_FILES_FILE))
endif
ifneq ($(filter sdk_addon,$(MAKECMDGOALS)),)
$(call dist-for-goals, sdk_addon, $(INSTALLED_FILES_FILE))
endif
# -----------------------------------------------------------------
# A zip of the tests that are built when running "make tests".

View File

@ -691,6 +691,8 @@ droidcore: files \
.PHONY: droid tests
droid tests: droidcore
# Dist for droid if droid is among the cmd goals, or no cmd goal is given.
ifneq ($(filter droid,$(MAKECMDGOALS))$(filter ||,|$(filter-out $(INTERNAL_MODIFIER_TARGETS),$(MAKECMDGOALS))|),)
$(call dist-for-goals, droid, \
$(INTERNAL_UPDATE_PACKAGE_TARGET) \
$(INTERNAL_OTA_PACKAGE_TARGET) \
@ -709,7 +711,7 @@ ifeq ($(EMMA_INSTRUMENT),true)
$(call dist-for-goals, droid, \
$(EMMA_META_ZIP) \
)
endif
endif # EMMA_INSTRUMENT
# Tests are installed in userdata.img. If we're building the tests
# variant, copy it for "make tests dist". Also copy a zip of the
@ -720,7 +722,8 @@ $(call dist-for-goals, droid, \
$(INSTALLED_USERDATAIMAGE_TARGET) \
$(BUILT_TESTS_ZIP_PACKAGE) \
)
endif
endif # tests
endif # droid in $(MAKECMDGOALS)
.PHONY: docs
docs: $(ALL_DOCS)
@ -728,10 +731,12 @@ docs: $(ALL_DOCS)
.PHONY: sdk
ALL_SDK_TARGETS := $(INTERNAL_SDK_TARGET)
sdk: $(ALL_SDK_TARGETS)
ifneq ($(filter sdk,$(MAKECMDGOALS)),)
$(call dist-for-goals,sdk, \
$(ALL_SDK_TARGETS) \
$(SYMBOLS_ZIP) \
)
endif
.PHONY: samplecode
sample_MODULES := $(sort $(call get-tagged-modules,samples))