@@ -1,5 +1,5 @@
#
-# Copyright © 2011 Intel Corporation
+# Copyright © 2011-2012 Intel Corporation
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the "Software"),
@@ -28,11 +28,16 @@ LIBDRM_TOP := $(LOCAL_PATH)
# Import variables LIBDRM_FILES, LIBDRM_HEADERS
include $(LOCAL_PATH)/Makefile.sources
+# Import variables LIBDRM_INCLUDE_HEADERS, LIBDRM_INCLUDE_VMWGFX_HEADERS
+include $(LOCAL_PATH)/include/drm/Makefile.sources
LOCAL_MODULE := libdrm
LOCAL_MODULE_TAGS := optional
LOCAL_SRC_FILES := $(LIBDRM_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+ $(LOCAL_PATH) \
+ $(LOCAL_PATH)/include/drm
LOCAL_C_INCLUDES := \
$(LIBDRM_TOP)/include/drm
@@ -40,6 +45,12 @@ LOCAL_C_INCLUDES := \
LOCAL_CFLAGS := \
-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+LOCAL_COPY_HEADERS := \
+ $(LIBDRM_HEADERS) \
+ $(addprefix include/drm/,$(LIBDRM_INCLUDE_HEADERS)) \
+ $(addprefix include/drm/,$(LIBDRM_INCLUDE_VMWGFX_HEADERS))
+
+LOCAL_COPY_HEADERS_TO := libdrm
include $(BUILD_SHARED_LIBRARY)
include $(LOCAL_PATH)/intel/Android.mk
@@ -33,6 +33,8 @@ LOCAL_MODULE_TAGS := optional
LOCAL_SHARED_LIBRARIES := libdrm
LOCAL_SRC_FILES := $(LIBDRM_INTEL_FILES)
+LOCAL_EXPORT_C_INCLUDE_DIRS += \
+ $(LOCAL_PATH)/intel
LOCAL_C_INCLUDES := \
$(LIBDRM_TOP) \
@@ -43,6 +45,9 @@ LOCAL_C_INCLUDES := \
LOCAL_CFLAGS := \
-DHAVE_LIBDRM_ATOMIC_PRIMITIVES=1
+LOCAL_COPY_HEADERS := $(LIBDRM_INTEL_HEADERS)
+LOCAL_COPY_HEADERS_TO := libdrm
+
LOCAL_SHARED_LIBRARIES := \
libdrm \
libpciaccess