summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/gallium/Makefile.template74
-rw-r--r--src/gallium/auxiliary/cso_cache/Makefile3
-rw-r--r--src/gallium/auxiliary/draw/Makefile4
-rw-r--r--src/gallium/auxiliary/indices/Makefile4
-rw-r--r--src/gallium/auxiliary/pipebuffer/Makefile3
-rw-r--r--src/gallium/auxiliary/rtasm/Makefile3
-rw-r--r--src/gallium/auxiliary/sct/Makefile3
-rw-r--r--src/gallium/auxiliary/tgsi/Makefile3
-rw-r--r--src/gallium/auxiliary/translate/Makefile3
-rw-r--r--src/gallium/auxiliary/util/Makefile3
-rw-r--r--src/gallium/drivers/failover/Makefile3
-rw-r--r--src/gallium/drivers/i915simple/Makefile3
-rw-r--r--src/gallium/drivers/i965simple/Makefile2
-rw-r--r--src/gallium/drivers/nv04/Makefile11
-rw-r--r--src/gallium/drivers/nv10/Makefile11
-rw-r--r--src/gallium/drivers/nv20/Makefile11
-rw-r--r--src/gallium/drivers/nv30/Makefile11
-rw-r--r--src/gallium/drivers/nv40/Makefile11
-rw-r--r--src/gallium/drivers/nv50/Makefile11
-rw-r--r--src/gallium/drivers/r300/Makefile2
-rw-r--r--src/gallium/drivers/softpipe/Makefile3
-rw-r--r--src/gallium/drivers/trace/Makefile6
-rw-r--r--src/gallium/state_trackers/glx/xlib/Makefile18
23 files changed, 50 insertions, 156 deletions
diff --git a/src/gallium/Makefile.template b/src/gallium/Makefile.template
index 655e949ca2..98487d43bd 100644
--- a/src/gallium/Makefile.template
+++ b/src/gallium/Makefile.template
@@ -1,64 +1,66 @@
-# -*-makefile-*-
+# src/gallium/Makefile.template
-
-# We still have a dependency on the "dri" buffer manager. Most likely
-# the interface can be reused in non-dri environments, and also as a
-# frontend to simpler memory managers.
+# Template makefile for gallium libraries.
+#
+# Usage:
+# The minimum that the including makefile needs to define
+# is TOP, LIBNAME and one of of the *_SOURCES.
#
-COMMON_SOURCES =
+# Optional defines:
+# LIBRARY_INCLUDES are appended to the list of includes directories.
+# LIBRARY_DEFINES is not used for makedepend, but for compilation.
-OBJECTS = $(C_SOURCES:.c=.o) \
- $(CPP_SOURCES:.cpp=.o) \
- $(ASM_SOURCES:.S=.o)
+### Basic defines ###
+OBJECTS = $(C_SOURCES:.c=.o) \
+ $(CPP_SOURCES:.cpp=.o) \
+ $(ASM_SOURCES:.S=.o)
-### Include directories
INCLUDES = \
-I. \
-I$(TOP)/src/gallium/include \
-I$(TOP)/src/gallium/auxiliary \
-I$(TOP)/src/gallium/drivers \
- -I$(TOP)/include \
- $(DRIVER_INCLUDES)
-
-
-##### RULES #####
-
-.c.o:
- $(CC) -c $(INCLUDES) $(CFLAGS) $(DRIVER_DEFINES) $< -o $@
-
-.cpp.o:
- $(CXX) -c $(INCLUDES) $(CXXFLAGS) $(DRIVER_DEFINES) $< -o $@
-
-.S.o:
- $(CC) -c $(INCLUDES) $(CFLAGS) $(DRIVER_DEFINES) $< -o $@
+ -I$(GALLIUM)/src/gallium/include \
+ -I$(GALLIUM)/src/gallium/auxiliary \
+ -I$(GALLIUM)/src/gallium/drivers \
+ $(LIBRARY_INCLUDES)
##### TARGETS #####
-default: depend symlinks lib$(LIBNAME).a
-
+default: depend lib$(LIBNAME).a
lib$(LIBNAME).a: $(OBJECTS) Makefile $(TOP)/src/gallium/Makefile.template
- $(TOP)/bin/mklib -o $(LIBNAME) -static $(OBJECTS) $(DRIVER_LIBS)
-
+ $(MKLIB) -o $(LIBNAME) -static $(OBJECTS)
depend: $(C_SOURCES) $(CPP_SOURCES) $(ASM_SOURCES) $(SYMLINKS)
rm -f depend
touch depend
- $(MKDEP) $(MKDEP_OPTIONS) $(DRIVER_DEFINES) $(INCLUDES) $(C_SOURCES) $(CPP_SOURCES) \
- $(ASM_SOURCES) 2> /dev/null
-
+ $(MKDEP) $(MKDEP_OPTIONS) $(INCLUDES) $(C_SOURCES) $(CPP_SOURCES) $(ASM_SOURCES) 2> /dev/null
# Emacs tags
tags:
etags `find . -name \*.[ch]` `find ../include`
-
# Remove .o and backup files
-clean::
- -rm -f *.o */*.o *~ *.so *~ server/*.o $(SYMLINKS)
- -rm -f depend depend.bak
+clean:
+ rm -f $(OBJECTS) lib$(LIBNAME).a depend depend.bak
+
+# Dummy target
+install:
+ @echo -n ""
+
+##### RULES #####
+
+.c.o:
+ $(CC) -c $(INCLUDES) $(CFLAGS) $(LIBRARY_DEFINES) $< -o $@
+
+.cpp.o:
+ $(CXX) -c $(INCLUDES) $(CXXFLAGS) $(LIBRARY_DEFINES) $< -o $@
+
+.S.o:
+ $(CC) -c $(INCLUDES) $(CFLAGS) $(LIBRARY_DEFINES) $< -o $@
-include depend
+sinclude depend
diff --git a/src/gallium/auxiliary/cso_cache/Makefile b/src/gallium/auxiliary/cso_cache/Makefile
index 6bd6602088..8726afcd94 100644
--- a/src/gallium/auxiliary/cso_cache/Makefile
+++ b/src/gallium/auxiliary/cso_cache/Makefile
@@ -9,6 +9,3 @@ C_SOURCES = \
cso_hash.c
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/auxiliary/draw/Makefile b/src/gallium/auxiliary/draw/Makefile
index bdbf5a08ed..5041dcc072 100644
--- a/src/gallium/auxiliary/draw/Makefile
+++ b/src/gallium/auxiliary/draw/Makefile
@@ -43,8 +43,4 @@ C_SOURCES = \
draw_vs_ppc.c \
draw_vs_sse.c
-
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/auxiliary/indices/Makefile b/src/gallium/auxiliary/indices/Makefile
index 8fa61d265e..25ee899c40 100644
--- a/src/gallium/auxiliary/indices/Makefile
+++ b/src/gallium/auxiliary/indices/Makefile
@@ -10,7 +10,3 @@ include ../../Makefile.template
u_indices_gen.c: u_indices_gen.py
python $< > $@
-
-
-symlinks:
-
diff --git a/src/gallium/auxiliary/pipebuffer/Makefile b/src/gallium/auxiliary/pipebuffer/Makefile
index 3b501c51df..1c00ba8d98 100644
--- a/src/gallium/auxiliary/pipebuffer/Makefile
+++ b/src/gallium/auxiliary/pipebuffer/Makefile
@@ -17,6 +17,3 @@ C_SOURCES = \
pb_validate.c
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/auxiliary/rtasm/Makefile b/src/gallium/auxiliary/rtasm/Makefile
index 252dc5274a..ab8ea464c6 100644
--- a/src/gallium/auxiliary/rtasm/Makefile
+++ b/src/gallium/auxiliary/rtasm/Makefile
@@ -11,6 +11,3 @@ C_SOURCES = \
rtasm_ppc_spe.c
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/auxiliary/sct/Makefile b/src/gallium/auxiliary/sct/Makefile
index 516d1756cf..a7d111b689 100644
--- a/src/gallium/auxiliary/sct/Makefile
+++ b/src/gallium/auxiliary/sct/Makefile
@@ -7,6 +7,3 @@ C_SOURCES = \
sct.c
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/auxiliary/tgsi/Makefile b/src/gallium/auxiliary/tgsi/Makefile
index d7df9490cf..b4900e8dba 100644
--- a/src/gallium/auxiliary/tgsi/Makefile
+++ b/src/gallium/auxiliary/tgsi/Makefile
@@ -19,6 +19,3 @@ C_SOURCES = \
tgsi_util.c
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/auxiliary/translate/Makefile b/src/gallium/auxiliary/translate/Makefile
index ad2a5b705e..3c82f8ae03 100644
--- a/src/gallium/auxiliary/translate/Makefile
+++ b/src/gallium/auxiliary/translate/Makefile
@@ -10,6 +10,3 @@ C_SOURCES = \
translate_cache.c
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/auxiliary/util/Makefile b/src/gallium/auxiliary/util/Makefile
index 671e671df2..160df8dfa7 100644
--- a/src/gallium/auxiliary/util/Makefile
+++ b/src/gallium/auxiliary/util/Makefile
@@ -27,6 +27,3 @@ C_SOURCES = \
u_simple_screen.c
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/drivers/failover/Makefile b/src/gallium/drivers/failover/Makefile
index f08b8df07a..dfb7f5dcf6 100644
--- a/src/gallium/drivers/failover/Makefile
+++ b/src/gallium/drivers/failover/Makefile
@@ -9,6 +9,3 @@ C_SOURCES = \
fo_context.c
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/drivers/i915simple/Makefile b/src/gallium/drivers/i915simple/Makefile
index 41a61a0020..12821c5a76 100644
--- a/src/gallium/drivers/i915simple/Makefile
+++ b/src/gallium/drivers/i915simple/Makefile
@@ -26,6 +26,3 @@ C_SOURCES = \
i915_surface.c
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/drivers/i965simple/Makefile b/src/gallium/drivers/i965simple/Makefile
index e97146e57c..19182afa75 100644
--- a/src/gallium/drivers/i965simple/Makefile
+++ b/src/gallium/drivers/i965simple/Makefile
@@ -50,5 +50,3 @@ C_SOURCES = \
brw_wm_surface_state.c
include ../../Makefile.template
-
-symlinks:
diff --git a/src/gallium/drivers/nv04/Makefile b/src/gallium/drivers/nv04/Makefile
index 4ed62dae95..cf9deea851 100644
--- a/src/gallium/drivers/nv04/Makefile
+++ b/src/gallium/drivers/nv04/Makefile
@@ -3,7 +3,7 @@ include $(TOP)/configs/current
LIBNAME = nv04
-DRIVER_SOURCES = \
+C_SOURCES = \
nv04_surface_2d.c \
nv04_clear.c \
nv04_context.c \
@@ -17,13 +17,4 @@ DRIVER_SOURCES = \
nv04_surface.c \
nv04_vbo.c
-C_SOURCES = \
- $(COMMON_SOURCES) \
- $(DRIVER_SOURCES)
-
-ASM_SOURCES =
-
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/drivers/nv10/Makefile b/src/gallium/drivers/nv10/Makefile
index 4ba7ce586d..2b5fbd4f5a 100644
--- a/src/gallium/drivers/nv10/Makefile
+++ b/src/gallium/drivers/nv10/Makefile
@@ -3,7 +3,7 @@ include $(TOP)/configs/current
LIBNAME = nv10
-DRIVER_SOURCES = \
+C_SOURCES = \
nv10_clear.c \
nv10_context.c \
nv10_fragprog.c \
@@ -16,13 +16,4 @@ DRIVER_SOURCES = \
nv10_surface.c \
nv10_vbo.c
-C_SOURCES = \
- $(COMMON_SOURCES) \
- $(DRIVER_SOURCES)
-
-ASM_SOURCES =
-
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/drivers/nv20/Makefile b/src/gallium/drivers/nv20/Makefile
index d777fd3d8b..93e34f8e92 100644
--- a/src/gallium/drivers/nv20/Makefile
+++ b/src/gallium/drivers/nv20/Makefile
@@ -3,7 +3,7 @@ include $(TOP)/configs/current
LIBNAME = nv20
-DRIVER_SOURCES = \
+C_SOURCES = \
nv20_clear.c \
nv20_context.c \
nv20_fragprog.c \
@@ -17,13 +17,4 @@ DRIVER_SOURCES = \
nv20_vbo.c
# nv20_vertprog.c
-C_SOURCES = \
- $(COMMON_SOURCES) \
- $(DRIVER_SOURCES)
-
-ASM_SOURCES =
-
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/drivers/nv30/Makefile b/src/gallium/drivers/nv30/Makefile
index 69f2790dfe..4c29e2eab3 100644
--- a/src/gallium/drivers/nv30/Makefile
+++ b/src/gallium/drivers/nv30/Makefile
@@ -3,7 +3,7 @@ include $(TOP)/configs/current
LIBNAME = nv30
-DRIVER_SOURCES = \
+C_SOURCES = \
nv30_clear.c \
nv30_context.c \
nv30_draw.c \
@@ -25,13 +25,4 @@ DRIVER_SOURCES = \
nv30_vbo.c \
nv30_vertprog.c
-C_SOURCES = \
- $(COMMON_SOURCES) \
- $(DRIVER_SOURCES)
-
-ASM_SOURCES =
-
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/drivers/nv40/Makefile b/src/gallium/drivers/nv40/Makefile
index 9c8eadf7e4..8c738aefa6 100644
--- a/src/gallium/drivers/nv40/Makefile
+++ b/src/gallium/drivers/nv40/Makefile
@@ -3,7 +3,7 @@ include $(TOP)/configs/current
LIBNAME = nv40
-DRIVER_SOURCES = \
+C_SOURCES = \
nv40_clear.c \
nv40_context.c \
nv40_draw.c \
@@ -25,13 +25,4 @@ DRIVER_SOURCES = \
nv40_vbo.c \
nv40_vertprog.c
-C_SOURCES = \
- $(COMMON_SOURCES) \
- $(DRIVER_SOURCES)
-
-ASM_SOURCES =
-
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/drivers/nv50/Makefile b/src/gallium/drivers/nv50/Makefile
index 48244dbbac..612aea28a3 100644
--- a/src/gallium/drivers/nv50/Makefile
+++ b/src/gallium/drivers/nv50/Makefile
@@ -3,7 +3,7 @@ include $(TOP)/configs/current
LIBNAME = nv50
-DRIVER_SOURCES = \
+C_SOURCES = \
nv50_clear.c \
nv50_context.c \
nv50_draw.c \
@@ -18,13 +18,4 @@ DRIVER_SOURCES = \
nv50_transfer.c \
nv50_vbo.c
-C_SOURCES = \
- $(COMMON_SOURCES) \
- $(DRIVER_SOURCES)
-
-ASM_SOURCES =
-
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/drivers/r300/Makefile b/src/gallium/drivers/r300/Makefile
index 85b3f15ac5..9b7524b523 100644
--- a/src/gallium/drivers/r300/Makefile
+++ b/src/gallium/drivers/r300/Makefile
@@ -18,5 +18,3 @@ C_SOURCES = \
r300_texture.c
include ../../Makefile.template
-
-symlinks:
diff --git a/src/gallium/drivers/softpipe/Makefile b/src/gallium/drivers/softpipe/Makefile
index f186f6df1d..516e3992fd 100644
--- a/src/gallium/drivers/softpipe/Makefile
+++ b/src/gallium/drivers/softpipe/Makefile
@@ -42,6 +42,3 @@ C_SOURCES = \
sp_surface.c
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/drivers/trace/Makefile b/src/gallium/drivers/trace/Makefile
index 3859b8acb0..e1bd970937 100644
--- a/src/gallium/drivers/trace/Makefile
+++ b/src/gallium/drivers/trace/Makefile
@@ -9,10 +9,6 @@ C_SOURCES = \
tr_screen.c \
tr_state.c \
tr_texture.c \
- tr_winsys.c
-
+ tr_winsys.c
include ../../Makefile.template
-
-symlinks:
-
diff --git a/src/gallium/state_trackers/glx/xlib/Makefile b/src/gallium/state_trackers/glx/xlib/Makefile
index 1b63db1f0e..6d10b090aa 100644
--- a/src/gallium/state_trackers/glx/xlib/Makefile
+++ b/src/gallium/state_trackers/glx/xlib/Makefile
@@ -3,23 +3,15 @@ include $(TOP)/configs/current
LIBNAME = xlib
-
-DRIVER_INCLUDES = \
+LIBRARY_INCLUDES = \
-I$(TOP)/include \
-I$(TOP)/src/mesa \
- -I$(TOP)/src/mesa/main \
- -I$(TOP)/src/gallium/include \
- -I$(TOP)/src/gallium/drivers \
- -I$(TOP)/src/gallium/auxiliary
+ -I$(TOP)/src/mesa/main
C_SOURCES = \
- glxapi.c \
- fakeglx.c \
- fakeglx_fonts.c \
+ glxapi.c \
+ fakeglx.c \
+ fakeglx_fonts.c \
xm_api.c
-
include ../../../Makefile.template
-
-symlinks:
-