Merge remote branch 'origin/gallium-0.2' into gallium-0.2
[mesa.git] / src / glx / x11 / Makefile
index fd83c6fc94d8761529d9c34b0805d9bdf26d7599..86d84d4b9ff4bf8df4103b7bca11d2bbcba0d4a8 100644 (file)
@@ -10,12 +10,14 @@ SOURCES = \
          compsize.c \
          eval.c \
          glxcmds.c \
+         glxcurrent.c \
          glxext.c \
          glxextensions.c \
          indirect.c \
          indirect_init.c \
          indirect_size.c \
          indirect_window_pos.c \
+         indirect_texture_compression.c \
          indirect_transpose_matrix.c \
          indirect_vertex_array.c \
          indirect_vertex_program.c \
@@ -29,13 +31,17 @@ SOURCES = \
          xfont.c \
          glx_pbuffer.c \
          glx_query.c \
-         glx_texture_compression.c \
+         drisw_glx.c \
+         dri_common.c \
          dri_glx.c \
-         XF86dri.c
+         XF86dri.c \
+         glxhash.c \
+         dri2_glx.c \
+         dri2.c
 
-include $(TOP)/src/mesa/sources
+include $(TOP)/src/mesa/sources.mak
 
-MESA_ASM_API = $(addprefix $(TOP)/src/mesa/, $(ASM_API))
+MESA_GLAPI_ASM_SOURCES = $(addprefix $(TOP)/src/mesa/, $(GLAPI_ASM_SOURCES))
 MESA_GLAPI_SOURCES = $(addprefix $(TOP)/src/mesa/, $(GLAPI_SOURCES))
 MESA_GLAPI_OBJECTS = $(addprefix $(TOP)/src/mesa/, $(GLAPI_OBJECTS))
 
@@ -44,9 +50,10 @@ OBJECTS = $(SOURCES:.c=.o) $(MESA_GLAPI_OBJECTS)
 INCLUDES = -I. \
        -I$(TOP)/include \
        -I$(TOP)/include/GL/internal \
-       -I$(TOP)/src/mesa/main \
+       -I$(TOP)/src/mesa \
        -I$(TOP)/src/mesa/glapi \
        $(LIBDRM_CFLAGS) \
+       $(DRI2PROTO_CFLAGS) \
        $(X11_INCLUDES)
 
 
@@ -64,28 +71,30 @@ default: depend $(TOP)/$(LIB_DIR)/$(GL_LIB_NAME)
 
 # Make libGL
 $(TOP)/$(LIB_DIR)/$(GL_LIB_NAME):  $(OBJECTS) Makefile
-       $(TOP)/bin/mklib -o $(GL_LIB) -linker '$(CC)' \
+       $(MKLIB) -o $(GL_LIB) -linker '$(CC)' -ldflags '$(LDFLAGS)' \
                -major 1 -minor 2 $(MKLIB_OPTIONS) \
-               -install $(TOP)/$(LIB_DIR) $(GL_LIB_DEPS) $(OBJECTS)
+               -install $(TOP)/$(LIB_DIR) -id $(INSTALL_LIB_DIR)/lib$(GL_LIB).1.dylib \
+               $(GL_LIB_DEPS) $(OBJECTS)
 
 
-depend: $(SOURCES) $(MESA_GLAPI_SOURCES) $(MESA_ASM_API) Makefile
+depend: $(SOURCES) $(MESA_GLAPI_SOURCES) $(MESA_GLAPI_ASM_SOURCES) Makefile
+       rm -f depend
        touch depend
        $(MKDEP) $(MKDEP_OPTIONS) $(INCLUDES) $(SOURCES) \
-               $(MESA_GLAPI_SOURCES) $(MESA_ASM_API
+               $(MESA_GLAPI_SOURCES) $(MESA_GLAPI_ASM_SOURCES
 
 
 # Emacs tags
 tags:
-       etags `find . -name \*.[ch]` `find ../include`
+       etags `find . -name \*.[ch]` `find $(TOP)/include`
 
-# Dummy install target
-install:
+install: $(TOP)/$(LIB_DIR)/$(GL_LIB_NAME)
+       $(MAKE) -C $(TOP)/src/mesa install-libgl
 
 # Remove .o and backup files
 clean:
        -rm -f $(TOP)/$(LIB_DIR)/libGL.so*
        -rm -f *.o *~
-       -rm -f depend
+       -rm -f depend depend.bak
 
-include depend
+-include depend