From edaf3dd763564b0d1806cf24c20891032741557b Mon Sep 17 00:00:00 2001 From: Dan Stoza Date: Wed, 27 Jul 2016 15:05:38 -0700 Subject: [PATCH] Build SF executable with USE_HWC2 when needed The SurfaceFlinger executable wasn't picking up the USE_HWC2 flag when enabled by the TARGET_USES_HWC2 BoardConfig, causing a mismatch in the size of the SurfaceFlinger object. This fixes that by also passing USE_HWC2 when building the executable. Test: Cherry-pick from internal branch Bug: 30302693 Change-Id: I1e41e5f548d4b8329590a082d9b69155ba365be9 --- services/surfaceflinger/Android.mk | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/services/surfaceflinger/Android.mk b/services/surfaceflinger/Android.mk index f73be68e00..036fee660e 100644 --- a/services/surfaceflinger/Android.mk +++ b/services/surfaceflinger/Android.mk @@ -172,6 +172,10 @@ ifneq ($(ENABLE_CPUSETS),) LOCAL_CFLAGS += -DENABLE_CPUSETS endif +ifeq ($(TARGET_USES_HWC2),true) + LOCAL_CFLAGS += -DUSE_HWC2 +endif + LOCAL_SRC_FILES := \ main_surfaceflinger.cpp -- 2.11.0