# -*-makefile-*-
+# Import mesa_dri_common_*
+include ../common/Makefile.sources
+
COMMON_GALLIUM_SOURCES = \
- ../common/utils.c \
- ../common/vblank.c \
- ../common/dri_util.c \
- ../common/xmlconfig.c
+ $(addprefix ../common/, $(mesa_dri_common_gallium_SOURCES))
-COMMON_SOURCES = $(COMMON_GALLIUM_SOURCES) \
- ../common/texmem.c \
- ../common/drirenderbuffer.c
+COMMON_SOURCES = \
+ $(addprefix ../common/, $(mesa_dri_common_SOURCES))
INCLUDES = $(SHARED_INCLUDES) $(EXPAT_INCLUDES)
### Include directories
SHARED_INCLUDES = \
-I. \
- -I$(TOP)/src/mesa/drivers/dri/common \
-Iserver \
- -I$(TOP)/include \
- -I$(TOP)/src/mapi \
- -I$(TOP)/src/mesa \
- -I$(TOP)/src/egl/main \
- -I$(TOP)/src/egl/drivers/dri \
+ $(addprefix -I$(TOP)/, $(mesa_dri_common_INCLUDES)) \
$(LIBDRM_CFLAGS)
INCLUDES += $(API_DEFINES)
--- /dev/null
+mesa_dri_common_gallium_SOURCES := \
+ utils.c \
+ vblank.c \
+ dri_util.c \
+ xmlconfig.c
+
+mesa_dri_common_SOURCES := \
+ $(mesa_dri_common_gallium_SOURCES) \
+ texmem.c \
+ drirenderbuffer.c
+
+# Paths are relative to MESA_TOP.
+mesa_dri_common_INCLUDES := \
+ include \
+ src/egl/drivers/dri \
+ src/egl/main \
+ src/mapi \
+ src/mesa \
+ src/mesa/drivers/dri/common