android: dri: correctly set HAVE_LIBDRM
authorEmil Velikov <emil.l.velikov@gmail.com>
Tue, 7 Jul 2015 15:04:27 +0000 (16:04 +0100)
committerEmil Velikov <emil.l.velikov@gmail.com>
Wed, 22 Jul 2015 15:35:25 +0000 (16:35 +0100)
Set the macro if we're not building swrast alone.

Cc: Eric Anholt <eric@anholt.net>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Chih-Wei Huang <cwhuang@linux.org.tw>
src/gallium/targets/dri/Android.mk

index 5ba129b7961b6fd6efbdb28ac019d9df7458f662..bccc91aa526dbcbb36086d10e328af85c8ab52eb 100644 (file)
@@ -35,17 +35,15 @@ endif
 
 LOCAL_SRC_FILES := target.c
 
-LOCAL_CFLAGS := -DDRI_TARGET -DHAVE_LIBDRM
+LOCAL_CFLAGS := -DDRI_TARGET
 
 LOCAL_SHARED_LIBRARIES := \
        libdl \
        libglapi \
        libexpat \
 
-# swrast only?
-ifeq ($(MESA_GPU_DRIVERS),swrast)
-LOCAL_CFLAGS += -D__NOT_HAVE_DRM_H
-else
+ifneq ($(filter-out swrast,$(MESA_GPU_DRIVERS)),)
+LOCAL_CFLAGS += -DHAVE_LIBDRM
 LOCAL_SHARED_LIBRARIES += libdrm
 endif