OSDN Git Service

Add libgralloc_drm library to export headers to mesa
authorRob Herring <robh@kernel.org>
Thu, 8 Jun 2017 20:45:53 +0000 (15:45 -0500)
committerRob Herring <robh@kernel.org>
Thu, 8 Jun 2017 20:45:53 +0000 (15:45 -0500)
Mesa mainline depends on libgralloc_drm shared library for importing
include paths. Add a dummy library for this purpose. This gets mesa master
building without any additional patches. Patches are still needed for
proper functioning.

Change-Id: Ib9577d0b7af028091f0c6f61d8dd2340cc8425d0
Signed-off-by: Rob Herring <robh@kernel.org>
Android.mk
gralloc_drm_handle.h

index 14d0b58..083a73f 100644 (file)
@@ -38,3 +38,12 @@ LOCAL_MODULE := gralloc.gbm
 LOCAL_MODULE_TAGS := optional
 LOCAL_MODULE_RELATIVE_PATH := hw
 include $(BUILD_SHARED_LIBRARY)
+
+include $(CLEAR_VARS)
+
+LOCAL_EXPORT_C_INCLUDE_DIRS := \
+       $(LOCAL_PATH)
+
+LOCAL_MODULE := libgralloc_drm
+LOCAL_MODULE_TAGS := optional
+include $(BUILD_SHARED_LIBRARY)
index cd69a4c..9edf22a 100644 (file)
@@ -86,6 +86,11 @@ static inline int gralloc_drm_get_prime_fd(buffer_handle_t _handle)
        return (handle) ? handle->prime_fd : -1;
 }
 
+static inline int gralloc_drm_get_gem_handle(buffer_handle_t handle)
+{
+       return 0; /* Not supported, return invalid handle. */
+}
+
 #ifdef __cplusplus
 }
 #endif