Permalink
Browse files

Allow usage of kernel headers

Change-Id: I9fa11bd72fa632551679d8b13a89cccbaae53e77
  • Loading branch information...
1 parent 920246a commit d6eb46820f4d2af59149d81891403fd6a1f277b7 @arco committed Apr 30, 2013
View
8 common.mk
@@ -41,3 +41,11 @@ endif
ifeq ($(TARGET_QCOM_HDMI_RESOLUTION_AUTO),true)
common_flags += -DFORCE_AUTO_RESOLUTION
endif
+
+common_deps :=
+kernel_includes :=
+
+ifneq ($(TARGET_KERNEL_SOURCE),)
+ common_deps += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/
+ kernel_includes += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/include
+endif
View
3 libcopybit/Android.mk
@@ -19,9 +19,10 @@ include $(CLEAR_VARS)
LOCAL_MODULE := copybit.$(TARGET_BOARD_PLATFORM)
LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/hw
LOCAL_MODULE_TAGS := optional
-LOCAL_C_INCLUDES := $(common_includes)
+LOCAL_C_INCLUDES := $(common_includes) $(kernel_includes)
LOCAL_SHARED_LIBRARIES := $(common_libs) libdl libmemalloc
LOCAL_CFLAGS := $(common_flags) -DLOG_TAG=\"qdcopybit\"
+LOCAL_ADDITIONAL_DEPENDENCIES := $(common_deps)
ifeq ($(TARGET_USES_C2D_COMPOSITION),true)
LOCAL_CFLAGS += -DCOPYBIT_Z180=1 -DC2D_SUPPORT_DISPLAY=1
View
3 libexternal/Android.mk
@@ -5,9 +5,10 @@ include $(CLEAR_VARS)
LOCAL_MODULE := libexternal
LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)
LOCAL_MODULE_TAGS := optional
-LOCAL_C_INCLUDES := $(common_includes)
+LOCAL_C_INCLUDES := $(common_includes) $(kernel_includes)
LOCAL_SHARED_LIBRARIES := $(common_libs) liboverlay
LOCAL_CFLAGS := $(common_flags) -DLOG_TAG=\"qdexternal\"
+LOCAL_ADDITIONAL_DEPENDENCIES := $(common_deps)
LOCAL_SRC_FILES := external.cpp
include $(BUILD_SHARED_LIBRARY)
View
1 libgenlock/Android.mk
@@ -10,6 +10,7 @@ LOCAL_CFLAGS := $(common_flags) -DLOG_TAG=\"qdgenlock\"
ifneq ($(TARGET_BOARD_PLATFORM), msm8960)
LOCAL_CFLAGS += -DUSE_GENLOCK
endif
+LOCAL_ADDITIONAL_DEPENDENCIES := $(common_deps)
LOCAL_SRC_FILES := genlock.cpp
include $(BUILD_SHARED_LIBRARY)
View
6 libgralloc/Android.mk
@@ -20,10 +20,11 @@ include $(CLEAR_VARS)
LOCAL_MODULE := gralloc.$(TARGET_BOARD_PLATFORM)
LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/hw
LOCAL_MODULE_TAGS := optional
-LOCAL_C_INCLUDES := $(common_includes)
+LOCAL_C_INCLUDES := $(common_includes) $(kernel_includes)
LOCAL_SHARED_LIBRARIES := $(common_libs) libmemalloc libgenlock
LOCAL_SHARED_LIBRARIES += libqdutils libGLESv1_CM
LOCAL_CFLAGS := $(common_flags) -DLOG_TAG=\"qdgralloc\"
+LOCAL_ADDITIONAL_DEPENDENCIES := $(common_deps) $(kernel_deps)
LOCAL_SRC_FILES := gpu.cpp gralloc.cpp framebuffer.cpp mapper.cpp
include $(BUILD_SHARED_LIBRARY)
@@ -33,9 +34,10 @@ include $(CLEAR_VARS)
LOCAL_MODULE := libmemalloc
LOCAL_MODULE_TAGS := optional
-LOCAL_C_INCLUDES := $(common_includes)
+LOCAL_C_INCLUDES := $(common_includes) $(kernel_includes)
LOCAL_SHARED_LIBRARIES := $(common_libs) libgenlock
LOCAL_CFLAGS := $(common_flags) -DLOG_TAG=\"qdmemalloc\"
+LOCAL_ADDITIONAL_DEPENDENCIES := $(common_deps) $(kernel_deps)
LOCAL_SRC_FILES := alloc_controller.cpp
ifeq ($(TARGET_USES_ION),true)
LOCAL_SRC_FILES += ionalloc.cpp
View
3 libhwcomposer/Android.mk
@@ -5,11 +5,12 @@ include $(CLEAR_VARS)
LOCAL_MODULE := hwcomposer.$(TARGET_BOARD_PLATFORM)
LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/hw
LOCAL_MODULE_TAGS := optional
-LOCAL_C_INCLUDES := $(common_includes)
+LOCAL_C_INCLUDES := $(common_includes) $(kernel_includes)
LOCAL_SHARED_LIBRARIES := $(common_libs) libEGL liboverlay libgenlock \
libexternal libqdutils libhardware_legacy \
libdl libmemalloc libqservice
LOCAL_CFLAGS := $(common_flags) -DLOG_TAG=\"qdhwcomposer\"
+LOCAL_ADDITIONAL_DEPENDENCIES := $(common_deps)
LOCAL_SRC_FILES := hwc.cpp \
hwc_video.cpp \
hwc_utils.cpp \
View
3 liboverlay/Android.mk
@@ -5,9 +5,10 @@ include $(CLEAR_VARS)
LOCAL_MODULE := liboverlay
LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)
LOCAL_MODULE_TAGS := optional
-LOCAL_C_INCLUDES := $(common_includes)
+LOCAL_C_INCLUDES := $(common_includes) $(kernel_includes)
LOCAL_SHARED_LIBRARIES := $(common_libs) libqdutils libmemalloc
LOCAL_CFLAGS := $(common_flags) -DLOG_TAG=\"qdoverlay\"
+LOCAL_ADDITIONAL_DEPENDENCIES := $(common_deps)
LOCAL_SRC_FILES := \
overlay.cpp \
overlayCtrl.cpp \
View
3 libqdutils/Android.mk
@@ -5,8 +5,9 @@ include $(CLEAR_VARS)
LOCAL_MODULE := libqdutils
LOCAL_MODULE_TAGS := optional
LOCAL_SHARED_LIBRARIES := $(common_libs)
-LOCAL_C_INCLUDES := $(common_includes)
+LOCAL_C_INCLUDES := $(common_includes) $(kernel_includes)
LOCAL_CFLAGS := $(common_flags) -DLOG_TAG=\"qdutils\"
+LOCAL_ADDITIONAL_DEPENDENCIES := $(common_deps)
LOCAL_SRC_FILES := profiler.cpp mdp_version.cpp \
idle_invalidator.cpp
View
3 libqservice/Android.mk
@@ -5,9 +5,10 @@ include $(CLEAR_VARS)
LOCAL_MODULE := libqservice
LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)
LOCAL_MODULE_TAGS := optional
-LOCAL_C_INCLUDES := $(common_includes)
+LOCAL_C_INCLUDES := $(common_includes) $(kernel_includes)
LOCAL_SHARED_LIBRARIES := $(common_libs) libexternal libbinder
LOCAL_CFLAGS := $(common_flags) -DLOG_TAG=\"qdqservice\"
+LOCAL_ADDITIONAL_DEPENDENCIES := $(common_deps)
LOCAL_SRC_FILES := QService.cpp \
IQService.cpp

0 comments on commit d6eb468

Please sign in to comment.