EXPAT_INCLUDES = -I/usr/local/include
X11_INCLUDES = -I/usr/X11R6/include -I/usr/X11R6/include/X11/extensions
-DEFINES = -DDRI_NEW_INTERFACE_ONLY -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1
+DEFINES = -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER
CFLAGS = $(DEFINES) -Wmissing-prototypes -g -std=c99 -Wundef -fPIC \
-ffast-math $(X11_INCLUDES)
CXXFLAGS = $(DEFINES) -Wall -g -ansi -pedantic -fPIC
WARN_FLAGS = -Wall -Wundef
OPT_FLAGS = -O3 -g
PIC_FLAGS = -fPIC
-
+
# Add '-DGLX_USE_TLS' to ARCH_FLAGS to enable TLS support.
ARCH_FLAGS ?=
DEFINES = -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE \
-D_BSD_SOURCE -D_GNU_SOURCE \
- -DDRI_NEW_INTERFACE_ONLY -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 -DDRM_USE_MALLOC
+ -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 -DDRM_USE_MALLOC -DIN_DRI_DRIVER
-CFLAGS = $(WARN_FLAGS) $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) \
- $(ASM_FLAGS) -std=c99 -ffast-math
+CFLAGS = $(WARN_FLAGS) $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) \
+ $(ASM_FLAGS) -std=c99 -ffast-math
CXXFLAGS = $(WARN_FLAGS) $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES)
-ASM_SOURCES =
+
+ASM_SOURCES =
# Library/program dependencies
DRI_LIB_DEPS = -lm -lpthread -lexpat -ldl -L$(LIB_DIR) -lEGL -l$(GL_LIB)
# Configuration for linux-solo-ia64: Linux DRI hardware drivers for fbdev
-include $(TOP)/configs/default
+include $(TOP)/configs/linux-solo
CONFIG_NAME = linux-solo-ia64
-# Compiler and flags
-CC = gcc
-CXX = g++
-
-DEFINES = -DDRI_NEW_INTERFACE_ONLY -D_POSIX_SOURCE -D_SVID_SOURCE -D_BSD_SOURCE -D_POSIX_C_SOURCE=199309L -D_GNU_SOURCE -DDRM_USE_MALLOC
-
-CFLAGS = $(DEFINES) -Wmissing-prototypes -g -std=c99 -Wundef -fPIC -ffast-math
-
-CXXFLAGS = $(DEFINES) -Wall -O3 -ansi -pedantic -fPIC
-
-
-# Library/program dependencies
-DRI_LIB_DEPS = -lm -lpthread -lexpat -ldl
-GL_LIB_DEPS = -lm -lpthread -ldl
-GLUT_LIB_DEPS = -L$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -lm
-APP_LIB_DEPS = -L$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm -lpthread
-
-# Directories
-SRC_DIRS = mesa glx/mini glu glut/mini
-DRIVER_DIRS = dri
-PROGRAM_DIRS = miniglx
-
DRI_DIRS = fb mach64 mga r128 r200 radeon sis tdfx unichrome
#ifndef DRI_INTERFACE_H
#define DRI_INTERFACE_H
-#ifndef DRI_NEW_INTERFACE_ONLY
+#if 0 /*ndef DRI_NEW_INTERFACE_ONLY*/
# include <X11/X.h>
# include <GL/glx.h>
# include "GL/glxint.h"
* \name Functions provided by the driver loader.
*/
/*@{*/
-extern __DRIscreen *__glXFindDRIScreen(__DRInativeDisplay *dpy, int scrn);
-
-
-
/**
* Type of a pointer to \c glXGetScreenDriver, as returned by
* \c glXGetProcAddress. This function is used to get the name of the DRI
typedef const char * (* PFNGLXGETDRIVERCONFIGPROC) (const char *driverName);
/**
- * Type of a pointer to \c __glXScrEnableExtension, as returned by
- * \c glXGetProcAddress. This function is used to enable a GLX extension
- * on the specified screen.
- *
- * \sa __glXScrEnableExtension, glXGetProcAddress
+ * Type of a pointer to \c glxEnableExtension, as returned by
+ * \c __DRIinterfaceMethods::getProcAddress. This function is used to enable
+ * a GLX extension on the specified screen.
*/
typedef void (* PFNGLXSCRENABLEEXTENSIONPROC) ( void *psc, const char * name );
-
-
-/* Test for the xf86dri.h header file */
-#ifndef _XF86DRI_H_
-extern GLboolean XF86DRIDestroyContext( __DRInativeDisplay *dpy, int screen,
- __DRIid context_id );
-
-extern GLboolean XF86DRICreateDrawable( __DRInativeDisplay *dpy, int screen,
- __DRIid drawable, drm_drawable_t *hHWDrawable );
-
-extern GLboolean XF86DRIDestroyDrawable( __DRInativeDisplay *dpy, int screen,
- __DRIid drawable);
-#endif
/*@}*/
#define INIT_MESA_SPARC
#endif
+#ifdef GLX_DIRECT_RENDERING
+static __DRIscreen *__glXFindDRIScreen(__DRInativeDisplay *dpy, int scrn);
+#endif /* GLX_DIRECT_RENDERING */
+
static Bool MakeContextCurrent(Display *dpy, GLXDrawable draw,
GLXDrawable read, GLXContext gc);