Compare commits
	
		
			36 Commits
		
	
	
		
			mesa_7_5_r
			...
			mesa_7_2_r
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 
						 | 
					419353dc2f | ||
| 
						 | 
					38d3b2262b | ||
| 
						 | 
					4db2a7f36c | ||
| 
						 | 
					1145042fd2 | ||
| 
						 | 
					772131280a | ||
| 
						 | 
					ee913c0fcc | ||
| 
						 | 
					cd1804c43a | ||
| 
						 | 
					253784d45e | ||
| 
						 | 
					463d19d477 | ||
| 
						 | 
					6e4fd90ca5 | ||
| 
						 | 
					06188c0c5c | ||
| 
						 | 
					dec9097647 | ||
| 
						 | 
					e234339dba | ||
| 
						 | 
					bb09d23e92 | ||
| 
						 | 
					1ffbcddb6f | ||
| 
						 | 
					33cf8f5c06 | ||
| 
						 | 
					7b8d878bed | ||
| 
						 | 
					86ae34fbb4 | ||
| 
						 | 
					16f3461fd6 | ||
| 
						 | 
					0ac8886b51 | ||
| 
						 | 
					1729d37223 | ||
| 
						 | 
					81edef6f9f | ||
| 
						 | 
					e040e18c7b | ||
| 
						 | 
					14d186644b | ||
| 
						 | 
					e4535e4d5e | ||
| 
						 | 
					a008813890 | ||
| 
						 | 
					da50dc7bb3 | ||
| 
						 | 
					7f628d9cbc | ||
| 
						 | 
					b2ffd0be03 | ||
| 
						 | 
					912b16c689 | ||
| 
						 | 
					6d9b25e522 | ||
| 
						 | 
					31bad23f0f | ||
| 
						 | 
					29b9b25e72 | ||
| 
						 | 
					e794f496c6 | ||
| 
						 | 
					68067c66d3 | ||
| 
						 | 
					ad5474e995 | 
@@ -1,10 +0,0 @@
 | 
			
		||||
;; -*- emacs-lisp -*-
 | 
			
		||||
;;
 | 
			
		||||
;; This file is processed by the dirvars emacs package.  Each variable
 | 
			
		||||
;; setting below is performed when this dirvars file is loaded.
 | 
			
		||||
;;
 | 
			
		||||
indent-tabs-mode: nil
 | 
			
		||||
tab-width: 8
 | 
			
		||||
c-basic-offset: 3
 | 
			
		||||
kde-emacs-after-parent-string: ""
 | 
			
		||||
evaluate: (c-set-offset 'inline-open '0)
 | 
			
		||||
							
								
								
									
										12
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										12
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							@@ -1,15 +1,8 @@
 | 
			
		||||
*.a
 | 
			
		||||
*.dll
 | 
			
		||||
*.exe
 | 
			
		||||
*.ilk
 | 
			
		||||
*.o
 | 
			
		||||
*.obj
 | 
			
		||||
*.pc
 | 
			
		||||
*.pdb
 | 
			
		||||
*.pyc
 | 
			
		||||
*.pyo
 | 
			
		||||
*.so
 | 
			
		||||
*.sw[a-z]
 | 
			
		||||
*.pc
 | 
			
		||||
*~
 | 
			
		||||
depend
 | 
			
		||||
depend.bak
 | 
			
		||||
@@ -21,6 +14,3 @@ aclocal.m4
 | 
			
		||||
config.log
 | 
			
		||||
config.status
 | 
			
		||||
cscope*
 | 
			
		||||
.scon*
 | 
			
		||||
config.py
 | 
			
		||||
build
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										106
									
								
								Makefile
									
									
									
									
									
								
							
							
						
						
									
										106
									
								
								Makefile
									
									
									
									
									
								
							@@ -12,8 +12,6 @@ default: $(TOP)/configs/current
 | 
			
		||||
		fi \
 | 
			
		||||
	done
 | 
			
		||||
 | 
			
		||||
all: default
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
doxygen:
 | 
			
		||||
	cd doxygen && $(MAKE)
 | 
			
		||||
@@ -37,8 +35,6 @@ realclean: clean
 | 
			
		||||
	  -name depend -o -name depend.bak ')' -exec rm -f '{}' ';'
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
distclean: realclean
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
install:
 | 
			
		||||
	@for dir in $(SUBDIRS) ; do \
 | 
			
		||||
@@ -48,7 +44,11 @@ install:
 | 
			
		||||
	done
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
.PHONY: default doxygen clean realclean distclean install linux-directfb-install
 | 
			
		||||
# DirectFBGL module installation
 | 
			
		||||
linux-directfb-install:
 | 
			
		||||
	cd src/mesa/drivers/directfb && $(MAKE) install
 | 
			
		||||
 | 
			
		||||
.PHONY: default doxygen clean realclean install linux-directfb-install
 | 
			
		||||
 | 
			
		||||
# If there's no current configuration file
 | 
			
		||||
$(TOP)/configs/current:
 | 
			
		||||
@@ -107,8 +107,6 @@ irix6-o32-static \
 | 
			
		||||
linux \
 | 
			
		||||
linux-alpha \
 | 
			
		||||
linux-alpha-static \
 | 
			
		||||
linux-cell \
 | 
			
		||||
linux-cell-debug \
 | 
			
		||||
linux-debug \
 | 
			
		||||
linux-directfb \
 | 
			
		||||
linux-dri \
 | 
			
		||||
@@ -117,7 +115,6 @@ linux-dri-x86 \
 | 
			
		||||
linux-dri-x86-64 \
 | 
			
		||||
linux-dri-ppc \
 | 
			
		||||
linux-dri-xcb \
 | 
			
		||||
linux-egl \
 | 
			
		||||
linux-indirect \
 | 
			
		||||
linux-fbdev \
 | 
			
		||||
linux-glide \
 | 
			
		||||
@@ -125,15 +122,12 @@ linux-ia64-icc \
 | 
			
		||||
linux-ia64-icc-static \
 | 
			
		||||
linux-icc \
 | 
			
		||||
linux-icc-static \
 | 
			
		||||
linux-llvm \
 | 
			
		||||
linux-osmesa \
 | 
			
		||||
linux-osmesa-static \
 | 
			
		||||
linux-osmesa16 \
 | 
			
		||||
linux-osmesa16-static \
 | 
			
		||||
linux-osmesa32 \
 | 
			
		||||
linux-ppc \
 | 
			
		||||
linux-ppc-static \
 | 
			
		||||
linux-profile \
 | 
			
		||||
linux-solo \
 | 
			
		||||
linux-solo-x86 \
 | 
			
		||||
linux-solo-ia64 \
 | 
			
		||||
@@ -147,10 +141,8 @@ linux-x86-debug \
 | 
			
		||||
linux-x86-32 \
 | 
			
		||||
linux-x86-64 \
 | 
			
		||||
linux-x86-64-debug \
 | 
			
		||||
linux-x86-64-profile \
 | 
			
		||||
linux-x86-64-static \
 | 
			
		||||
linux-x86-glide \
 | 
			
		||||
linux-x86-profile \
 | 
			
		||||
linux-x86-static \
 | 
			
		||||
netbsd \
 | 
			
		||||
openbsd \
 | 
			
		||||
@@ -182,11 +174,10 @@ ultrix-gcc:
 | 
			
		||||
 | 
			
		||||
# Rules for making release tarballs
 | 
			
		||||
 | 
			
		||||
VERSION=7.5-rc3
 | 
			
		||||
DIRECTORY = Mesa-$(VERSION)
 | 
			
		||||
LIB_NAME = MesaLib-$(VERSION)
 | 
			
		||||
DEMO_NAME = MesaDemos-$(VERSION)
 | 
			
		||||
GLUT_NAME = MesaGLUT-$(VERSION)
 | 
			
		||||
DIRECTORY = Mesa-7.2-rc1
 | 
			
		||||
LIB_NAME = MesaLib-7.2-rc1
 | 
			
		||||
DEMO_NAME = MesaDemos-7.2-rc1
 | 
			
		||||
GLUT_NAME = MesaGLUT-7.2-rc1
 | 
			
		||||
 | 
			
		||||
MAIN_FILES = \
 | 
			
		||||
	$(DIRECTORY)/Makefile*						\
 | 
			
		||||
@@ -194,6 +185,8 @@ MAIN_FILES = \
 | 
			
		||||
	$(DIRECTORY)/configure.ac					\
 | 
			
		||||
	$(DIRECTORY)/acinclude.m4					\
 | 
			
		||||
	$(DIRECTORY)/aclocal.m4						\
 | 
			
		||||
	$(DIRECTORY)/descrip.mms					\
 | 
			
		||||
	$(DIRECTORY)/mms-config.					\
 | 
			
		||||
	$(DIRECTORY)/bin/config.guess					\
 | 
			
		||||
	$(DIRECTORY)/bin/config.sub					\
 | 
			
		||||
	$(DIRECTORY)/bin/install-sh					\
 | 
			
		||||
@@ -207,7 +200,9 @@ MAIN_FILES = \
 | 
			
		||||
	$(DIRECTORY)/docs/RELNOTES*					\
 | 
			
		||||
	$(DIRECTORY)/docs/*.spec					\
 | 
			
		||||
	$(DIRECTORY)/include/GL/internal/glcore.h			\
 | 
			
		||||
	$(DIRECTORY)/include/GL/amesa.h					\
 | 
			
		||||
	$(DIRECTORY)/include/GL/dmesa.h					\
 | 
			
		||||
	$(DIRECTORY)/include/GL/fxmesa.h				\
 | 
			
		||||
	$(DIRECTORY)/include/GL/ggimesa.h				\
 | 
			
		||||
	$(DIRECTORY)/include/GL/gl.h					\
 | 
			
		||||
	$(DIRECTORY)/include/GL/glext.h					\
 | 
			
		||||
@@ -222,24 +217,30 @@ MAIN_FILES = \
 | 
			
		||||
	$(DIRECTORY)/include/GL/mglmesa.h				\
 | 
			
		||||
	$(DIRECTORY)/include/GL/osmesa.h				\
 | 
			
		||||
	$(DIRECTORY)/include/GL/svgamesa.h				\
 | 
			
		||||
	$(DIRECTORY)/include/GL/ugl*.h					\
 | 
			
		||||
	$(DIRECTORY)/include/GL/vms_x_fix.h				\
 | 
			
		||||
	$(DIRECTORY)/include/GL/wglext.h				\
 | 
			
		||||
	$(DIRECTORY)/include/GL/wmesa.h					\
 | 
			
		||||
	$(DIRECTORY)/include/GL/xmesa.h					\
 | 
			
		||||
	$(DIRECTORY)/include/GL/xmesa_x.h				\
 | 
			
		||||
	$(DIRECTORY)/include/GL/xmesa_xf86.h				\
 | 
			
		||||
	$(DIRECTORY)/include/GLView.h					\
 | 
			
		||||
	$(DIRECTORY)/src/Makefile					\
 | 
			
		||||
	$(DIRECTORY)/src/descrip.mms					\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/Makefile*					\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/sources.mak				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/sources					\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/descrip.mms				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/gl.pc.in					\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/osmesa.pc.in				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/depend					\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/main/*.[chS]				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/main/descrip.mms				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/glapi/*.[chS]				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/glapi/descrip.mms				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/math/*.[ch]				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/math/descrip.mms				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/shader/*.[ch]				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/shader/descrip.mms			\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/shader/grammar/*.[ch]			\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/shader/grammar/descrip.mms		\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/shader/slang/*.[ch]			\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/shader/slang/descrip.mms			\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/shader/slang/library/*.[ch]		\
 | 
			
		||||
@@ -286,8 +287,6 @@ MAIN_FILES = \
 | 
			
		||||
	$(DIRECTORY)/src/mesa/drivers/x11/Makefile			\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/drivers/x11/descrip.mms			\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/drivers/x11/*.[ch]			\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/drivers/glslcompiler/Makefile		\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/drivers/glslcompiler/glslcompiler.c	\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/ppc/*.[ch]				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/sparc/*.[chS]				\
 | 
			
		||||
	$(DIRECTORY)/src/mesa/x86/Makefile				\
 | 
			
		||||
@@ -300,41 +299,22 @@ MAIN_FILES = \
 | 
			
		||||
	$(DIRECTORY)/progs/util/README					\
 | 
			
		||||
	$(DIRECTORY)/progs/util/*.[ch]					\
 | 
			
		||||
	$(DIRECTORY)/progs/util/sampleMakefile				\
 | 
			
		||||
	$(DIRECTORY)/windows/VC8/
 | 
			
		||||
 | 
			
		||||
EGL_FILES = \
 | 
			
		||||
	$(DIRECTORY)/include/EGL/*.h					\
 | 
			
		||||
	$(DIRECTORY)/include/GLES/*.h					\
 | 
			
		||||
	$(DIRECTORY)/include/GLES2/*.h					\
 | 
			
		||||
	$(DIRECTORY)/src/egl/Makefile					\
 | 
			
		||||
	$(DIRECTORY)/src/egl/*/Makefile					\
 | 
			
		||||
	$(DIRECTORY)/src/egl/*/*.[ch]					\
 | 
			
		||||
	$(DIRECTORY)/src/egl/*/*/Makefile				\
 | 
			
		||||
	$(DIRECTORY)/src/egl/*/*/*.[ch]					\
 | 
			
		||||
 | 
			
		||||
