radeon/llvm: Set End of Program bit on RAT instructions
[mesa.git] / src / gallium / targets / Makefile.dri
index 16477e349630b30b55fba8a711cb60d6f75c797b..5b6676d655e196e44c1e43d252b6351c9d3347b8 100644 (file)
@@ -1,19 +1,22 @@
 # -*-makefile-*-
 
+
+ifeq ($(MESA_LLVM),1)
+LDFLAGS += $(LLVM_LDFLAGS)
+DRIVER_EXTRAS = $(LLVM_LIBS)
+endif
+
 MESA_MODULES = \
        $(TOP)/src/mesa/libmesagallium.a \
        $(GALLIUM_AUXILIARIES)
 
 COMMON_GALLIUM_SOURCES = \
         $(TOP)/src/mesa/drivers/dri/common/utils.c \
-        $(TOP)/src/mesa/drivers/dri/common/vblank.c \
         $(TOP)/src/mesa/drivers/dri/common/dri_util.c \
         $(TOP)/src/mesa/drivers/dri/common/xmlconfig.c
 
 COMMON_SOURCES = $(COMMON_GALLIUM_SOURCES) \
-        $(TOP)/src/mesa/drivers/common/driverfuncs.c \
-        $(TOP)/src/mesa/drivers/dri/common/texmem.c \
-        $(TOP)/src/mesa/drivers/dri/common/drirenderbuffer.c
+        $(TOP)/src/mesa/drivers/common/driverfuncs.c
 
 COMMON_BM_SOURCES = \
        $(TOP)/src/mesa/drivers/dri/common/dri_bufmgr.c \
@@ -33,13 +36,13 @@ SHARED_INCLUDES = \
        -Iserver \
        -I$(TOP)/include \
        -I$(TOP)/include/GL/internal \
+       -I$(TOP)/src/mapi \
        -I$(TOP)/src/gallium/include \
        -I$(TOP)/src/gallium/auxiliary \
        -I$(TOP)/src/gallium/drivers \
-       -I$(TOP)/src/gallium/winsys/common \
+       -I$(TOP)/src/gallium/winsys \
        -I$(TOP)/src/mesa \
        -I$(TOP)/src/mesa/main \
-       -I$(TOP)/src/mesa/glapi \
        -I$(TOP)/src/mesa/math \
        -I$(TOP)/src/mesa/transform \
        -I$(TOP)/src/mesa/shader \
@@ -49,6 +52,8 @@ SHARED_INCLUDES = \
        -I$(TOP)/src/egl/drivers/dri \
        $(LIBDRM_CFLAGS)
 
+LIBNAME_STAGING = $(TOP)/$(LIB_DIR)/gallium/$(LIBNAME)
+
 
 ##### RULES #####
 
@@ -61,22 +66,22 @@ SHARED_INCLUDES = \
 
 ##### TARGETS #####
 
-default: depend symlinks $(TOP)/$(LIB_DIR)/gallium/$(LIBNAME)
+default: depend symlinks $(TOP)/$(LIB_DIR)/gallium $(LIBNAME) $(LIBNAME_STAGING)
 
 $(LIBNAME): $(OBJECTS) $(MESA_MODULES) $(PIPE_DRIVERS) Makefile \
-               $(TOP)/src/mesa/drivers/dri/Makefile.template $(TOP)/src/mesa/drivers/dri/common/dri_test.o
-       $(MKLIB) -o $@.tmp -noprefix -linker '$(CC)' -ldflags '$(LDFLAGS)' \
+               $(TOP)/src/mesa/drivers/dri/common/dri_test.o
+       $(MKLIB) -o $@.tmp -noprefix -linker '$(CXX)' -ldflags '$(LDFLAGS)' \
                $(OBJECTS) $(PIPE_DRIVERS) \
                 -Wl,--start-group $(MESA_MODULES) -Wl,--end-group \
-                 $(DRI_LIB_DEPS) $(DRIVER_EXTRAS)
-       $(CC) $(CFLAGS) -o $@.test $(TOP)/src/mesa/drivers/dri/common/dri_test.o $@.tmp $(DRI_LIB_DEPS)
+                 $(GALLIUM_DRI_LIB_DEPS) $(DRIVER_EXTRAS)
+       $(CXX) $(CFLAGS) -o $@.test $(TOP)/src/mesa/drivers/dri/common/dri_test.o $@.tmp $(GALLIUM_DRI_LIB_DEPS) $(LDFLAGS);
        @rm -f $@.test
        mv -f $@.tmp $@
 
 $(TOP)/$(LIB_DIR)/gallium:
        mkdir -p $@
 
-$(TOP)/$(LIB_DIR)/gallium/$(LIBNAME): $(LIBNAME) $(TOP)/$(LIB_DIR)/gallium
+$(LIBNAME_STAGING): $(LIBNAME)
        $(INSTALL) $(LIBNAME) $(TOP)/$(LIB_DIR)/gallium
 
 depend: $(C_SOURCES) $(ASM_SOURCES) $(SYMLINKS)