Enable -Wall/-Werror with LOCAL_RENDERSCRIPT_FLAGS.
Change-Id: Ia2a058e6711839d89072c2e96f0c60aa4cedda6b
This commit is contained in:
parent
bfcdc63c22
commit
914f7a2990
3 changed files with 8 additions and 0 deletions
|
@ -107,6 +107,7 @@ LOCAL_MANIFEST_FILE:=
|
|||
LOCAL_RENDERSCRIPT_INCLUDES:=
|
||||
LOCAL_RENDERSCRIPT_INCLUDES_OVERRIDE:=
|
||||
LOCAL_RENDERSCRIPT_CC:=
|
||||
LOCAL_RENDERSCRIPT_FLAGS:=
|
||||
LOCAL_RENDERSCRIPT_TARGET_API:=
|
||||
LOCAL_BUILD_HOST_DEX:=
|
||||
LOCAL_DEX_PREOPT:= # '',true,false,nostripping
|
||||
|
|
|
@ -802,6 +802,7 @@ $(hide) $(PRIVATE_RS_CC) \
|
|||
-d $(PRIVATE_RS_OUTPUT_DIR) \
|
||||
-a $@ -MD \
|
||||
$(addprefix -target-api , $(PRIVATE_RS_TARGET_API)) \
|
||||
$(PRIVATE_RS_FLAGS) \
|
||||
$(foreach inc,$(PRIVATE_RS_INCLUDES),$(addprefix -I , $(inc))) \
|
||||
$(PRIVATE_RS_SOURCE_FILES)
|
||||
#$(hide) $(LLVM_RS_LINK) \
|
||||
|
|
|
@ -152,6 +152,11 @@ ifeq ($(LOCAL_RENDERSCRIPT_CC),)
|
|||
LOCAL_RENDERSCRIPT_CC := $(LLVM_RS_CC)
|
||||
endif
|
||||
|
||||
# Turn on all warnings and warnings as errors for RS compiles.
|
||||
# This can be disabled with LOCAL_RENDERSCRIPT_FLAGS := -Wno-error
|
||||
renderscript_flags := -Wall -Werror
|
||||
renderscript_flags += $(LOCAL_RENDERSCRIPT_FLAGS)
|
||||
|
||||
# prepend the RenderScript system include path
|
||||
ifneq ($(filter-out current,$(LOCAL_SDK_VERSION)),)
|
||||
LOCAL_RENDERSCRIPT_INCLUDES := \
|
||||
|
@ -171,6 +176,7 @@ endif
|
|||
|
||||
$(RenderScript_file_stamp): PRIVATE_RS_INCLUDES := $(LOCAL_RENDERSCRIPT_INCLUDES)
|
||||
$(RenderScript_file_stamp): PRIVATE_RS_CC := $(LOCAL_RENDERSCRIPT_CC)
|
||||
$(RenderScript_file_stamp): PRIVATE_RS_FLAGS := $(renderscript_flags)
|
||||
$(RenderScript_file_stamp): PRIVATE_RS_SOURCE_FILES := $(renderscript_sources_fullpath)
|
||||
# By putting the generated java files into $(LOCAL_INTERMEDIATE_SOURCE_DIR), they will be
|
||||
# automatically found by the java compiling function transform-java-to-classes.jar.
|
||||
|
|
Loading…
Reference in a new issue