summaryrefslogtreecommitdiff
path: root/src/mesa
diff options
context:
space:
mode:
authorJosé Fonseca <jrfonseca@tungstengraphics.com>2008-02-18 14:25:04 +0900
committerJosé Fonseca <jrfonseca@tungstengraphics.com>2008-02-18 14:25:04 +0900
commitbfd5916eafb9a97ad10f1d4a8738e7dcb02e04f4 (patch)
tree4d9acef3ff83664c8c4109d379eda69b1e25c222 /src/mesa
parent56bf73b1fb974e2223c9a4dcc96d39dac84a2df5 (diff)
Code reorganization: split gallium and mesa makefiles.
In other words, don't build src/gallium source code from within src/mesa/Makefile. Also, allow to customize which gallium auxiliary dirs, driver driver, winsys dirs get built from the config/* files.
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/Makefile74
-rw-r--r--src/mesa/sources56
2 files changed, 8 insertions, 122 deletions
diff --git a/src/mesa/Makefile b/src/mesa/Makefile
index c8cb2b592f..86a9cf0b88 100644
--- a/src/mesa/Makefile
+++ b/src/mesa/Makefile
@@ -11,19 +11,6 @@ GL_MINOR = 5
GL_TINY = 0$(MESA_MAJOR)0$(MESA_MINOR)0$(MESA_TINY)
-PIPE_LIB = \
- $(TOP)/src/gallium/drivers/softpipe/libsoftpipe.a \
- $(TOP)/src/gallium/drivers/i965simple/libi965simple.a
-
-ifeq ($(CONFIG_NAME), linux-cell)
-CELL_LIB = $(TOP)/src/gallium/drivers/cell/ppu/libcell.a
-CELL_LIB_SPU = $(TOP)/src/gallium/drivers/cell/spu/g3d_spu.a
-endif
-
-ifeq ($(CONFIG_NAME), linux-llvm)
-LLVM_LIB = $(TOP)/src/gallium/auxiliary/llvm/libgallivm.a
-endif
-
.SUFFIXES : .cpp
.c.o:
@@ -36,33 +23,14 @@ endif
$(CC) -c $(INCLUDE_DIRS) $(CFLAGS) $< -o $@
-# Figure out what to make here
-default:
- @if [ "${DRIVER_DIRS}" = "dri" ] ; then \
- $(MAKE) linux-solo ; \
- elif [ "${DRIVER_DIRS}" = "osmesa" ] ; then \
- $(MAKE) osmesa-only ; \
- elif [ "$(DRIVER_DIRS)" = "beos" ]; then \
- $(MAKE) beos ; \
- elif [ "$(DRIVER_DIRS)" = "directfb" ]; then \
- $(MAKE) directfb ; \
- elif [ "$(DRIVER_DIRS)" = "fbdev osmesa" ]; then \
- $(MAKE) fbdev ; $(MAKE) osmesa-only ; \
- else \
- $(MAKE) stand-alone ; \
- fi
-
+default: depend subdirs libmesa.a
-######################################################################
-# BeOS driver target
-
-beos: depend subdirs libmesa.a
- cd drivers/beos; $(MAKE)
+ifneq ($(DRIVER_DIRS),dri)
+default: libglapi.a
+endif
######################################################################
-# Linux DRI drivers
-
# Make archive of core object files
libmesa.a: $(SOLO_OBJECTS)
@ $(TOP)/bin/mklib -o mesa -static $(SOLO_OBJECTS);
@@ -70,32 +38,8 @@ libmesa.a: $(SOLO_OBJECTS)
mimeset -f "$@" ; \
fi
-linux-solo: depend subdirs libmesa.a
- cd $(TOP)/src/gallium/winsys/dri ; $(MAKE)
-
-
-#####################################################################
-# Stand-alone Mesa libGL, no built-in drivers (DirectFB)
-
-libgl-core: $(CORE_OBJECTS)
- @ $(TOP)/bin/mklib -o $(GL_LIB) \
- -major $(MESA_MAJOR) -minor $(MESA_MINOR) -patch $(MESA_TINY) \
- -install $(TOP)/$(LIB_DIR) $(MKLIB_OPTIONS) $(CORE_OBJECTS) \
- $(GL_LIB_DEPS)
-
-directfb: depend subdirs libgl-core
- cd drivers/directfb ; $(MAKE)
-
-
-#####################################################################
-# fbdev Mesa driver (libGL.so)
-
-fbdev: $(CORE_OBJECTS) $(FBDEV_DRIVER_OBJECTS) $(COMMON_DRIVER_OBJECTS)
- @ $(TOP)/bin/mklib -o $(GL_LIB) \
- -major $(MESA_MAJOR) -minor $(MESA_MINOR) -patch $(MESA_TINY) \
- -install $(TOP)/$(LIB_DIR) $(MKLIB_OPTIONS) \
- $(CORE_OBJECTS) $(FBDEV_DRIVER_OBJECTS) \
- $(COMMON_DRIVER_OBJECTS) $(GL_LIB_DEPS)
+libglapi.a: $(GLAPI_OBJECTS)
+ @ $(TOP)/bin/mklib -o glapi -static $(GLAPI_OBJECTS)
######################################################################
@@ -176,9 +120,6 @@ install: default
@if [ -e $(TOP)/$(LIB_DIR)/$(OSMESA_LIB_NAME) ]; then \
$(INSTALL) $(TOP)/$(LIB_DIR)/libOSMesa* $(INSTALL_DIR)/$(LIB_DIR); \
fi
- @if [ "${DRIVER_DIRS}" = "dri" ] ; then \
- cd $(TOP)/gallium/winsys/dri ; $(MAKE) install ; \
- fi
## NOT INSTALLED YET:
## $(INSTALL) -d $(INSTALL_DIR)/include/GLES
@@ -192,9 +133,8 @@ tags:
clean:
-rm -f */*.o
-rm -f */*/*.o
- -rm -f depend depend.bak libmesa.a
+ -rm -f depend depend.bak libmesa.a libglapi.a
-rm -f drivers/*/*.o
- (cd drivers/dri && $(MAKE) clean)
(cd x86 && $(MAKE) clean)
(cd x86-64 && $(MAKE) clean)
diff --git a/src/mesa/sources b/src/mesa/sources
index f83d247a1e..0d185fd5f3 100644
--- a/src/mesa/sources
+++ b/src/mesa/sources
@@ -156,51 +156,6 @@ VF_SOURCES = \
vf/vf_generic.c \
vf/vf_sse.c
-
-DRAW_SOURCES = \
- $(TOP)/src/gallium/auxiliary/draw/draw_clip.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_vs_exec.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_vs_sse.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_vs_llvm.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_context.c\
- $(TOP)/src/gallium/auxiliary/draw/draw_cull.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_debug.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_flatshade.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_offset.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_prim.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_stipple.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_twoside.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_unfilled.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_validate.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_vbuf.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_vertex.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_vertex_cache.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_vertex_fetch.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_vertex_shader.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_vf.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_vf_generic.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_vf_sse.c \
- $(TOP)/src/gallium/auxiliary/draw/draw_wide_prims.c
-
-TGSIEXEC_SOURCES = \
- $(TOP)/src/gallium/auxiliary/tgsi/exec/tgsi_exec.c \
- $(TOP)/src/gallium/auxiliary/tgsi/exec/tgsi_sse2.c
-
-TGSIUTIL_SOURCES = \
- $(TOP)/src/gallium/auxiliary/tgsi/util/tgsi_build.c \
- $(TOP)/src/gallium/auxiliary/tgsi/util/tgsi_dump.c \
- $(TOP)/src/gallium/auxiliary/tgsi/util/tgsi_parse.c \
- $(TOP)/src/gallium/auxiliary/tgsi/util/tgsi_util.c
-
-STATECACHE_SOURCES = \
- $(TOP)/src/gallium/auxiliary/cso_cache/cso_hash.c \
- $(TOP)/src/gallium/auxiliary/cso_cache/cso_cache.c
-
-PIPEUTIL_SOURCES = \
- $(TOP)/src/gallium/auxiliary/util/p_debug.c \
- $(TOP)/src/gallium/auxiliary/util/p_tile.c \
- $(TOP)/src/gallium/auxiliary/util/p_util.c
-
STATETRACKER_SOURCES = \
state_tracker/st_atom.c \
state_tracker/st_atom_blend.c \
@@ -229,7 +184,7 @@ STATETRACKER_SOURCES = \
state_tracker/st_cb_readpixels.c \
state_tracker/st_cb_strings.c \
state_tracker/st_cb_texture.c \
- state_tracker/st_cache.c \
+ state_tracker/st_cache.c \
state_tracker/st_context.c \
state_tracker/st_debug.c \
state_tracker/st_draw.c \
@@ -333,15 +288,6 @@ SPARC_API = \
__COMMON_DRIVER_SOURCES = \
drivers/common/driverfuncs.c
-X11_DRIVER_SOURCES = \
- $(TOP)/src/gallium/winsys/xlib/glxapi.c \
- $(TOP)/src/gallium/winsys/xlib/fakeglx.c \
- $(TOP)/src/gallium/winsys/xlib/xfonts.c \
- $(TOP)/src/gallium/winsys/xlib/xm_api.c \
- $(TOP)/src/gallium/winsys/xlib/xm_winsys.c \
- $(TOP)/src/gallium/winsys/xlib/xm_winsys_aub.c \
- $(TOP)/src/gallium/winsys/xlib/brw_aub.c
-
OSMESA_DRIVER_SOURCES = \
drivers/osmesa/osmesa.c