GALLIUM_FILES = \
 | 
			
		||||
	$(DIRECTORY)/src/mesa/state_tracker/*[ch]			\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/Makefile				\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/Makefile.template			\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/SConscript				\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/Makefile				\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/SConscript				\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/*/Makefile				\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/*/Makefile.template			\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/*/SConscript				\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/*/*.[ch]				\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/*/*.py				\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/*/*/Makefile				\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/*/*/SConscript			\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/*/*/*.[ch]				\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/*/*/*.py				\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/*/*/*/Makefile			\
 | 
			
		||||
	$(DIRECTORY)/src/gallium/*/*/*/*/*.[ch]				\
 | 
			
		||||
	$(DIRECTORY)/vms/analyze_map.com				\
 | 
			
		||||
	$(DIRECTORY)/vms/xlib.opt					\
 | 
			
		||||
	$(DIRECTORY)/vms/xlib_share.opt					\
 | 
			
		||||
	$(DIRECTORY)/windows/VC8/mesa/mesa.sln				\
 | 
			
		||||
	$(DIRECTORY)/windows/VC8/mesa/gdi/gdi.vcproj			\
 | 
			
		||||
	$(DIRECTORY)/windows/VC8/mesa/glu/glu.vcproj			\
 | 
			
		||||
	$(DIRECTORY)/windows/VC8/mesa/mesa/mesa.vcproj			\
 | 
			
		||||
	$(DIRECTORY)/windows/VC8/mesa/osmesa/osmesa.vcproj		\
 | 
			
		||||
	$(DIRECTORY)/windows/VC8/progs/progs.sln			\
 | 
			
		||||
	$(DIRECTORY)/windows/VC8/progs/demos/gears.vcproj		\
 | 
			
		||||
	$(DIRECTORY)/windows/VC8/progs/glut/glut.vcproj
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
DRI_FILES = \
 | 
			
		||||
	$(DIRECTORY)/include/GL/internal/dri_interface.h		\
 | 
			
		||||
	$(DIRECTORY)/include/GL/internal/glcore.h			\
 | 
			
		||||
	$(DIRECTORY)/include/GL/internal/dri_sarea.h			\
 | 
			
		||||
	$(DIRECTORY)/include/GL/internal/sarea.h			\
 | 
			
		||||
	$(DIRECTORY)/src/glx/Makefile					\
 | 
			
		||||
	$(DIRECTORY)/src/glx/x11/Makefile				\
 | 
			
		||||
@@ -351,12 +331,15 @@ DRI_FILES = \
 | 
			
		||||
 | 
			
		||||
SGI_GLU_FILES = \
 | 
			
		||||
	$(DIRECTORY)/src/glu/Makefile					\
 | 
			
		||||
	$(DIRECTORY)/src/glu/descrip.mms				\
 | 
			
		||||
	$(DIRECTORY)/src/glu/glu.pc.in					\
 | 
			
		||||
	$(DIRECTORY)/src/glu/sgi/Makefile				\
 | 
			
		||||
	$(DIRECTORY)/src/glu/sgi/Makefile.mgw				\
 | 
			
		||||
	$(DIRECTORY)/src/glu/sgi/Makefile.win				\
 | 
			
		||||
	$(DIRECTORY)/src/glu/sgi/Makefile.DJ				\
 | 
			
		||||
	$(DIRECTORY)/src/glu/sgi/glu.def				\
 | 
			
		||||
	$(DIRECTORY)/src/glu/sgi/dummy.cc				\
 | 
			
		||||
	$(DIRECTORY)/src/glu/sgi/descrip.mms				\
 | 
			
		||||
	$(DIRECTORY)/src/glu/sgi/glu.exports				\
 | 
			
		||||
	$(DIRECTORY)/src/glu/sgi/glu.exports.darwin			\
 | 
			
		||||
	$(DIRECTORY)/src/glu/sgi/mesaglu.opt				\
 | 
			
		||||
@@ -404,6 +387,7 @@ DEMO_FILES = \
 | 
			
		||||
	$(DIRECTORY)/progs/osdemos/Makefile		\
 | 
			
		||||
	$(DIRECTORY)/progs/osdemos/*.c			\
 | 
			
		||||
	$(DIRECTORY)/progs/xdemos/Makefile*		\
 | 
			
		||||
	$(DIRECTORY)/progs/xdemos/descrip.mms		\
 | 
			
		||||
	$(DIRECTORY)/progs/xdemos/*.[chf]		\
 | 
			
		||||
	$(DIRECTORY)/progs/redbook/Makefile*		\
 | 
			
		||||
	$(DIRECTORY)/progs/redbook/README		\
 | 
			
		||||
@@ -419,6 +403,9 @@ DEMO_FILES = \
 | 
			
		||||
	$(DIRECTORY)/progs/windml/*.c			\
 | 
			
		||||
	$(DIRECTORY)/progs/windml/*.bmp			\
 | 
			
		||||
	$(DIRECTORY)/progs/ggi/*.c			\
 | 
			
		||||
	$(DIRECTORY)/windows/VC6/progs/demos/*.dsp	\
 | 
			
		||||
	$(DIRECTORY)/windows/VC6/progs/progs.dsw	\
 | 
			
		||||
	$(DIRECTORY)/windows/VC7/progs/demos/*.vcproj	\
 | 
			
		||||
	$(DIRECTORY)/windows/VC7/progs/progs.sln
 | 
			
		||||
 | 
			
		||||
GLUT_FILES = \
 | 
			
		||||
@@ -428,11 +415,14 @@ GLUT_FILES = \
 | 
			
		||||
	$(DIRECTORY)/src/glut/glx/depend		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/glx/glut.pc.in		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/glx/*def			\
 | 
			
		||||
	$(DIRECTORY)/src/glut/glx/descrip.mms		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/glx/mms_depend		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/glx/*.[ch]		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/beos/*.[ch]		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/beos/*.cpp		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/beos/Makefile		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/dos/*.[ch]		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/dos/Makefile.DJ		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/dos/PC_HW/*.[chS]		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/ggi/*.[ch]		\
 | 
			
		||||
	$(DIRECTORY)/src/glut/ggi/Makefile		\
 | 
			
		||||
@@ -454,13 +444,7 @@ DEPEND_FILES = \
 | 
			
		||||
	$(TOP)/src/glu/sgi/depend
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
LIB_FILES = \
 | 
			
		||||
	$(MAIN_FILES)		\
 | 
			
		||||
	$(EGL_FILES)		\
 | 
			
		||||
	$(GALLIUM_FILES)	\
 | 
			
		||||
	$(DRI_FILES)		\
 | 
			
		||||
	$(SGI_GLU_FILES)	\
 | 
			
		||||
	$(GLW_FILES)
 | 
			
		||||
LIB_FILES = $(MAIN_FILES) $(DRI_FILES) $(SGI_GLU_FILES) $(GLW_FILES)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Everything for new a Mesa release:
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										88
									
								
								Makefile.DJ
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										88
									
								
								Makefile.DJ
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,88 @@
 | 
			
		||||
# Mesa 3-D graphics library
 | 
			
		||||
# Version:  4.0
 | 
			
		||||
# 
 | 
			
		||||
# Copyright (C) 1999  Brian Paul   All Rights Reserved.
 | 
			
		||||
# 
 | 
			
		||||
# Permission is hereby granted, free of charge, to any person obtaining a
 | 
			
		||||
# copy of this software and associated documentation files (the "Software"),
 | 
			
		||||
# to deal in the Software without restriction, including without limitation
 | 
			
		||||
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
 | 
			
		||||
# and/or sell copies of the Software, and to permit persons to whom the
 | 
			
		||||
# Software is furnished to do so, subject to the following conditions:
 | 
			
		||||
# 
 | 
			
		||||
# The above copyright notice and this permission notice shall be included
 | 
			
		||||
# in all copies or substantial portions of the Software.
 | 
			
		||||
# 
 | 
			
		||||
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 | 
			
		||||
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 | 
			
		||||
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
 | 
			
		||||
# BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
 | 
			
		||||
# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 | 
			
		||||
# CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 | 
			
		||||
 | 
			
		||||
# DOS/DJGPP makefile for Mesa
 | 
			
		||||
#
 | 
			
		||||
#  Author: Daniel Borca
 | 
			
		||||
#  Email : dborca@users.sourceforge.net
 | 
			
		||||
#  Web   : http://www.geocities.com/dborca
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#
 | 
			
		||||
#  Available options:
 | 
			
		||||
#
 | 
			
		||||
#    Environment variables:
 | 
			
		||||
#	GLIDE		path to Glide3 SDK; used with FX.
 | 
			
		||||
#			default = $(TOP)/glide3
 | 
			
		||||
#	FX=1		build for 3dfx Glide3. Note that this disables
 | 
			
		||||
#			compilation of most DMesa code and requires fxMesa.
 | 
			
		||||
#			As a consequence, you'll need the DJGPP Glide3
 | 
			
		||||
#			library to build any application.
 | 
			
		||||
#			default = no
 | 
			
		||||
#	X86=1		optimize for x86 (if possible, use MMX, SSE, 3DNow).
 | 
			
		||||
#			default = no
 | 
			
		||||
#
 | 
			
		||||
#    Targets:
 | 
			
		||||
#	all:		build everything
 | 
			
		||||
#	libgl:		build GL
 | 
			
		||||
#	libglu:		build GLU
 | 
			
		||||
#	libglut:	build GLUT
 | 
			
		||||
#	clean:		remove object files
 | 
			
		||||
#	realclean:	remove all generated files
 | 
			
		||||
#
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
.PHONY : all libgl libglu libglut clean realclean
 | 
			
		||||
 | 
			
		||||
CFLAGS = -Wall -W -pedantic
 | 
			
		||||
CFLAGS += -O2 -ffast-math
 | 
			
		||||
 | 
			
		||||
export CFLAGS
 | 
			
		||||
 | 
			
		||||
ifeq ($(wildcard $(addsuffix /rm.exe,$(subst ;, ,$(PATH)))),)
 | 
			
		||||
UNLINK = del $(subst /,\,$(1))
 | 
			
		||||
else
 | 
			
		||||
UNLINK = $(RM) $(1)
 | 
			
		||||
endif
 | 
			
		||||
 | 
			
		||||
all: libgl libglu libglut
 | 
			
		||||
 | 
			
		||||
libgl: lib
 | 
			
		||||
	$(MAKE) -f Makefile.DJ -C src/mesa
 | 
			
		||||
libglu: lib
 | 
			
		||||
	$(MAKE) -f Makefile.DJ -C src/glu/sgi
 | 
			
		||||
libglut: lib
 | 
			
		||||
	$(MAKE) -f Makefile.DJ -C src/glut/dos
 | 
			
		||||
 | 
			
		||||
lib:
 | 
			
		||||
	mkdir lib
 | 
			
		||||
 | 
			
		||||
clean:
 | 
			
		||||
	$(MAKE) -f Makefile.DJ clean -C src/mesa
 | 
			
		||||
	$(MAKE) -f Makefile.DJ clean -C src/glu/mesa
 | 
			
		||||
	$(MAKE) -f Makefile.DJ clean -C src/glu/sgi
 | 
			
		||||
	$(MAKE) -f Makefile.DJ clean -C src/glut/dos
 | 
			
		||||
 | 
			
		||||
realclean: clean
 | 
			
		||||
	-$(call UNLINK,lib/*.a)
 | 
			
		||||
	-$(call UNLINK,lib/*.dxe)
 | 
			
		||||
							
								
								
									
										110
									
								
								Makefile.mgw
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										110
									
								
								Makefile.mgw
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,110 @@
 | 
			
		||||
# Mesa 3-D graphics library
 | 
			
		||||
# Version:  4.0
 | 
			
		||||
# 
 | 
			
		||||
# Copyright (C) 1999  Brian Paul   All Rights Reserved.
 | 
			
		||||
# 
 | 
			
		||||
# Permission is hereby granted, free of charge, to any person obtaining a
 | 
			
		||||
# copy of this software and associated documentation files (the "Software"),
 | 
			
		||||
# to deal in the Software without restriction, including without limitation
 | 
			
		||||
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
 | 
			
		||||
# and/or sell copies of the Software, and to permit persons to whom the
 | 
			
		||||
# Software is furnished to do so, subject to the following conditions:
 | 
			
		||||
# 
 | 
			
		||||
# The above copyright notice and this permission notice shall be included
 | 
			
		||||
# in all copies or substantial portions of the Software.
 | 
			
		||||
# 
 | 
			
		||||
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 | 
			
		||||
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 | 
			
		||||
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
 | 
			
		||||
# BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
 | 
			
		||||
# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 | 
			
		||||
# CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 | 
			
		||||
 | 
			
		||||
# MinGW makefile v1.2 for Mesa
 | 
			
		||||
#
 | 
			
		||||
#  Copyright (C) 2002 - Daniel Borca
 | 
			
		||||
#  Email : dborca@users.sourceforge.net
 | 
			
		||||
#  Web   : http://www.geocities.com/dborca
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#
 | 
			
		||||
#  Available options:
 | 
			
		||||
#
 | 
			
		||||
#    Environment variables:
 | 
			
		||||
#	GLIDE		path to Glide3 SDK; used with FX.
 | 
			
		||||
#			default = $(TOP)/glide3
 | 
			
		||||
#	FX=1		build for 3dfx Glide3. Note that this disables
 | 
			
		||||
#			compilation of most WMesa code and requires fxMesa.
 | 
			
		||||
#			As a consequence, you'll need the Win32 Glide3
 | 
			
		||||
#			library to build any application.
 | 
			
		||||
#			default = no
 | 
			
		||||
#	ICD=1		build the installable client driver interface
 | 
			
		||||
#			(windows opengl driver interface)
 | 
			
		||||
#			default = no
 | 
			
		||||
#	X86=1		optimize for x86 (if possible, use MMX, SSE, 3DNow).
 | 
			
		||||
#			default = no
 | 
			
		||||
#
 | 
			
		||||
#    Targets:
 | 
			
		||||
#	all:		build everything
 | 
			
		||||
#	libgl:		build GL
 | 
			
		||||
#	clean:		remove object files
 | 
			
		||||
#	realclean:	remove all generated files
 | 
			
		||||
#
 | 
			
		||||
 | 
			
		||||
# MinGW core makefile updated for Mesa 7.0
 | 
			
		||||
#
 | 
			
		||||
#  Updated : by Heromyth, on 2007-7-21
 | 
			
		||||
#  Email   : zxpmyth@yahoo.com.cn
 | 
			
		||||
#  Bugs    : 1) All the default settings work fine. But the setting X86=1 can't work. 
 | 
			
		||||
#            The others havn't been tested yet.
 | 
			
		||||
#            2) The generated DLLs are *not* compatible with the ones built
 | 
			
		||||
#            with the other compilers like VC8, especially for GLUT. 
 | 
			
		||||
#            3) MAlthough more tests are needed, it can be used individually!
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
.PHONY : all libgl clean realclean
 | 
			
		||||
 | 
			
		||||
ifeq ($(ICD),1)
 | 
			
		||||
  # when -std=c99 mingw will not define WIN32
 | 
			
		||||
  CFLAGS = -Wall -Werror
 | 
			
		||||
else
 | 
			
		||||
  # I love c89
 | 
			
		||||
  CFLAGS = -Wall -pedantic
 | 
			
		||||
endif
 | 
			
		||||
CFLAGS += -O2 -ffast-math
 | 
			
		||||
 | 
			
		||||
export CFLAGS
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
ifeq ($(wildcard $(addsuffix /rm.exe,$(subst ;, ,$(PATH)))),)
 | 
			
		||||
UNLINK = del $(subst /,\,$(1))
 | 
			
		||||
else
 | 
			
		||||
UNLINK = $(RM) $(1)
 | 
			
		||||
endif
 | 
			
		||||
 | 
			
		||||
all: libgl libglu libglut example
 | 
			
		||||
 | 
			
		||||
libgl: lib
 | 
			
		||||
	$(MAKE) -f Makefile.mgw -C src/mesa
 | 
			
		||||
 | 
			
		||||
libglu: libgl
 | 
			
		||||
	$(MAKE) -f Makefile.mgw -C src/glu/sgi
 | 
			
		||||
 | 
			
		||||
libglut: libglu 
 | 
			
		||||
	$(MAKE) -f Makefile.mgw -C src/glut/glx
 | 
			
		||||
 | 
			
		||||
example: libglut 
 | 
			
		||||
	$(MAKE) -f Makefile.mgw star -C progs/samples
 | 
			
		||||
	copy progs\samples\star.exe lib
 | 
			
		||||
 | 
			
		||||
lib:
 | 
			
		||||
	mkdir lib
 | 
			
		||||
 | 
			
		||||
clean:
 | 
			
		||||
	$(MAKE) -f Makefile.mgw clean -C src/mesa
 | 
			
		||||
	$(MAKE) -f Makefile.mgw clean -C src/glu/sgi
 | 
			
		||||
	$(MAKE) -f Makefile.mgw clean -C src/glut/glx
 | 
			
		||||
 | 
			
		||||
realclean: clean
 | 
			
		||||
	-$(call UNLINK,lib/*.a)
 | 
			
		||||
	-$(call UNLINK,lib/*.dll)
 | 
			
		||||
							
								
								
									
										167
									
								
								SConstruct
									
									
									
									
									
								
							
							
						
						
									
										167
									
								
								SConstruct
									
									
									
									
									
								
							@@ -1,167 +0,0 @@
 | 
			
		||||
#######################################################################
 | 
			
		||||
# Top-level SConstruct
 | 
			
		||||
#
 | 
			
		||||
# For example, invoke scons as 
 | 
			
		||||
#
 | 
			
		||||
#   scons debug=1 dri=0 machine=x86
 | 
			
		||||
#
 | 
			
		||||
# to set configuration variables. Or you can write those options to a file
 | 
			
		||||
# named config.py:
 | 
			
		||||
#
 | 
			
		||||
#   # config.py
 | 
			
		||||
#   debug=1
 | 
			
		||||
#   dri=0
 | 
			
		||||
#   machine='x86'
 | 
			
		||||
# 
 | 
			
		||||
# Invoke
 | 
			
		||||
#
 | 
			
		||||
#   scons -h
 | 
			
		||||
#
 | 
			
		||||
# to get the full list of options. See scons manpage for more info.
 | 
			
		||||
#  
 | 
			
		||||
 | 
			
		||||
import os
 | 
			
		||||
import os.path
 | 
			
		||||
import sys
 | 
			
		||||
 | 
			
		||||
import common
 | 
			
		||||
 | 
			
		||||
#######################################################################
 | 
			
		||||
# Configuration options
 | 
			
		||||
 | 
			
		||||
default_statetrackers = 'mesa'
 | 
			
		||||
 | 
			
		||||
if common.default_platform in ('linux', 'freebsd', 'darwin'):
 | 
			
		||||
	default_drivers = 'softpipe,failover,i915simple,trace'
 | 
			
		||||
	default_winsys = 'xlib'
 | 
			
		||||
elif common.default_platform in ('winddk',):
 | 
			
		||||
	default_drivers = 'softpipe,i915simple,trace'
 | 
			
		||||
	default_winsys = 'all'
 | 
			
		||||
else:
 | 
			
		||||
	default_drivers = 'all'
 | 
			
		||||
	default_winsys = 'all'
 | 
			
		||||
 | 
			
		||||
opts = Variables('config.py')
 | 
			
		||||
common.AddOptions(opts)
 | 
			
		||||
opts.Add(ListVariable('statetrackers', 'state trackers to build', default_statetrackers,
 | 
			
		||||
                     ['mesa', 'python']))
 | 
			
		||||
opts.Add(ListVariable('drivers', 'pipe drivers to build', default_drivers,
 | 
			
		||||
                     ['softpipe', 'failover', 'i915simple', 'i965simple', 'cell', 'trace', 'r300']))
 | 
			
		||||
opts.Add(ListVariable('winsys', 'winsys drivers to build', default_winsys,
 | 
			
		||||
                     ['xlib', 'intel', 'gdi', 'radeon']))
 | 
			
		||||
 | 
			
		||||
opts.Add(EnumVariable('MSVS_VERSION', 'MS Visual C++ version', None, allowed_values=('7.1', '8.0', '9.0')))
 | 
			
		||||
 | 
			
		||||
env = Environment(
 | 
			
		||||
	options = opts,
 | 
			
		||||
	tools = ['gallium'],
 | 
			
		||||
	toolpath = ['#scons'],	
 | 
			
		||||
	ENV = os.environ,
 | 
			
		||||
)
 | 
			
		||||
 | 
			
		||||
Help(opts.GenerateHelpText(env))
 | 
			
		||||
 | 
			
		||||
# replicate options values in local variables
 | 
			
		||||
debug = env['debug']
 | 
			
		||||
dri = env['dri']
 | 
			
		||||
llvm = env['llvm']
 | 
			
		||||
machine = env['machine']
 | 
			
		||||
platform = env['platform']
 | 
			
		||||
 | 
			
		||||
# derived options
 | 
			
		||||
x86 = machine == 'x86'
 | 
			
		||||
ppc = machine == 'ppc'
 | 
			
		||||
gcc = platform in ('linux', 'freebsd', 'darwin')
 | 
			
		||||
msvc = platform in ('windows', 'winddk')
 | 
			
		||||
 | 
			
		||||
Export([
 | 
			
		||||
	'debug', 
 | 
			
		||||
	'x86', 
 | 
			
		||||
	'ppc', 
 | 
			
		||||
	'dri', 
 | 
			
		||||
	'llvm',
 | 
			
		||||
	'platform',
 | 
			
		||||
	'gcc',
 | 
			
		||||
	'msvc',
 | 
			
		||||
])
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#######################################################################
 | 
			
		||||
# Environment setup
 | 
			
		||||
 | 
			
		||||
# Includes
 | 
			
		||||
env.Append(CPPPATH = [
 | 
			
		||||
	'#/include',
 | 
			
		||||
	'#/src/gallium/include',
 | 
			
		||||
	'#/src/gallium/auxiliary',
 | 
			
		||||
	'#/src/gallium/drivers',
 | 
			
		||||
])
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Posix
 | 
			
		||||
if platform in ('posix', 'linux', 'freebsd', 'darwin'):
 | 
			
		||||
	env.Append(CPPDEFINES = [
 | 
			
		||||
		'_POSIX_SOURCE',
 | 
			
		||||
		('_POSIX_C_SOURCE', '199309L'), 
 | 
			
		||||
		'_SVID_SOURCE',
 | 
			
		||||
		'_BSD_SOURCE', 
 | 
			
		||||
		'_GNU_SOURCE',
 | 
			
		||||
		
 | 
			
		||||
		'PTHREADS',
 | 
			
		||||
		'HAVE_POSIX_MEMALIGN',
 | 
			
		||||
	])
 | 
			
		||||
	env.Append(CPPPATH = ['/usr/X11R6/include'])
 | 
			
		||||
	env.Append(LIBPATH = ['/usr/X11R6/lib'])
 | 
			
		||||
	env.Append(LIBS = [
 | 
			
		||||
		'm',
 | 
			
		||||
		'pthread',
 | 
			
		||||
		'expat',
 | 
			
		||||
		'dl',
 | 
			
		||||
	])
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# DRI
 | 
			
		||||
if dri:
 | 
			
		||||
	env.ParseConfig('pkg-config --cflags --libs libdrm')
 | 
			
		||||
	env.Append(CPPDEFINES = [
 | 
			
		||||
		('USE_EXTERNAL_DXTN_LIB', '1'), 
 | 
			
		||||
		'IN_DRI_DRIVER',
 | 
			
		||||
		'GLX_DIRECT_RENDERING',
 | 
			
		||||
		'GLX_INDIRECT_RENDERING',
 | 
			
		||||
	])
 | 
			
		||||
 | 
			
		||||
# LLVM
 | 
			
		||||
if llvm:
 | 
			
		||||
	# See also http://www.scons.org/wiki/UsingPkgConfig
 | 
			
		||||
	env.ParseConfig('llvm-config --cflags --ldflags --libs backend bitreader engine instrumentation interpreter ipo')
 | 
			
		||||
	env.Append(CPPDEFINES = ['MESA_LLVM'])
 | 
			
		||||
        # Force C++ linkage
 | 
			
		||||
	env['LINK'] = env['CXX']
 | 
			
		||||
 | 
			
		||||
# libGL
 | 
			
		||||
if platform in ('linux', 'freebsd', 'darwin'):
 | 
			
		||||
	env.Append(LIBS = [
 | 
			
		||||
		'X11',
 | 
			
		||||
		'Xext',
 | 
			
		||||
		'Xxf86vm',
 | 
			
		||||
		'Xdamage',
 | 
			
		||||
		'Xfixes',
 | 
			
		||||
	])
 | 
			
		||||
 | 
			
		||||
# for debugging
 | 
			
		||||
#print env.Dump()
 | 
			
		||||
 | 
			
		||||
Export('env')
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#######################################################################
 | 
			
		||||
# Invoke SConscripts
 | 
			
		||||
 | 
			
		||||
# TODO: Build several variants at the same time?
 | 
			
		||||
# http://www.scons.org/wiki/SimultaneousVariantBuilds
 | 
			
		||||
 | 
			
		||||
SConscript(
 | 
			
		||||
	'src/SConscript',
 | 
			
		||||
	variant_dir = env['build'],
 | 
			
		||||
	duplicate = 0 # http://www.scons.org/doc/0.97/HTML/scons-user/x2261.html
 | 
			
		||||
)
 | 
			
		||||
@@ -11,8 +11,6 @@ if test "x$SRCDIR" != "x$ORIGDIR"; then
 | 
			
		||||
	exit 1
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
MAKEFLAGS=""
 | 
			
		||||
 | 
			
		||||
autoreconf -v --install || exit 1
 | 
			
		||||
 | 
			
		||||
"$srcdir"/configure "$@"
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										71
									
								
								bin/config.guess
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										71
									
								
								bin/config.guess
									
									
									
									
										vendored
									
									
								
							@@ -1,10 +1,10 @@
 | 
			
		||||
#! /bin/sh
 | 
			
		||||
# Attempt to guess a canonical system name.
 | 
			
		||||
#   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
 | 
			
		||||
#   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
 | 
			
		||||
#   Free Software Foundation, Inc.
 | 
			
		||||
#   2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation,
 | 
			
		||||
#   Inc.
 | 
			
		||||
 | 
			
		||||
timestamp='2009-02-03'
 | 
			
		||||
timestamp='2007-07-22'
 | 
			
		||||
 | 
			
		||||
# This file is free software; you can redistribute it and/or modify it
 | 
			
		||||
# under the terms of the GNU General Public License as published by
 | 
			
		||||
@@ -56,8 +56,8 @@ version="\
 | 
			
		||||
GNU config.guess ($timestamp)
 | 
			
		||||
 | 
			
		||||
Originally written by Per Bothner.
 | 
			
		||||
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
 | 
			
		||||
2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 | 
			
		||||
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
 | 
			
		||||
Free Software Foundation, Inc.
 | 
			
		||||
 | 
			
		||||
This is free software; see the source for copying conditions.  There is NO
 | 
			
		||||
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
 | 
			
		||||
@@ -331,20 +331,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
 | 
			
		||||
	echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
 | 
			
		||||
	exit ;;
 | 
			
		||||
    i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
 | 
			
		||||
	eval $set_cc_for_build
 | 
			
		||||
	SUN_ARCH="i386"
 | 
			
		||||
	# If there is a compiler, see if it is configured for 64-bit objects.
 | 
			
		||||
	# Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
 | 
			
		||||
	# This test works for both compilers.
 | 
			
		||||
	if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
 | 
			
		||||
	    if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
 | 
			
		||||
		(CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
 | 
			
		||||
		grep IS_64BIT_ARCH >/dev/null
 | 
			
		||||
	    then
 | 
			
		||||
		SUN_ARCH="x86_64"
 | 
			
		||||
	    fi
 | 
			
		||||
	fi
 | 
			
		||||
	echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
 | 
			
		||||
	echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
 | 
			
		||||
	exit ;;
 | 
			
		||||
    sun4*:SunOS:6*:*)
 | 
			
		||||
	# According to config.sub, this is the proper way to canonicalize
 | 
			
		||||
@@ -545,7 +532,7 @@ EOF
 | 
			
		||||
		echo rs6000-ibm-aix3.2
 | 
			
		||||
	fi
 | 
			
		||||
	exit ;;
 | 
			
		||||
    *:AIX:*:[456])
 | 
			
		||||
    *:AIX:*:[45])
 | 
			
		||||
	IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
 | 
			
		||||
	if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
 | 
			
		||||
		IBM_ARCH=rs6000
 | 
			
		||||
@@ -809,12 +796,9 @@ EOF
 | 
			
		||||
	    x86)
 | 
			
		||||
		echo i586-pc-interix${UNAME_RELEASE}
 | 
			
		||||
		exit ;;
 | 
			
		||||
	    EM64T | authenticamd | genuineintel)
 | 
			
		||||
	    EM64T | authenticamd)
 | 
			
		||||
		echo x86_64-unknown-interix${UNAME_RELEASE}
 | 
			
		||||
		exit ;;
 | 
			
		||||
	    IA64)
 | 
			
		||||
		echo ia64-unknown-interix${UNAME_RELEASE}
 | 
			
		||||
		exit ;;
 | 
			
		||||
	esac ;;
 | 
			
		||||
    [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
 | 
			
		||||
	echo i${UNAME_MACHINE}-pc-mks
 | 
			
		||||
@@ -849,14 +833,7 @@ EOF
 | 
			
		||||
	echo ${UNAME_MACHINE}-pc-minix
 | 
			
		||||
	exit ;;
 | 
			
		||||
    arm*:Linux:*:*)
 | 
			
		||||
	eval $set_cc_for_build
 | 
			
		||||
	if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
 | 
			
		||||
	    | grep -q __ARM_EABI__
 | 
			
		||||
	then
 | 
			
		||||
	    echo ${UNAME_MACHINE}-unknown-linux-gnu
 | 
			
		||||
	else
 | 
			
		||||
	    echo ${UNAME_MACHINE}-unknown-linux-gnueabi
 | 
			
		||||
	fi
 | 
			
		||||
	echo ${UNAME_MACHINE}-unknown-linux-gnu
 | 
			
		||||
	exit ;;
 | 
			
		||||
    avr32*:Linux:*:*)
 | 
			
		||||
	echo ${UNAME_MACHINE}-unknown-linux-gnu
 | 
			
		||||
@@ -948,9 +925,6 @@ EOF
 | 
			
		||||
	if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
 | 
			
		||||
	echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
 | 
			
		||||
	exit ;;
 | 
			
		||||
    padre:Linux:*:*)
 | 
			
		||||
	echo sparc-unknown-linux-gnu
 | 
			
		||||
	exit ;;
 | 
			
		||||
    parisc:Linux:*:* | hppa:Linux:*:*)
 | 
			
		||||
	# Look for CPU level
 | 
			
		||||
	case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
 | 
			
		||||
@@ -980,8 +954,8 @@ EOF
 | 
			
		||||
    x86_64:Linux:*:*)
 | 
			
		||||
	echo x86_64-unknown-linux-gnu
 | 
			
		||||
	exit ;;
 | 
			
		||||
    xtensa*:Linux:*:*)
 | 
			
		||||
    	echo ${UNAME_MACHINE}-unknown-linux-gnu
 | 
			
		||||
    xtensa:Linux:*:*)
 | 
			
		||||
    	echo xtensa-unknown-linux-gnu
 | 
			
		||||
	exit ;;
 | 
			
		||||
    i*86:Linux:*:*)
 | 
			
		||||
	# The BFD linker knows what the default object file format is, so
 | 
			
		||||
@@ -1001,6 +975,9 @@ EOF
 | 
			
		||||
	  a.out-i386-linux)
 | 
			
		||||
		echo "${UNAME_MACHINE}-pc-linux-gnuaout"
 | 
			
		||||
		exit ;;
 | 
			
		||||
	  coff-i386)
 | 
			
		||||
		echo "${UNAME_MACHINE}-pc-linux-gnucoff"
 | 
			
		||||
		exit ;;
 | 
			
		||||
	  "")
 | 
			
		||||
		# Either a pre-BFD a.out linker (linux-gnuoldld) or
 | 
			
		||||
		# one that does not give us useful --help.
 | 
			
		||||
@@ -1154,16 +1131,6 @@ EOF
 | 
			
		||||
    3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
 | 
			
		||||
        /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
 | 
			
		||||
          && { echo i486-ncr-sysv4; exit; } ;;
 | 
			
		||||
    NCR*:*:4.2:* | MPRAS*:*:4.2:*)
 | 
			
		||||
	OS_REL='.3'
 | 
			
		||||
	test -r /etc/.relid \
 | 
			
		||||
	    && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
 | 
			
		||||
	/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
 | 
			
		||||
	    && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
 | 
			
		||||
	/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
 | 
			
		||||
	    && { echo i586-ncr-sysv4.3${OS_REL}; exit; }
 | 
			
		||||
	/bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \
 | 
			
		||||
	    && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
 | 
			
		||||
    m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
 | 
			
		||||
	echo m68k-unknown-lynxos${UNAME_RELEASE}
 | 
			
		||||
	exit ;;
 | 
			
		||||
@@ -1239,9 +1206,6 @@ EOF
 | 
			
		||||
    BePC:BeOS:*:*)	# BeOS running on Intel PC compatible.
 | 
			
		||||
	echo i586-pc-beos
 | 
			
		||||
	exit ;;
 | 
			
		||||
    BePC:Haiku:*:*)	# Haiku running on Intel PC compatible.
 | 
			
		||||
	echo i586-pc-haiku
 | 
			
		||||
	exit ;;
 | 
			
		||||
    SX-4:SUPER-UX:*:*)
 | 
			
		||||
	echo sx4-nec-superux${UNAME_RELEASE}
 | 
			
		||||
	exit ;;
 | 
			
		||||
@@ -1350,9 +1314,6 @@ EOF
 | 
			
		||||
    i*86:rdos:*:*)
 | 
			
		||||
	echo ${UNAME_MACHINE}-pc-rdos
 | 
			
		||||
	exit ;;
 | 
			
		||||
    i*86:AROS:*:*)
 | 
			
		||||
	echo ${UNAME_MACHINE}-pc-aros
 | 
			
		||||
	exit ;;
 | 
			
		||||
esac
 | 
			
		||||
 | 
			
		||||
#echo '(No uname command or uname output not recognized.)' 1>&2
 | 
			
		||||
@@ -1513,9 +1474,9 @@ This script, last modified $timestamp, has failed to recognize
 | 
			
		||||
the operating system you are using. It is advised that you
 | 
			
		||||
download the most up to date version of the config scripts from
 | 
			
		||||
 | 
			
		||||
  http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
 | 
			
		||||
  http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.guess
 | 
			
		||||
and
 | 
			
		||||
  http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
 | 
			
		||||
  http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.sub
 | 
			
		||||
 | 
			
		||||
If the version you run ($0) is already up to date, please
 | 
			
		||||
send the following data and any information you think might be
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										95
									
								
								bin/config.sub
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										95
									
								
								bin/config.sub
									
									
									
									
										vendored
									
									
								
							@@ -1,10 +1,10 @@
 | 
			
		||||
#! /bin/sh
 | 
			
		||||
# Configuration validation subroutine script.
 | 
			
		||||
#   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
 | 
			
		||||
#   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
 | 
			
		||||
#   Free Software Foundation, Inc.
 | 
			
		||||
#   2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation,
 | 
			
		||||
#   Inc.
 | 
			
		||||
 | 
			
		||||
timestamp='2009-02-03'
 | 
			
		||||
timestamp='2007-06-28'
 | 
			
		||||
 | 
			
		||||
# This file is (in principle) common to ALL GNU software.
 | 
			
		||||
# The presence of a machine in this file suggests that SOME GNU software
 | 
			
		||||
@@ -72,8 +72,8 @@ Report bugs and patches to <config-patches@gnu.org>."
 | 
			
		||||
version="\
 | 
			
		||||
GNU config.sub ($timestamp)
 | 
			
		||||
 | 
			
		||||
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
 | 
			
		||||
2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 | 
			
		||||
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
 | 
			
		||||
Free Software Foundation, Inc.
 | 
			
		||||
 | 
			
		||||
This is free software; see the source for copying conditions.  There is NO
 | 
			
		||||
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
 | 
			
		||||
@@ -122,7 +122,6 @@ maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
 | 
			
		||||
case $maybe_os in
 | 
			
		||||
  nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \
 | 
			
		||||
  uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \
 | 
			
		||||
  kopensolaris*-gnu* | \
 | 
			
		||||
  storm-chaos* | os2-emx* | rtmk-nova*)
 | 
			
		||||
    os=-$maybe_os
 | 
			
		||||
    basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
 | 
			
		||||
@@ -250,16 +249,13 @@ case $basic_machine in
 | 
			
		||||
	| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
 | 
			
		||||
	| i370 | i860 | i960 | ia64 \
 | 
			
		||||
	| ip2k | iq2000 \
 | 
			
		||||
	| lm32 \
 | 
			
		||||
	| m32c | m32r | m32rle | m68000 | m68k | m88k \
 | 
			
		||||
	| maxq | mb | microblaze | mcore | mep | metag \
 | 
			
		||||
	| maxq | mb | microblaze | mcore | mep \
 | 
			
		||||
	| mips | mipsbe | mipseb | mipsel | mipsle \
 | 
			
		||||
	| mips16 \
 | 
			
		||||
	| mips64 | mips64el \
 | 
			
		||||
	| mips64octeon | mips64octeonel \
 | 
			
		||||
	| mips64orion | mips64orionel \
 | 
			
		||||
	| mips64r5900 | mips64r5900el \
 | 
			
		||||
	| mips64vr | mips64vrel \
 | 
			
		||||
	| mips64orion | mips64orionel \
 | 
			
		||||
	| mips64vr4100 | mips64vr4100el \
 | 
			
		||||
	| mips64vr4300 | mips64vr4300el \
 | 
			
		||||
	| mips64vr5000 | mips64vr5000el \
 | 
			
		||||
@@ -281,7 +277,7 @@ case $basic_machine in
 | 
			
		||||
	| powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
 | 
			
		||||
	| pyramid \
 | 
			
		||||
	| score \
 | 
			
		||||
	| sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
 | 
			
		||||
	| sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
 | 
			
		||||
	| sh64 | sh64le \
 | 
			
		||||
	| sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \
 | 
			
		||||
	| sparcv8 | sparcv9 | sparcv9b | sparcv9v \
 | 
			
		||||
@@ -290,7 +286,7 @@ case $basic_machine in
 | 
			
		||||
	| v850 | v850e \
 | 
			
		||||
	| we32k \
 | 
			
		||||
	| x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \
 | 
			
		||||
	| z8k | z80)
 | 
			
		||||
	| z8k)
 | 
			
		||||
		basic_machine=$basic_machine-unknown
 | 
			
		||||
		;;
 | 
			
		||||
	m6811 | m68hc11 | m6812 | m68hc12)
 | 
			
		||||
@@ -333,17 +329,14 @@ case $basic_machine in
 | 
			
		||||
	| hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
 | 
			
		||||
	| i*86-* | i860-* | i960-* | ia64-* \
 | 
			
		||||
	| ip2k-* | iq2000-* \
 | 
			
		||||
	| lm32-* \
 | 
			
		||||
	| m32c-* | m32r-* | m32rle-* \
 | 
			
		||||
	| m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
 | 
			
		||||
	| m88110-* | m88k-* | maxq-* | mcore-* | metag-* \
 | 
			
		||||
	| m88110-* | m88k-* | maxq-* | mcore-* \
 | 
			
		||||
	| mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
 | 
			
		||||
	| mips16-* \
 | 
			
		||||
	| mips64-* | mips64el-* \
 | 
			
		||||
	| mips64octeon-* | mips64octeonel-* \
 | 
			
		||||
	| mips64orion-* | mips64orionel-* \
 | 
			
		||||
	| mips64r5900-* | mips64r5900el-* \
 | 
			
		||||
	| mips64vr-* | mips64vrel-* \
 | 
			
		||||
	| mips64orion-* | mips64orionel-* \
 | 
			
		||||
	| mips64vr4100-* | mips64vr4100el-* \
 | 
			
		||||
	| mips64vr4300-* | mips64vr4300el-* \
 | 
			
		||||
	| mips64vr5000-* | mips64vr5000el-* \
 | 
			
		||||
@@ -365,24 +358,20 @@ case $basic_machine in
 | 
			
		||||
	| powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
 | 
			
		||||
	| pyramid-* \
 | 
			
		||||
	| romp-* | rs6000-* \
 | 
			
		||||
	| sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
 | 
			
		||||
	| sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
 | 
			
		||||
	| shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
 | 
			
		||||
	| sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \
 | 
			
		||||
	| sparclite-* \
 | 
			
		||||
	| sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \
 | 
			
		||||
	| tahoe-* | thumb-* \
 | 
			
		||||
	| tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* | tile-* \
 | 
			
		||||
	| tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
 | 
			
		||||
	| tron-* \
 | 
			
		||||
	| v850-* | v850e-* | vax-* \
 | 
			
		||||
	| we32k-* \
 | 
			
		||||
	| x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \
 | 
			
		||||
	| xstormy16-* | xtensa*-* \
 | 
			
		||||
	| xstormy16-* | xtensa-* \
 | 
			
		||||
	| ymp-* \
 | 
			
		||||
	| z8k-* | z80-*)
 | 
			
		||||
		;;
 | 
			
		||||
	# Recognize the basic CPU types without company name, with glob match.
 | 
			
		||||
	xtensa*)
 | 
			
		||||
		basic_machine=$basic_machine-unknown
 | 
			
		||||
	| z8k-*)
 | 
			
		||||
		;;
 | 
			
		||||
	# Recognize the various machine names and aliases which stand
 | 
			
		||||
	# for a CPU type and a company and sometimes even an OS.
 | 
			
		||||
@@ -446,10 +435,6 @@ case $basic_machine in
 | 
			
		||||
		basic_machine=m68k-apollo
 | 
			
		||||
		os=-bsd
 | 
			
		||||
		;;
 | 
			
		||||
	aros)
 | 
			
		||||
		basic_machine=i386-pc
 | 
			
		||||
		os=-aros
 | 
			
		||||
		;;
 | 
			
		||||
	aux)
 | 
			
		||||
		basic_machine=m68k-apple
 | 
			
		||||
		os=-aux
 | 
			
		||||
@@ -458,22 +443,10 @@ case $basic_machine in
 | 
			
		||||
		basic_machine=ns32k-sequent
 | 
			
		||||
		os=-dynix
 | 
			
		||||
		;;
 | 
			
		||||
	blackfin)
 | 
			
		||||
		basic_machine=bfin-unknown
 | 
			
		||||
		os=-linux
 | 
			
		||||
		;;
 | 
			
		||||
	blackfin-*)
 | 
			
		||||
		basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'`
 | 
			
		||||
		os=-linux
 | 
			
		||||
		;;
 | 
			
		||||
	c90)
 | 
			
		||||
		basic_machine=c90-cray
 | 
			
		||||
		os=-unicos
 | 
			
		||||
		;;
 | 
			
		||||
        cegcc)
 | 
			
		||||
		basic_machine=arm-unknown
 | 
			
		||||
		os=-cegcc
 | 
			
		||||
		;;
 | 
			
		||||
	convex-c1)
 | 
			
		||||
		basic_machine=c1-convex
 | 
			
		||||
		os=-bsd
 | 
			
		||||
@@ -541,10 +514,6 @@ case $basic_machine in
 | 
			
		||||
		basic_machine=m88k-motorola
 | 
			
		||||
		os=-sysv3
 | 
			
		||||
		;;
 | 
			
		||||
	dicos)
 | 
			
		||||
		basic_machine=i686-pc
 | 
			
		||||
		os=-dicos
 | 
			
		||||
		;;
 | 
			
		||||
	djgpp)
 | 
			
		||||
		basic_machine=i586-pc
 | 
			
		||||
		os=-msdosdjgpp
 | 
			
		||||
@@ -699,14 +668,6 @@ case $basic_machine in
 | 
			
		||||
		basic_machine=m68k-isi
 | 
			
		||||
		os=-sysv
 | 
			
		||||
		;;
 | 
			
		||||
	m68knommu)
 | 
			
		||||
		basic_machine=m68k-unknown
 | 
			
		||||
		os=-linux
 | 
			
		||||
		;;
 | 
			
		||||
	m68knommu-*)
 | 
			
		||||
		basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'`
 | 
			
		||||
		os=-linux
 | 
			
		||||
		;;
 | 
			
		||||
	m88k-omron*)
 | 
			
		||||
		basic_machine=m88k-omron
 | 
			
		||||
		;;
 | 
			
		||||
@@ -852,14 +813,6 @@ case $basic_machine in
 | 
			
		||||
		basic_machine=i860-intel
 | 
			
		||||
		os=-osf
 | 
			
		||||
		;;
 | 
			
		||||
	parisc)
 | 
			
		||||
		basic_machine=hppa-unknown
 | 
			
		||||
		os=-linux
 | 
			
		||||
		;;
 | 
			
		||||
	parisc-*)
 | 
			
		||||
		basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'`
 | 
			
		||||
		os=-linux
 | 
			
		||||
		;;
 | 
			
		||||
	pbd)
 | 
			
		||||
		basic_machine=sparc-tti
 | 
			
		||||
		;;
 | 
			
		||||
@@ -1068,10 +1021,6 @@ case $basic_machine in
 | 
			
		||||
		basic_machine=tic6x-unknown
 | 
			
		||||
		os=-coff
 | 
			
		||||
		;;
 | 
			
		||||
	tile*)
 | 
			
		||||
		basic_machine=tile-unknown
 | 
			
		||||
		os=-linux-gnu
 | 
			
		||||
		;;
 | 
			
		||||
	tx39)
 | 
			
		||||
		basic_machine=mipstx39-unknown
 | 
			
		||||
		;;
 | 
			
		||||
@@ -1147,10 +1096,6 @@ case $basic_machine in
 | 
			
		||||
		basic_machine=z8k-unknown
 | 
			
		||||
		os=-sim
 | 
			
		||||
		;;
 | 
			
		||||
	z80-*-coff)
 | 
			
		||||
		basic_machine=z80-unknown
 | 
			
		||||
		os=-sim
 | 
			
		||||
		;;
 | 
			
		||||
	none)
 | 
			
		||||
		basic_machine=none-none
 | 
			
		||||
		os=-none
 | 
			
		||||
@@ -1189,7 +1134,7 @@ case $basic_machine in
 | 
			
		||||
	we32k)
 | 
			
		||||
		basic_machine=we32k-att
 | 
			
		||||
		;;
 | 
			
		||||
	sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele)
 | 
			
		||||
	sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele)
 | 
			
		||||
		basic_machine=sh-unknown
 | 
			
		||||
		;;
 | 
			
		||||
	sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v)
 | 
			
		||||
@@ -1261,9 +1206,8 @@ case $os in
 | 
			
		||||
	-gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
 | 
			
		||||
	      | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\
 | 
			
		||||
	      | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
 | 
			
		||||
	      | -kopensolaris* \
 | 
			
		||||
	      | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
 | 
			
		||||
	      | -aos* | -aros* \
 | 
			
		||||
	      | -aos* \
 | 
			
		||||
	      | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
 | 
			
		||||
	      | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
 | 
			
		||||
	      | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \
 | 
			
		||||
@@ -1272,7 +1216,7 @@ case $os in
 | 
			
		||||
	      | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
 | 
			
		||||
	      | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
 | 
			
		||||
	      | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
 | 
			
		||||
	      | -chorusos* | -chorusrdb* | -cegcc* \
 | 
			
		||||
	      | -chorusos* | -chorusrdb* \
 | 
			
		||||
	      | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
 | 
			
		||||
	      | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \
 | 
			
		||||
	      | -uxpv* | -beos* | -mpeix* | -udk* \
 | 
			
		||||
@@ -1412,9 +1356,6 @@ case $os in
 | 
			
		||||
	-zvmoe)
 | 
			
		||||
		os=-zvmoe
 | 
			
		||||
		;;
 | 
			
		||||
	-dicos*)
 | 
			
		||||
		os=-dicos
 | 
			
		||||
		;;
 | 
			
		||||
	-none)
 | 
			
		||||
		;;
 | 
			
		||||
	*)
 | 
			
		||||
 
 | 
			
		||||
@@ -66,11 +66,8 @@ if [ $# -ge 2 ] ; then
 | 
			
		||||
 | 
			
		||||
		elif [ -f "$FILE" ] ; then
 | 
			
		||||
			#echo "$FILE" is a regular file
 | 
			
		||||
			# Only copy if the files differ
 | 
			
		||||
			if ! cmp -s $FILE $DEST/`basename $FILE`; then
 | 
			
		||||
				$RM "$DEST/`basename $FILE`"
 | 
			
		||||
				cp "$FILE" "$DEST"
 | 
			
		||||
			fi
 | 
			
		||||
			$RM "$DEST/`basename $FILE`"
 | 
			
		||||
			cp "$FILE" "$DEST"
 | 
			
		||||
			if [ $MODE ] ; then
 | 
			
		||||
				FILE=`basename "$FILE"`
 | 
			
		||||
				chmod $MODE "$DEST/$FILE"
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										72
									
								
								bin/mklib
									
									
									
									
									
								
							
							
						
						
									
										72
									
								
								bin/mklib
									
									
									
									
									
								
							@@ -176,23 +176,6 @@ if [ ${ARCH} = "auto" ] ; then
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
if [ $STATIC = 1 ]; then
 | 
			
		||||
    # filter out linker options inside object list
 | 
			
		||||
    NEWOBJECTS=""
 | 
			
		||||
    for OBJ in $OBJECTS ; do
 | 
			
		||||
	case $OBJ in
 | 
			
		||||
	    -Wl,*)
 | 
			
		||||
		echo "mklib: warning: ignoring $OBJ for static library"
 | 
			
		||||
		;;
 | 
			
		||||
	    *)
 | 
			
		||||
		NEWOBJECTS="$NEWOBJECTS $OBJ"
 | 
			
		||||
		;;
 | 
			
		||||
	esac
 | 
			
		||||
    done
 | 
			
		||||
    OBJECTS=$NEWOBJECTS
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#
 | 
			
		||||
# Error checking
 | 
			
		||||
#
 | 
			
		||||
@@ -277,34 +260,9 @@ case $ARCH in
 | 
			
		||||
                OPTS=${ALTOPTS}
 | 
			
		||||
            fi
 | 
			
		||||
            rm -f ${LIBNAME}
 | 
			
		||||
 | 
			
		||||
	    # expand any .a objects into constituent .o files.
 | 
			
		||||
	    NEWOBJECTS=""
 | 
			
		||||
	    DELETIA=""
 | 
			
		||||
	    for OBJ in $OBJECTS ; do
 | 
			
		||||
		case $OBJ in
 | 
			
		||||
		    *.a)
 | 
			
		||||
			# extract the .o files from this .a archive
 | 
			
		||||
			FILES=`ar t $OBJ`
 | 
			
		||||
			ar x $OBJ
 | 
			
		||||
			NEWOBJECTS="$NEWOBJECTS $FILES"
 | 
			
		||||
			# keep track of temporary .o files and delete them below
 | 
			
		||||
			DELETIA="$DELETIA $FILES"
 | 
			
		||||
			;;
 | 
			
		||||
		    *)
 | 
			
		||||
			# ordinary .o file
 | 
			
		||||
			NEWOBJECTS="$NEWOBJECTS $OBJ"
 | 
			
		||||
			;;
 | 
			
		||||
		esac
 | 
			
		||||
	    done
 | 
			
		||||
 | 
			
		||||
            # make lib
 | 
			
		||||
            ${LINK} ${OPTS} ${LIBNAME} ${NEWOBJECTS}
 | 
			
		||||
            ${LINK} ${OPTS} ${LIBNAME} ${OBJECTS}
 | 
			
		||||
            ranlib ${LIBNAME}
 | 
			
		||||
 | 
			
		||||
	    # remove temporary extracted .o files
 | 
			
		||||
	    rm -f ${DELETIA}
 | 
			
		||||
 | 
			
		||||
            # finish up
 | 
			
		||||
            FINAL_LIBS=${LIBNAME}
 | 
			
		||||
        else
 | 
			
		||||
@@ -414,30 +372,6 @@ case $ARCH in
 | 
			
		||||
		fi
 | 
			
		||||
	    fi
 | 
			
		||||
 | 
			
		||||
	    # If using Sun C++ compiler, need to tell it not to add runpaths
 | 
			
		||||
	    # that are specific to the build machine
 | 
			
		||||
	    if [ ${LINK} = "CC" ] ; then
 | 
			
		||||
		OPTS="${OPTS} -norunpath"
 | 
			
		||||
	    fi
 | 
			
		||||
 | 
			
		||||
	    # Solaris linker requires explicitly listing the Standard C & C++
 | 
			
		||||
	    # libraries in the link path when building shared objects
 | 
			
		||||
	    if [ ${LINK} = "CC" ] ; then
 | 
			
		||||
		DEPS="${DEPS} -lCrun"
 | 
			
		||||
	    fi
 | 
			
		||||
	    DEPS="${DEPS} -lc"
 | 
			
		||||
 | 
			
		||||
	    if [ $EXPORTS ] ; then
 | 
			
		||||
		# Make the 'mapfile.scope' linker mapfile
 | 
			
		||||
		echo "{" > mapfile.scope
 | 
			
		||||
		echo "global:" >> mapfile.scope
 | 
			
		||||
		sed 's/$/;/' ${EXPORTS} >> mapfile.scope
 | 
			
		||||
		echo "local:" >> mapfile.scope
 | 
			
		||||
		echo "    *;" >> mapfile.scope
 | 
			
		||||
		echo "};" >> mapfile.scope
 | 
			
		||||
		OPTS="${OPTS} -Wl,-Mmapfile.scope"
 | 
			
		||||
	    fi
 | 
			
		||||
 | 
			
		||||
	    # Check if objects are SPARC v9
 | 
			
		||||
	    # file says: ELF 64-bit MSB relocatable SPARCV9 Version 1
 | 
			
		||||
	    set ${OBJECTS}
 | 
			
		||||
@@ -450,19 +384,17 @@ case $ARCH in
 | 
			
		||||
            if [ "${ALTOPTS}" ] ; then
 | 
			
		||||
                OPTS=${ALTOPTS}
 | 
			
		||||
            fi
 | 
			
		||||
 | 
			
		||||
	    # for debug:
 | 
			
		||||
	    #echo "mklib: linker is" ${LINK} ${OPTS}
 | 
			
		||||
	    if [ $NOPREFIX = 1 ] ; then
 | 
			
		||||
		rm -f ${LIBNAME}
 | 
			
		||||
		${LINK} ${OPTS} ${LDFLAGS} -o ${LIBNAME} ${OBJECTS} ${DEPS}
 | 
			
		||||
		FINAL_LIBS="${LIBNAME}"
 | 
			
		||||
	    else
 | 
			
		||||
		rm -f ${LIBNAME}.${MAJOR} ${LIBNAME}
 | 
			
		||||
		${LINK} ${OPTS} ${LDFLAGS} -o ${LIBNAME}.${MAJOR} -h ${LIBNAME}.${MAJOR} ${OBJECTS} ${DEPS}
 | 
			
		||||
		ln -s ${LIBNAME}.${MAJOR} ${LIBNAME}
 | 
			
		||||
		FINAL_LIBS="${LIBNAME}.${MAJOR} ${LIBNAME}"
 | 
			
		||||
	    fi
 | 
			
		||||
	    FINAL_LIBS="${LIBNAME}.${MAJOR} ${LIBNAME}"
 | 
			
		||||
	fi
 | 
			
		||||
	;;
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										366
									
								
								bin/raw2png.py
									
									
									
									
									
								
							
							
						
						
									
										366
									
								
								bin/raw2png.py
									
									
									
									
									
								
							@@ -1,366 +0,0 @@
 | 
			
		||||
#!/usr/bin/env python
 | 
			
		||||
##########################################################################
 | 
			
		||||
# 
 | 
			
		||||
# Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas.
 | 
			
		||||
# All Rights Reserved.
 | 
			
		||||
# 
 | 
			
		||||
# Permission is hereby granted, free of charge, to any person obtaining a
 | 
			
		||||
# copy of this software and associated documentation files (the
 | 
			
		||||
# "Software"), to deal in the Software without restriction, including
 | 
			
		||||
# without limitation the rights to use, copy, modify, merge, publish,
 | 
			
		||||
# distribute, sub license, and/or sell copies of the Software, and to
 | 
			
		||||
# permit persons to whom the Software is furnished to do so, subject to
 | 
			
		||||
# the following conditions:
 | 
			
		||||
# 
 | 
			
		||||
# The above copyright notice and this permission notice (including the
 | 
			
		||||
# next paragraph) shall be included in all copies or substantial portions
 | 
			
		||||
# of the Software.
 | 
			
		||||
# 
 | 
			
		||||
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 | 
			
		||||
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 | 
			
		||||
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
 | 
			
		||||
# IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
 | 
			
		||||
# ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
 | 
			
		||||
# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
 | 
			
		||||
# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 | 
			
		||||
# 
 | 
			
		||||
##########################################################################
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
import os.path
 | 
			
		||||
import sys
 | 
			
		||||
import struct
 | 
			
		||||
import Image # http://www.pythonware.com/products/pil/
 | 
			
		||||
 | 
			
		||||
PIPE_FORMAT_LAYOUT_RGBAZS   = 0
 | 
			
		||||
PIPE_FORMAT_LAYOUT_YCBCR    = 1
 | 
			
		||||
PIPE_FORMAT_LAYOUT_DXT      = 2
 | 
			
		||||
PIPE_FORMAT_LAYOUT_MIXED    = 3
 | 
			
		||||
 | 
			
		||||
PIPE_FORMAT_COMP_R    = 0
 | 
			
		||||
PIPE_FORMAT_COMP_G    = 1
 | 
			
		||||
PIPE_FORMAT_COMP_B    = 2
 | 
			
		||||
PIPE_FORMAT_COMP_A    = 3
 | 
			
		||||
PIPE_FORMAT_COMP_0    = 4
 | 
			
		||||
PIPE_FORMAT_COMP_1    = 5
 | 
			
		||||
PIPE_FORMAT_COMP_Z    = 6
 | 
			
		||||
PIPE_FORMAT_COMP_S    = 7
 | 
			
		||||
 | 
			
		||||
PIPE_FORMAT_TYPE_UNKNOWN = 0
 | 
			
		||||
PIPE_FORMAT_TYPE_FLOAT   = 1
 | 
			
		||||
PIPE_FORMAT_TYPE_UNORM   = 2
 | 
			
		||||
PIPE_FORMAT_TYPE_SNORM   = 3
 | 
			
		||||
PIPE_FORMAT_TYPE_USCALED = 4
 | 
			
		||||
PIPE_FORMAT_TYPE_SSCALED = 5
 | 
			
		||||
PIPE_FORMAT_TYPE_SRGB    = 6
 | 
			
		||||
PIPE_FORMAT_TYPE_FIXED   = 7
 | 
			
		||||
 | 
			
		||||
def _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, EXP2, TYPE ):
 | 
			
		||||
   return ((PIPE_FORMAT_LAYOUT_RGBAZS << 0) |\
 | 
			
		||||
   ((SWZ) << 2) |\
 | 
			
		||||
   ((SIZEX) << 14) |\
 | 
			
		||||
   ((SIZEY) << 17) |\
 | 
			
		||||
   ((SIZEZ) << 20) |\
 | 
			
		||||
   ((SIZEW) << 23) |\
 | 
			
		||||
   ((EXP2) << 26) |\
 | 
			
		||||
   ((TYPE) << 29) )
 | 
			
		||||
 | 
			
		||||
def _PIPE_FORMAT_SWZ( SWZX, SWZY, SWZZ, SWZW ):
 | 
			
		||||
	return (((SWZX) << 0) | ((SWZY) << 3) | ((SWZZ) << 6) | ((SWZW) << 9))
 | 
			
		||||
 | 
			
		||||
def _PIPE_FORMAT_RGBAZS_1( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, TYPE ):
 | 
			
		||||
	return _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, 0, TYPE )
 | 
			
		||||
 | 
			
		||||
def _PIPE_FORMAT_RGBAZS_2( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, TYPE ):
 | 
			
		||||
    _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, 1, TYPE )
 | 
			
		||||
 | 
			
		||||
def _PIPE_FORMAT_RGBAZS_8( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, TYPE ):
 | 
			
		||||
	return _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, 3, TYPE )
 | 
			
		||||
 | 
			
		||||
def _PIPE_FORMAT_RGBAZS_64( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, TYPE ):
 | 
			
		||||
	return _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, 6, TYPE )
 | 
			
		||||
 | 
			
		||||
def _PIPE_FORMAT_MIXED( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, SIGNX, SIGNY, SIGNZ, SIGNW, NORMALIZED, SCALE8 ):
 | 
			
		||||
    return ((PIPE_FORMAT_LAYOUT_MIXED << 0) |\
 | 
			
		||||
    ((SWZ) << 2) |\
 | 
			
		||||
    ((SIZEX) << 14) |\
 | 
			
		||||
    ((SIZEY) << 17) |\
 | 
			
		||||
    ((SIZEZ) << 20) |\
 | 
			
		||||
    ((SIZEW) << 23) |\
 | 
			
		||||
    ((SIGNX) << 26) |\
 | 
			
		||||
    ((SIGNY) << 27) |\
 | 
			
		||||
    ((SIGNZ) << 28) |\
 | 
			
		||||
    ((SIGNW) << 29) |\
 | 
			
		||||
    ((NORMALIZED) << 30) |\
 | 
			
		||||
    ((SCALE8) << 31) )
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
_PIPE_FORMAT_R001 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_1 )
 | 
			
		||||
_PIPE_FORMAT_RG01 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_1 )
 | 
			
		||||
_PIPE_FORMAT_RGB1 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_1 )
 | 
			
		||||
_PIPE_FORMAT_RGBA = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_A )
 | 
			
		||||
_PIPE_FORMAT_ARGB = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_A, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B )
 | 
			
		||||
_PIPE_FORMAT_ABGR = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_A, PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_R )
 | 
			
		||||
_PIPE_FORMAT_BGRA = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_A )
 | 
			
		||||
_PIPE_FORMAT_1RGB = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_1, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B )
 | 
			
		||||
_PIPE_FORMAT_1BGR = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_1, PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_R )
 | 
			
		||||
_PIPE_FORMAT_BGR1 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_1 )
 | 
			
		||||
_PIPE_FORMAT_0000 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
 | 
			
		||||
_PIPE_FORMAT_000R = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_R )
 | 
			
		||||
_PIPE_FORMAT_RRR1 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_1 )
 | 
			
		||||
_PIPE_FORMAT_RRRR = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R )
 | 
			
		||||
_PIPE_FORMAT_RRRG = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G )
 | 
			
		||||
_PIPE_FORMAT_Z000 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
 | 
			
		||||
_PIPE_FORMAT_0Z00 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
 | 
			
		||||
_PIPE_FORMAT_SZ00 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_S, PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
 | 
			
		||||
_PIPE_FORMAT_ZS00 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_S, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
 | 
			
		||||
_PIPE_FORMAT_S000 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_S, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
 | 
			
		||||
 | 
			
		||||
def _PIPE_FORMAT_YCBCR( REV ):
 | 
			
		||||
   return ((PIPE_FORMAT_LAYOUT_YCBCR << 0) |\
 | 
			
		||||
   ((REV) << 2) )
 | 
			
		||||
 | 
			
		||||
def _PIPE_FORMAT_DXT( LEVEL, RSIZE, GSIZE, BSIZE, ASIZE ):
 | 
			
		||||
    return ((PIPE_FORMAT_LAYOUT_DXT << 0) | \
 | 
			
		||||
    ((LEVEL) << 2) | \
 | 
			
		||||
    ((RSIZE) << 5) | \
 | 
			
		||||
    ((GSIZE) << 8) | \
 | 
			
		||||
    ((BSIZE) << 11) | \
 | 
			
		||||
    ((ASIZE) << 14) )
 | 
			
		||||
 | 
			
		||||
PIPE_FORMAT_NONE                  = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_0000, 0, 0, 0, 0, PIPE_FORMAT_TYPE_UNKNOWN )
 | 
			
		||||
PIPE_FORMAT_A8R8G8B8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_ARGB, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_X8R8G8B8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_1RGB, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_B8G8R8A8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_BGRA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_B8G8R8X8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_BGR1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_A1R5G5B5_UNORM        = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_ARGB, 1, 5, 5, 5, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_A4R4G4B4_UNORM        = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_ARGB, 4, 4, 4, 4, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R5G6B5_UNORM          = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_RGB1, 5, 6, 5, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_A2B10G10R10_UNORM     = _PIPE_FORMAT_RGBAZS_2 ( _PIPE_FORMAT_ABGR, 1, 5, 5, 5, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_L8_UNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRR1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_A8_UNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_000R, 0, 0, 0, 1, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_I8_UNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRRR, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_A8L8_UNORM            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRRG, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_L16_UNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRR1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_YCBCR                 = _PIPE_FORMAT_YCBCR( 0 )
 | 
			
		||||
PIPE_FORMAT_YCBCR_REV             = _PIPE_FORMAT_YCBCR( 1 )
 | 
			
		||||
PIPE_FORMAT_Z16_UNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 2, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_Z32_UNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 4, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_Z32_FLOAT             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 4, 0, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
 | 
			
		||||
PIPE_FORMAT_S8Z24_UNORM           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_SZ00, 1, 3, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_Z24S8_UNORM           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_ZS00, 3, 1, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_X8Z24_UNORM           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_0Z00, 1, 3, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_Z24X8_UNORM           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 3, 1, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_S8_UNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_S000, 1, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R64_FLOAT             = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
 | 
			
		||||
PIPE_FORMAT_R64G64_FLOAT          = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
 | 
			
		||||
PIPE_FORMAT_R64G64B64_FLOAT       = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_FLOAT )
 | 
			
		||||
PIPE_FORMAT_R64G64B64A64_FLOAT    = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_FLOAT )
 | 
			
		||||
PIPE_FORMAT_R32_FLOAT             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
 | 
			
		||||
PIPE_FORMAT_R32G32_FLOAT          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
 | 
			
		||||
PIPE_FORMAT_R32G32B32_FLOAT       = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_FLOAT )
 | 
			
		||||
PIPE_FORMAT_R32G32B32A32_FLOAT    = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_FLOAT )
 | 
			
		||||
PIPE_FORMAT_R32_UNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R32G32_UNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R32G32B32_UNORM       = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R32G32B32A32_UNORM    = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R32_USCALED           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R32G32_USCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R32G32B32_USCALED     = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R32G32B32A32_USCALED  = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R32_SNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R32G32_SNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R32G32B32_SNORM       = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R32G32B32A32_SNORM    = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R32_SSCALED           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R32G32_SSCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R32G32B32_SSCALED     = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R32G32B32A32_SSCALED  = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R16_UNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R16G16_UNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R16G16B16_UNORM       = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R16G16B16A16_UNORM    = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R16_USCALED           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R16G16_USCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R16G16B16_USCALED     = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R16G16B16A16_USCALED  = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R16_SNORM             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R16G16_SNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R16G16B16_SNORM       = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R16G16B16A16_SNORM    = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R16_SSCALED           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R16G16_SSCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R16G16B16_SSCALED     = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R16G16B16A16_SSCALED  = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R8_UNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R8G8_UNORM            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R8G8B8_UNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R8G8B8A8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R8G8B8X8_UNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
 | 
			
		||||
PIPE_FORMAT_R8_USCALED            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R8G8_USCALED          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R8G8B8_USCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R8G8B8A8_USCALED      = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R8G8B8X8_USCALED      = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_USCALED )
 | 
			
		||||
PIPE_FORMAT_R8_SNORM              = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R8G8_SNORM            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R8G8B8_SNORM          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R8G8B8A8_SNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R8G8B8X8_SNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_B6G5R5_SNORM          = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_BGR1, 6, 5, 5, 0, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_A8B8G8R8_SNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_BGRA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_X8B8G8R8_SNORM        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM )
 | 
			
		||||
PIPE_FORMAT_R8_SSCALED            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R8G8_SSCALED          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R8G8B8_SSCALED        = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R8G8B8A8_SSCALED      = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R8G8B8X8_SSCALED      = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SSCALED )
 | 
			
		||||
PIPE_FORMAT_R32_FIXED             = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_FIXED )
 | 
			
		||||
PIPE_FORMAT_R32G32_FIXED          = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_FIXED )
 | 
			
		||||
PIPE_FORMAT_R32G32B32_FIXED       = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_FIXED )
 | 
			
		||||
PIPE_FORMAT_R32G32B32A32_FIXED    = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_FIXED )
 | 
			
		||||
PIPE_FORMAT_L8_SRGB               = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRR1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SRGB )
 | 
			
		||||
PIPE_FORMAT_A8_L8_SRGB            = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRRG, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SRGB )
 | 
			
		||||
PIPE_FORMAT_R8G8B8_SRGB           = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SRGB )
 | 
			
		||||
PIPE_FORMAT_R8G8B8A8_SRGB         = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SRGB )
 | 
			
		||||
PIPE_FORMAT_R8G8B8X8_SRGB         = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SRGB )
 | 
			
		||||
PIPE_FORMAT_X8UB8UG8SR8S_NORM     = _PIPE_FORMAT_MIXED( _PIPE_FORMAT_1BGR, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1 )
 | 
			
		||||
PIPE_FORMAT_B6UG5SR5S_NORM        = _PIPE_FORMAT_MIXED( _PIPE_FORMAT_BGR1, 6, 5, 5, 0, 0, 1, 1, 0, 1, 0 )
 | 
			
		||||
PIPE_FORMAT_DXT1_RGB              = _PIPE_FORMAT_DXT( 1, 8, 8, 8, 0 )
 | 
			
		||||
PIPE_FORMAT_DXT1_RGBA             = _PIPE_FORMAT_DXT( 1, 8, 8, 8, 8 )
 | 
			
		||||
PIPE_FORMAT_DXT3_RGBA             = _PIPE_FORMAT_DXT( 3, 8, 8, 8, 8 )
 | 
			
		||||
PIPE_FORMAT_DXT5_RGBA             = _PIPE_FORMAT_DXT( 5, 8, 8, 8, 8 )
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
formats = {}
 | 
			
		||||
for name, value in globals().items():
 | 
			
		||||
    if name.startswith("PIPE_FORMAT_") and isinstance(value, int):
 | 
			
		||||
        formats[value] = name
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
def clip(g):
 | 
			
		||||
	return min(max(g, 0), 255)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
def yuv2rgb(y, u, v):
 | 
			
		||||
	C = y - 16
 | 
			
		||||
	D = u - 128
 | 
			
		||||
	E = v - 128
 | 
			
		||||
 | 
			
		||||
	r = clip(( 298 * C           + 409 * E + 128) >> 8)
 | 
			
		||||
	g = clip(( 298 * C - 100 * D - 208 * E + 128) >> 8)
 | 
			
		||||
	b = clip(( 298 * C + 516 * D           + 128) >> 8)
 | 
			
		||||
	
 | 
			
		||||
	return r, g, b
 | 
			
		||||
 | 
			
		||||
	
 | 
			
		||||
def translate_r5g6b5(data):
 | 
			
		||||
	value, = struct.unpack_from("H", data)
 | 
			
		||||
	r = ((value >> 11) & 0x1f)*0xff/0x1f
 | 
			
		||||
	g = ((value >>  5) & 0x3f)*0xff/0x3f
 | 
			
		||||
	b = ((value >>  0) & 0x1f)*0xff/0x1f
 | 
			
		||||
	a = 255
 | 
			
		||||
	return [[(r, g, b, a)]]
 | 
			
		||||
 | 
			
		||||
def translate_a8r8g8b8(data):
 | 
			
		||||
    b, g, r, a = struct.unpack_from("BBBB", data)
 | 
			
		||||
    return [[(r, g, b, a)]]
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
def translate_x8r8g8b8(data):
 | 
			
		||||
    b, g, r, x = struct.unpack_from("BBBB", data)
 | 
			
		||||
    a = 255
 | 
			
		||||
    return [[(r, g, b, a)]]
 | 
			
		||||
 | 
			
		||||
def translate_r8g8b8a8(data):
 | 
			
		||||
	r, g, b, a = struct.unpack_from("BBBB", data)
 | 
			
		||||
	return [[(r, g, b, a)]]
 | 
			
		||||
 | 
			
		||||
def translate_ycbcr(data):
 | 
			
		||||
	y1, u, y2, v = struct.unpack_from("BBBB", data)
 | 
			
		||||
	r1, g1, b1 = yuv2rgb(y1, u, v)
 | 
			
		||||
	r2, g2, b2 = yuv2rgb(y1, u, v)
 | 
			
		||||
	return [[(r1, g1, b1, 255), (r2, g2, b2, 255)]]
 | 
			
		||||
 | 
			
		||||
def translate_ycbcr_rev(data):
 | 
			
		||||
    v, y2, u, y1 = struct.unpack_from("BBBB", data)
 | 
			
		||||
    r1, g1, b1 = yuv2rgb(y1, u, v)
 | 
			
		||||
    r2, g2, b2 = yuv2rgb(y1, u, v)
 | 
			
		||||
    return [[(r1, g1, b1, 255), (r2, g2, b2, 255)]]
 | 
			
		||||
 | 
			
		||||
def translate_x8z24(data):
 | 
			
		||||
    value, = struct.unpack_from("I", data)
 | 
			
		||||
    r = g = b = (value & 0xffffff)*0xff/0xffffff
 | 
			
		||||
    a = 255
 | 
			
		||||
    return [[(r, g, b, a)]]
 | 
			
		||||
 | 
			
		||||
def translate_s8z24(data):
 | 
			
		||||
    value, = struct.unpack_from("I", data)
 | 
			
		||||
    r = (value & 0xffffff)*0xff/0xffffff
 | 
			
		||||
    g = value >> 24
 | 
			
		||||
    b = 0
 | 
			
		||||
    a = 255
 | 
			
		||||
    return [[(r, g, b, a)]]
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
translate = {
 | 
			
		||||
	PIPE_FORMAT_A8R8G8B8_UNORM: (4, 1, 1, translate_a8r8g8b8),
 | 
			
		||||
	PIPE_FORMAT_X8R8G8B8_UNORM: (4, 1, 1, translate_x8r8g8b8),
 | 
			
		||||
	PIPE_FORMAT_B8G8R8A8_UNORM: (4, 1, 1, translate_r8g8b8a8),
 | 
			
		||||
	PIPE_FORMAT_B8G8R8X8_UNORM: (4, 1, 1, translate_r8g8b8a8),
 | 
			
		||||
	PIPE_FORMAT_A8B8G8R8_SNORM: (4, 1, 1, translate_r8g8b8a8),
 | 
			
		||||
	PIPE_FORMAT_R5G6B5_UNORM: (2, 1, 1, translate_r5g6b5),
 | 
			
		||||
	PIPE_FORMAT_YCBCR: (4, 2, 1, translate_ycbcr),
 | 
			
		||||
	PIPE_FORMAT_YCBCR_REV: (4, 2, 1, translate_ycbcr_rev),
 | 
			
		||||
    PIPE_FORMAT_S8Z24_UNORM: (4, 1, 1, translate_s8z24),
 | 
			
		||||
    PIPE_FORMAT_X8Z24_UNORM: (4, 1, 1, translate_x8z24),
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
def read_header(infile):
 | 
			
		||||
	header_fmt = "IIII"
 | 
			
		||||
	header = infile.read(struct.calcsize(header_fmt))
 | 
			
		||||
	return struct.unpack_from(header_fmt, header)
 | 
			
		||||
 | 
			
		||||
def process(infilename, outfilename):
 | 
			
		||||
	sys.stderr.write("%s -> %s\n" % (infilename, outfilename))
 | 
			
		||||
	infile = open(infilename, "rb")
 | 
			
		||||
	format, cpp, width, height = read_header(infile)
 | 
			
		||||
	sys.stderr.write("  %ux%ux%ubpp %s\n" % (width, height, cpp*8, formats[format]))
 | 
			
		||||
	outimage = Image.new(
 | 
			
		||||
	mode='RGB',
 | 
			
		||||
	size=(width, height),
 | 
			
		||||
	color=(0,0,0))
 | 
			
		||||
	outpixels = outimage.load()
 | 
			
		||||
	try:
 | 
			
		||||
		bsize, bwidth, bheight, translate_func = translate[format]
 | 
			
		||||
	except KeyError:
 | 
			
		||||
		sys.stderr.write('error: unsupported format %s\n' % formats[format])
 | 
			
		||||
		return
 | 
			
		||||
	for y in range(0, height, bheight):
 | 
			
		||||
		for x in range(0, width, bwidth):
 | 
			
		||||
			indata = infile.read(bsize)
 | 
			
		||||
			outdata = translate_func(indata)
 | 
			
		||||
			for j in range(bheight):
 | 
			
		||||
				for i in range(bwidth):
 | 
			
		||||
					r, g, b, a = outdata[j][i]
 | 
			
		||||
					outpixels[x+i, y+j] = r, g, b
 | 
			
		||||
	outimage.save(outfilename, "PNG")
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
def main():
 | 
			
		||||
	if sys.platform == 'win32':
 | 
			
		||||
		# wildcard expansion
 | 
			
		||||
		from glob import glob
 | 
			
		||||
		args = []
 | 
			
		||||
		for arg in sys.argv[1:]:
 | 
			
		||||
			args.extend(glob(arg))
 | 
			
		||||
	else:
 | 
			
		||||
		args = sys.argv[1:]
 | 
			
		||||
	for infilename in args:
 | 
			
		||||
		root, ext = os.path.splitext(infilename)
 | 
			
		||||
		outfilename = root + ".png"
 | 
			
		||||
		process(infilename, outfilename)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
if __name__ == '__main__':
 | 
			
		||||
	main()
 | 
			
		||||
@@ -1,309 +0,0 @@
 | 
			
		||||
#!/usr/bin/env python
 | 
			
		||||
##########################################################################
 | 
			
		||||
# 
 | 
			
		||||
# Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas.
 | 
			
		||||
# All Rights Reserved.
 | 
			
		||||
# 
 | 
			
		||||
# Permission is hereby granted, free of charge, to any person obtaining a
 | 
			
		||||
# copy of this software and associated documentation files (the
 | 
			
		||||
# "Software"), to deal in the Software without restriction, including
 | 
			
		||||
# without limitation the rights to use, copy, modify, merge, publish,
 | 
			
		||||
# distribute, sub license, and/or sell copies of the Software, and to
 | 
			
		||||
# permit persons to whom the Software is furnished to do so, subject to
 | 
			
		||||
# the following conditions:
 | 
			
		||||
# 
 | 
			
		||||
# The above copyright notice and this permission notice (including the
 | 
			
		||||
# next paragraph) shall be included in all copies or substantial portions
 | 
			
		||||
# of the Software.
 | 
			
		||||
# 
 | 
			
		||||
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 | 
			
		||||
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 | 
			
		||||
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
 | 
			
		||||
# IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
 | 
			
		||||
# ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
 | 
			
		||||
# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
 | 
			
		||||
# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 | 
			
		||||
# 
 | 
			
		||||
##########################################################################
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
import sys
 | 
			
		||||
import optparse
 | 
			
		||||
import re
 | 
			
		||||
import struct
 | 
			
		||||
 | 
			
		||||
from gprof2dot import Call, Function, Profile
 | 
			
		||||
from gprof2dot import CALLS, SAMPLES, TIME, TIME_RATIO, TOTAL_TIME, TOTAL_TIME_RATIO
 | 
			
		||||
from gprof2dot import DotWriter, TEMPERATURE_COLORMAP
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
__version__ = '0.1'
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
class ParseError(Exception):
 | 
			
		||||
    pass
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
class MsvcDemangler:
 | 
			
		||||
    # http://www.kegel.com/mangle.html
 | 
			
		||||
 | 
			
		||||
    def __init__(self, symbol):
 | 
			
		||||
        self._symbol = symbol
 | 
			
		||||
        self._pos = 0
 | 
			
		||||
 | 
			
		||||
    def lookahead(self):
 | 
			
		||||
        return self._symbol[self._pos]
 | 
			
		||||
 | 
			
		||||
    def consume(self):
 | 
			
		||||
        ret = self.lookahead()
 | 
			
		||||
        self._pos += 1
 | 
			
		||||
        return ret
 | 
			
		||||
    
 | 
			
		||||
    def match(self, c):
 | 
			
		||||
        if self.lookahead() != c:
 | 
			
		||||
            raise ParseError
 | 
			
		||||
        self.consume()
 | 
			
		||||
 | 
			
		||||
    def parse(self):
 | 
			
		||||
        self.match('?')
 | 
			
		||||
        name = self.parse_name()
 | 
			
		||||
        qualifications = self.parse_qualifications()
 | 
			
		||||
        return '::'.join(qualifications + [name])
 | 
			
		||||
 | 
			
		||||
    def parse_name(self):
 | 
			
		||||
        if self.lookahead() == '?':
 | 
			
		||||
            return self.consume() + self.consume()
 | 
			
		||||
        else:
 | 
			
		||||
            name = self.parse_id()
 | 
			
		||||
            self.match('@')
 | 
			
		||||
            return name
 | 
			
		||||
 | 
			
		||||
    def parse_qualifications(self):
 | 
			
		||||
        qualifications = []
 | 
			
		||||
        while self.lookahead() != '@':
 | 
			
		||||
            name = self.parse_id()
 | 
			
		||||
            qualifications.append(name)
 | 
			
		||||
            self.match('@')
 | 
			
		||||
        return qualifications
 | 
			
		||||
 | 
			
		||||
    def parse_id(self):
 | 
			
		||||
        s = ''
 | 
			
		||||
        while True:
 | 
			
		||||
            c = self.lookahead()
 | 
			
		||||
            if c.isalnum() or c in '_':
 | 
			
		||||
                s += c
 | 
			
		||||
                self.consume()
 | 
			
		||||
            else:
 | 
			
		||||
                break
 | 
			
		||||
        return s
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
def demangle(name):
 | 
			
		||||
    if name.startswith('_'):
 | 
			
		||||
        name = name[1:]
 | 
			
		||||
        idx = name.rfind('@')
 | 
			
		||||
        if idx != -1 and name[idx+1:].isdigit():
 | 
			
		||||
            name = name[:idx]
 | 
			
		||||
        return name
 | 
			
		||||
    if name.startswith('?'):
 | 
			
		||||
        demangler = MsvcDemangler(name)
 | 
			
		||||
        return demangler.parse()
 | 
			
		||||
    return name
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
class Reader:
 | 
			
		||||
 | 
			
		||||
    def __init__(self):
 | 
			
		||||
        self.symbols = []
 | 
			
		||||
        self.symbol_cache = {}
 | 
			
		||||
        self.base_addr = None
 | 
			
		||||
    
 | 
			
		||||
    def read_map(self, mapfile):
 | 
			
		||||
        # See http://msdn.microsoft.com/en-us/library/k7xkk3e2.aspx
 | 
			
		||||
        last_addr = 0
 | 
			
		||||
        last_name = 0
 | 
			
		||||
        for line in file(mapfile, "rt"):
 | 
			
		||||
            fields = line.split()
 | 
			
		||||
            try:
 | 
			
		||||
                section_offset, name, addr, type, lib_object = fields
 | 
			
		||||
            except ValueError:
 | 
			
		||||
                continue
 | 
			
		||||
            if type != 'f':
 | 
			
		||||
                continue
 | 
			
		||||
            section, offset = section_offset.split(':')
 | 
			
		||||
            addr = int(offset, 16)
 | 
			
		||||
            self.symbols.append((addr, name))
 | 
			
		||||
            last_addr = addr
 | 
			
		||||
            last_name = name
 | 
			
		||||
 | 
			
		||||
        # sort symbols
 | 
			
		||||
        self.symbols.sort(key = lambda (addr, name): addr)
 | 
			
		||||
 | 
			
		||||
    def lookup_addr(self, addr):
 | 
			
		||||
        try:
 | 
			
		||||
            return self.symbol_cache[addr]
 | 
			
		||||
        except KeyError:
 | 
			
		||||
            pass
 | 
			
		||||
 | 
			
		||||
        tolerance = 4196
 | 
			
		||||
        s, e = 0, len(self.symbols)
 | 
			
		||||
        while s != e:
 | 
			
		||||
            i = (s + e)//2
 | 
			
		||||
            start_addr, name = self.symbols[i]
 | 
			
		||||
            try:
 | 
			
		||||
                end_addr, next_name = self.symbols[i + 1]
 | 
			
		||||
            except IndexError:
 | 
			
		||||
                end_addr = start_addr + tolerance
 | 
			
		||||
            if addr < start_addr:
 | 
			
		||||
                e = i
 | 
			
		||||
                continue
 | 
			
		||||
            if addr == end_addr:
 | 
			
		||||
                return next_name, addr - start_addr
 | 
			
		||||
            if addr > end_addr:
 | 
			
		||||
                s = i
 | 
			
		||||
                continue
 | 
			
		||||
            return name, addr - start_addr
 | 
			
		||||
        raise ValueError
 | 
			
		||||
 | 
			
		||||
    def lookup_symbol(self, name):
 | 
			
		||||
        for symbol_addr, symbol_name in self.symbols:
 | 
			
		||||
            if name == symbol_name:
 | 
			
		||||
                return symbol_addr
 | 
			
		||||
        return 0
 | 
			
		||||
 | 
			
		||||
    def read_data(self, data):
 | 
			
		||||
        profile = Profile()
 | 
			
		||||
 | 
			
		||||
        fp = file(data, "rb")
 | 
			
		||||
        entry_format = "IIII"
 | 
			
		||||
        entry_size = struct.calcsize(entry_format)
 | 
			
		||||
        caller = None
 | 
			
		||||
        caller_stack = []
 | 
			
		||||
        while True:
 | 
			
		||||
            entry = fp.read(entry_size)
 | 
			
		||||
            if len(entry) < entry_size:
 | 
			
		||||
                break
 | 
			
		||||
            caller_addr, callee_addr, samples_lo, samples_hi = struct.unpack(entry_format, entry)
 | 
			
		||||
            if caller_addr == 0 and callee_addr == 0:
 | 
			
		||||
                continue
 | 
			
		||||
 | 
			
		||||
            if self.base_addr is None:
 | 
			
		||||
                ref_addr = self.lookup_symbol('___debug_profile_reference@0')
 | 
			
		||||
                if ref_addr:
 | 
			
		||||
                    self.base_addr = (caller_addr - ref_addr) & ~(options.align - 1)
 | 
			
		||||
                else:
 | 
			
		||||
                    self.base_addr = 0
 | 
			
		||||
                sys.stderr.write('Base addr: %08x\n' % self.base_addr)
 | 
			
		||||
 | 
			
		||||
            samples = (samples_hi << 32) | samples_lo
 | 
			
		||||
            
 | 
			
		||||
            try:
 | 
			
		||||
                caller_raddr = caller_addr - self.base_addr
 | 
			
		||||
                caller_sym, caller_ofs = self.lookup_addr(caller_raddr)
 | 
			
		||||
 | 
			
		||||
                try:
 | 
			
		||||
                    caller = profile.functions[caller_sym]
 | 
			
		||||
                except KeyError:
 | 
			
		||||
                    caller_name = demangle(caller_sym)
 | 
			
		||||
                    caller = Function(caller_sym, caller_name)
 | 
			
		||||
                    profile.add_function(caller)
 | 
			
		||||
                    caller[CALLS] = 0
 | 
			
		||||
                    caller[SAMPLES] = 0
 | 
			
		||||
            except ValueError:
 | 
			
		||||
                caller = None
 | 
			
		||||
 | 
			
		||||
            if not callee_addr:
 | 
			
		||||
                if caller:
 | 
			
		||||
                    caller[SAMPLES] += samples
 | 
			
		||||
            else:
 | 
			
		||||
                callee_raddr = callee_addr - self.base_addr
 | 
			
		||||
                callee_sym, callee_ofs = self.lookup_addr(callee_raddr)
 | 
			
		||||
 | 
			
		||||
                try:
 | 
			
		||||
                    callee = profile.functions[callee_sym]
 | 
			
		||||
                except KeyError:
 | 
			
		||||
                    callee_name = demangle(callee_sym)
 | 
			
		||||
                    callee = Function(callee_sym, callee_name)
 | 
			
		||||
                    profile.add_function(callee)
 | 
			
		||||
                    callee[CALLS] = samples
 | 
			
		||||
                    callee[SAMPLES] = 0
 | 
			
		||||
                else:
 | 
			
		||||
                    callee[CALLS] += samples
 | 
			
		||||
 | 
			
		||||
                if caller is not None:
 | 
			
		||||
                    try:
 | 
			
		||||
                        call = caller.calls[callee.id]
 | 
			
		||||
                    except KeyError:
 | 
			
		||||
                        call = Call(callee.id)
 | 
			
		||||
                        call[CALLS] = samples
 | 
			
		||||
                        caller.add_call(call)
 | 
			
		||||
                    else:
 | 
			
		||||
                        call[CALLS] += samples
 | 
			
		||||
            
 | 
			
		||||
            if options.verbose:
 | 
			
		||||
                if not callee_addr:
 | 
			
		||||
                    sys.stderr.write('%s+%u: %u\n' % (caller_sym, caller_ofs, samples))
 | 
			
		||||
                else:
 | 
			
		||||
                    sys.stderr.write('%s+%u -> %s+%u: %u\n' % (caller_sym, caller_ofs, callee_sym, callee_ofs, samples))
 | 
			
		||||
 | 
			
		||||
        # compute derived data
 | 
			
		||||
        profile.validate()
 | 
			
		||||
        profile.find_cycles()
 | 
			
		||||
        profile.aggregate(SAMPLES)
 | 
			
		||||
        profile.ratio(TIME_RATIO, SAMPLES)
 | 
			
		||||
        profile.call_ratios(CALLS)
 | 
			
		||||
        profile.integrate(TOTAL_TIME_RATIO, TIME_RATIO)
 | 
			
		||||
 | 
			
		||||
        return profile
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
def main():
 | 
			
		||||
    parser = optparse.OptionParser(
 | 
			
		||||
        usage="\n\t%prog [options] [file] ...",
 | 
			
		||||
        version="%%prog %s" % __version__)
 | 
			
		||||
    parser.add_option(
 | 
			
		||||
        '-a', '--align', metavar='NUMBER',
 | 
			
		||||
        type="int", dest="align", default=16,
 | 
			
		||||
        help="section alignment")
 | 
			
		||||
    parser.add_option(
 | 
			
		||||
        '-m', '--map', metavar='FILE',
 | 
			
		||||
        type="string", dest="map",
 | 
			
		||||
        help="map file")
 | 
			
		||||
    parser.add_option(
 | 
			
		||||
        '-b', '--base', metavar='FILE',
 | 
			
		||||
        type="string", dest="base",
 | 
			
		||||
        help="base addr")
 | 
			
		||||
    parser.add_option(
 | 
			
		||||
        '-n', '--node-thres', metavar='PERCENTAGE',
 | 
			
		||||
        type="float", dest="node_thres", default=0.5,
 | 
			
		||||
        help="eliminate nodes below this threshold [default: %default]")
 | 
			
		||||
    parser.add_option(
 | 
			
		||||
        '-e', '--edge-thres', metavar='PERCENTAGE',
 | 
			
		||||
        type="float", dest="edge_thres", default=0.1,
 | 
			
		||||
        help="eliminate edges below this threshold [default: %default]")
 | 
			
		||||
    parser.add_option(
 | 
			
		||||
        '-v', '--verbose',
 | 
			
		||||
        action="count",
 | 
			
		||||
        dest="verbose", default=0,
 | 
			
		||||
        help="verbose output")
 | 
			
		||||
 | 
			
		||||
    global options
 | 
			
		||||
    (options, args) = parser.parse_args(sys.argv[1:])
 | 
			
		||||
 | 
			
		||||
    reader = Reader()
 | 
			
		||||
    if options.base is not None:
 | 
			
		||||
        reader.base_addr = int(options.base, 16)
 | 
			
		||||
    if options.map is not None:
 | 
			
		||||
        reader.read_map(options.map)
 | 
			
		||||
    for arg in args:
 | 
			
		||||
        profile = reader.read_data(arg)
 | 
			
		||||
        profile.prune(options.node_thres/100.0, options.edge_thres/100.0)
 | 
			
		||||
        output = sys.stdout
 | 
			
		||||
        dot = DotWriter(output)
 | 
			
		||||
        colormap = TEMPERATURE_COLORMAP
 | 
			
		||||
        dot.graph(profile, colormap)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
if __name__ == '__main__':
 | 
			
		||||
    main()
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										67
									
								
								common.py
									
									
									
									
									
								
							
							
						
						
									
										67
									
								
								common.py
									
									
									
									
									
								
							@@ -1,67 +0,0 @@
 | 
			
		||||
#######################################################################
 | 
			
		||||
# Common SCons code
 | 
			
		||||
 | 
			
		||||
import os
 | 
			
		||||
import os.path
 | 
			
		||||
import sys
 | 
			
		||||
import platform as _platform
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#######################################################################
 | 
			
		||||
# Defaults
 | 
			
		||||
 | 
			
		||||
_platform_map = {
 | 
			
		||||
	'linux2': 'linux',
 | 
			
		||||
	'win32': 'winddk',
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
default_platform = sys.platform
 | 
			
		||||
default_platform = _platform_map.get(default_platform, default_platform)
 | 
			
		||||
 | 
			
		||||
_machine_map = {
 | 
			
		||||
	'x86': 'x86',
 | 
			
		||||
	'i386': 'x86',
 | 
			
		||||
	'i486': 'x86',
 | 
			
		||||
	'i586': 'x86',
 | 
			
		||||
	'i686': 'x86',
 | 
			
		||||
	'ppc' : 'ppc',
 | 
			
		||||
	'x86_64': 'x86_64',
 | 
			
		||||
}
 | 
			
		||||
if 'PROCESSOR_ARCHITECTURE' in os.environ:
 | 
			
		||||
	default_machine = os.environ['PROCESSOR_ARCHITECTURE']
 | 
			
		||||
else:
 | 
			
		||||
	default_machine = _platform.machine()
 | 
			
		||||
default_machine = _machine_map.get(default_machine, 'generic')
 | 
			
		||||
 | 
			
		||||
if default_platform in ('linux', 'freebsd', 'darwin'):
 | 
			
		||||
	default_dri = 'yes'
 | 
			
		||||
elif default_platform in ('winddk', 'windows', 'wince'):
 | 
			
		||||
	default_dri = 'no'
 | 
			
		||||
else:
 | 
			
		||||
	default_dri = 'no'
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#######################################################################
 | 
			
		||||
# Common options
 | 
			
		||||
 | 
			
		||||
def AddOptions(opts):
 | 
			
		||||
	try:
 | 
			
		||||
		from SCons.Variables.BoolVariable import BoolVariable as BoolOption
 | 
			
		||||
	except ImportError:
 | 
			
		||||
		from SCons.Options.BoolOption import BoolOption
 | 
			
		||||
	try:
 | 
			
		||||
		from SCons.Variables.EnumVariable import EnumVariable as EnumOption
 | 
			
		||||
	except ImportError:
 | 
			
		||||
		from SCons.Options.EnumOption import EnumOption
 | 
			
		||||
	opts.Add(BoolOption('debug', 'debug build', 'no'))
 | 
			
		||||
	opts.Add(BoolOption('profile', 'profile build', 'no'))
 | 
			
		||||
	opts.Add(BoolOption('quiet', 'quiet command lines', 'yes'))
 | 
			
		||||
	opts.Add(EnumOption('machine', 'use machine-specific assembly code', default_machine,
 | 
			
		||||
											 allowed_values=('generic', 'ppc', 'x86', 'x86_64')))
 | 
			
		||||
	opts.Add(EnumOption('platform', 'target platform', default_platform,
 | 
			
		||||
											 allowed_values=('linux', 'cell', 'windows', 'winddk', 'wince')))
 | 
			
		||||
	opts.Add(EnumOption('toolchain', 'compiler toolchain', 'default',
 | 
			
		||||
											 allowed_values=('default', 'crossmingw', 'winsdk', 'winddk')))
 | 
			
		||||
	opts.Add(BoolOption('llvm', 'use LLVM', 'no'))
 | 
			
		||||
	opts.Add(BoolOption('dri', 'build DRI drivers', default_dri))
 | 
			
		||||
 | 
			
		||||
@@ -22,8 +22,8 @@ LDFLAGS = @LDFLAGS@
 | 
			
		||||
EXTRA_LIB_PATH = @EXTRA_LIB_PATH@
 | 
			
		||||
 | 
			
		||||
# Assembler
 | 
			
		||||
MESA_ASM_SOURCES = @MESA_ASM_SOURCES@
 | 
			
		||||
GLAPI_ASM_SOURCES = @GLAPI_ASM_SOURCES@
 | 
			
		||||
ASM_SOURCES = @ASM_SOURCES@
 | 
			
		||||
ASM_API = @ASM_API@
 | 
			
		||||
 | 
			
		||||
# Misc tools and flags
 | 
			
		||||
MAKE = @MAKE@
 | 
			
		||||
@@ -50,32 +50,16 @@ GLUT_LIB_NAME = @GLUT_LIB_NAME@
 | 
			
		||||
GLW_LIB_NAME = @GLW_LIB_NAME@
 | 
			
		||||
OSMESA_LIB_NAME = @OSMESA_LIB_NAME@
 | 
			
		||||
 | 
			
		||||
# Globs used to install the lib and all symlinks
 | 
			
		||||
GL_LIB_GLOB = @GL_LIB_GLOB@
 | 
			
		||||
GLU_LIB_GLOB = @GLU_LIB_GLOB@
 | 
			
		||||
GLUT_LIB_GLOB = @GLUT_LIB_GLOB@
 | 
			
		||||
GLW_LIB_GLOB = @GLW_LIB_GLOB@
 | 
			
		||||
OSMESA_LIB_GLOB = @OSMESA_LIB_GLOB@
 | 
			
		||||
 | 
			
		||||
# Directories to build
 | 
			
		||||
LIB_DIR = @LIB_DIR@
 | 
			
		||||
SRC_DIRS = @SRC_DIRS@
 | 
			
		||||
GLU_DIRS = @GLU_DIRS@
 | 
			
		||||
DRIVER_DIRS = @DRIVER_DIRS@
 | 
			
		||||
GALLIUM_DIRS = @GALLIUM_DIRS@
 | 
			
		||||
GALLIUM_AUXILIARY_DIRS = @GALLIUM_AUXILIARY_DIRS@
 | 
			
		||||
GALLIUM_DRIVERS_DIRS = @GALLIUM_DRIVERS_DIRS@
 | 
			
		||||
GALLIUM_WINSYS_DIRS = @GALLIUM_WINSYS_DIRS@
 | 
			
		||||
GALLIUM_WINSYS_DRM_DIRS = @GALLIUM_WINSYS_DRM_DIRS@
 | 
			
		||||
GALLIUM_STATE_TRACKERS_DIRS = @GALLIUM_STATE_TRACKERS_DIRS@
 | 
			
		||||
GALLIUM_AUXILIARIES = $(foreach DIR,$(GALLIUM_AUXILIARY_DIRS),$(TOP)/src/gallium/auxiliary/$(DIR)/lib$(DIR).a)
 | 
			
		||||
GALLIUM_DRIVERS = $(foreach DIR,$(GALLIUM_DRIVERS_DIRS),$(TOP)/src/gallium/drivers/$(DIR)/lib$(DIR).a)
 | 
			
		||||
 | 
			
		||||
# Which subdirs under $(TOP)/progs/ to enter:
 | 
			
		||||
PROGRAM_DIRS = @PROGRAM_DIRS@
 | 
			
		||||
 | 
			
		||||
# Driver specific build vars
 | 
			
		||||
DRI_DIRS = @DRI_DIRS@ 
 | 
			
		||||
DRI_DIRS = @DRI_DIRS@
 | 
			
		||||
WINDOW_SYSTEM = @WINDOW_SYSTEM@
 | 
			
		||||
USING_EGL = @USING_EGL@
 | 
			
		||||
 | 
			
		||||
@@ -90,7 +74,6 @@ MOTIF_CFLAGS = @MOTIF_CFLAGS@
 | 
			
		||||
GL_LIB_DEPS = $(EXTRA_LIB_PATH) @GL_LIB_DEPS@
 | 
			
		||||
OSMESA_LIB_DEPS = -L$(TOP)/$(LIB_DIR) @OSMESA_MESA_DEPS@ \
 | 
			
		||||
	$(EXTRA_LIB_PATH) @OSMESA_LIB_DEPS@
 | 
			
		||||
EGL_LIB_DEPS = $(EXTRA_LIB_PATH) @EGL_LIB_DEPS@
 | 
			
		||||
GLU_LIB_DEPS = -L$(TOP)/$(LIB_DIR) @GLU_MESA_DEPS@ \
 | 
			
		||||
	$(EXTRA_LIB_PATH) @GLU_LIB_DEPS@
 | 
			
		||||
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) @GLUT_MESA_DEPS@ \
 | 
			
		||||
@@ -103,7 +86,6 @@ APP_LIB_DEPS = $(EXTRA_LIB_PATH) @APP_LIB_DEPS@
 | 
			
		||||
DRI_LIB_DEPS = $(EXTRA_LIB_PATH) @DRI_LIB_DEPS@
 | 
			
		||||
LIBDRM_CFLAGS = @LIBDRM_CFLAGS@
 | 
			
		||||
LIBDRM_LIB = @LIBDRM_LIBS@
 | 
			
		||||
DRI2PROTO_CFLAGS = @DRI2PROTO_CFLAGS@
 | 
			
		||||
EXPAT_INCLUDES = @EXPAT_INCLUDES@
 | 
			
		||||
 | 
			
		||||
# Autoconf directories
 | 
			
		||||
@@ -122,24 +104,3 @@ DRI_DRIVER_INSTALL_DIR = @DRI_DRIVER_INSTALL_DIR@
 | 
			
		||||
 | 
			
		||||
# Where libGL will look for DRI hardware drivers
 | 
			
		||||
DRI_DRIVER_SEARCH_DIR = $(DRI_DRIVER_INSTALL_DIR)
 | 
			
		||||
 | 
			
		||||
# Xorg driver install directory (for xorg state-tracker)
 | 
			
		||||
XORG_DRIVER_INSTALL_DIR = @XORG_DRIVER_INSTALL_DIR@
 | 
			
		||||
 | 
			
		||||
# pkg-config substitutions
 | 
			
		||||
GL_PC_REQ_PRIV = @GL_PC_REQ_PRIV@
 | 
			
		||||
GL_PC_LIB_PRIV = @GL_PC_LIB_PRIV@
 | 
			
		||||
GL_PC_CFLAGS = @GL_PC_CFLAGS@
 | 
			
		||||
DRI_PC_REQ_PRIV = @DRI_PC_REQ_PRIV@
 | 
			
		||||
GLU_PC_REQ = @GLU_PC_REQ@
 | 
			
		||||
GLU_PC_REQ_PRIV = @GLU_PC_REQ_PRIV@
 | 
			
		||||
GLU_PC_LIB_PRIV = @GLU_PC_LIB_PRIV@
 | 
			
		||||
GLU_PC_CFLAGS = @GLU_PC_CFLAGS@
 | 
			
		||||
GLUT_PC_REQ_PRIV = @GLUT_PC_REQ_PRIV@
 | 
			
		||||
GLUT_PC_LIB_PRIV = @GLUT_PC_LIB_PRIV@
 | 
			
		||||
GLUT_PC_CFLAGS = @GLUT_PC_CFLAGS@
 | 
			
		||||
GLW_PC_REQ_PRIV = @GLW_PC_REQ_PRIV@
 | 
			
		||||
GLW_PC_LIB_PRIV = @GLW_PC_LIB_PRIV@
 | 
			
		||||
GLW_PC_CFLAGS = @GLW_PC_CFLAGS@
 | 
			
		||||
OSMESA_PC_REQ = @OSMESA_PC_REQ@
 | 
			
		||||
OSMESA_PC_LIB_PRIV = @OSMESA_PC_LIB_PRIV@
 | 
			
		||||
 
 | 
			
		||||
@@ -26,8 +26,8 @@ ifeq ($(CPU), x86)
 | 
			
		||||
		-DUSE_3DNOW_ASM \
 | 
			
		||||
		-DUSE_SSE_ASM
 | 
			
		||||
	
 | 
			
		||||
	MESA_ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
	GLAPI_ASM_SOURCES = $(X86_API)
 | 
			
		||||
	ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
	ASM_API = $(X86_API)
 | 
			
		||||
 | 
			
		||||
	CC = gcc
 | 
			
		||||
	CXX = g++
 | 
			
		||||
@@ -90,7 +90,7 @@ else
 | 
			
		||||
endif
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS = gallium mesa glu glut/beos glew
 | 
			
		||||
SRC_DIRS = mesa glu glut/beos
 | 
			
		||||
GLU_DIRS = sgi
 | 
			
		||||
DRIVER_DIRS = beos
 | 
			
		||||
PROGRAM_DIRS = beos samples redbook demos tests
 | 
			
		||||
 
 | 
			
		||||
@@ -6,26 +6,24 @@ CONFIG_NAME = darwin
 | 
			
		||||
 | 
			
		||||
INSTALL_DIR = /usr/X11
 | 
			
		||||
 | 
			
		||||
X11_DIR = $(INSTALL_DIR)
 | 
			
		||||
 | 
			
		||||
# Compiler and flags
 | 
			
		||||
CC = gcc
 | 
			
		||||
CXX = gcc
 | 
			
		||||
PIC_FLAGS = -fPIC
 | 
			
		||||
DEFINES =  -D_DARWIN_C_SOURCE -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L \
 | 
			
		||||
	   -D_BSD_SOURCE -D_SVID_SOURCE -D_GNU_SOURCE -DPTHREADS \
 | 
			
		||||
	   -DGLX_ALIAS_UNSUPPORTED -DGLX_INDIRECT_RENDERING
 | 
			
		||||
	   -DGLX_INDIRECT_RENDERING \
 | 
			
		||||
	   -DGLX_ALIAS_UNSUPPORTED
 | 
			
		||||
 | 
			
		||||
# -DGLX_DIRECT_RENDERING - pulls in libdrm stuff in glx/x11
 | 
			
		||||
# -DGLX_USE_APPLEGL      - supposed to be used with GLX_DIRECT_RENDERING to use AGL rather than DRM, but doesn't compile
 | 
			
		||||
# -DIN_DRI_DRIVER
 | 
			
		||||
 | 
			
		||||
ARCH_FLAGS += $(RC_CFLAGS)
 | 
			
		||||
 | 
			
		||||
CFLAGS =  -ggdb3 -Os -Wall -Wmissing-prototypes -std=c99 -ffast-math -fno-strict-aliasing \
 | 
			
		||||
	-I$(INSTALL_DIR)/include -I$(X11_DIR)/include $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(ASM_FLAGS) $(DEFINES)
 | 
			
		||||
CXXFLAGS =  -ggdb3 -Os -Wall -fno-strict-aliasing \
 | 
			
		||||
	-I$(INSTALL_DIR)/include -I$(X11_DIR)/include $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(ASM_FLAGS) $(DEFINES)
 | 
			
		||||
CFLAGS =  -g -O2 -Wall -Wmissing-prototypes -std=c99 -ffast-math -fno-strict-aliasing \
 | 
			
		||||
	-I$(INSTALL_DIR)/include $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(ASM_FLAGS) $(DEFINES)
 | 
			
		||||
CXXFLAGS =  -g -O2 -Wall -fno-strict-aliasing \
 | 
			
		||||
	-I$(INSTALL_DIR)/include $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(ASM_FLAGS) $(DEFINES)
 | 
			
		||||
 | 
			
		||||
# Library names (actual file names)
 | 
			
		||||
GL_LIB_NAME = libGL.dylib
 | 
			
		||||
@@ -41,15 +39,15 @@ GLUT_LIB_GLOB = libglut.*dylib
 | 
			
		||||
GLW_LIB_GLOB = libGLw.*dylib
 | 
			
		||||
OSMESA_LIB_GLOB = libOSMesa.*dylib
 | 
			
		||||
 | 
			
		||||
GL_LIB_DEPS = -L$(INSTALL_DIR)/$(LIB_DIR) -L$(X11_DIR)/$(LIB_DIR) -lX11 -lXext -lm -lpthread
 | 
			
		||||
GL_LIB_DEPS = -L$(INSTALL_DIR)/$(LIB_DIR) -lX11 -lXext -lm -lpthread
 | 
			
		||||
OSMESA_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB)
 | 
			
		||||
GLU_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB)
 | 
			
		||||
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB)  -L$(INSTALL_DIR)/$(LIB_DIR) -L$(X11_DIR)/$(LIB_DIR) -lX11 -lXmu -lXi -lXext
 | 
			
		||||
GLW_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -L$(INSTALL_DIR)/$(LIB_DIR) -L$(X11_DIR)/$(LIB_DIR) -lX11 -lXt
 | 
			
		||||
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L$(INSTALL_DIR)/$(LIB_DIR) -L$(X11_DIR)/$(LIB_DIR) -lX11 -lXmu -lXt -lXi -lm
 | 
			
		||||
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB)  -L$(INSTALL_DIR)/$(LIB_DIR) -lX11 -lXmu -lXi -lXext
 | 
			
		||||
GLW_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -L$(INSTALL_DIR)/$(LIB_DIR) -lX11 -lXt
 | 
			
		||||
APP_LIB_DEPS = -L$(TOP)/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L$(INSTALL_DIR)/$(LIB_DIR) -lX11 -lXmu -lXt -lXi -lm
 | 
			
		||||
 | 
			
		||||
# omit glw lib for now:
 | 
			
		||||
SRC_DIRS = glx/x11 mesa glu glut/glx glew
 | 
			
		||||
SRC_DIRS = glx/x11 mesa glu glw glut/glx
 | 
			
		||||
GLU_DIRS = sgi
 | 
			
		||||
DRIVER_DIRS = osmesa
 | 
			
		||||
#DRIVER_DIRS = dri
 | 
			
		||||
 
 | 
			
		||||
@@ -1,33 +0,0 @@
 | 
			
		||||
# Configuration for Darwin / MacOS X, making dynamic libs
 | 
			
		||||
 | 
			
		||||
include $(TOP)/configs/default
 | 
			
		||||
 | 
			
		||||
CONFIG_NAME = darwin
 | 
			
		||||
 | 
			
		||||
# Compiler and flags
 | 
			
		||||
CC = cc
 | 
			
		||||
CXX = cc
 | 
			
		||||
CFLAGS = -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk \
 | 
			
		||||
         -I/usr/X11R6/include -O3 -fPIC -fno-common -ffast-math -funroll-loops -fexpensive-optimizations -no-cpp-precomp -dynamic -Ddarwin
 | 
			
		||||
CXXFLAGS = -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk \
 | 
			
		||||
         -I/usr/X11R6/include -O3 -fPIC -fno-common -ffast-math -funroll-loops -fexpensive-optimizations -no-cpp-precomp -dynamic -Ddarwin
 | 
			
		||||
 | 
			
		||||
MKLIB_OPTIONS = -archopt "-isysroot /Developer/SDKs/MacOSX10.4u.sdk"
 | 
			
		||||
 | 
			
		||||
# Library names (actual file names)
 | 
			
		||||
GL_LIB_NAME = libGL.dylib
 | 
			
		||||
GLU_LIB_NAME = libGLU.dylib
 | 
			
		||||
GLUT_LIB_NAME = libglut.dylib
 | 
			
		||||
GLW_LIB_NAME = libGLw.dylib
 | 
			
		||||
OSMESA_LIB_NAME = libOSMesa.dylib
 | 
			
		||||
 | 
			
		||||
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lm -lpthread
 | 
			
		||||
OSMESA_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -lGL
 | 
			
		||||
GLU_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -lGL
 | 
			
		||||
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -lGL -lGLU -L/usr/X11R6/lib -lX11 -lXmu -lXi -lXext
 | 
			
		||||
GLW_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXt $(TOP)/lib/GL.dylib
 | 
			
		||||
APP_LIB_DEPS = -L$(TOP)/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm
 | 
			
		||||
 | 
			
		||||
# omit glw lib for now:
 | 
			
		||||
SRC_DIRS = gallium mesa glu glut/glx glew
 | 
			
		||||
 | 
			
		||||
@@ -9,7 +9,7 @@ CONFIG_NAME = default
 | 
			
		||||
 | 
			
		||||
# Version info
 | 
			
		||||
MESA_MAJOR=7
 | 
			
		||||
MESA_MINOR=5
 | 
			
		||||
MESA_MINOR=2
 | 
			
		||||
MESA_TINY=0
 | 
			
		||||
MESA_VERSION = $(MESA_MAJOR).$(MESA_MINOR).$(MESA_TINY)
 | 
			
		||||
 | 
			
		||||
@@ -19,16 +19,11 @@ DRM_SOURCE_PATH=$(TOP)/../drm
 | 
			
		||||
# Compiler and flags
 | 
			
		||||
CC = cc
 | 
			
		||||
CXX = CC
 | 
			
		||||
HOST_CC = $(CC)
 | 
			
		||||
CFLAGS = -O
 | 
			
		||||
CXXFLAGS = -O
 | 
			
		||||
LDFLAGS =
 | 
			
		||||
GLU_CFLAGS = 
 | 
			
		||||
 | 
			
		||||
# Compiler for building demos/tests/etc
 | 
			
		||||
APP_CC = $(CC)
 | 
			
		||||
APP_CXX = $(CXX)
 | 
			
		||||
 | 
			
		||||
# Misc tools and flags
 | 
			
		||||
SHELL = /bin/sh
 | 
			
		||||
MKLIB = $(SHELL) $(TOP)/bin/mklib
 | 
			
		||||
@@ -48,7 +43,6 @@ INDENT_FLAGS = -i4 -nut -br -brs -npcs -ce -T GLubyte -T GLbyte -T Bool
 | 
			
		||||
GL_LIB = GL
 | 
			
		||||
GLU_LIB = GLU
 | 
			
		||||
GLUT_LIB = glut
 | 
			
		||||
GLEW_LIB = GLEW
 | 
			
		||||
GLW_LIB = GLw
 | 
			
		||||
OSMESA_LIB = OSMesa
 | 
			
		||||
 | 
			
		||||
@@ -57,7 +51,6 @@ OSMESA_LIB = OSMesa
 | 
			
		||||
GL_LIB_NAME = lib$(GL_LIB).so
 | 
			
		||||
GLU_LIB_NAME = lib$(GLU_LIB).so
 | 
			
		||||
GLUT_LIB_NAME = lib$(GLUT_LIB).so
 | 
			
		||||
GLEW_LIB_NAME = lib$(GLEW_LIB).a
 | 
			
		||||
GLW_LIB_NAME = lib$(GLW_LIB).so
 | 
			
		||||
OSMESA_LIB_NAME = lib$(OSMESA_LIB).so
 | 
			
		||||
 | 
			
		||||
@@ -69,7 +62,7 @@ GLW_LIB_GLOB = $(GLW_LIB_NAME)*
 | 
			
		||||
OSMESA_LIB_GLOB = $(OSMESA_LIB_NAME)*
 | 
			
		||||
 | 
			
		||||
# Optional assembly language optimization files for libGL
 | 
			
		||||
MESA_ASM_SOURCES = 
 | 
			
		||||
ASM_SOURCES = 
 | 
			
		||||
 | 
			
		||||
# GLw widget sources (Append "GLwMDrawA.c" here and add -lXm to GLW_LIB_DEPS in
 | 
			
		||||
# order to build the Motif widget too)
 | 
			
		||||
@@ -79,35 +72,20 @@ MOTIF_CFLAGS = -I/usr/include/Motif1.2
 | 
			
		||||
 | 
			
		||||
# Directories to build
 | 
			
		||||
LIB_DIR = lib
 | 
			
		||||
SRC_DIRS = mesa gallium egl gallium/winsys glu glut/glx glew glw
 | 
			
		||||
SRC_DIRS = mesa glu glut/glx glw
 | 
			
		||||
GLU_DIRS = sgi
 | 
			
		||||
DRIVER_DIRS = x11 osmesa
 | 
			
		||||
# Which subdirs under $(TOP)/progs/ to enter:
 | 
			
		||||
PROGRAM_DIRS = demos redbook samples glsl xdemos
 | 
			
		||||
 | 
			
		||||
# EGL directories
 | 
			
		||||
EGL_DRIVERS_DIRS = demo
 | 
			
		||||
 | 
			
		||||
# Gallium directories and 
 | 
			
		||||
GALLIUM_DIRS = auxiliary drivers state_trackers
 | 
			
		||||
GALLIUM_AUXILIARY_DIRS = draw translate cso_cache pipebuffer tgsi sct rtasm util indices
 | 
			
		||||
GALLIUM_AUXILIARIES = $(foreach DIR,$(GALLIUM_AUXILIARY_DIRS),$(TOP)/src/gallium/auxiliary/$(DIR)/lib$(DIR).a)
 | 
			
		||||
GALLIUM_DRIVERS_DIRS = softpipe i915simple failover trace
 | 
			
		||||
GALLIUM_DRIVERS = $(foreach DIR,$(GALLIUM_DRIVERS_DIRS),$(TOP)/src/gallium/drivers/$(DIR)/lib$(DIR).a)
 | 
			
		||||
GALLIUM_WINSYS_DIRS = xlib egl_xlib
 | 
			
		||||
GALLIUM_WINSYS_DRM_DIRS =
 | 
			
		||||
GALLIUM_STATE_TRACKERS_DIRS = glx
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Library dependencies
 | 
			
		||||
#EXTRA_LIB_PATH ?=
 | 
			
		||||
GL_LIB_DEPS     = $(EXTRA_LIB_PATH) -lX11 -lXext -lm -lpthread
 | 
			
		||||
EGL_LIB_DEPS    = $(EXTRA_LIB_PATH) -lX11 -ldl
 | 
			
		||||
OSMESA_LIB_DEPS = $(EXTRA_LIB_PATH) -L$(TOP)/$(LIB_DIR) -l$(GL_LIB)
 | 
			
		||||
GLU_LIB_DEPS    = $(EXTRA_LIB_PATH) -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -lm
 | 
			
		||||
GLUT_LIB_DEPS   = $(EXTRA_LIB_PATH) -L$(TOP)/$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -lX11 -lXmu -lXi -lm
 | 
			
		||||
GLW_LIB_DEPS    = $(EXTRA_LIB_PATH) -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -lXt -lX11
 | 
			
		||||
APP_LIB_DEPS    = $(EXTRA_LIB_PATH) -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm
 | 
			
		||||
GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lm -lpthread
 | 
			
		||||
OSMESA_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB)
 | 
			
		||||
GLU_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -lm
 | 
			
		||||
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) $(EXTRA_LIB_PATH) -lX11 -lXmu -lXi -lm
 | 
			
		||||
GLW_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) $(EXTRA_LIB_PATH) -lXt -lX11
 | 
			
		||||
 | 
			
		||||
# Program dependencies - specific GL/glut libraries added in Makefiles
 | 
			
		||||
APP_LIB_DEPS = -lm
 | 
			
		||||
@@ -122,23 +100,3 @@ DRI_DRIVER_INSTALL_DIR = $(INSTALL_LIB_DIR)/dri
 | 
			
		||||
# Where libGL will look for DRI hardware drivers
 | 
			
		||||
DRI_DRIVER_SEARCH_DIR = $(DRI_DRIVER_INSTALL_DIR)
 | 
			
		||||
 | 
			
		||||
# Xorg driver install directory (for xorg state-tracker)
 | 
			
		||||
XORG_DRIVER_INSTALL_DIR = $(INSTALL_LIB_DIR)/xorg/modules/drivers
 | 
			
		||||
 | 
			
		||||
# pkg-config substitutions
 | 
			
		||||
GL_PC_REQ_PRIV =
 | 
			
		||||
GL_PC_LIB_PRIV =
 | 
			
		||||
GL_PC_CFLAGS =
 | 
			
		||||
DRI_PC_REQ_PRIV =
 | 
			
		||||
GLU_PC_REQ = gl
 | 
			
		||||
GLU_PC_REQ_PRIV =
 | 
			
		||||
GLU_PC_LIB_PRIV =
 | 
			
		||||
GLU_PC_CFLAGS =
 | 
			
		||||
GLUT_PC_REQ_PRIV =
 | 
			
		||||
GLUT_PC_LIB_PRIV =
 | 
			
		||||
GLUT_PC_CFLAGS =
 | 
			
		||||
GLW_PC_REQ_PRIV =
 | 
			
		||||
GLW_PC_LIB_PRIV =
 | 
			
		||||
GLW_PC_CFLAGS =
 | 
			
		||||
OSMESA_PC_REQ =
 | 
			
		||||
OSMESA_PC_LIB_PRIV =
 | 
			
		||||
 
 | 
			
		||||
@@ -27,7 +27,6 @@ CFLAGS += -fno-strict-aliasing
 | 
			
		||||
CXXFLAGS += -fno-strict-aliasing
 | 
			
		||||
 | 
			
		||||
ASM_SOURCES = 
 | 
			
		||||
MESA_ASM_SOURCES = 
 | 
			
		||||
 | 
			
		||||
# Library/program dependencies
 | 
			
		||||
LIBDRM_CFLAGS = `pkg-config --cflags libdrm`
 | 
			
		||||
@@ -41,7 +40,7 @@ GLW_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -L/usr/local/lib -lGL -lXt -lX11
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS = glx/x11 gallium mesa glu glut/glx glew glw
 | 
			
		||||
SRC_DIRS = glx/x11 mesa glu glut/glx glw
 | 
			
		||||
DRIVER_DIRS = dri
 | 
			
		||||
PROGRAM_DIRS = 
 | 
			
		||||
WINDOW_SYSTEM=dri
 | 
			
		||||
 
 | 
			
		||||
@@ -6,5 +6,5 @@ include $(TOP)/configs/freebsd-dri
 | 
			
		||||
CONFIG_NAME = freebsd-dri-x86-64
 | 
			
		||||
 | 
			
		||||
ASM_FLAGS = -DUSE_X86_64_ASM
 | 
			
		||||
MESA_ASM_SOURCES = $(X86-64_SOURCES)
 | 
			
		||||
GLAPI_ASM_SOURCES = $(X86-64_API)
 | 
			
		||||
ASM_SOURCES = $(X86-64_SOURCES)
 | 
			
		||||
ASM_API = $(X86-64_API)
 | 
			
		||||
 
 | 
			
		||||
@@ -9,5 +9,5 @@ CONFIG_NAME = freebsd-dri-x86
 | 
			
		||||
PIC_FLAGS = 
 | 
			
		||||
 | 
			
		||||
ASM_FLAGS = -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM
 | 
			
		||||
MESA_ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
GLAPI_ASM_SOURCES = $(X86_API)
 | 
			
		||||
ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
ASM_API = $(X86_API)
 | 
			
		||||
 
 | 
			
		||||
@@ -22,8 +22,7 @@ DEFINES = -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE \
 | 
			
		||||
 | 
			
		||||
X11_INCLUDES = -I/usr/X11R6/include
 | 
			
		||||
 | 
			
		||||
CFLAGS = -Wall -Wmissing-prototypes -Wdeclaration-after-statement \
 | 
			
		||||
	$(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) \
 | 
			
		||||
CFLAGS = -Wall -Wmissing-prototypes $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) \
 | 
			
		||||
	$(DEFINES) $(ASM_FLAGS) $(X11_INCLUDES) -std=c99 -ffast-math 
 | 
			
		||||
 | 
			
		||||
CXXFLAGS = -Wall $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) \
 | 
			
		||||
 
 | 
			
		||||
@@ -1,67 +0,0 @@
 | 
			
		||||
# linux-cell  (non-debug build)
 | 
			
		||||
 | 
			
		||||
include $(TOP)/configs/default
 | 
			
		||||
 | 
			
		||||
CONFIG_NAME = linux-cell
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Omiting other gallium drivers:
 | 
			
		||||
GALLIUM_DRIVERS_DIRS = cell softpipe trace
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Compiler and flags
 | 
			
		||||
CC = ppu32-gcc
 | 
			
		||||
CXX = ppu32-g++
 | 
			
		||||
HOST_CC = gcc
 | 
			
		||||
APP_CC = gcc
 | 
			
		||||
APP_CXX = g++
 | 
			
		||||
 | 
			
		||||
OPT_FLAGS = -O3
 | 
			
		||||
 | 
			
		||||
# Cell SDK location
 | 
			
		||||
## For SDK 2.1: (plus, remove -DSPU_MAIN_PARAM_LONG_LONG below)
 | 
			
		||||
#SDK = /opt/ibm/cell-sdk/prototype/sysroot/usr
 | 
			
		||||
## For SDK 3.0:
 | 
			
		||||
SDK = /opt/cell/sdk/usr
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
CFLAGS = $(OPT_FLAGS) -Wall -Winline -Wmissing-prototypes \
 | 
			
		||||
	-fPIC -m32 -std=c99 -mabi=altivec -maltivec \
 | 
			
		||||
	-I. -I$(SDK)/include \
 | 
			
		||||
	-DGALLIUM_CELL -DUSE_XSHM -D_BSD_SOURCE -D_SVID_SOURCE
 | 
			
		||||
 | 
			
		||||
CXXFLAGS = $(CFLAGS)
 | 
			
		||||
 | 
			
		||||
# Omitting glw here:
 | 
			
		||||
SRC_DIRS = gallium mesa gallium/winsys glu glut/glx glew
 | 
			
		||||
 | 
			
		||||
# Build no traditional Mesa drivers:
 | 
			
		||||
DRIVER_DIRS =
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
MKDEP_OPTIONS = -fdepend -Y
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lm -lpthread \
 | 
			
		||||
	-L$(SDK)/lib -m32 -Wl,-m,elf32ppc -R$(SDK)/lib -lspe2
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
CELL_SPU_LIB = $(TOP)/src/gallium/drivers/cell/spu/g3d_spu.a
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
### SPU stuff
 | 
			
		||||
 | 
			
		||||
SPU_CC = spu-gcc
 | 
			
		||||
 | 
			
		||||
SPU_CFLAGS = $(OPT_FLAGS) -W -Wall -Winline -Wmissing-prototypes -Wno-main \
 | 
			
		||||
	-I. -I$(SDK)/spu/include -I$(TOP)/src/mesa/ $(INCLUDE_DIRS) \
 | 
			
		||||
	-DSPU_MAIN_PARAM_LONG_LONG \
 | 
			
		||||
	-include spu_intrinsics.h
 | 
			
		||||
 | 
			
		||||
SPU_LFLAGS = -L$(SDK)/spu/lib -Wl,-N -lmisc -lm
 | 
			
		||||
 | 
			
		||||
SPU_AR = ppu-ar
 | 
			
		||||
SPU_AR_FLAGS = -qcs
 | 
			
		||||
 | 
			
		||||
SPU_EMBED = ppu32-embedspu
 | 
			
		||||
SPU_EMBED_FLAGS = -m32
 | 
			
		||||
@@ -1,10 +0,0 @@
 | 
			
		||||
# linux-cell-debug
 | 
			
		||||
 | 
			
		||||
include $(TOP)/configs/linux-cell
 | 
			
		||||
 | 
			
		||||
# just override name and OPT_FLAGS here:
 | 
			
		||||
 | 
			
		||||
CONFIG_NAME = linux-cell-debug
 | 
			
		||||
 | 
			
		||||
OPT_FLAGS = -g -DDEBUG
 | 
			
		||||
 | 
			
		||||
@@ -21,12 +21,12 @@ HAVE_X86 = $(shell uname -m | grep 'i[3-6]86' >/dev/null && echo yes)
 | 
			
		||||
ifeq ($(HAVE_X86), yes)
 | 
			
		||||
     CFLAGS   += -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM
 | 
			
		||||
     CXXFLAGS += -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM
 | 
			
		||||
     MESA_ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
     GLAPI_ASM_SOURCES = $(X86_API)
 | 
			
		||||
     ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
     ASM_API = $(X86_API)
 | 
			
		||||
endif
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS     = gallium mesa glu glut/directfb glew
 | 
			
		||||
SRC_DIRS     = mesa glu glut/directfb
 | 
			
		||||
GLU_DIRS     = sgi
 | 
			
		||||
DRIVER_DIRS  = directfb
 | 
			
		||||
PROGRAM_DIRS = demos directfb
 | 
			
		||||
 
 | 
			
		||||
@@ -13,7 +13,7 @@ CXX = g++
 | 
			
		||||
#MKDEP = gcc -M
 | 
			
		||||
#MKDEP_OPTIONS = -MF depend
 | 
			
		||||
 | 
			
		||||
OPT_FLAGS  = -O2 -g
 | 
			
		||||
OPT_FLAGS  = -O -g
 | 
			
		||||
PIC_FLAGS  = -fPIC
 | 
			
		||||
 | 
			
		||||
# Add '-DGLX_USE_TLS' to ARCH_FLAGS to enable TLS support.
 | 
			
		||||
@@ -38,30 +38,37 @@ GLUT_CFLAGS = -fexceptions
 | 
			
		||||
CFLAGS += -fno-strict-aliasing
 | 
			
		||||
CXXFLAGS += -fno-strict-aliasing
 | 
			
		||||
 | 
			
		||||
MESA_ASM_SOURCES = 
 | 
			
		||||
ASM_SOURCES = 
 | 
			
		||||
 | 
			
		||||
# Library/program dependencies
 | 
			
		||||
EXTRA_LIB_PATH=-L/usr/X11R6/lib
 | 
			
		||||
 | 
			
		||||
LIBDRM_CFLAGS = $(shell pkg-config --cflags libdrm)
 | 
			
		||||
LIBDRM_LIB = $(shell pkg-config --libs libdrm)
 | 
			
		||||
LIBDRM_CFLAGS = `pkg-config --cflags libdrm`
 | 
			
		||||
LIBDRM_LIB = `pkg-config --libs libdrm`
 | 
			
		||||
DRI_LIB_DEPS  = $(EXTRA_LIB_PATH) -lm -lpthread -lexpat -ldl $(LIBDRM_LIB)
 | 
			
		||||
GL_LIB_DEPS   = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lXdamage -lXfixes \
 | 
			
		||||
		-lm -lpthread -ldl $(LIBDRM_LIB)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS := glx/x11 egl $(SRC_DIRS)
 | 
			
		||||
PROGRAM_DIRS := egl $(PROGRAM_DIRS)
 | 
			
		||||
# This is now 0 by default since it seems to confuse the hell out of people
 | 
			
		||||
# and generate a lot of extra noise on bugzilla.  If you need to build with
 | 
			
		||||
# EGL, do 'make linux-dri USING_EGL=1'
 | 
			
		||||
 | 
			
		||||
# EGL directories
 | 
			
		||||
EGL_DRIVERS_DIRS = demo glx
 | 
			
		||||
USING_EGL=0
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
ifeq ($(USING_EGL), 1)
 | 
			
		||||
SRC_DIRS = egl glx/x11 mesa glu glut/glx glw
 | 
			
		||||
PROGRAM_DIRS = egl xdemos
 | 
			
		||||
else
 | 
			
		||||
SRC_DIRS = glx/x11 mesa glu glut/glx glw
 | 
			
		||||
PROGRAM_DIRS = xdemos
 | 
			
		||||
endif
 | 
			
		||||
 | 
			
		||||
DRIVER_DIRS = dri
 | 
			
		||||
WINDOW_SYSTEM = dri
 | 
			
		||||
GALLIUM_WINSYS_DIRS = drm
 | 
			
		||||
GALLIUM_WINSYS_DRM_DIRS = intel
 | 
			
		||||
GALLIUM_STATE_TRACKERS_DIRS = egl
 | 
			
		||||
WINDOW_SYSTEM=dri
 | 
			
		||||
 | 
			
		||||
# gamma are missing because they have not been converted to use the new
 | 
			
		||||
# interface.
 | 
			
		||||
DRI_DIRS = i810 i915 i965 mach64 mga r128 r200 r300 radeon s3v \
 | 
			
		||||
	savage sis tdfx trident unichrome ffb swrast
 | 
			
		||||
	savage sis tdfx trident unichrome ffb
 | 
			
		||||
 
 | 
			
		||||
@@ -9,7 +9,7 @@ OPT_FLAGS = -Os -mcpu=603
 | 
			
		||||
PIC_FLAGS = -fPIC
 | 
			
		||||
 | 
			
		||||
ASM_FLAGS = -DUSE_PPC_ASM -DUSE_VMX_ASM
 | 
			
		||||
MESA_ASM_SOURCES = $(PPC_SOURCES)
 | 
			
		||||
ASM_SOURCES = $(PPC_SOURCES)
 | 
			
		||||
 | 
			
		||||
# Build only the drivers for cards that exist on PowerPC.  At some point MGA
 | 
			
		||||
# will be added, but not yet.
 | 
			
		||||
 
 | 
			
		||||
@@ -5,9 +5,10 @@ include $(TOP)/configs/linux-dri
 | 
			
		||||
 | 
			
		||||
CONFIG_NAME = linux-dri-x86
 | 
			
		||||
 | 
			
		||||
ARCH_FLAGS = -m32 -mmmx -msse -msse2
 | 
			
		||||
# Add -m32 to CFLAGS:
 | 
			
		||||
ARCH_FLAGS = -m32
 | 
			
		||||
 | 
			
		||||
ASM_FLAGS = -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM
 | 
			
		||||
MESA_ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
GLAPI_ASM_SOURCES = $(X86_API)
 | 
			
		||||
ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
ASM_API = $(X86_API)
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -8,8 +8,8 @@ CONFIG_NAME = linux-dri-x86-64
 | 
			
		||||
ARCH_FLAGS = -m64
 | 
			
		||||
 | 
			
		||||
ASM_FLAGS = -DUSE_X86_64_ASM
 | 
			
		||||
MESA_ASM_SOURCES = $(X86-64_SOURCES)
 | 
			
		||||
GLAPI_ASM_SOURCES = $(X86-64_API)
 | 
			
		||||
ASM_SOURCES = $(X86-64_SOURCES)
 | 
			
		||||
ASM_API = $(X86-64_API)
 | 
			
		||||
 | 
			
		||||
LIB_DIR = lib64
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -25,7 +25,7 @@ DEFINES = -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE \
 | 
			
		||||
	-DGLX_DIRECT_RENDERING -DGLX_INDIRECT_RENDERING \
 | 
			
		||||
        -DHAVE_ALIAS -DUSE_XCB -DHAVE_POSIX_MEMALIGN
 | 
			
		||||
 | 
			
		||||
X11_INCLUDES = $(shell pkg-config --cflags-only-I x11) $(shell pkg-config --cflags-only-I xcb) $(shell pkg-config --cflags-only-I x11-xcb) $(shell pkg-config --cflags-only-I xcb-glx)
 | 
			
		||||
X11_INCLUDES = `pkg-config --cflags-only-I x11` `pkg-config --cflags-only-I xcb` `pkg-config --cflags-only-I x11-xcb` `pkg-config --cflags-only-I xcb-glx`
 | 
			
		||||
 | 
			
		||||
CFLAGS = -Wall -Wmissing-prototypes $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) \
 | 
			
		||||
	$(DEFINES) $(ASM_FLAGS) -std=c99 -ffast-math 
 | 
			
		||||
@@ -36,16 +36,17 @@ CXXFLAGS = -Wall $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES)
 | 
			
		||||
CFLAGS += -fno-strict-aliasing
 | 
			
		||||
CXXFLAGS += -fno-strict-aliasing
 | 
			
		||||
 | 
			
		||||
MESA_ASM_SOURCES = 
 | 
			
		||||
ASM_SOURCES = 
 | 
			
		||||
 | 
			
		||||
# Library/program dependencies
 | 
			
		||||
EXTRA_LIB_PATH=$(shell pkg-config --libs-only-L x11)
 | 
			
		||||
EXTRA_LIB_PATH=`pkg-config --libs-only-L x11`
 | 
			
		||||
 | 
			
		||||
LIBDRM_CFLAGS = $(shell pkg-config --cflags libdrm)
 | 
			
		||||
LIBDRM_LIB = $(shell pkg-config --libs libdrm)
 | 
			
		||||
LIBDRM_CFLAGS = `pkg-config --cflags libdrm`
 | 
			
		||||
LIBDRM_LIB = `pkg-config --libs libdrm`
 | 
			
		||||
DRI_LIB_DEPS  = $(EXTRA_LIB_PATH) -lm -lpthread -lexpat -ldl $(LIBDRM_LIB)
 | 
			
		||||
GL_LIB_DEPS   = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lm -lpthread -ldl \
 | 
			
		||||
                $(LIBDRM_LIB) $(shell pkg-config --libs xcb) $(shell pkg-config --libs x11-xcb) $(shell pkg-config --libs xcb-glx)
 | 
			
		||||
GL_LIB_DEPS   = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lXdamage -lXfixes \
 | 
			
		||||
		-lm -lpthread -ldl $(LIBDRM_LIB) `pkg-config --libs xcb` \
 | 
			
		||||
		`pkg-config --libs x11-xcb` `pkg-config --libs xcb-glx`
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# This is now 0 by default since it seems to confuse the hell out of people
 | 
			
		||||
@@ -56,10 +57,10 @@ USING_EGL=0
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
ifeq ($(USING_EGL), 1)
 | 
			
		||||
SRC_DIRS = egl glx/x11 gallium mesa glu glut/glx glew glw
 | 
			
		||||
PROGRAM_DIRS = egl
 | 
			
		||||
SRC_DIRS = egl glx/x11 mesa glu glut/glx glw
 | 
			
		||||
PROGRAM_DIRS = egl xdemos
 | 
			
		||||
else
 | 
			
		||||
SRC_DIRS = glx/x11 gallium mesa glu glut/glx glew glw
 | 
			
		||||
SRC_DIRS = glx/x11 mesa glu glut/glx glw
 | 
			
		||||
PROGRAM_DIRS = xdemos
 | 
			
		||||
endif
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -1,65 +0,0 @@
 | 
			
		||||
# -*-makefile-*-
 | 
			
		||||
# Configuration for linux-dri: Linux DRI hardware drivers for XFree86 & others
 | 
			
		||||
 | 
			
		||||
include $(TOP)/configs/default
 | 
			
		||||
 | 
			
		||||
CONFIG_NAME = linux-dri
 | 
			
		||||
 | 
			
		||||
# Compiler and flags
 | 
			
		||||
CC = gcc
 | 
			
		||||
CXX = g++
 | 
			
		||||
 | 
			
		||||
#MKDEP = /usr/X11R6/bin/makedepend
 | 
			
		||||
#MKDEP = gcc -M
 | 
			
		||||
#MKDEP_OPTIONS = -MF depend
 | 
			
		||||
 | 
			
		||||
OPT_FLAGS  = -O -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 \
 | 
			
		||||
	-DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER \
 | 
			
		||||
	-DGLX_DIRECT_RENDERING -DGLX_INDIRECT_RENDERING \
 | 
			
		||||
	-DHAVE_ALIAS -DHAVE_POSIX_MEMALIGN
 | 
			
		||||
 | 
			
		||||
X11_INCLUDES = -I/usr/X11R6/include
 | 
			
		||||
 | 
			
		||||
CFLAGS = -Wall -Wmissing-prototypes -std=c99 -ffast-math \
 | 
			
		||||
	$(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) $(ASM_FLAGS)
 | 
			
		||||
 | 
			
		||||
CXXFLAGS = -Wall $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
MESA_ASM_SOURCES = 
 | 
			
		||||
 | 
			
		||||
# Library/program dependencies
 | 
			
		||||
EXTRA_LIB_PATH=-L/usr/X11R6/lib
 | 
			
		||||
 | 
			
		||||
LIBDRM_CFLAGS = $(shell pkg-config --cflags libdrm)
 | 
			
		||||
LIBDRM_LIB = $(shell pkg-config --libs libdrm)
 | 
			
		||||
DRI_LIB_DEPS  = $(EXTRA_LIB_PATH) -lm -lpthread -lexpat -ldl $(LIBDRM_LIB)
 | 
			
		||||
GL_LIB_DEPS   = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lXdamage -lXfixes \
 | 
			
		||||
		-lm -lpthread -ldl \
 | 
			
		||||
                $(LIBDRM_LIB)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# This is now 0 by default since it seems to confuse the hell out of people
 | 
			
		||||
# and generate a lot of extra noise on bugzilla.  If you need to build with
 | 
			
		||||
# EGL, do 'make linux-dri USING_EGL=1'
 | 
			
		||||
 | 
			
		||||
USING_EGL=0
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS = gallium mesa gallium/winsys glu egl
 | 
			
		||||
PROGRAM_DIRS = egl
 | 
			
		||||
 | 
			
		||||
DRIVER_DIRS = dri
 | 
			
		||||
WINDOW_SYSTEM = dri
 | 
			
		||||
GALLIUM_WINSYS_DIRS = egl_drm
 | 
			
		||||
 | 
			
		||||
# gamma are missing because they have not been converted to use the new
 | 
			
		||||
# interface.
 | 
			
		||||
DRI_DIRS = intel 
 | 
			
		||||
@@ -9,7 +9,7 @@ CFLAGS = -O3 -ffast-math -ansi -pedantic -fPIC -D_POSIX_C_SOURCE=199309L -D_SVID
 | 
			
		||||
# Work around aliasing bugs - developers should comment this out
 | 
			
		||||
CFLAGS += -fno-strict-aliasing
 | 
			
		||||
 | 
			
		||||
SRC_DIRS = gallium mesa glu glut/fbdev glew
 | 
			
		||||
SRC_DIRS = mesa glu glut/fbdev
 | 
			
		||||
DRIVER_DIRS = fbdev osmesa
 | 
			
		||||
PROGRAM_DIRS = fbdev demos redbook samples
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -16,7 +16,7 @@ GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lm -lpthread
 | 
			
		||||
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm
 | 
			
		||||
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm
 | 
			
		||||
 | 
			
		||||
MESA_ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
GLAPI_ASM_SOURCES = $(X86_API)
 | 
			
		||||
ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
ASM_API = $(X86_API)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -23,5 +23,5 @@ GL_LIB_DEPS =
 | 
			
		||||
GLUT_LIB_DEPS =
 | 
			
		||||
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm -lpthread -lcxa -lunwind
 | 
			
		||||
 | 
			
		||||
MESA_ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
GLAPI_ASM_SOURCES = $(X86_API)
 | 
			
		||||
ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
ASM_API = $(X86_API)
 | 
			
		||||
 
 | 
			
		||||
@@ -37,7 +37,7 @@ CXXFLAGS = $(WARN_FLAGS) $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES)
 | 
			
		||||
CFLAGS += -fno-strict-aliasing
 | 
			
		||||
CXXFLAGS += -fno-strict-aliasing
 | 
			
		||||
 | 
			
		||||
MESA_ASM_SOURCES = 
 | 
			
		||||
ASM_SOURCES = 
 | 
			
		||||
 | 
			
		||||
# Library/program dependencies
 | 
			
		||||
EXTRA_LIB_PATH=-L/usr/X11R6/lib
 | 
			
		||||
@@ -47,7 +47,7 @@ GL_LIB_DEPS   = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lm -lpthread -ldl
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS = glx/x11 glu glut/glx glew glw
 | 
			
		||||
SRC_DIRS = glx/x11 glu glut/glx glw
 | 
			
		||||
DRIVER_DIRS =
 | 
			
		||||
PROGRAM_DIRS = 
 | 
			
		||||
WINDOW_SYSTEM=dri
 | 
			
		||||
 
 | 
			
		||||
@@ -1,35 +0,0 @@
 | 
			
		||||
# -*-makefile-*-
 | 
			
		||||
# Configuration for Linux and LLVM with debugging info
 | 
			
		||||
 | 
			
		||||
include $(TOP)/configs/linux
 | 
			
		||||
 | 
			
		||||
CONFIG_NAME = linux-llvm
 | 
			
		||||
 | 
			
		||||
GALLIUM_AUXILIARY_DIRS += gallivm
 | 
			
		||||
 | 
			
		||||
OPT_FLAGS = -g -ansi -pedantic
 | 
			
		||||
DEFINES += -DDEBUG -DDEBUG_MATH -DMESA_LLVM=1
 | 
			
		||||
 | 
			
		||||
LLVM_VERSION := $(shell llvm-config --version)
 | 
			
		||||
 | 
			
		||||
ifeq ($(LLVM_VERSION),)
 | 
			
		||||
  $(warning Could not find LLVM! Make Sure 'llvm-config' is in the path)
 | 
			
		||||
  MESA_LLVM=0
 | 
			
		||||
else
 | 
			
		||||
  MESA_LLVM=1
 | 
			
		||||
  $(info Using LLVM version: $(LLVM_VERSION))
 | 
			
		||||
endif
 | 
			
		||||
 | 
			
		||||
ifeq ($(MESA_LLVM),1)
 | 
			
		||||
#  LLVM_CFLAGS=`llvm-config --cflags`
 | 
			
		||||
  LLVM_CXXFLAGS=`llvm-config --cxxflags backend bitreader engine ipo interpreter instrumentation` -Wno-long-long
 | 
			
		||||
  LLVM_LDFLAGS=`llvm-config --ldflags backend bitreader engine ipo interpreter instrumentation`
 | 
			
		||||
  LLVM_LIBS=`llvm-config --libs backend bitreader engine ipo interpreter instrumentation`
 | 
			
		||||
  MKLIB_OPTIONS=-cplusplus
 | 
			
		||||
else
 | 
			
		||||
  LLVM_CFLAGS=
 | 
			
		||||
  LLVM_CXXFLAGS=
 | 
			
		||||
endif
 | 
			
		||||
 | 
			
		||||
LD = g++
 | 
			
		||||
GL_LIB_DEPS = $(LLVM_LDFLAGS) $(LLVM_LIBS) $(EXTRA_LIB_PATH) -lX11 -lXext -lm -lpthread -lstdc++
 | 
			
		||||
@@ -17,7 +17,7 @@ CFLAGS += -fno-strict-aliasing
 | 
			
		||||
CXXFLAGS += -fno-strict-aliasing
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS = gallium mesa glu
 | 
			
		||||
SRC_DIRS = mesa glu
 | 
			
		||||
DRIVER_DIRS = osmesa
 | 
			
		||||
PROGRAM_DIRS = osdemos
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -1,37 +0,0 @@
 | 
			
		||||
# Configuration for building static libOSMesa.a on Linux, no Xlib driver
 | 
			
		||||
# This doesn't really have any Linux dependencies, so it should be usable
 | 
			
		||||
# on other (gcc-based) systems.
 | 
			
		||||
 | 
			
		||||
include $(TOP)/configs/default
 | 
			
		||||
 | 
			
		||||
CONFIG_NAME = linux-osmesa
 | 
			
		||||
 | 
			
		||||
# Compiler and flags
 | 
			
		||||
CC = gcc -m32
 | 
			
		||||
CXX = g++ -m32
 | 
			
		||||
CFLAGS = -O3 -ansi -pedantic -fPIC -ffast-math -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE -DPTHREADS
 | 
			
		||||
CXXFLAGS = -O3 -ansi -pedantic -fPIC -ffast-math -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE
 | 
			
		||||
 | 
			
		||||
MKLIB_OPTIONS = -static
 | 
			
		||||
 | 
			
		||||
# Library names (actual file names)
 | 
			
		||||
GL_LIB_NAME = libGL.a
 | 
			
		||||
GLU_LIB_NAME = libGLU.a
 | 
			
		||||
GLUT_LIB_NAME = libglut.a
 | 
			
		||||
GLW_LIB_NAME = libGLw.a
 | 
			
		||||
OSMESA_LIB_NAME = libOSMesa.a
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS = mesa glu
 | 
			
		||||
DRIVER_DIRS = osmesa
 | 
			
		||||
PROGRAM_DIRS = osdemos
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Dependencies
 | 
			
		||||
GL_LIB_DEPS =
 | 
			
		||||
OSMESA_LIB_DEPS =
 | 
			
		||||
GLU_LIB_DEPS =
 | 
			
		||||
GLUT_LIB_DEPS =
 | 
			
		||||
GLW_LIB_DEPS =
 | 
			
		||||
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) \
 | 
			
		||||
               $(EXTRA_LIB_PATH) -lX11 -lXmu -lXt -lXi -lpthread -lstdc++ -lm
 | 
			
		||||
@@ -20,7 +20,7 @@ OSMESA_LIB_NAME = libOSMesa16.so
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS = gallium mesa glu
 | 
			
		||||
SRC_DIRS = mesa glu
 | 
			
		||||
DRIVER_DIRS = osmesa
 | 
			
		||||
PROGRAM_DIRS = 
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -22,7 +22,7 @@ OSMESA_LIB_NAME = libOSMesa16.a
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS = gallium mesa glu
 | 
			
		||||
SRC_DIRS = mesa glu
 | 
			
		||||
DRIVER_DIRS = osmesa
 | 
			
		||||
PROGRAM_DIRS = 
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -20,7 +20,7 @@ OSMESA_LIB_NAME = libOSMesa32.so
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS = gallium mesa glu
 | 
			
		||||
SRC_DIRS = mesa glu
 | 
			
		||||
DRIVER_DIRS = osmesa
 | 
			
		||||
PROGRAM_DIRS = 
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -1,8 +1,29 @@
 | 
			
		||||
# Configuration for profiling on Linux with gprof
 | 
			
		||||
 | 
			
		||||
include $(TOP)/configs/linux-static
 | 
			
		||||
include $(TOP)/configs/default
 | 
			
		||||
 | 
			
		||||
CONFIG_NAME = linux-profile
 | 
			
		||||
 | 
			
		||||
OPT_FLAGS = -pg -g -O2
 | 
			
		||||
DEFINES += -DNDEBUG
 | 
			
		||||
# Compiler and flags
 | 
			
		||||
CC = gcc
 | 
			
		||||
CXX = g++
 | 
			
		||||
 | 
			
		||||
CFLAGS = -pg -O -ansi -pedantic -Wall -Wmissing-prototypes -Wundef -fPIC -ffast-math -D_POSIX_SOURCE -D_SVID_SOURCE -D_BSD_SOURCE -I/usr/X11R6/include -DUSE_XSHM -DPTHREADS -DDEBUG
 | 
			
		||||
 | 
			
		||||
CXXFLAGS = -pg -O -ansi -pedantic -Wall -Wundef -fPIC -ffast-math -D_POSIX_SOURCE -D_SVID_SOURCE -D_BSD_SOURCE -DDEBUG
 | 
			
		||||
 | 
			
		||||
GLUT_CFLAGS = -fexceptions
 | 
			
		||||
 | 
			
		||||
# Need to have -L/usr/X11R6/lib in these:
 | 
			
		||||
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lm -lpthread
 | 
			
		||||
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm
 | 
			
		||||
GLW_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -lXt -L/usr/X11R6/lib -lX11
 | 
			
		||||
 | 
			
		||||
# Need to make static libs for profiling:
 | 
			
		||||
MKLIB_OPTIONS = -static
 | 
			
		||||
GL_LIB_NAME = lib$(GL_LIB).a
 | 
			
		||||
GLU_LIB_NAME = lib$(GLU_LIB).a
 | 
			
		||||
GLUT_LIB_NAME = lib$(GLUT_LIB).a
 | 
			
		||||
GLW_LIB_NAME = lib$(GLW_LIB).a
 | 
			
		||||
OSMESA_LIB_NAME = lib$(OSMesa).a
 | 
			
		||||
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm -lpthread
 | 
			
		||||
 
 | 
			
		||||
@@ -16,10 +16,10 @@ PIC_FLAGS  = -fPIC
 | 
			
		||||
ARCH_FLAGS ?=
 | 
			
		||||
 | 
			
		||||
# DRM and pciaccess
 | 
			
		||||
LIBDRM_CFLAGS = $(shell pkg-config --cflags libdrm)
 | 
			
		||||
LIBDRM_LIB = $(shell pkg-config --libs libdrm)
 | 
			
		||||
PCIACCESS_CFLAGS = $(shell pkg-config --cflags pciaccess)
 | 
			
		||||
PCIACCESS_LIB = $(shell pkg-config --libs pciaccess)
 | 
			
		||||
LIBDRM_CFLAGS = `pkg-config --cflags libdrm`
 | 
			
		||||
LIBDRM_LIB = `pkg-config --libs libdrm`
 | 
			
		||||
PCIACCESS_CFLAGS = `pkg-config --cflags pciaccess`
 | 
			
		||||
PCIACCESS_LIB = `pkg-config --libs pciaccess`
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
DEFINES = -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE \
 | 
			
		||||
@@ -36,7 +36,7 @@ CXXFLAGS = $(WARN_FLAGS) $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES)
 | 
			
		||||
CFLAGS += -fno-strict-aliasing
 | 
			
		||||
CXXFLAGS += -fno-strict-aliasing
 | 
			
		||||
 | 
			
		||||
MESA_ASM_SOURCES = 
 | 
			
		||||
ASM_SOURCES = 
 | 
			
		||||
 | 
			
		||||
# Library/program dependencies
 | 
			
		||||
DRI_LIB_DEPS = -lm -lpthread -lexpat -ldl -L$(TOP)/$(LIB_DIR) $(PCIACCESS_LIB)
 | 
			
		||||
@@ -46,7 +46,7 @@ GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -lm
 | 
			
		||||
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm -lpthread
 | 
			
		||||
 | 
			
		||||
# Directories
 | 
			
		||||
SRC_DIRS = glx/mini gallium mesa glu glut/mini glew
 | 
			
		||||
SRC_DIRS = glx/mini mesa glu glut/mini
 | 
			
		||||
DRIVER_DIRS = dri
 | 
			
		||||
PROGRAM_DIRS = miniglx
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -6,5 +6,5 @@ include $(TOP)/configs/linux-solo
 | 
			
		||||
CONFIG_NAME = linux-solo-x86
 | 
			
		||||
 | 
			
		||||
ASM_FLAGS = -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM
 | 
			
		||||
MESA_ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
GLAPI_ASM_SOURCES = $(X86_API)
 | 
			
		||||
ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
ASM_API = $(X86_API)
 | 
			
		||||
 
 | 
			
		||||
@@ -5,5 +5,5 @@ include $(TOP)/configs/linux
 | 
			
		||||
CONFIG_NAME = linux-sparc
 | 
			
		||||
 | 
			
		||||
#ASM_FLAGS = -DUSE_SPARC_ASM
 | 
			
		||||
#MESA_ASM_SOURCES = $(SPARC_SOURCES)
 | 
			
		||||
#GLAPI_ASM_SOURCES = $(SPARC_API)
 | 
			
		||||
#ASM_SOURCES = $(SPARC_SOURCES)
 | 
			
		||||
#ASM_API = $(SPARC_API)
 | 
			
		||||
 
 | 
			
		||||
@@ -22,5 +22,5 @@ GLUT_LIB_DEPS =
 | 
			
		||||
GLW_LIB_DEPS = 
 | 
			
		||||
 | 
			
		||||
# Need to specify all libraries we may need
 | 
			
		||||
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) \
 | 
			
		||||
	-l$(GL_LIB) -lm -L/usr/X11R6/lib/ -lX11 -lXext -lXmu -lXi -lpthread
 | 
			
		||||
APP_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lXmu -lXt -lXi -lpthread \
 | 
			
		||||
	-lstdc++ -lm
 | 
			
		||||
 
 | 
			
		||||
@@ -4,8 +4,6 @@ include $(TOP)/configs/linux
 | 
			
		||||
 | 
			
		||||
CONFIG_NAME = linux-x86
 | 
			
		||||
 | 
			
		||||
ARCH_FLAGS = -m32 -mmmx -msse -msse2
 | 
			
		||||
 | 
			
		||||
ASM_FLAGS = -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM
 | 
			
		||||
MESA_ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
GLAPI_ASM_SOURCES = $(X86_API)
 | 
			
		||||
ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
ASM_API = $(X86_API)
 | 
			
		||||
 
 | 
			
		||||
@@ -6,8 +6,8 @@ CONFIG_NAME = linux-x86-64
 | 
			
		||||
 | 
			
		||||
ARCH_FLAGS = -m64
 | 
			
		||||
 | 
			
		||||
MESA_ASM_SOURCES = $(X86-64_SOURCES)
 | 
			
		||||
GLAPI_ASM_SOURCES = $(X86-64_API)
 | 
			
		||||
ASM_SOURCES = $(X86-64_SOURCES)
 | 
			
		||||
ASM_API = $(X86-64_API)
 | 
			
		||||
ASM_FLAGS = -DUSE_X86_64_ASM
 | 
			
		||||
 | 
			
		||||
LIB_DIR = lib64
 | 
			
		||||
 
 | 
			
		||||
@@ -1,8 +0,0 @@
 | 
			
		||||
# Configuration for profiling on Linux for 64-bit X86 (Opteron) with gprof
 | 
			
		||||
 | 
			
		||||
include $(TOP)/configs/linux-x86-64-static
 | 
			
		||||
 | 
			
		||||
CONFIG_NAME = linux-x86-64-profile
 | 
			
		||||
 | 
			
		||||
OPT_FLAGS = -pg -g -O2
 | 
			
		||||
DEFINES += -DNDEBUG
 | 
			
		||||
@@ -20,8 +20,5 @@ OSMESA_LIB_DEPS =
 | 
			
		||||
GLU_LIB_DEPS = 
 | 
			
		||||
GLUT_LIB_DEPS = 
 | 
			
		||||
GLW_LIB_DEPS = 
 | 
			
		||||
 | 
			
		||||
# Need to specify all libraries we may need
 | 
			
		||||
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -Wl,--start-group \
 | 
			
		||||
               -l$(GL_LIB) $(TOP)/src/mesa/pipe/softpipe/libsoftpipe.a -Wl,--end-group \
 | 
			
		||||
               $(EXTRA_LIB_PATH) -lX11 -lXext -lXmu -lXt -lXi -lpthread -lstdc++ -lm
 | 
			
		||||
APP_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lXmu -lXt -lXi -lpthread \
 | 
			
		||||
	-lstdc++ -lm
 | 
			
		||||
 
 | 
			
		||||
@@ -18,8 +18,8 @@ GLUT_CFLAGS = -fexceptions
 | 
			
		||||
CFLAGS += -fno-strict-aliasing
 | 
			
		||||
CXXFLAGS += -fno-strict-aliasing
 | 
			
		||||
 | 
			
		||||
MESA_ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
GLAPI_ASM_SOURCES = $(X86_API)
 | 
			
		||||
ASM_SOURCES = $(X86_SOURCES)
 | 
			
		||||
ASM_API = $(X86_API)
 | 
			
		||||
 | 
			
		||||
# Library/program dependencies
 | 
			
		||||
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -L/usr/local/glide/lib -lglide3x -lm -lpthread
 | 
			
		||||
 
 | 
			
		||||
@@ -1,8 +0,0 @@
 | 
			
		||||
# Configuration for profiling on Linux with x86 optimizations with gprof
 | 
			
		||||
 | 
			
		||||
include $(TOP)/configs/linux-x86-static
 | 
			
		||||
 | 
			
		||||
CONFIG_NAME = linux-x86-profile
 | 
			
		||||
 | 
			
		||||
OPT_FLAGS = -pg -g -O2
 | 
			
		||||
DEFINES += -DNDEBUG
 | 
			
		||||
@@ -20,7 +20,5 @@ OSMESA_LIB_DEPS =
 | 
			
		||||
GLU_LIB_DEPS = 
 | 
			
		||||
GLUT_LIB_DEPS = 
 | 
			
		||||
GLW_LIB_DEPS = 
 | 
			
		||||
 | 
			
		||||
# Need to specify all libraries we may need
 | 
			
		||||
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) \
 | 
			
		||||
	-l$(GL_LIB) $(EXTRA_LIB_PATH) -lX11 -lXext -lXmu -lXt -lXi -lpthread -lstdc++ -lm
 | 
			
		||||
APP_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lXmu -lXt -lXi -lpthread \
 | 
			
		||||
	-lstdc++ -lm
 | 
			
		||||
 
 | 
			
		||||
@@ -16,8 +16,8 @@ ARCH_FLAGS ?=
 | 
			
		||||
 | 
			
		||||
DEFINES = -D_REENTRANT -DUSE_XSHM
 | 
			
		||||
 | 
			
		||||
MESA_ASM_SOURCES = $(SPARC_SOURCES)
 | 
			
		||||
GLAPI_ASM_SOURCES = $(SPARC_API)
 | 
			
		||||
ASM_SOURCES = $(SPARC_SOURCES)
 | 
			
		||||
ASM_API = $(SPARC_API)
 | 
			
		||||
ASM_FLAGS = -DUSE_SPARC_ASM
 | 
			
		||||
 | 
			
		||||
CFLAGS   = $(WARN_FLAGS) $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) \
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										369
									
								
								configure.ac
									
									
									
									
									
								
							
							
						
						
									
										369
									
								
								configure.ac
									
									
									
									
									
								
							@@ -5,8 +5,12 @@ AC_PREREQ([2.59])
 | 
			
		||||
dnl Versioning - scrape the version from configs/default
 | 
			
		||||
m4_define([mesa_version],
 | 
			
		||||
    [m4_esyscmd([${MAKE-make} -s -f bin/version.mk version | tr -d '\n'])])
 | 
			
		||||
m4_ifval(mesa_version,,
 | 
			
		||||
    [m4_fatal([Failed to get the Mesa version from `make -f bin/version.mk version`])])
 | 
			
		||||
m4_ifval(mesa_version,[],[
 | 
			
		||||
    m4_errprint([Error: Failed to get the Mesa version from the output of
 | 
			
		||||
       running `make -f bin/version.mk version'
 | 
			
		||||
])
 | 
			
		||||
    m4_exit([1])
 | 
			
		||||
])
 | 
			
		||||
 | 
			
		||||
dnl Tell the user about autoconf.html in the --help output
 | 
			
		||||
m4_divert_once([HELP_END], [
 | 
			
		||||
@@ -18,8 +22,7 @@ AC_CONFIG_AUX_DIR([bin])
 | 
			
		||||
AC_CANONICAL_HOST
 | 
			
		||||
 | 
			
		||||
dnl Versions for external dependencies
 | 
			
		||||
LIBDRM_REQUIRED=2.4.3
 | 
			
		||||
DRI2PROTO_REQUIRED=1.99.3
 | 
			
		||||
LIBDRM_REQUIRED=2.3.1
 | 
			
		||||
 | 
			
		||||
dnl Check for progs
 | 
			
		||||
AC_PROG_CPP
 | 
			
		||||
@@ -42,23 +45,23 @@ esac
 | 
			
		||||
MKDEP_OPTIONS=-fdepend
 | 
			
		||||
dnl Ask gcc where it's keeping its secret headers
 | 
			
		||||
if test "x$GCC" = xyes; then
 | 
			
		||||
    for dir in include include-fixed; do
 | 
			
		||||
        GCC_INCLUDES=`$CC -print-file-name=$dir`
 | 
			
		||||
        if test "x$GCC_INCLUDES" != x && \
 | 
			
		||||
           test "$GCC_INCLUDES" != "$dir" && \
 | 
			
		||||
           test -d "$GCC_INCLUDES"; then
 | 
			
		||||
            MKDEP_OPTIONS="$MKDEP_OPTIONS -I$GCC_INCLUDES"
 | 
			
		||||
        fi
 | 
			
		||||
    done
 | 
			
		||||
    GCC_INCLUDES=`$CC -print-file-name=include`
 | 
			
		||||
    if test "x$GCC_INCLUDES" != x; then
 | 
			
		||||
        MKDEP_OPTIONS="$MKDEP_OPTIONS -I$GCC_INCLUDES"
 | 
			
		||||
    fi
 | 
			
		||||
fi
 | 
			
		||||
AC_SUBST([MKDEP_OPTIONS])
 | 
			
		||||
 | 
			
		||||
dnl Make sure the pkg-config macros are defined
 | 
			
		||||
m4_ifndef([PKG_PROG_PKG_CONFIG],
 | 
			
		||||
    [m4_fatal([Could not locate the pkg-config autoconf macros.
 | 
			
		||||
  These are usually located in /usr/share/aclocal/pkg.m4. If your macros
 | 
			
		||||
  are in a different location, try setting the environment variable
 | 
			
		||||
  ACLOCAL="aclocal -I/other/macro/dir" before running autoreconf.])])
 | 
			
		||||
m4_ifdef([PKG_PROG_PKG_CONFIG],[],[
 | 
			
		||||
    m4_errprint([Error: Could not locate the pkg-config autoconf macros.
 | 
			
		||||
       These are usually located in /usr/share/aclocal/pkg.m4. If your
 | 
			
		||||
       macros are in a different location, try setting the environment
 | 
			
		||||
       variable ACLOCAL="aclocal -I/other/macro/dir" before running
 | 
			
		||||
       autoreconf.
 | 
			
		||||
])
 | 
			
		||||
    m4_exit([1])
 | 
			
		||||
])
 | 
			
		||||
PKG_PROG_PKG_CONFIG()
 | 
			
		||||
 | 
			
		||||
dnl LIB_DIR - library basename
 | 
			
		||||
@@ -79,8 +82,11 @@ dnl Compiler macros
 | 
			
		||||
DEFINES=""
 | 
			
		||||
AC_SUBST([DEFINES])
 | 
			
		||||
case "$host_os" in
 | 
			
		||||
linux*|*-gnu*|gnu*)
 | 
			
		||||
    DEFINES="$DEFINES -D_GNU_SOURCE -DPTHREADS"
 | 
			
		||||
linux*)
 | 
			
		||||
if test "x$GCC" = xyes; then
 | 
			
		||||
    DEFINES="$DEFINES -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_BSD_SOURCE"
 | 
			
		||||
fi
 | 
			
		||||
    DEFINES="$DEFINES -D_SVID_SOURCE -D_GNU_SOURCE -DPTHREADS"
 | 
			
		||||
    ;;
 | 
			
		||||
solaris*)
 | 
			
		||||
    DEFINES="$DEFINES -DPTHREADS -DSVR4"
 | 
			
		||||
@@ -217,40 +223,24 @@ dnl
 | 
			
		||||
dnl library names
 | 
			
		||||
dnl
 | 
			
		||||
if test "$enable_static" = yes; then
 | 
			
		||||
    LIB_EXTENSION='a'
 | 
			
		||||
    GL_LIB_NAME='lib$(GL_LIB).a'
 | 
			
		||||
    GLU_LIB_NAME='lib$(GLU_LIB).a'
 | 
			
		||||
    GLUT_LIB_NAME='lib$(GLUT_LIB).a'
 | 
			
		||||
    GLW_LIB_NAME='lib$(GLW_LIB).a'
 | 
			
		||||
    OSMESA_LIB_NAME='lib$(OSMESA_LIB).a'
 | 
			
		||||
else
 | 
			
		||||
    case "$host_os" in
 | 
			
		||||
    darwin* )
 | 
			
		||||
        LIB_EXTENSION='dylib' ;;
 | 
			
		||||
    * )
 | 
			
		||||
        LIB_EXTENSION='so' ;;
 | 
			
		||||
    esac
 | 
			
		||||
    GL_LIB_NAME='lib$(GL_LIB).so'
 | 
			
		||||
    GLU_LIB_NAME='lib$(GLU_LIB).so'
 | 
			
		||||
    GLUT_LIB_NAME='lib$(GLUT_LIB).so'
 | 
			
		||||
    GLW_LIB_NAME='lib$(GLW_LIB).so'
 | 
			
		||||
    OSMESA_LIB_NAME='lib$(OSMESA_LIB).so'
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
GL_LIB_NAME='lib$(GL_LIB).'${LIB_EXTENSION}
 | 
			
		||||
GLU_LIB_NAME='lib$(GLU_LIB).'${LIB_EXTENSION}
 | 
			
		||||
GLUT_LIB_NAME='lib$(GLUT_LIB).'${LIB_EXTENSION}
 | 
			
		||||
GLW_LIB_NAME='lib$(GLW_LIB).'${LIB_EXTENSION}
 | 
			
		||||
OSMESA_LIB_NAME='lib$(OSMESA_LIB).'${LIB_EXTENSION}
 | 
			
		||||
 | 
			
		||||
GL_LIB_GLOB='lib$(GL_LIB).*'${LIB_EXTENSION}'*'
 | 
			
		||||
GLU_LIB_GLOB='lib$(GLU_LIB).*'${LIB_EXTENSION}'*'
 | 
			
		||||
GLUT_LIB_GLOB='lib$(GLUT_LIB).*'${LIB_EXTENSION}'*'
 | 
			
		||||
GLW_LIB_GLOB='lib$(GLW_LIB).*'${LIB_EXTENSION}'*'
 | 
			
		||||
OSMESA_LIB_GLOB='lib$(OSMESA_LIB).*'${LIB_EXTENSION}'*'
 | 
			
		||||
 | 
			
		||||
AC_SUBST([GL_LIB_NAME])
 | 
			
		||||
AC_SUBST([GLU_LIB_NAME])
 | 
			
		||||
AC_SUBST([GLUT_LIB_NAME])
 | 
			
		||||
AC_SUBST([GLW_LIB_NAME])
 | 
			
		||||
AC_SUBST([OSMESA_LIB_NAME])
 | 
			
		||||
 | 
			
		||||
AC_SUBST([GL_LIB_GLOB])
 | 
			
		||||
AC_SUBST([GLU_LIB_GLOB])
 | 
			
		||||
AC_SUBST([GLUT_LIB_GLOB])
 | 
			
		||||
AC_SUBST([GLW_LIB_GLOB])
 | 
			
		||||
AC_SUBST([OSMESA_LIB_GLOB])
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl Arch/platform-specific settings
 | 
			
		||||
dnl
 | 
			
		||||
@@ -262,8 +252,8 @@ AC_ARG_ENABLE([asm],
 | 
			
		||||
)
 | 
			
		||||
asm_arch=""
 | 
			
		||||
ASM_FLAGS=""
 | 
			
		||||
MESA_ASM_SOURCES=""
 | 
			
		||||
GLAPI_ASM_SOURCES=""
 | 
			
		||||
ASM_SOURCES=""
 | 
			
		||||
ASM_API=""
 | 
			
		||||
AC_MSG_CHECKING([whether to enable assembly])
 | 
			
		||||
test "x$enable_asm" = xno && AC_MSG_RESULT([no])
 | 
			
		||||
# disable if cross compiling on x86/x86_64 since we must run gen_matypes
 | 
			
		||||
@@ -280,14 +270,14 @@ if test "x$enable_asm" = xyes; then
 | 
			
		||||
    case "$host_cpu" in
 | 
			
		||||
    i?86)
 | 
			
		||||
        case "$host_os" in
 | 
			
		||||
        linux* | *freebsd* | dragonfly*)
 | 
			
		||||
        linux* | freebsd* | dragonfly*)
 | 
			
		||||
            test "x$enable_64bit" = xyes && asm_arch=x86_64 || asm_arch=x86
 | 
			
		||||
            ;;
 | 
			
		||||
        esac
 | 
			
		||||
        ;;
 | 
			
		||||
    x86_64)
 | 
			
		||||
        case "$host_os" in
 | 
			
		||||
        linux* | *freebsd* | dragonfly*)
 | 
			
		||||
        linux* | freebsd* | dragonfly*)
 | 
			
		||||
            test "x$enable_32bit" = xyes && asm_arch=x86 || asm_arch=x86_64
 | 
			
		||||
            ;;
 | 
			
		||||
        esac
 | 
			
		||||
@@ -299,47 +289,34 @@ if test "x$enable_asm" = xyes; then
 | 
			
		||||
            ;;
 | 
			
		||||
        esac
 | 
			
		||||
        ;;
 | 
			
		||||
    sparc*)
 | 
			
		||||
        case "$host_os" in
 | 
			
		||||
        linux*)
 | 
			
		||||
            asm_arch=sparc
 | 
			
		||||
            ;;
 | 
			
		||||
        esac
 | 
			
		||||
        ;;
 | 
			
		||||
    esac
 | 
			
		||||
 | 
			
		||||
    case "$asm_arch" in
 | 
			
		||||
    x86)
 | 
			
		||||
        ASM_FLAGS="-DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM"
 | 
			
		||||
        MESA_ASM_SOURCES='$(X86_SOURCES)'
 | 
			
		||||
        GLAPI_ASM_SOURCES='$(X86_API)'
 | 
			
		||||
        ASM_SOURCES='$(X86_SOURCES)'
 | 
			
		||||
        ASM_API='$(X86_API)'
 | 
			
		||||
        AC_MSG_RESULT([yes, x86])
 | 
			
		||||
        ;;
 | 
			
		||||
    x86_64)
 | 
			
		||||
        ASM_FLAGS="-DUSE_X86_64_ASM"
 | 
			
		||||
        MESA_ASM_SOURCES='$(X86-64_SOURCES)'
 | 
			
		||||
        GLAPI_ASM_SOURCES='$(X86-64_API)'
 | 
			
		||||
        ASM_SOURCES='$(X86-64_SOURCES)'
 | 
			
		||||
        ASM_API='$(X86-64_API)'
 | 
			
		||||
        AC_MSG_RESULT([yes, x86_64])
 | 
			
		||||
        ;;
 | 
			
		||||
    ppc)
 | 
			
		||||
        ASM_FLAGS="-DUSE_PPC_ASM -DUSE_VMX_ASM"
 | 
			
		||||
        MESA_ASM_SOURCES='$(PPC_SOURCES)'
 | 
			
		||||
        ASM_SOURCES='$(PPC_SOURCES)'
 | 
			
		||||
        AC_MSG_RESULT([yes, ppc])
 | 
			
		||||
        ;;
 | 
			
		||||
    sparc)
 | 
			
		||||
        ASM_FLAGS="-DUSE_SPARC_ASM"
 | 
			
		||||
        MESA_ASM_SOURCES='$(SPARC_SOURCES)'
 | 
			
		||||
        GLAPI_ASM_SOURCES='$(SPARC_API)'
 | 
			
		||||
        AC_MSG_RESULT([yes, sparc])
 | 
			
		||||
        ;;
 | 
			
		||||
    *)
 | 
			
		||||
        AC_MSG_RESULT([no, platform not supported])
 | 
			
		||||
        ;;
 | 
			
		||||
    esac
 | 
			
		||||
fi
 | 
			
		||||
AC_SUBST([ASM_FLAGS])
 | 
			
		||||
AC_SUBST([MESA_ASM_SOURCES])
 | 
			
		||||
AC_SUBST([GLAPI_ASM_SOURCES])
 | 
			
		||||
AC_SUBST([ASM_SOURCES])
 | 
			
		||||
AC_SUBST([ASM_API])
 | 
			
		||||
 | 
			
		||||
dnl PIC code macro
 | 
			
		||||
MESA_PIC_FLAGS
 | 
			
		||||
@@ -367,6 +344,17 @@ if test "x$enable_selinux" = "xyes"; then
 | 
			
		||||
    DEFINES="$DEFINES -DMESA_SELINUX"
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
dnl OS-specific libraries
 | 
			
		||||
OS_LIBS=""
 | 
			
		||||
case "$host_os" in
 | 
			
		||||
solaris*)
 | 
			
		||||
    OS_LIBS="-lc"
 | 
			
		||||
    if test "x$GXX" != xyes; then
 | 
			
		||||
        OS_CPLUSPLUS_LIBS="-lCrun $OS_LIBS"
 | 
			
		||||
    fi
 | 
			
		||||
    ;;
 | 
			
		||||
esac
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl Driver configuration. Options are xlib, dri and osmesa right now.
 | 
			
		||||
dnl More later: directfb, fbdev, ...
 | 
			
		||||
@@ -376,12 +364,12 @@ default_driver="xlib"
 | 
			
		||||
case "$host_os" in
 | 
			
		||||
linux*)
 | 
			
		||||
    case "$host_cpu" in
 | 
			
		||||
    i*86|x86_64|powerpc*|sparc*) default_driver="dri";;
 | 
			
		||||
    i*86|x86_64|powerpc*) default_driver="dri";;
 | 
			
		||||
    esac
 | 
			
		||||
    ;;
 | 
			
		||||
*freebsd* | dragonfly*)
 | 
			
		||||
freebsd* | dragonfly*)
 | 
			
		||||
    case "$host_cpu" in
 | 
			
		||||
    i*86|x86_64|powerpc*|sparc*) default_driver="dri";;
 | 
			
		||||
    i*86|x86_64) default_driver="dri";;
 | 
			
		||||
    esac
 | 
			
		||||
    ;;
 | 
			
		||||
esac
 | 
			
		||||
@@ -403,26 +391,17 @@ esac
 | 
			
		||||
dnl
 | 
			
		||||
dnl Driver specific build directories
 | 
			
		||||
dnl
 | 
			
		||||
SRC_DIRS="mesa glew"
 | 
			
		||||
SRC_DIRS="mesa"
 | 
			
		||||
GLU_DIRS="sgi"
 | 
			
		||||
WINDOW_SYSTEM=""
 | 
			
		||||
GALLIUM_DIRS="auxiliary drivers state_trackers"
 | 
			
		||||
GALLIUM_WINSYS_DIRS=""
 | 
			
		||||
GALLIUM_WINSYS_DRM_DIRS=""
 | 
			
		||||
GALLIUM_AUXILIARY_DIRS="draw translate cso_cache pipebuffer tgsi sct rtasm util indices"
 | 
			
		||||
GALLIUM_DRIVERS_DIRS="softpipe failover trace"
 | 
			
		||||
GALLIUM_STATE_TRACKERS_DIRS=""
 | 
			
		||||
 | 
			
		||||
case "$mesa_driver" in
 | 
			
		||||
xlib)
 | 
			
		||||
    DRIVER_DIRS="x11"
 | 
			
		||||
    GALLIUM_WINSYS_DIRS="$GALLIUM_WINSYS_DIRS xlib"
 | 
			
		||||
    ;;
 | 
			
		||||
dri)
 | 
			
		||||
    SRC_DIRS="glx/x11 $SRC_DIRS"
 | 
			
		||||
    DRIVER_DIRS="dri"
 | 
			
		||||
    WINDOW_SYSTEM="dri"
 | 
			
		||||
    GALLIUM_WINSYS_DIRS="$GALLIUM_WINSYS_DIRS drm"
 | 
			
		||||
    ;;
 | 
			
		||||
osmesa)
 | 
			
		||||
    DRIVER_DIRS="osmesa"
 | 
			
		||||
@@ -432,12 +411,6 @@ AC_SUBST([SRC_DIRS])
 | 
			
		||||
AC_SUBST([GLU_DIRS])
 | 
			
		||||
AC_SUBST([DRIVER_DIRS])
 | 
			
		||||
AC_SUBST([WINDOW_SYSTEM])
 | 
			
		||||
AC_SUBST([GALLIUM_DIRS])
 | 
			
		||||
AC_SUBST([GALLIUM_WINSYS_DIRS])
 | 
			
		||||
AC_SUBST([GALLIUM_WINSYS_DRM_DIRS])
 | 
			
		||||
AC_SUBST([GALLIUM_DRIVERS_DIRS])
 | 
			
		||||
AC_SUBST([GALLIUM_AUXILIARY_DIRS])
 | 
			
		||||
AC_SUBST([GALLIUM_STATE_TRACKERS_DIRS])
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl User supplied program configuration
 | 
			
		||||
@@ -533,18 +506,14 @@ case "$mesa_driver" in
 | 
			
		||||
xlib)
 | 
			
		||||
    if test "$x11_pkgconfig" = yes; then
 | 
			
		||||
        PKG_CHECK_MODULES([XLIBGL], [x11 xext])
 | 
			
		||||
        GL_PC_REQ_PRIV="x11 xext"
 | 
			
		||||
        X11_INCLUDES="$X11_INCLUDES $XLIBGL_CFLAGS"
 | 
			
		||||
        GL_LIB_DEPS="$XLIBGL_LIBS"
 | 
			
		||||
    else
 | 
			
		||||
        # should check these...
 | 
			
		||||
        X11_INCLUDES="$X11_INCLUDES $X_CFLAGS"
 | 
			
		||||
        GL_LIB_DEPS="$X_LIBS -lX11 -lXext"
 | 
			
		||||
        GL_PC_LIB_PRIV="$GL_LIB_DEPS"
 | 
			
		||||
        GL_PC_CFLAGS="$X11_INCLUDES"
 | 
			
		||||
    fi
 | 
			
		||||
    GL_LIB_DEPS="$GL_LIB_DEPS $SELINUX_LIBS -lm -lpthread"
 | 
			
		||||
    GL_PC_LIB_PRIV="$GL_PC_LIB_PRIV $SELINUX_LIBS -lm -lpthread"
 | 
			
		||||
    GL_LIB_DEPS="$GL_LIB_DEPS $SELINUX_LIBS -lm -lpthread $OS_LIBS"
 | 
			
		||||
 | 
			
		||||
    # if static, move the external libraries to the programs
 | 
			
		||||
    # and empty the libraries for libGL
 | 
			
		||||
@@ -561,9 +530,6 @@ dri)
 | 
			
		||||
 | 
			
		||||
    # Check for libdrm
 | 
			
		||||
    PKG_CHECK_MODULES([LIBDRM], [libdrm >= $LIBDRM_REQUIRED])
 | 
			
		||||
    PKG_CHECK_MODULES([DRI2PROTO], [dri2proto >= $DRI2PROTO_REQUIRED])
 | 
			
		||||
    GL_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED dri2proto >= $DRI2PROTO_REQUIRED"
 | 
			
		||||
    DRI_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED"
 | 
			
		||||
 | 
			
		||||
    # find the DRI deps for libGL
 | 
			
		||||
    if test "$x11_pkgconfig" = yes; then
 | 
			
		||||
@@ -574,39 +540,30 @@ dri)
 | 
			
		||||
        fi
 | 
			
		||||
 | 
			
		||||
        PKG_CHECK_MODULES([DRIGL], [$dri_modules])
 | 
			
		||||
        GL_PC_REQ_PRIV="$GL_PC_REQ_PRIV $dri_modules"
 | 
			
		||||
        X11_INCLUDES="$X11_INCLUDES $DRIGL_CFLAGS"
 | 
			
		||||
        GL_LIB_DEPS="$DRIGL_LIBS"
 | 
			
		||||
    else
 | 
			
		||||
        # should check these...
 | 
			
		||||
        X11_INCLUDES="$X11_INCLUDES $X_CFLAGS"
 | 
			
		||||
        GL_LIB_DEPS="$X_LIBS -lX11 -lXext -lXxf86vm -lXdamage -lXfixes"
 | 
			
		||||
        GL_PC_LIB_PRIV="$GL_LIB_DEPS"
 | 
			
		||||
        GL_PC_CFLAGS="$X11_INCLUDES"
 | 
			
		||||
 | 
			
		||||
        # XCB can only be used from pkg-config
 | 
			
		||||
        if test "$enable_xcb" = yes; then
 | 
			
		||||
            PKG_CHECK_MODULES([XCB],[x11-xcb xcb-glx])
 | 
			
		||||
            GL_PC_REQ_PRIV="$GL_PC_REQ_PRIV x11-xcb xcb-glx"
 | 
			
		||||
            X11_INCLUDES="$X11_INCLUDES $XCB_CFLAGS"
 | 
			
		||||
            GL_LIB_DEPS="$GL_LIB_DEPS $XCB_LIBS"
 | 
			
		||||
        fi
 | 
			
		||||
    fi
 | 
			
		||||
 | 
			
		||||
    # need DRM libs, -lpthread, etc.
 | 
			
		||||
    GL_LIB_DEPS="$GL_LIB_DEPS $LIBDRM_LIBS -lm -lpthread $DLOPEN_LIBS"
 | 
			
		||||
    GL_PC_LIB_PRIV="-lm -lpthread $DLOPEN_LIBS"
 | 
			
		||||
    GL_LIB_DEPS="$GL_LIB_DEPS $LIBDRM_LIBS -lm -lpthread $DLOPEN_LIBS $OS_LIBS"
 | 
			
		||||
    ;;
 | 
			
		||||
osmesa)
 | 
			
		||||
    # No libGL for osmesa
 | 
			
		||||
    GL_LIB_DEPS=""
 | 
			
		||||
    GL_LIB_DEPS="$OS_LIBS"
 | 
			
		||||
    ;;
 | 
			
		||||
esac
 | 
			
		||||
AC_SUBST([GL_LIB_DEPS])
 | 
			
		||||
AC_SUBST([GL_PC_REQ_PRIV])
 | 
			
		||||
AC_SUBST([GL_PC_LIB_PRIV])
 | 
			
		||||
AC_SUBST([GL_PC_CFLAGS])
 | 
			
		||||
AC_SUBST([DRI_PC_REQ_PRIV])
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl More X11 setup
 | 
			
		||||
@@ -636,6 +593,20 @@ AC_ARG_ENABLE([driglx-direct],
 | 
			
		||||
        [enable direct rendering in GLX for DRI @<:@default=enabled@:>@])],
 | 
			
		||||
    [driglx_direct="$enableval"],
 | 
			
		||||
    [driglx_direct="yes"])
 | 
			
		||||
dnl ttm support
 | 
			
		||||
AC_ARG_ENABLE([ttm-api],
 | 
			
		||||
    [AS_HELP_STRING([--enable-ttm-api],
 | 
			
		||||
        [enable TTM API users @<:@default=disabled@:>@])],
 | 
			
		||||
    [ttmapi="$enableval"],
 | 
			
		||||
    [ttmapi="no"])
 | 
			
		||||
 | 
			
		||||
if test "x$ttmapi" = "xyes"; then
 | 
			
		||||
    save_CFLAGS=$CFLAGS
 | 
			
		||||
    CFLAGS=$LIBDRM_CFLAGS
 | 
			
		||||
    AC_CHECK_HEADERS([xf86mm.h],[],[AC_MSG_ERROR([xf86mm.h required for TTM.])],[#include "stdint.h"\n#include "drm.h"])
 | 
			
		||||
    CFLAGS=$save_CFLAGS
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
dnl Which drivers to build - default is chosen by platform
 | 
			
		||||
AC_ARG_WITH([dri-drivers],
 | 
			
		||||
    [AS_HELP_STRING([--with-dri-drivers@<:@=DIRS...@:>@],
 | 
			
		||||
@@ -677,6 +648,10 @@ if test "$mesa_driver" = dri; then
 | 
			
		||||
        DEFINES="$DEFINES -DGLX_USE_TLS -DPTHREADS"
 | 
			
		||||
    fi
 | 
			
		||||
 | 
			
		||||
    if test "x$ttmapi" = xyes; then
 | 
			
		||||
        DEFINES="$DEFINES -DTTM_API"
 | 
			
		||||
    fi
 | 
			
		||||
 | 
			
		||||
    if test "x$USING_EGL" = x1; then
 | 
			
		||||
        PROGRAM_DIRS="egl"
 | 
			
		||||
    fi
 | 
			
		||||
@@ -685,10 +660,10 @@ if test "$mesa_driver" = dri; then
 | 
			
		||||
    case "$host_os" in
 | 
			
		||||
    linux*)
 | 
			
		||||
        DEFINES="$DEFINES -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER"
 | 
			
		||||
        DEFINES="$DEFINES -DGLX_INDIRECT_RENDERING -DHAVE_ALIAS"
 | 
			
		||||
        if test "x$driglx_direct" = xyes; then
 | 
			
		||||
            DEFINES="$DEFINES -DGLX_DIRECT_RENDERING"
 | 
			
		||||
        fi
 | 
			
		||||
        DEFINES="$DEFINES -DGLX_INDIRECT_RENDERING -DHAVE_ALIAS"
 | 
			
		||||
 | 
			
		||||
        case "$host_cpu" in
 | 
			
		||||
        x86_64)
 | 
			
		||||
@@ -734,10 +709,6 @@ if test "$mesa_driver" = dri; then
 | 
			
		||||
                unichrome savage sis swrast"
 | 
			
		||||
        fi
 | 
			
		||||
        ;;
 | 
			
		||||
    gnu*)
 | 
			
		||||
        DEFINES="$DEFINES -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER"
 | 
			
		||||
        DEFINES="$DEFINES -DGLX_INDIRECT_RENDERING -DHAVE_ALIAS"
 | 
			
		||||
	;;
 | 
			
		||||
    solaris*)
 | 
			
		||||
        DEFINES="$DEFINES -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER"
 | 
			
		||||
        DEFINES="$DEFINES -DGLX_INDIRECT_RENDERING"
 | 
			
		||||
@@ -826,12 +797,11 @@ case "$mesa_driver" in
 | 
			
		||||
osmesa)
 | 
			
		||||
    # only link libraries with osmesa if shared
 | 
			
		||||
    if test "$enable_static" = no; then
 | 
			
		||||
        OSMESA_LIB_DEPS="-lm -lpthread $SELINUX_LIBS $DLOPEN_LIBS"
 | 
			
		||||
        OSMESA_LIB_DEPS="-lm -lpthread $SELINUX_LIBS"
 | 
			
		||||
    else
 | 
			
		||||
        OSMESA_LIB_DEPS=""
 | 
			
		||||
    fi
 | 
			
		||||
    OSMESA_MESA_DEPS=""
 | 
			
		||||
    OSMESA_PC_LIB_PRIV="-lm -lpthread $SELINUX_LIBS $DLOPEN_LIBS"
 | 
			
		||||
    ;;
 | 
			
		||||
*)
 | 
			
		||||
    # Link OSMesa to libGL otherwise
 | 
			
		||||
@@ -842,36 +812,13 @@ osmesa)
 | 
			
		||||
    else
 | 
			
		||||
        OSMESA_MESA_DEPS=""
 | 
			
		||||
    fi
 | 
			
		||||
    OSMESA_PC_REQ="gl"
 | 
			
		||||
    ;;
 | 
			
		||||
esac
 | 
			
		||||
OSMESA_PC_LIB_PRIV="$OSMESA_PC_LIB_PRIV"
 | 
			
		||||
if test "$enable_static" = no; then
 | 
			
		||||
    OSMESA_LIB_DEPS="$OSMESA_LIB_DEPS $OS_LIBS"
 | 
			
		||||
fi
 | 
			
		||||
AC_SUBST([OSMESA_LIB_DEPS])
 | 
			
		||||
AC_SUBST([OSMESA_MESA_DEPS])
 | 
			
		||||
AC_SUBST([OSMESA_PC_REQ])
 | 
			
		||||
AC_SUBST([OSMESA_PC_LIB_PRIV])
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl EGL configuration
 | 
			
		||||
dnl
 | 
			
		||||
AC_ARG_ENABLE([egl],
 | 
			
		||||
    [AS_HELP_STRING([--disable-egl],
 | 
			
		||||
        [disable EGL library @<:@default=enabled@:>@])],
 | 
			
		||||
    [enable_egl="$enableval"],
 | 
			
		||||
    [enable_egl=yes])
 | 
			
		||||
if test "x$enable_egl" = xyes; then
 | 
			
		||||
    SRC_DIRS="$SRC_DIRS egl"
 | 
			
		||||
 | 
			
		||||
    if test "$x11_pkgconfig" = yes; then
 | 
			
		||||
        PKG_CHECK_MODULES([EGL], [x11])
 | 
			
		||||
        EGL_LIB_DEPS="$EGL_LIBS"
 | 
			
		||||
    else
 | 
			
		||||
        # should check these...
 | 
			
		||||
        EGL_LIB_DEPS="$X_LIBS -lX11"
 | 
			
		||||
    fi
 | 
			
		||||
    EGL_LIB_DEPS="$EGL_LIB_DEPS $DLOPEN_LIBS"
 | 
			
		||||
fi
 | 
			
		||||
AC_SUBST([EGL_LIB_DEPS])
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl GLU configuration
 | 
			
		||||
@@ -894,7 +841,6 @@ if test "x$enable_glu" = xyes; then
 | 
			
		||||
 | 
			
		||||
        # Link libGLU to libOSMesa instead of libGL
 | 
			
		||||
        GLU_LIB_DEPS=""
 | 
			
		||||
        GLU_PC_REQ="osmesa"
 | 
			
		||||
        if test "$enable_static" = no; then
 | 
			
		||||
            GLU_MESA_DEPS='-l$(OSMESA_LIB)'
 | 
			
		||||
        else
 | 
			
		||||
@@ -903,8 +849,6 @@ if test "x$enable_glu" = xyes; then
 | 
			
		||||
        ;;
 | 
			
		||||
    *)
 | 
			
		||||
        # If static, empty GLU_LIB_DEPS and add libs for programs to link
 | 
			
		||||
        GLU_PC_REQ="gl"
 | 
			
		||||
        GLU_PC_LIB_PRIV="-lm"
 | 
			
		||||
        if test "$enable_static" = no; then
 | 
			
		||||
            GLU_LIB_DEPS="-lm"
 | 
			
		||||
            GLU_MESA_DEPS='-l$(GL_LIB)'
 | 
			
		||||
@@ -919,13 +863,8 @@ fi
 | 
			
		||||
if test "$enable_static" = no; then
 | 
			
		||||
    GLU_LIB_DEPS="$GLU_LIB_DEPS $OS_CPLUSPLUS_LIBS"
 | 
			
		||||
fi
 | 
			
		||||
GLU_PC_LIB_PRIV="$GLU_PC_LIB_PRIV $OS_CPLUSPLUS_LIBS"
 | 
			
		||||
AC_SUBST([GLU_LIB_DEPS])
 | 
			
		||||
AC_SUBST([GLU_MESA_DEPS])
 | 
			
		||||
AC_SUBST([GLU_PC_REQ])
 | 
			
		||||
AC_SUBST([GLU_PC_REQ_PRIV])
 | 
			
		||||
AC_SUBST([GLU_PC_LIB_PRIV])
 | 
			
		||||
AC_SUBST([GLU_PC_CFLAGS])
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl GLw configuration
 | 
			
		||||
@@ -950,13 +889,10 @@ if test "x$enable_glw" = xyes; then
 | 
			
		||||
    SRC_DIRS="$SRC_DIRS glw"
 | 
			
		||||
    if test "$x11_pkgconfig" = yes; then
 | 
			
		||||
        PKG_CHECK_MODULES([GLW],[x11 xt])
 | 
			
		||||
        GLW_PC_REQ_PRIV="x11 xt"
 | 
			
		||||
        GLW_LIB_DEPS="$GLW_LIBS"
 | 
			
		||||
    else
 | 
			
		||||
        # should check these...
 | 
			
		||||
        GLW_LIB_DEPS="$X_LIBS -lXt -lX11"
 | 
			
		||||
        GLW_PC_LIB_PRIV="$GLW_LIB_DEPS"
 | 
			
		||||
        GLW_PC_CFLAGS="$X11_INCLUDES"
 | 
			
		||||
    fi
 | 
			
		||||
 | 
			
		||||
    GLW_SOURCES="GLwDrawA.c"
 | 
			
		||||
@@ -975,15 +911,12 @@ if test "x$enable_glw" = xyes; then
 | 
			
		||||
        fi
 | 
			
		||||
        # MOTIF_LIBS is prepended to GLW_LIB_DEPS since Xm needs Xt/X11
 | 
			
		||||
        GLW_LIB_DEPS="$MOTIF_LIBS $GLW_LIB_DEPS"
 | 
			
		||||
        GLW_PC_LIB_PRIV="$MOTIF_LIBS $GLW_PC_LIB_PRIV"
 | 
			
		||||
        GLW_PC_CFLAGS="$MOTIF_CFLAGS $GLW_PC_CFLAGS"
 | 
			
		||||
    fi
 | 
			
		||||
 | 
			
		||||
    # If static, empty GLW_LIB_DEPS and add libs for programs to link
 | 
			
		||||
    GLW_PC_LIB_PRIV="$GLW_PC_LIB_PRIV"
 | 
			
		||||
    if test "$enable_static" = no; then
 | 
			
		||||
        GLW_MESA_DEPS='-l$(GL_LIB)'
 | 
			
		||||
        GLW_LIB_DEPS="$GLW_LIB_DEPS"
 | 
			
		||||
        GLW_LIB_DEPS="$GLW_LIB_DEPS $OS_LIBS"
 | 
			
		||||
    else
 | 
			
		||||
        APP_LIB_DEPS="$APP_LIB_DEPS $GLW_LIB_DEPS"
 | 
			
		||||
        GLW_LIB_DEPS=""
 | 
			
		||||
@@ -994,9 +927,6 @@ AC_SUBST([GLW_LIB_DEPS])
 | 
			
		||||
AC_SUBST([GLW_MESA_DEPS])
 | 
			
		||||
AC_SUBST([GLW_SOURCES])
 | 
			
		||||
AC_SUBST([MOTIF_CFLAGS])
 | 
			
		||||
AC_SUBST([GLW_PC_REQ_PRIV])
 | 
			
		||||
AC_SUBST([GLW_PC_LIB_PRIV])
 | 
			
		||||
AC_SUBST([GLW_PC_CFLAGS])
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl GLUT configuration
 | 
			
		||||
@@ -1031,16 +961,12 @@ if test "x$enable_glut" = xyes; then
 | 
			
		||||
    fi
 | 
			
		||||
    if test "$x11_pkgconfig" = yes; then
 | 
			
		||||
        PKG_CHECK_MODULES([GLUT],[x11 xmu xi])
 | 
			
		||||
        GLUT_PC_REQ_PRIV="x11 xmu xi"
 | 
			
		||||
        GLUT_LIB_DEPS="$GLUT_LIBS"
 | 
			
		||||
    else
 | 
			
		||||
        # should check these...
 | 
			
		||||
        GLUT_LIB_DEPS="$X_LIBS -lX11 -lXmu -lXi"
 | 
			
		||||
        GLUT_PC_LIB_PRIV="$GLUT_LIB_DEPS"
 | 
			
		||||
        GLUT_PC_CFLAGS="$X11_INCLUDES"
 | 
			
		||||
    fi
 | 
			
		||||
    GLUT_LIB_DEPS="$GLUT_LIB_DEPS -lm"
 | 
			
		||||
    GLUT_PC_LIB_PRIV="$GLUT_PC_LIB_PRIV -lm"
 | 
			
		||||
    GLUT_LIB_DEPS="$GLUT_LIB_DEPS -lm $OS_LIBS"
 | 
			
		||||
 | 
			
		||||
    # If glut is available, we can build most programs
 | 
			
		||||
    if test "$with_demos" = yes; then
 | 
			
		||||
@@ -1059,9 +985,6 @@ fi
 | 
			
		||||
AC_SUBST([GLUT_LIB_DEPS])
 | 
			
		||||
AC_SUBST([GLUT_MESA_DEPS])
 | 
			
		||||
AC_SUBST([GLUT_CFLAGS])
 | 
			
		||||
AC_SUBST([GLUT_PC_REQ_PRIV])
 | 
			
		||||
AC_SUBST([GLUT_PC_LIB_PRIV])
 | 
			
		||||
AC_SUBST([GLUT_PC_CFLAGS])
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl Program library dependencies
 | 
			
		||||
@@ -1081,104 +1004,6 @@ fi
 | 
			
		||||
AC_SUBST([APP_LIB_DEPS])
 | 
			
		||||
AC_SUBST([PROGRAM_DIRS])
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl Gallium configuration
 | 
			
		||||
dnl
 | 
			
		||||
AC_ARG_ENABLE([gallium],
 | 
			
		||||
    [AS_HELP_STRING([--disable-gallium],
 | 
			
		||||
        [build gallium @<:@default=enabled@:>@])],
 | 
			
		||||
    [enable_gallium="$enableval"],
 | 
			
		||||
    [enable_gallium=yes])
 | 
			
		||||
if test "x$enable_gallium" = xyes; then
 | 
			
		||||
    SRC_DIRS="$SRC_DIRS gallium gallium/winsys"
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl Gallium state trackers configuration
 | 
			
		||||
dnl
 | 
			
		||||
AC_ARG_WITH([state-trackers],
 | 
			
		||||
    [AS_HELP_STRING([--with-state-trackers@<:@=DIRS...@:>@],
 | 
			
		||||
        [comma delimited state_trackers list, e.g.
 | 
			
		||||
        "egl,glx" @<:@default=auto@:>@])],
 | 
			
		||||
    [with_state_trackers="$withval"],
 | 
			
		||||
    [with_state_trackers=yes])
 | 
			
		||||
 | 
			
		||||
case "$with_state_trackers" in
 | 
			
		||||
no)
 | 
			
		||||
    GALLIUM_STATE_TRACKERS_DIRS=""
 | 
			
		||||
    ;;
 | 
			
		||||
yes)
 | 
			
		||||
    # look at what else is built
 | 
			
		||||
    case "$mesa_driver" in
 | 
			
		||||
    xlib)
 | 
			
		||||
        GALLIUM_STATE_TRACKERS_DIRS=glx
 | 
			
		||||
        ;;
 | 
			
		||||
    dri)
 | 
			
		||||
        test "x$enable_egl" = xyes && GALLIUM_STATE_TRACKERS_DIRS=egl
 | 
			
		||||
        ;;
 | 
			
		||||
    esac
 | 
			
		||||
    ;;
 | 
			
		||||
*)
 | 
			
		||||
    # verify the requested state tracker exist
 | 
			
		||||
    state_trackers=`IFS=', '; echo $with_state_trackers`
 | 
			
		||||
    for tracker in $state_trackers; do
 | 
			
		||||
        test -d "$srcdir/src/gallium/state_trackers/$tracker" || \
 | 
			
		||||
            AC_MSG_ERROR([state tracker '$tracker' doesn't exist])
 | 
			
		||||
 | 
			
		||||
        if test "$tracker" = egl && test "x$enable_egl" != xyes; then
 | 
			
		||||
            AC_MSG_ERROR([cannot build egl state tracker without EGL library])
 | 
			
		||||
        fi
 | 
			
		||||
    done
 | 
			
		||||
    GALLIUM_STATE_TRACKERS_DIRS="$state_trackers"
 | 
			
		||||
    ;;
 | 
			
		||||
esac
 | 
			
		||||
 | 
			
		||||
AC_ARG_WITH([xorg-driver-dir],
 | 
			
		||||
    [AS_HELP_STRING([--with-xorg-driver-dir=DIR],
 | 
			
		||||
                    [Default xorg driver directory[[default=${libdir}/xorg/modules/drivers]]])],
 | 
			
		||||
    [XORG_DRIVER_INSTALL_DIR="$withval"],
 | 
			
		||||
    [XORG_DRIVER_INSTALL_DIR="${libdir}/xorg/modules/drivers"])
 | 
			
		||||
AC_SUBST([XORG_DRIVER_INSTALL_DIR])
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl Gallium Intel configuration
 | 
			
		||||
dnl
 | 
			
		||||
AC_ARG_ENABLE([gallium-intel],
 | 
			
		||||
    [AS_HELP_STRING([--disable-gallium-intel],
 | 
			
		||||
        [build gallium intel @<:@default=enabled@:>@])],
 | 
			
		||||
    [enable_gallium_intel="$enableval"],
 | 
			
		||||
    [enable_gallium_intel=yes])
 | 
			
		||||
if test "x$enable_gallium_intel" = xyes; then
 | 
			
		||||
    GALLIUM_WINSYS_DRM_DIRS="$GALLIUM_WINSYS_DRM_DIRS intel"
 | 
			
		||||
    GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS i915simple"
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl Gallium Radeon configuration
 | 
			
		||||
dnl
 | 
			
		||||
AC_ARG_ENABLE([gallium-radeon],
 | 
			
		||||
    [AS_HELP_STRING([--enable-gallium-radeon],
 | 
			
		||||
        [build gallium radeon @<:@default=disabled@:>@])],
 | 
			
		||||
    [enable_gallium_radeon="$enableval"],
 | 
			
		||||
    [enable_gallium_radeon=no])
 | 
			
		||||
if test "x$enable_gallium_radeon" = xyes; then
 | 
			
		||||
    GALLIUM_WINSYS_DRM_DIRS="$GALLIUM_WINSYS_DRM_DIRS radeon"
 | 
			
		||||
    GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS r300"
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
dnl
 | 
			
		||||
dnl Gallium Radeon configuration
 | 
			
		||||
dnl
 | 
			
		||||
AC_ARG_ENABLE([gallium-nouveau],
 | 
			
		||||
    [AS_HELP_STRING([--enable-gallium-nouveau],
 | 
			
		||||
        [build gallium nouveau @<:@default=disabled@:>@])],
 | 
			
		||||
    [enable_gallium_nouveau="$enableval"],
 | 
			
		||||
    [enable_gallium_nouveau=no])
 | 
			
		||||
if test "x$enable_gallium_nouveau" = xyes; then
 | 
			
		||||
    GALLIUM_WINSYS_DRM_DIRS="$GALLIUM_WINSYS_DRM_DIRS nouveau"
 | 
			
		||||
    GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS nv04 nv10 nv20 nv30 nv40 nv50"
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
dnl Restore LDFLAGS and CPPFLAGS
 | 
			
		||||
LDFLAGS="$_SAVE_LDFLAGS"
 | 
			
		||||
@@ -1223,27 +1048,13 @@ else
 | 
			
		||||
    echo "        DRI drivers:     $dri_dirs"
 | 
			
		||||
fi
 | 
			
		||||
    echo "        DRI driver dir:  $DRI_DRIVER_INSTALL_DIR"
 | 
			
		||||
fi
 | 
			
		||||
echo "        Use XCB:         $enable_xcb"
 | 
			
		||||
 | 
			
		||||
echo ""
 | 
			
		||||
if echo "$SRC_DIRS" | grep 'gallium' >/dev/null 2>&1; then
 | 
			
		||||
    echo "        Gallium:         yes"
 | 
			
		||||
    echo "        Gallium dirs:    $GALLIUM_DIRS"
 | 
			
		||||
    echo "        Winsys dirs:     $GALLIUM_WINSYS_DIRS"
 | 
			
		||||
    echo "        Winsys drm dirs:$GALLIUM_WINSYS_DRM_DIRS"
 | 
			
		||||
    echo "        Auxiliary dirs:  $GALLIUM_AUXILIARY_DIRS"
 | 
			
		||||
    echo "        Driver dirs:     $GALLIUM_DRIVERS_DIRS"
 | 
			
		||||
    echo "        Trackers dirs:   $GALLIUM_STATE_TRACKERS_DIRS"
 | 
			
		||||
else
 | 
			
		||||
    echo "        Gallium:         no"
 | 
			
		||||
    echo "        TTM API support: $ttmapi"
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
dnl Libraries
 | 
			
		||||
echo ""
 | 
			
		||||
echo "        Shared libs:     $enable_shared"
 | 
			
		||||
echo "        Static libs:     $enable_static"
 | 
			
		||||
echo "        EGL:             $enable_egl"
 | 
			
		||||
echo "        GLU:             $enable_glu"
 | 
			
		||||
echo "        GLw:             $enable_glw (Motif: $enable_motif)"
 | 
			
		||||
echo "        glut:            $enable_glut"
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										22
									
								
								descrip.mms
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										22
									
								
								descrip.mms
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,22 @@
 | 
			
		||||
# Makefile for Mesa for VMS
 | 
			
		||||
# contributed by Jouk Jansen  joukj@hrem.stm.tudelft.nl
 | 
			
		||||
 | 
			
		||||
macro : 
 | 
			
		||||
        @ macro=""
 | 
			
		||||
.ifdef NOSHARE
 | 
			
		||||
.else
 | 
			
		||||
	@ if f$getsyi("HW_MODEL") .ge. 1024 then macro= "/MACRO=(SHARE=1)"
 | 
			
		||||
.endif
 | 
			
		||||
	$(MMS)$(MMSQUALIFIERS)'macro' all
 | 
			
		||||
 | 
			
		||||
all :
 | 
			
		||||
	if f$search("lib.dir") .eqs. "" then create/directory [.lib]
 | 
			
		||||
	set default [.src]
 | 
			
		||||
	$(MMS)$(MMSQUALIFIERS)
 | 
			
		||||
	set default [-.progs.util]
 | 
			
		||||
	$(MMS)$(MMSQUALIFIERS)
 | 
			
		||||
	set default [-.demos]
 | 
			
		||||
	$(MMS)$(MMSQUALIFIERS)
 | 
			
		||||
	set default [-.xdemos]
 | 
			
		||||
	$(MMS)$(MMSQUALIFIERS)
 | 
			
		||||
	if f$search("[-]tests.DIR") .nes. "" then pipe set default [-.tests] ; $(MMS)$(MMSQUALIFIERS)
 | 
			
		||||
@@ -16,7 +16,7 @@ Status
 | 
			
		||||
 | 
			
		||||
Version
 | 
			
		||||
 | 
			
		||||
    Last Modified Date:  12 January 2009
 | 
			
		||||
    Last Modified Date:  8 June 2000
 | 
			
		||||
 | 
			
		||||
Number
 | 
			
		||||
 | 
			
		||||
@@ -69,12 +69,6 @@ Additions to Chapter 3 of the GLX 1.3 Specification (Functions and Errors)
 | 
			
		||||
    <width> and <height> indicate the size in pixels.  Coordinate (0,0)
 | 
			
		||||
    corresponds to the lower-left pixel of the window, like glReadPixels.
 | 
			
		||||
 | 
			
		||||
    If dpy and drawable are the display and drawable for the calling
 | 
			
		||||
    thread's current context, glXCopySubBufferMESA performs an
 | 
			
		||||
    implicit glFlush before it returns.  Subsequent OpenGL commands
 | 
			
		||||
    may be issued immediately after calling glXCopySubBufferMESA, but
 | 
			
		||||
    are not executed until the copy is completed. 
 | 
			
		||||
 | 
			
		||||
GLX Protocol
 | 
			
		||||
 | 
			
		||||
    None at this time.  The extension is implemented in terms of ordinary
 | 
			
		||||
@@ -90,7 +84,5 @@ New State
 | 
			
		||||
 | 
			
		||||
Revision History
 | 
			
		||||
 | 
			
		||||
    12 January 2009 Ian Romanick - Added language about implicit flush
 | 
			
		||||
                                   and command completion.
 | 
			
		||||
    8 June 2000     Brian Paul   - initial specification
 | 
			
		||||
    8 June 2000 - initial specification
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -16,6 +16,7 @@ Status
 | 
			
		||||
 | 
			
		||||
Version
 | 
			
		||||
 | 
			
		||||
    $Id: MESA_resize_buffers.spec,v 1.3 2004/03/25 01:42:42 brianp Exp $
 | 
			
		||||
 | 
			
		||||
Number
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -13,12 +13,13 @@ Contact
 | 
			
		||||
 | 
			
		||||
Status
 | 
			
		||||
 | 
			
		||||
    Obsolete.
 | 
			
		||||
    XXX - Not complete yet!!!
 | 
			
		||||
 | 
			
		||||
Version
 | 
			
		||||
 | 
			
		||||
    Last Modified Date: July 30, 2006
 | 
			
		||||
    Author Revision: 0.2
 | 
			
		||||
    $Date: 2006/07/30 14:28:38 $ $Revision: 1.2 $
 | 
			
		||||
 | 
			
		||||
Number
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -20,6 +20,7 @@ Status
 | 
			
		||||
 | 
			
		||||
Version
 | 
			
		||||
 | 
			
		||||
    $Date: 2007/05/16$ $Revision: 0.4$
 | 
			
		||||
 | 
			
		||||
Number
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -1,214 +0,0 @@
 | 
			
		||||
Name
 | 
			
		||||
 | 
			
		||||
    MESA_texture_signed_rgba
 | 
			
		||||
 | 
			
		||||
Name Strings
 | 
			
		||||
 | 
			
		||||
    GL_MESA_texture_signed_rgba
 | 
			
		||||
 | 
			
		||||
Contact
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
Notice
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
IP Status
 | 
			
		||||
 | 
			
		||||
    No known IP issues
 | 
			
		||||
 | 
			
		||||
Status
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
Version
 | 
			
		||||
 | 
			
		||||
    0.3, 2009-03-24
 | 
			
		||||
 | 
			
		||||
Number
 | 
			
		||||
 | 
			
		||||
    Not assigned ?
 | 
			
		||||
 | 
			
		||||
Dependencies
 | 
			
		||||
 | 
			
		||||
    Written based on the wording of the OpenGL 2.0 specification.
 | 
			
		||||
 | 
			
		||||
    This extension trivially interacts with ARB_texture_float.
 | 
			
		||||
    This extension shares some language with ARB_texture_compression_rgtc
 | 
			
		||||
    but does not depend on it.
 | 
			
		||||
 | 
			
		||||
Overview
 | 
			
		||||
 | 
			
		||||
    OpenGL prior to 3.1 does not support any signed texture formats.
 | 
			
		||||
    ARB_texture_compression_rgtc introduces some compressed red and
 | 
			
		||||
    red_green signed formats but no uncompressed ones, which might
 | 
			
		||||
    still be useful. NV_texture_shader adds signed texture formats,
 | 
			
		||||
    but also a lot of functionality which has been superceded by fragment
 | 
			
		||||
    shaders.
 | 
			
		||||
    It is usually possible to get the same functionality
 | 
			
		||||
    using a unsigned format by doing scale and bias in a shader, but this
 | 
			
		||||
    is undesirable since modern hardware has direct support for this.
 | 
			
		||||
    This extension adds a signed 4-channel texture format by backporting
 | 
			
		||||
    the relevant features from OpenGL 3.1, as a means to support this in
 | 
			
		||||
    OpenGL implementations only supporting older versions.
 | 
			
		||||
 | 
			
		||||
Issues
 | 
			
		||||
 | 
			
		||||
    1) What should this extension be called?
 | 
			
		||||
 | 
			
		||||
       RESOLVED: MESA_texture_signed_rgba seems reasonable.
 | 
			
		||||
       The rgba part is there because only 4 channel format is supported.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
    2) Should the full set of signed formats (alpha, luminance, rgb, etc.)
 | 
			
		||||
       be supported?
 | 
			
		||||
 | 
			
		||||
       RESOLVED: NO. To keep this extension simple, only add the most
 | 
			
		||||
       universal format, rgba. alpha/luminance can't be trivially supported
 | 
			
		||||
       since OpenGL 3.1 does not support them any longer, and there is some
 | 
			
		||||
       implied dependency on ARB_texture_rg for red/red_green formats so
 | 
			
		||||
       avoid all this. Likewise, only 8 bits per channel is supported.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
    3) Should this extension use new enums for the texture formats?
 | 
			
		||||
 | 
			
		||||
       RESOLVED: NO. Same enums as those used in OpenGL 3.1.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
    4) How are signed integer values mapped to floating-point values?
 | 
			
		||||
 | 
			
		||||
       RESOLVED: Same as described in issue 5) of
 | 
			
		||||
       ARB_texture_compression_rgtc (quote):
 | 
			
		||||
       A signed 8-bit two's complement value X is computed to
 | 
			
		||||
       a floating-point value Xf with the formula:
 | 
			
		||||
 | 
			
		||||
                { X / 127.0, X > -128
 | 
			
		||||
           Xf = {
 | 
			
		||||
                { -1.0,      X == -128
 | 
			
		||||
 | 
			
		||||
       This conversion means -1, 0, and +1 are all exactly representable,
 | 
			
		||||
       however -128 and -127 both map to -1.0.  Mapping -128 to -1.0
 | 
			
		||||
       avoids the numerical awkwardness of have a representable value
 | 
			
		||||
       slightly more negative than -1.0.
 | 
			
		||||
 | 
			
		||||
       This conversion is intentionally NOT the "byte" conversion listed
 | 
			
		||||
       in Table 2.9 for component conversions.  That conversion says:
 | 
			
		||||
 | 
			
		||||
           Xf = (2*X + 1) / 255.0
 | 
			
		||||
 | 
			
		||||
       The Table 2.9 conversion is incapable of exactly representing
 | 
			
		||||
       zero.
 | 
			
		||||
 | 
			
		||||
       (Difference to ARB_texture_compression_rgtc):
 | 
			
		||||
       This is the same mapping as OpenGL 3.1 uses.
 | 
			
		||||
       This is also different to what NV_texture_shader used.
 | 
			
		||||
       The above mapping should be considered the reference, but there
 | 
			
		||||
       is some leeway so other mappings are allowed for implementations which
 | 
			
		||||
       cannot do this. Particulary the mapping given in NV_texture_shader or
 | 
			
		||||
       the standard OpenGL byte/float mapping is considered acceptable too, as
 | 
			
		||||
       might be a mapping which represents -1.0 by -128, 0.0 by 0 and 1.0 by
 | 
			
		||||
       127 (that is, uses different scale factors for negative and positive
 | 
			
		||||
       numbers).
 | 
			
		||||
       Also, it is ok to store incoming GL_BYTE user data as-is, without
 | 
			
		||||
       converting to GL_FLOAT (using the standard OpenGL float/byte mapping)
 | 
			
		||||
       and converting back (using the mapping described here).
 | 
			
		||||
       Other than those subtle issues there are no other non-standard
 | 
			
		||||
       conversions used, so when using for instance CopyTexImage2D with
 | 
			
		||||
       a framebuffer clamped to [0,1] all converted numbers will be in the range
 | 
			
		||||
       [0, 127] (and not scaled and biased).
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
    5) How will signed components resulting from RGBA8_SNORM texture
 | 
			
		||||
       fetches interact with fragment coloring?
 | 
			
		||||
 | 
			
		||||
       RESOLVED: Same as described in issue 6) of
 | 
			
		||||
       ARB_texture_compression_rgtc (quote):
 | 
			
		||||
       The specification language for this extension is silent
 | 
			
		||||
       about clamping behavior leaving this to the core specification
 | 
			
		||||
       and other extensions.  The clamping or lack of clamping is left
 | 
			
		||||
       to the core specification and other extensions.
 | 
			
		||||
 | 
			
		||||
       For assembly program extensions supporting texture fetches
 | 
			
		||||
       (ARB_fragment_program, NV_fragment_program, NV_vertex_program3,
 | 
			
		||||
       etc.) or the OpenGL Shading Language, these signed formats will
 | 
			
		||||
       appear as expected with unclamped signed components as a result
 | 
			
		||||
       of a texture fetch instruction.
 | 
			
		||||
 | 
			
		||||
       If ARB_color_buffer_float is supported, its clamping controls
 | 
			
		||||
       will apply.
 | 
			
		||||
 | 
			
		||||
       NV_texture_shader extension, if supported, adds support for
 | 
			
		||||
       fixed-point textures with signed components and relaxed the
 | 
			
		||||
       fixed-function texture environment clamping appropriately.  If the
 | 
			
		||||
       NV_texture_shader extension is supported, its specified behavior
 | 
			
		||||
       for the texture environment applies where intermediate values
 | 
			
		||||
       are clamped to [-1,1] unless stated otherwise as in the case
 | 
			
		||||
       of explicitly clamped to [0,1] for GL_COMBINE.  or clamping the
 | 
			
		||||
       linear interpolation weight to [0,1] for GL_DECAL and GL_BLEND.
 | 
			
		||||
 | 
			
		||||
       Otherwise, the conventional core texture environment clamps
 | 
			
		||||
       incoming, intermediate, and output color components to [0,1].
 | 
			
		||||
 | 
			
		||||
       This implies that the conventional texture environment
 | 
			
		||||
       functionality of unextended OpenGL 1.5 or OpenGL 2.0 without
 | 
			
		||||
       using GLSL (and with none of the extensions referred to above)
 | 
			
		||||
       is unable to make proper use of the signed texture formats added
 | 
			
		||||
       by this extension because the conventional texture environment
 | 
			
		||||
       requires texture source colors to be clamped to [0,1].  Texture
 | 
			
		||||
       filtering of these signed formats would be still signed, but
 | 
			
		||||
       negative values generated post-filtering would be clamped to
 | 
			
		||||
       zero by the core texture environment functionality.  The
 | 
			
		||||
       expectation is clearly that this extension would be co-implemented
 | 
			
		||||
       with one of the previously referred to extensions or used with
 | 
			
		||||
       GLSL for the new signed formats to be useful.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
    6) Should the RGBA_SNORM tokens also be accepted by CopyTexImage
 | 
			
		||||
       functions?
 | 
			
		||||
 | 
			
		||||
       RESOLVED: YES.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
    7) What to do with GetTexParameter if ARB_texture_float is supported,
 | 
			
		||||
       in particular what datatype should this return for TEXTURE_RED_TYPE_ARB,
 | 
			
		||||
       TEXTURE_GREEN_TYPE_ARB, TEXTURE_BLUE_TYPE_ARB, TEXTURE_ALPHA_TYPE_ARB?
 | 
			
		||||
 | 
			
		||||
       RESOLVED: ARB_texture_float states type is either NONE,
 | 
			
		||||
       UNSIGNED_NORMALIZED_ARB, or FLOAT. This extension adds a new enum,
 | 
			
		||||
       SIGNED_NORMALIZED, which will be returned accordingly. This is the
 | 
			
		||||
       same behaviour as in OpenGL 3.1.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
New Tokens
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
    Accepted by the <internalformat> parameter of
 | 
			
		||||
    TexImage1D, TexImage2D, TexImage3D, CopyTexImage1D, and CopyTexImage2D:
 | 
			
		||||
 | 
			
		||||
        RGBA_SNORM                                0x8F93
 | 
			
		||||
        RGBA8_SNORM                               0x8F97
 | 
			
		||||
 | 
			
		||||
    Returned by the <params> parameter of GetTexLevelParameter:
 | 
			
		||||
 | 
			
		||||
        SIGNED_NORMALIZED                         0x8F9C
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
Additions to Chapter 3 of the OpenGL 2.0 Specification (Rasterization):
 | 
			
		||||
 | 
			
		||||
 -- Section 3.8.1, Texture Image Specification
 | 
			
		||||
 | 
			
		||||
    Add to Table 3.16 (page 154): Sized internal formats
 | 
			
		||||
 | 
			
		||||
    Sized             Base             R    G    B    A    L    I    D
 | 
			
		||||
    Internal Format   Internal Format bits bits bits bits bits bits bits
 | 
			
		||||
    ---------------   --------------- ---- ---- ---- ---- ---- ---- ----
 | 
			
		||||
    RGBA8_SNORM       RGBA             8    8    8    8    0    0    0
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
Dependencies on ARB_texture_float extension:
 | 
			
		||||
 | 
			
		||||
    If ARB_texture_float is supported, GetTexParameter queries with <value>
 | 
			
		||||
    of TEXTURE_RED_TYPE_ARB, TEXTURE_GREEN_TYPE_ARB, TEXTURE_BLUE_TYPE_ARB or
 | 
			
		||||
    TEXTURE_ALPHA_TYPE_ARB return SIGNED_NORMALIZED if
 | 
			
		||||
    the base internal format is RGBA_SNORM.
 | 
			
		||||
@@ -16,6 +16,7 @@ Status
 | 
			
		||||
 | 
			
		||||
Version
 | 
			
		||||
 | 
			
		||||
    $Id: MESA_window_pos.spec,v 1.4 2004/03/25 01:42:42 brianp Exp $
 | 
			
		||||
 | 
			
		||||
Number
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -17,6 +17,7 @@ Status
 | 
			
		||||
 | 
			
		||||
Version
 | 
			
		||||
 | 
			
		||||
    $Id: MESA_packed_depth_stencil.spec,v 1.2 2003/09/19 14:58:21 brianp Exp $
 | 
			
		||||
 | 
			
		||||
Number
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -18,6 +18,7 @@ Version
 | 
			
		||||
 | 
			
		||||
    Last Modified Date: July 20, 2003
 | 
			
		||||
    Author Revision: 1.0
 | 
			
		||||
    $Date: 2004/03/25 01:42:41 $ $Revision: 1.4 $
 | 
			
		||||
 | 
			
		||||
Number
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -16,6 +16,7 @@ Status
 | 
			
		||||
 | 
			
		||||
Version
 | 
			
		||||
 | 
			
		||||
    $Id: MESA_sprite_point.spec,v 1.2 2003/09/19 14:58:21 brianp Exp $
 | 
			
		||||
 | 
			
		||||
Number
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -17,6 +17,7 @@ Status
 | 
			
		||||
 | 
			
		||||
Version
 | 
			
		||||
 | 
			
		||||
    $Id: MESA_trace.spec,v 1.4 2004/03/25 01:42:42 brianp Exp $
 | 
			
		||||
 | 
			
		||||
Number
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -134,3 +134,4 @@ as of February, 1999.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: README.BEOS,v 1.12 2004/10/13 00:35:55 phoudoin Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -205,3 +205,4 @@ http://www.linuxgames.com/quake2/
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: README.QUAKE,v 1.3 1998/08/23 15:26:26 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -22,8 +22,7 @@ Installation
 | 
			
		||||
 | 
			
		||||
  to install OpenGL libraries and
 | 
			
		||||
 | 
			
		||||
     cd src/mesa/drivers/directfb ; make install
 | 
			
		||||
     make linux-directfb-install
 | 
			
		||||
 | 
			
		||||
  to install DirectFBGL module in the proper location.
 | 
			
		||||
  Actually, that last command may not be needed.  Please provide feedback.
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -143,3 +143,4 @@ code).  Anyone want to help?
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-3.1,v 1.2 2000/04/07 17:08:06 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -9,3 +9,4 @@ have been added.  For a list of bug fixes please read the VERSIONS file.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-3.2,v 1.2 2000/04/07 17:08:06 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -29,3 +29,4 @@ GLU library.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-3.2.1,v 1.2 2000/07/21 16:32:33 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -268,3 +268,4 @@ image convolution.  This will (hopefully) be done for Mesa 3.5/3.6.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-3.3,v 1.8 2000/07/21 16:26:41 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -19,3 +19,4 @@ see the VERSIONS file.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-3.4,v 1.2 2002/03/23 02:37:17 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -19,3 +19,4 @@ the Mesa 3.4 release.  For details, see the VERSIONS file.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-3.4.1,v 1.2 2001/05/23 14:45:01 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -19,3 +19,4 @@ the Mesa 3.4.1 release.  For details, see the VERSIONS file.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-3.4.2,v 1.2 2001/05/23 14:45:01 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -225,3 +225,4 @@ In the future I hope to implement support for 32-bit, floating point
 | 
			
		||||
color channels.
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-3.5,v 1.14 2001/06/20 19:02:48 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -160,3 +160,4 @@ See the VERSIONS file for more details about bug fixes, etc. in Mesa 4.0.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-4.0,v 3.2 2001/10/17 14:59:21 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -19,3 +19,4 @@ Mesa 4.0.1 only contains bug fixes since version 4.0.
 | 
			
		||||
See the docs/VERSIONS file for the list of bug fixes.
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-4.0.1,v 1.2 2001/12/18 14:08:23 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -47,3 +47,4 @@ D3D			needs updating
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-4.0.2,v 1.2 2002/03/23 02:38:39 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -49,3 +49,4 @@ D3D			needs updating
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-4.0.3,v 1.2 2002/06/26 02:36:34 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -305,3 +305,4 @@ are some things to change:
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-4.1,v 1.22 2002/10/29 15:06:37 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -82,3 +82,4 @@ driver call the _mesa_enable_1_4_extensions() function.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-5.0,v 3.2 2002/11/13 15:33:51 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -43,3 +43,4 @@ driver call the _mesa_enable_1_4_extensions() function.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-5.0.1,v 3.1 2003/03/30 16:17:54 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -43,3 +43,4 @@ driver call the _mesa_enable_1_4_extensions() function.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-5.0.2,v 1.1 2003/09/04 23:10:38 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -84,3 +84,4 @@ See the VERSIONS file for more details about bug fixes, etc. in Mesa 6.0.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-6.0,v 1.3 2004/01/15 15:47:57 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -47,3 +47,4 @@ D3D			needs updating
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-6.0.1,v 3.1 2004/04/02 23:37:02 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -109,3 +109,4 @@ See the VERSIONS file for more details about bug fixes, etc. in Mesa 6.1.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-6.1,v 3.5 2004/08/17 22:58:23 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -49,3 +49,4 @@ D3D			needs updating
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-6.2,v 3.4 2004/10/02 15:43:14 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -47,3 +47,4 @@ D3D			needs updating
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-6.2.1,v 3.1 2004/12/09 23:21:36 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -112,3 +112,4 @@ D3D			needs updating
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-6.3,v 3.13 2005/07/21 15:57:29 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -46,3 +46,4 @@ D3D			needs updating
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-6.3.1,v 3.1 2005/07/21 18:45:54 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -34,3 +34,4 @@ D3D			needs updating
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-6.3.2,v 3.2 2005/08/19 16:57:50 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -47,3 +47,4 @@ in Mesa 6.3.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
----------------------------------------------------------------------
 | 
			
		||||
$Id: RELNOTES-6.4,v 3.1 2005/10/24 23:33:27 brianp Exp $
 | 
			
		||||
 
 | 
			
		||||
@@ -14,16 +14,29 @@ The Mesa
 | 
			
		||||
driver is part of the 
 | 
			
		||||
<a href="http://www.tungstengraphics.com/wiki/index.php/Gallium3D" target="_parent">Gallium3D</a>
 | 
			
		||||
architecture.
 | 
			
		||||
Tungsten Graphics did the original implementation of the Cell driver.
 | 
			
		||||
</p>
 | 
			
		||||
 | 
			
		||||
<p>
 | 
			
		||||
<a href="http://www.tungstengraphics.com/" target="_parent">Tungsten Graphics</a>
 | 
			
		||||
is leading the project.
 | 
			
		||||
Two phases are planned.
 | 
			
		||||
First, to implement the framework for parallel rasterization using the Cell
 | 
			
		||||
SPEs, including texture mapping.
 | 
			
		||||
Second, to implement a full-featured OpenGL driver with support for GLSL, etc.
 | 
			
		||||
The second phase is now underway.
 | 
			
		||||
</p>
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
<H2>Source Code</H2>
 | 
			
		||||
 | 
			
		||||
<p>
 | 
			
		||||
The latest Cell driver source code is on the master branch of the Mesa
 | 
			
		||||
git repository.
 | 
			
		||||
The latest Cell driver source code is on the <code>gallium-0.2</code> branch
 | 
			
		||||
of the Mesa git repository.
 | 
			
		||||
After you've cloned the repository, check out the branch with:
 | 
			
		||||
</p>
 | 
			
		||||
<pre>
 | 
			
		||||
   git-checkout -b gallium-0.2 origin/gallium-0.2
 | 
			
		||||
</pre>
 | 
			
		||||
<p>
 | 
			
		||||
To build the driver you'll need the IBM Cell SDK (version 2.1 or 3.0).
 | 
			
		||||
To use the driver you'll need a Cell system, such as a PS3 running Linux,
 | 
			
		||||
@@ -37,21 +50,19 @@ special changes.
 | 
			
		||||
 | 
			
		||||
<p>
 | 
			
		||||
To compile the code, run <code>make linux-cell</code>.
 | 
			
		||||
Or to build in debug mode, run <code>make linux-cell-debug</code>.
 | 
			
		||||
To build in debug mode, run <code>make linux-cell-debug</code>.
 | 
			
		||||
</p>
 | 
			
		||||
 | 
			
		||||
<p>
 | 
			
		||||
To use the library, make sure your current directory is the top of the
 | 
			
		||||
Mesa tree, then set <code>LD_LIBRARY_PATH</code> like this:
 | 
			
		||||
<pre>
 | 
			
		||||
  export LD_LIBRARY_PATH=$PWD/lib/gallium:$PWD/lib/
 | 
			
		||||
</pre>
 | 
			
		||||
To use the library, make sure <code>LD_LIBRARY_PATH</code> points the Mesa/lib/
 | 
			
		||||
directory that contains <code>libGL.so</code>.
 | 
			
		||||
</p>
 | 
			
		||||
 | 
			
		||||
<p>
 | 
			
		||||
Verify that the Cell driver is being used by running
 | 
			
		||||
<code>progs/xdemos/glxinfo</code> and looking for:
 | 
			
		||||
Verify that the Cell driver is being used by running <code>glxinfo</code>
 | 
			
		||||
and looking for:
 | 
			
		||||
<pre>
 | 
			
		||||
  OpenGL renderer string: Gallium 0.3, Cell on Xlib
 | 
			
		||||
  OpenGL renderer string: Gallium 0.2, Cell on Xlib
 | 
			
		||||
</pre>
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@@ -72,23 +83,23 @@ Similarly, textures are tiled and brought into local store as needed.
 | 
			
		||||
<H2>Status</H2>
 | 
			
		||||
 | 
			
		||||
<p>
 | 
			
		||||
As of October 2008, the driver runs quite a few OpenGL demos.
 | 
			
		||||
Features that work include:
 | 
			
		||||
</p>
 | 
			
		||||
<ul>
 | 
			
		||||
<li>Point/line/triangle rendering, glDrawPixels
 | 
			
		||||
<li>2D, NPOT and cube texture maps with nearest/linear/mipmap filtering
 | 
			
		||||
<li>Dynamic SPU code generation for fragment shaders, but not complete
 | 
			
		||||
<li>Dynamic SPU code generation for fragment ops (blend, Z-test, etc), but not complete
 | 
			
		||||
<li>Dynamic PPU/PPC code generation for vertex shaders, but not complete
 | 
			
		||||
</ul>
 | 
			
		||||
<p>
 | 
			
		||||
Performance has recently improved with the addition of PPC code generation
 | 
			
		||||
for vertex shaders, but the code quality isn't too great yet.
 | 
			
		||||
As of September 2008, the driver supports smooth/flat shaded triangle rendering
 | 
			
		||||
with Z testing and simple texture mapping.
 | 
			
		||||
Simple demos like gears run successfully.
 | 
			
		||||
To test texture mapping, try progs/demos/texcyl (press right mouse button for
 | 
			
		||||
rendering options).
 | 
			
		||||
</p>
 | 
			
		||||
<p>
 | 
			
		||||
Another bottleneck is SwapBuffers.  It may be the limiting factor for
 | 
			
		||||
many simple GL tests.
 | 
			
		||||
Runtime/dynamic code generation is being done for per-fragment
 | 
			
		||||
operations (Z test, blend, etc) and for fragment programs (though only a
 | 
			
		||||
few opcodes are implemented now).
 | 
			
		||||
</p>
 | 
			
		||||
<p>
 | 
			
		||||
In general, however, the driver is rather slow because all vertex
 | 
			
		||||
transformation is being done by an interpreter running on the PPU.
 | 
			
		||||
Programs with many vertices or complex vertex shaders will run especially
 | 
			
		||||
slow.
 | 
			
		||||
This will be addressed in the future.
 | 
			
		||||
</p>
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@@ -103,20 +114,8 @@ more of the following debug options:
 | 
			
		||||
<li><b>checker</b> - use a different background clear color for each SPU.
 | 
			
		||||
   This lets you see which SPU is rendering which screen tiles.
 | 
			
		||||
<li><b>sync</b> - wait/synchronize after each DMA transfer
 | 
			
		||||
<li><b>asm</b> - print generated SPU assembly code to stdout
 | 
			
		||||
<li><b>fragops</b> - emit fragment ops debug messages
 | 
			
		||||
<li><b>fragopfallback</b> - don't use codegen for fragment ops
 | 
			
		||||
<li><b>cmd</b> - print SPU commands as their received
 | 
			
		||||
<li><b>cache</b> - print texture cache statistics when program exits
 | 
			
		||||
</ul>
 | 
			
		||||
<p>
 | 
			
		||||
Note that some of these options may only work for linux-cell-debug builds.
 | 
			
		||||
</p>
 | 
			
		||||
 | 
			
		||||
<p>
 | 
			
		||||
If the GALLIUM_NOPPC env var is set, PPC code generation will not be used
 | 
			
		||||
and vertex shaders will be run with the TGSI interpreter.
 | 
			
		||||
</p>
 | 
			
		||||
<p>
 | 
			
		||||
If the GALLIUM_NOCELL env var is set, the softpipe driver will be used
 | 
			
		||||
intead of the Cell driver.
 | 
			
		||||
 
 | 
			
		||||
@@ -37,8 +37,8 @@ a:visited {
 | 
			
		||||
 | 
			
		||||
<b>Download / Install</b>
 | 
			
		||||
<ul>
 | 
			
		||||
<li><a href="download.html" target="MainFrame">Downloading / Unpacking</a>
 | 
			
		||||
<li><a href="install.html" target="MainFrame">Compiling / Installing</a>
 | 
			
		||||
<li><a href="download.html" target="MainFrame">Downloading/Unpacking</a>
 | 
			
		||||
<li><a href="install.html" target="MainFrame">Compilation/Installation</a>
 | 
			
		||||
<li><a href="glu.html" target="MainFrame">SGI's GLU</a>
 | 
			
		||||
<li><a href="precompiled.html" target="MainFrame">Precompiled Libraries</a>
 | 
			
		||||
</ul>
 | 
			
		||||
@@ -48,7 +48,7 @@ a:visited {
 | 
			
		||||
<li><a href="lists.html" target="MainFrame">Mailing Lists</a>
 | 
			
		||||
<li><a href="bugs.html" target="MainFrame">Bug Database</a>
 | 
			
		||||
<li><a href="webmaster.html" target="MainFrame">Webmaster</a>
 | 
			
		||||
<li><a href="http://dri.freedesktop.org/" target="_parent">Mesa/DRI Wiki</a>
 | 
			
		||||
<li><a href="http://dri.freedesktop.org/" target="MainFrame">Wiki</a>
 | 
			
		||||
</ul>
 | 
			
		||||
 | 
			
		||||
<b>User Topics</b>
 | 
			
		||||
 
 | 
			
		||||
@@ -8,6 +8,12 @@
 | 
			
		||||
 | 
			
		||||
<H1>Downloading</H1>
 | 
			
		||||
 | 
			
		||||
<p>
 | 
			
		||||
Current stable release: <b>7.2</b>
 | 
			
		||||
<br>
 | 
			
		||||
Current development: Mesa git/master
 | 
			
		||||
</p>
 | 
			
		||||
 | 
			
		||||
<p>
 | 
			
		||||
Primary download site:
 | 
			
		||||
<a href="http://sourceforge.net/project/showfiles.php?group_id=3"
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,4 @@
 | 
			
		||||
 | 
			
		||||
See the OpenGL ARB enum registry at http://www.opengl.org/registry/api/enum.spec
 | 
			
		||||
 | 
			
		||||
Blocks allocated to Mesa:
 | 
			
		||||
       0x8750-0x875F
 | 
			
		||||
       0x8BB0-0x8BBF
 | 
			
		||||
@@ -32,12 +30,12 @@ MESA_ycbcr_texture.spec:
 | 
			
		||||
GL_MESA_pack_invert.spec
 | 
			
		||||
	GL_PACK_INVERT_MESA              0x8758
 | 
			
		||||
 | 
			
		||||
GL_MESA_shader_debug.spec: (obsolete)
 | 
			
		||||
GL_MESA_shader_debug.spec:
 | 
			
		||||
        GL_DEBUG_OBJECT_MESA             0x8759
 | 
			
		||||
        GL_DEBUG_PRINT_MESA              0x875A
 | 
			
		||||
        GL_DEBUG_ASSERT_MESA             0x875B
 | 
			
		||||
 | 
			
		||||
GL_MESA_program_debug.spec: (obsolete)
 | 
			
		||||
GL_MESA_program_debug.spec:
 | 
			
		||||
	GL_FRAGMENT_PROGRAM_CALLBACK_MESA      0x????
 | 
			
		||||
	GL_VERTEX_PROGRAM_CALLBACK_MESA        0x????
 | 
			
		||||
	GL_FRAGMENT_PROGRAM_POSITION_MESA      0x????
 | 
			
		||||
@@ -47,11 +45,3 @@ GL_MESA_program_debug.spec: (obsolete)
 | 
			
		||||
	GL_VERTEX_PROGRAM_CALLBACK_FUNC_MESA   0x????
 | 
			
		||||
	GL_VERTEX_PROGRAM_CALLBACK_DATA_MESA   0x????
 | 
			
		||||
 | 
			
		||||
GL_MESAX_texture_stack:
 | 
			
		||||
	GL_TEXTURE_1D_STACK_MESAX            0x8759
 | 
			
		||||
	GL_TEXTURE_2D_STACK_MESAX            0x875A
 | 
			
		||||
	GL_PROXY_TEXTURE_1D_STACK_MESAX      0x875B
 | 
			
		||||
	GL_PROXY_TEXTURE_2D_STACK_MESAX      0x875C
 | 
			
		||||
	GL_TEXTURE_1D_STACK_BINDING_MESAX    0x875D
 | 
			
		||||
	GL_TEXTURE_2D_STACK_BINDING_MESAX    0x875E
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -29,7 +29,7 @@ Setting this variable automatically sets the MESA_TEX_PROG variable as well.
 | 
			
		||||
 | 
			
		||||
<p>
 | 
			
		||||
The following are only applicable to the Xlib software driver.
 | 
			
		||||
See the <A HREF="xlibdriver.html">Xlib software driver page</A> for details.
 | 
			
		||||
See <A HREF="README.X11">README.X11</A> for details.
 | 
			
		||||
</p>
 | 
			
		||||
<ul>
 | 
			
		||||
<li>MESA_RGB_VISUAL - specifies the X visual and depth for RGB mode
 | 
			
		||||
 
 | 
			
		||||
Some files were not shown because too many files have changed in this diff Show More
		Reference in New Issue
	
	Block a user