From ae4a02e746d3e46c5700686c2b2d552a5903c333 Mon Sep 17 00:00:00 2001 From: Andrew Sutherland Date: Sat, 2 Jun 2012 23:42:54 -0500 Subject: [PATCH] copybit: fix ion define Change-Id: I9d4005b30f16aa191d3eb4c8455e5dbe198d5607 --- libcopybit/Android.mk | 8 +++++--- libgralloc/ashmemalloc.h | 2 ++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/libcopybit/Android.mk b/libcopybit/Android.mk index e6c6d2a..d1a8241 100644 --- a/libcopybit/Android.mk +++ b/libcopybit/Android.mk @@ -19,6 +19,11 @@ LOCAL_PATH:= $(call my-dir) ifeq ($(TARGET_USES_C2D_COMPOSITION),true) include $(CLEAR_VARS) + + ifeq ($(TARGET_USES_ION),true) + LOCAL_CFLAGS += -DUSE_ION + endif + LOCAL_PRELINK_MODULE := false LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/hw LOCAL_SHARED_LIBRARIES := liblog libdl libcutils libmemalloc libutils @@ -28,9 +33,6 @@ ifeq ($(TARGET_USES_C2D_COMPOSITION),true) LOCAL_CFLAGS += -DCOPYBIT_Z180=1 -DC2D_SUPPORT_DISPLAY=1 LOCAL_MODULE_TAGS := optional include $(BUILD_SHARED_LIBRARY) -ifeq ($(TARGET_USES_ION),true) - LOCAL_CFLAGS += -DUSE_ION -endif else ifneq ($(TARGET_BOARD_PLATFORM),msm7x30) ifeq ($(TARGET_BOARD_PLATFORM),qsd8k) diff --git a/libgralloc/ashmemalloc.h b/libgralloc/ashmemalloc.h index 051dcd1..fb85991 100644 --- a/libgralloc/ashmemalloc.h +++ b/libgralloc/ashmemalloc.h @@ -31,7 +31,9 @@ #define GRALLOC_ASHMEMALLOC_H #include "memalloc.h" +#ifdef USE_ION #include +#endif namespace gralloc { class AshmemAlloc : public IMemAlloc {