summaryrefslogtreecommitdiff
path: root/src/gallium
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/Makefile2
-rw-r--r--src/gallium/drivers/softpipe/sp_draw_arrays.c10
-rw-r--r--src/gallium/state_trackers/Makefile2
-rw-r--r--src/gallium/winsys/drm/Makefile16
-rw-r--r--src/gallium/winsys/drm/Makefile.template14
-rw-r--r--src/gallium/winsys/drm/intel/gem/Makefile.template6
-rw-r--r--src/gallium/winsys/drm/nouveau/common/Makefile.template6
-rw-r--r--src/gallium/winsys/egl_xlib/Makefile2
-rw-r--r--src/gallium/winsys/xlib/Makefile10
9 files changed, 38 insertions, 30 deletions
diff --git a/src/gallium/Makefile b/src/gallium/Makefile
index c7b594d084..875314f6c3 100644
--- a/src/gallium/Makefile
+++ b/src/gallium/Makefile
@@ -2,7 +2,7 @@ TOP = ../..
include $(TOP)/configs/current
-SUBDIRS = auxiliary drivers state_trackers
+SUBDIRS = $(GALLIUM_DIRS)
# Note winsys/ needs to be built after src/mesa
diff --git a/src/gallium/drivers/softpipe/sp_draw_arrays.c b/src/gallium/drivers/softpipe/sp_draw_arrays.c
index ecc9d00319..7e3a25e34b 100644
--- a/src/gallium/drivers/softpipe/sp_draw_arrays.c
+++ b/src/gallium/drivers/softpipe/sp_draw_arrays.c
@@ -47,16 +47,22 @@ static void
softpipe_map_constant_buffers(struct softpipe_context *sp)
{
struct pipe_winsys *ws = sp->pipe.winsys;
- uint i;
+ uint i, size;
+
for (i = 0; i < PIPE_SHADER_TYPES; i++) {
if (sp->constants[i].buffer && sp->constants[i].buffer->size)
sp->mapped_constants[i] = ws->buffer_map(ws, sp->constants[i].buffer,
PIPE_BUFFER_USAGE_CPU_READ);
}
+ if (sp->constants[PIPE_SHADER_VERTEX].buffer)
+ size = sp->constants[PIPE_SHADER_VERTEX].buffer->size;
+ else
+ size = 0;
+
draw_set_mapped_constant_buffer(sp->draw,
sp->mapped_constants[PIPE_SHADER_VERTEX],
- sp->constants[PIPE_SHADER_VERTEX].buffer->size);
+ size);
}
static void
diff --git a/src/gallium/state_trackers/Makefile b/src/gallium/state_trackers/Makefile
index 07b3fbf311..265ca468c2 100644
--- a/src/gallium/state_trackers/Makefile
+++ b/src/gallium/state_trackers/Makefile
@@ -2,7 +2,7 @@ TOP = ../../..
include $(TOP)/configs/current
-SUBDIRS = glx
+SUBDIRS = $(GALLIUM_STATE_TRACKERS_DIRS)
default: subdirs
diff --git a/src/gallium/winsys/drm/Makefile b/src/gallium/winsys/drm/Makefile
index f466ce6c3c..a84fcd8418 100644
--- a/src/gallium/winsys/drm/Makefile
+++ b/src/gallium/winsys/drm/Makefile
@@ -1,20 +1,20 @@
-# src/mesa/drivers/dri/Makefile
+# src/gallium/winsys/drm/Makefile
TOP = ../../../..
include $(TOP)/configs/current
+SUBDIRS = $(GALLIUM_WINSYS_DRM_DIRS)
+default: $(TOP)/$(LIB_DIR)/gallium subdirs
-default: $(TOP)/$(LIB_DIR) subdirs
-
-$(TOP)/$(LIB_DIR):
- -mkdir $(TOP)/$(LIB_DIR)
+$(TOP)/$(LIB_DIR)/gallium:
+ -mkdir -p $(TOP)/$(LIB_DIR)/gallium
subdirs:
- @for dir in $(DRI_DIRS) ; do \
+ @for dir in $(SUBDIRS) ; do \
if [ -d $$dir ] ; then \
(cd $$dir && $(MAKE)) || exit 1 ; \
fi \
@@ -22,7 +22,7 @@ subdirs:
install:
- @for dir in $(DRI_DIRS) ; do \
+ @for dir in $(SUBDIRS) ; do \
if [ -d $$dir ] ; then \
(cd $$dir && $(MAKE) install) || exit 1 ; \
fi \
@@ -30,7 +30,7 @@ install:
clean:
- @for dir in $(DRI_DIRS) ; do \
+ @for dir in $(SUBDIRS) ; do \
if [ -d $$dir ] ; then \
(cd $$dir && $(MAKE) clean) ; \
fi \
diff --git a/src/gallium/winsys/drm/Makefile.template b/src/gallium/winsys/drm/Makefile.template
index 211f4d875e..cccf8abdfd 100644
--- a/src/gallium/winsys/drm/Makefile.template
+++ b/src/gallium/winsys/drm/Makefile.template
@@ -1,9 +1,9 @@
# -*-makefile-*-
MESA_MODULES = \
- $(TOP)/src/mesa/libmesa.a \
+ $(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 \
@@ -79,7 +79,7 @@ SHARED_INCLUDES = \
##### TARGETS #####
-default: depend symlinks $(LIBNAME) $(TOP)/$(LIB_DIR)/$(LIBNAME) $(LIBNAME_EGL) $(TOP)/$(LIB_DIR)/$(LIBNAME_EGL)
+default: depend symlinks $(LIBNAME) $(TOP)/$(LIB_DIR)/gallium/$(LIBNAME) $(LIBNAME_EGL) $(TOP)/$(LIB_DIR)/gallium/$(LIBNAME_EGL)
$(LIBNAME): $(OBJECTS) $(MESA_MODULES) $(PIPE_DRIVERS) $(WINOBJ) Makefile $(TOP)/src/mesa/drivers/dri/Makefile.template
@@ -93,11 +93,11 @@ $(LIBNAME_EGL): $(WINSYS_OBJECTS) $(LIBS)
$(OBJECTS) $(MKLIB_OPTIONS) $(WINSYS_OBJECTS) $(PIPE_DRIVERS) $(WINOBJ) $(DRI_LIB_DEPS) \
--whole-archive $(LIBS) $(GALLIUM_AUXILIARIES) --no-whole-archive $(DRIVER_EXTRAS)
-$(TOP)/$(LIB_DIR)/$(LIBNAME): $(LIBNAME)
- $(INSTALL) $(LIBNAME) $(TOP)/$(LIB_DIR)
+$(TOP)/$(LIB_DIR)/gallium/$(LIBNAME): $(LIBNAME)
+ $(INSTALL) $(LIBNAME) $(TOP)/$(LIB_DIR)/gallium
-$(TOP)/$(LIB_DIR)/$(LIBNAME_EGL): $(LIBNAME_EGL)
- $(INSTALL) $(LIBNAME_EGL) $(TOP)/$(LIB_DIR)
+$(TOP)/$(LIB_DIR)/gallium/$(LIBNAME_EGL): $(LIBNAME_EGL)
+ $(INSTALL) $(LIBNAME_EGL) $(TOP)/$(LIB_DIR)/gallium
depend: $(C_SOURCES) $(ASM_SOURCES) $(SYMLINKS)
rm -f depend
diff --git a/src/gallium/winsys/drm/intel/gem/Makefile.template b/src/gallium/winsys/drm/intel/gem/Makefile.template
index 557070ae02..b60e978894 100644
--- a/src/gallium/winsys/drm/intel/gem/Makefile.template
+++ b/src/gallium/winsys/drm/intel/gem/Makefile.template
@@ -36,11 +36,11 @@ INCLUDES = \
##### TARGETS #####
-default: depend symlinks $(LIBNAME)
+default: depend symlinks lib$(LIBNAME).a
-$(LIBNAME): $(OBJECTS) Makefile Makefile.template
- $(TOP)/bin/mklib -o $@ -static $(OBJECTS) $(DRIVER_LIBS)
+lib$(LIBNAME).a: $(OBJECTS) Makefile Makefile.template
+ $(TOP)/bin/mklib -o $(LIBNAME) -static $(OBJECTS) $(DRIVER_LIBS)
depend: $(C_SOURCES) $(CPP_SOURCES) $(ASM_SOURCES) $(SYMLINKS)
diff --git a/src/gallium/winsys/drm/nouveau/common/Makefile.template b/src/gallium/winsys/drm/nouveau/common/Makefile.template
index e40836e0a8..f0d098bb1c 100644
--- a/src/gallium/winsys/drm/nouveau/common/Makefile.template
+++ b/src/gallium/winsys/drm/nouveau/common/Makefile.template
@@ -31,11 +31,11 @@ INCLUDES = \
##### TARGETS #####
-default: depend symlinks $(LIBNAME)
+default: depend symlinks lib$(LIBNAME).a
-$(LIBNAME): $(OBJECTS) Makefile Makefile.template
- $(TOP)/bin/mklib -o $@ -static $(OBJECTS) $(DRIVER_LIBS)
+lib$(LIBNAME).a: $(OBJECTS) Makefile Makefile.template
+ $(TOP)/bin/mklib -o $(LIBNAME) -static $(OBJECTS) $(DRIVER_LIBS)
depend: $(C_SOURCES) $(CPP_SOURCES) $(ASM_SOURCES) $(SYMLINKS)
diff --git a/src/gallium/winsys/egl_xlib/Makefile b/src/gallium/winsys/egl_xlib/Makefile
index 76f1b56da4..02ac47caa4 100644
--- a/src/gallium/winsys/egl_xlib/Makefile
+++ b/src/gallium/winsys/egl_xlib/Makefile
@@ -34,7 +34,7 @@ LIBS = \
# mesa code, as done for ES 1.x, 2.x, OpenVG, etc)
UNUSED_LIBS = \
$(TOP)/src/mesa/libglapi.a \
- $(TOP)/src/mesa/libmesa.a \
+ $(TOP)/src/mesa/libmesagallium.a \
LOCAL_CFLAGS = -D_EGL_PLATFORM_X=1
diff --git a/src/gallium/winsys/xlib/Makefile b/src/gallium/winsys/xlib/Makefile
index 8c2892d49b..bb187cc14a 100644
--- a/src/gallium/winsys/xlib/Makefile
+++ b/src/gallium/winsys/xlib/Makefile
@@ -47,7 +47,7 @@ LIBS = \
$(GALLIUM_DRIVERS) \
$(TOP)/src/gallium/state_trackers/glx/xlib/libxlib.a \
$(TOP)/src/mesa/libglapi.a \
- $(TOP)/src/mesa/libmesa.a \
+ $(TOP)/src/mesa/libmesagallium.a \
$(GALLIUM_AUXILIARIES) \
$(CELL_SPU_LIB) \
@@ -62,15 +62,17 @@ LIBS = \
-default: $(TOP)/$(LIB_DIR)/$(GL_LIB_NAME)
+default: $(TOP)/$(LIB_DIR)/gallium $(TOP)/$(LIB_DIR)/gallium/$(GL_LIB_NAME)
+$(TOP)/$(LIB_DIR)/gallium:
+ @ mkdir -p $(TOP)/$(LIB_DIR)/gallium
# Make the libGL.so library
-$(TOP)/$(LIB_DIR)/$(GL_LIB_NAME): $(XLIB_WINSYS_OBJECTS) $(LIBS) Makefile
+$(TOP)/$(LIB_DIR)/gallium/$(GL_LIB_NAME): $(XLIB_WINSYS_OBJECTS) $(LIBS) Makefile
$(TOP)/bin/mklib -o $(GL_LIB) \
-linker "$(CC)" \
-major $(GL_MAJOR) -minor $(GL_MINOR) -patch $(GL_TINY) \
- -install $(TOP)/$(LIB_DIR) \
+ -install $(TOP)/$(LIB_DIR)/gallium \
$(MKLIB_OPTIONS) $(XLIB_WINSYS_OBJECTS) \
--start-group $(LIBS) --end-group $(GL_LIB_DEPS)