summaryrefslogtreecommitdiffstats
path: root/jni
diff options
context:
space:
mode:
authorChih-Hung Hsieh <chh@google.com>2017-11-02 10:24:36 -0700
committerArne Coucheron <arco68@gmail.com>2018-11-10 23:57:54 +0100
commit23ccb99841bee49014176c37a894dd653429a3a8 (patch)
treed5f005201a2031a3e07d8802e1496e1a55d10a50 /jni
parent9cb8d8ffc5c783c5e73f141e31ba38b7099a7b3b (diff)
downloadandroid_packages_apps_Gallery2-23ccb99841bee49014176c37a894dd653429a3a8.tar.gz
android_packages_apps_Gallery2-23ccb99841bee49014176c37a894dd653429a3a8.tar.bz2
android_packages_apps_Gallery2-23ccb99841bee49014176c37a894dd653429a3a8.zip
Use -Werror in packages/apps/Gallery2
* Keep constant-conversion warnings to fix later. Bug: 66996870 Test: build with WITH_TIDY=1 Change-Id: Ib93e954e025fd2f0202960df20583b50b97fce7f
Diffstat (limited to 'jni')
-rw-r--r--jni/Android.mk11
1 files changed, 10 insertions, 1 deletions
diff --git a/jni/Android.mk b/jni/Android.mk
index 1a45a90be..28c6d78b7 100644
--- a/jni/Android.mk
+++ b/jni/Android.mk
@@ -1,8 +1,16 @@
LOCAL_PATH:= $(call my-dir)
+Gallery2_jni_cflags := \
+ -Wall -Wextra -Werror \
+ -Wno-error=constant-conversion \
+ -Wno-unused-parameter \
+
+# to fix implicit conversion from 'int' to 'char', (255 to -1, 128 to -128)
+
include $(CLEAR_VARS)
LOCAL_CFLAGS += -DEGL_EGLEXT_PROTOTYPES
+LOCAL_CFLAGS += $(Gallery2_jni_cflags)
LOCAL_SRC_FILES := jni_egl_fence.cpp
@@ -44,7 +52,8 @@ LOCAL_SRC_FILES := filters/gradient.c \
filters/tinyplanet.cc \
filters/kmeans.cc
-LOCAL_CFLAGS += -ffast-math -O3 -funroll-loops
+LOCAL_CFLAGS += -ffast-math -O3 -funroll-loops
+LOCAL_CFLAGS += $(Gallery2_jni_cflags)
LOCAL_LDLIBS := -llog -ljnigraphics
LOCAL_ARM_MODE := arm