1 # $Id: Makefile.X11,v 1.3 2003/10/20 02:17:33 jonsmirl Exp $
3 # Mesa 3-D graphics library
5 # Copyright (C) 1995-2002 Brian Paul
11 SHARED_INCLUDES = $(INCLUDE_DIRS) -I. -I../common -Iserver
12 MINIGLX_INCLUDES = -I$(TOP)/src/glx/mini
22 -DGLX_DIRECT_RENDERING
25 # MINIGLX_SOURCES = server/i830_dri.c
45 INCLUDES = $(MINIGLX_INCLUDES) \
49 C_SOURCES = $(DRIVER_SOURCES) \
52 MESA_MODULES = $(TOP)/src/mesa/mesa.a
55 ifeq ($(WINDOW_SYSTEM),dri)
56 WINOBJ=$(MESABUILDDIR)/dri/dri.a
60 WINLIB=-L$(MESA)/src/glx/mini
64 OBJECTS = $(C_SOURCES:.c=.o) \
67 ### Include directories
72 -I$(TOP)/src/mesa/main \
73 -I$(TOP)/src/mesa/glapi \
74 -I$(TOP)/src/mesa/math \
75 -I$(TOP)/src/mesa/transform \
76 -I$(TOP)/src/mesa/swrast \
77 -I$(TOP)/src/mesa/swrast_setup
83 $(CC) -c $(SHARED_INCLUDES) $(MINIGLX_INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@
86 $(CC) -c $(SHARED_INCLUDES) $(MINIGLX_INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@
91 targets: depend i830_dri.so
93 i830_dri.so: $(OBJECTS) $(MESA_MODULES) $(WINOBJ) Makefile.X11
94 rm -f $@ && gcc -o $@ -shared $(OBJECTS) $(MESA_MODULES) $(WINOBJ) $(WINLIB) -lc $(GL_LIB_DEPS)
95 rm -f $(TOP)/lib/i830_dri.so && \
96 install i830_dri.so $(TOP)/lib/i830_dri.so
98 $(TOP)/lib/i830_dri.so: i830_dri.so
99 rm -f $(TOP)/lib/i830_dri.so && \
100 install i830_dri.so $(TOP)/lib/i830_dri.so
102 # Run 'make -f Makefile.X11 dep' to update the dependencies if you change
103 # what's included by any source file.
104 depend: $(C_SOURCES) $(ASM_SOURCES)
105 makedepend -fdepend -Y $(SHARED_INCLUDES) $(MINIGLX_INCLUDES) \
106 $(C_SOURCES) $(ASM_SOURCES)
111 etags `find . -name \*.[ch]` `find ../include`
114 # Remove .o and backup files
116 -rm -f *.o */*.o *~ *.o *~ *.so server/*.o
119 include $(TOP)/Make-config