Merge "lint support."
This commit is contained in:
commit
3caa951610
4 changed files with 14 additions and 0 deletions
|
@ -125,6 +125,7 @@ LOCAL_ADDRESS_SANITIZER:=
|
|||
# Whether to keep the generated R/Manifest classes when building static Java library
|
||||
# with Android resource. false(default), or true
|
||||
LOCAL_KEEP_R_CLASS_IN_STATIC_JAVA_LIBRARY:=
|
||||
LOCAL_LINT_FLAGS:=
|
||||
|
||||
# Trim MAKEFILE_LIST so that $(call my-dir) doesn't need to
|
||||
# iterate over thousands of entries every time.
|
||||
|
|
|
@ -295,6 +295,7 @@ LLVM_RS_CC := $(HOST_OUT_EXECUTABLES)/llvm-rs-cc$(HOST_EXECUTABLE_SUFFIX)
|
|||
LLVM_RS_LINK := $(HOST_OUT_EXECUTABLES)/llvm-rs-link$(HOST_EXECUTABLE_SUFFIX)
|
||||
DEXOPT := $(HOST_OUT_EXECUTABLES)/dexopt$(HOST_EXECUTABLE_SUFFIX)
|
||||
DEXPREOPT := dalvik/tools/dex-preopt
|
||||
LINT := prebuilts/sdk/tools/lint
|
||||
|
||||
# ACP is always for the build OS, not for the host OS
|
||||
ACP := $(BUILD_OUT_EXECUTABLES)/acp$(BUILD_EXECUTABLE_SUFFIX)
|
||||
|
|
|
@ -817,6 +817,8 @@ $(call dist-for-goals,sdk win_sdk, \
|
|||
)
|
||||
endif
|
||||
|
||||
.PHONY: lintall
|
||||
|
||||
.PHONY: samplecode
|
||||
sample_MODULES := $(sort $(call get-tagged-modules,samples))
|
||||
sample_APKS_DEST_PATH := $(TARGET_COMMON_OUT_ROOT)/samples
|
||||
|
|
|
@ -407,4 +407,14 @@ endif
|
|||
|
||||
PACKAGES := $(PACKAGES) $(LOCAL_PACKAGE_NAME)
|
||||
|
||||
# Lint phony targets
|
||||
.PHONY: lint-$(LOCAL_PACKAGE_NAME)
|
||||
lint-$(LOCAL_PACKAGE_NAME): PRIVATE_PATH := $(LOCAL_PATH)
|
||||
lint-$(LOCAL_PACKAGE_NAME): PRIVATE_LINT_FLAGS := $(LOCAL_LINT_FLAGS)
|
||||
lint-$(LOCAL_PACKAGE_NAME) :
|
||||
@echo lint $(PRIVATE_PATH)
|
||||
$(LINT) $(PRIVATE_LINT_FLAGS) $(PRIVATE_PATH)
|
||||
|
||||
lintall : lint-$(LOCAL_PACKAGE_NAME)
|
||||
|
||||
endif # skip_definition
|
||||
|
|
Loading…
Reference in a new issue