1
0
forked from rpms/mesa

Today's git snapshot for DRI2 goodness.

This commit is contained in:
Adam Jackson 2008-02-15 23:21:58 +00:00
parent 3db994ee91
commit cfe4e414ad
13 changed files with 95 additions and 386 deletions

View File

@ -1,2 +1,2 @@
gl-manpages-1.0.1.tar.bz2
mesa-20071127.tar.bz2
mesa-20080215.tar.bz2

17
make-git-snapshot.sh Executable file
View File

@ -0,0 +1,17 @@
#!/bin/sh
DIRNAME=mesa-$( date +%Y%m%d )
rm -rf $DIRNAME
git clone git://git.freedesktop.org/git/mesa/mesa $DIRNAME
cd $DIRNAME
if [ -z "$1" ]; then
git log | head -1
else
git checkout $1
fi
git log | head -1 | awk '{ print $2 }' > ../commitid
git repack -a -d
cd ..
tar jcf $DIRNAME.tar.bz2 $DIRNAME
rm -rf $DIRNAME

View File

@ -1,17 +0,0 @@
--- progs/xdemos/Makefile.dont-libglut-me-harder-ok-thx-bye 2006-07-25 05:27:36.000000000 -0400
+++ progs/xdemos/Makefile 2006-07-25 05:33:57.000000000 -0400
@@ -49,8 +49,13 @@
-rm -f $(PROGS)
-rm -f *.o *~
-
# special cases
+glxgears:
+ $(CC) $(CFLAGS) glxgears.c -lGL -o $@
+
+glxinfo:
+ $(CC) $(CFLAGS) -I$(INCDIR) glxinfo.c -L$(TOP)/lib -L$(TOP)/lib64 -lGL -lGLU -o $@
+
pbinfo: pbinfo.o pbutil.o
$(CC) $(CFLAGS) pbinfo.o pbutil.o $(APP_LIB_DEPS) -o $@

View File

@ -1,107 +0,0 @@
diff -up mesa-20071127/src/mesa/main/execmem.c.selinux-awareness mesa-20071127/src/mesa/main/execmem.c
--- mesa-20071127/src/mesa/main/execmem.c.selinux-awareness 2007-11-27 14:33:54.000000000 -0500
+++ mesa-20071127/src/mesa/main/execmem.c 2007-11-27 14:34:34.000000000 -0500
@@ -46,6 +46,7 @@
#include <unistd.h>
#include <sys/mman.h>
#include "mm.h"
+#include <selinux/selinux.h>
#define EXEC_HEAP_SIZE (10*1024*1024)
@@ -55,9 +56,16 @@ static struct mem_block *exec_heap = NUL
static unsigned char *exec_mem = NULL;
-static void
+static int
init_heap(void)
{
+
+ if (is_selinux_enabled()) {
+ if (!security_get_boolean_active("allow_execmem") ||
+ !security_get_boolean_pending("allow_execmem"))
+ return 0;
+ }
+
if (!exec_heap)
exec_heap = mmInit( 0, EXEC_HEAP_SIZE );
@@ -65,6 +73,8 @@ init_heap(void)
exec_mem = (unsigned char *) mmap(0, EXEC_HEAP_SIZE,
PROT_EXEC | PROT_READ | PROT_WRITE,
MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
+
+ return (exec_mem != NULL);
}
@@ -76,7 +86,8 @@ _mesa_exec_malloc(GLuint size)
_glthread_LOCK_MUTEX(exec_mutex);
- init_heap();
+ if (!init_heap())
+ goto bail;
if (exec_heap) {
size = (size + 31) & ~31;
@@ -87,7 +98,8 @@ _mesa_exec_malloc(GLuint size)
addr = exec_mem + block->ofs;
else
_mesa_printf("_mesa_exec_malloc failed\n");
-
+
+bail:
_glthread_UNLOCK_MUTEX(exec_mutex);
return addr;
diff -up mesa-20071127/src/mesa/x86/rtasm/x86sse.c.selinux-awareness mesa-20071127/src/mesa/x86/rtasm/x86sse.c
diff -up mesa-20071127/src/mesa/x86/rtasm/x86sse.h.selinux-awareness mesa-20071127/src/mesa/x86/rtasm/x86sse.h
diff -up mesa-20071127/src/mesa/tnl/t_vertex_sse.c.selinux-awareness mesa-20071127/src/mesa/tnl/t_vertex_sse.c
diff -up mesa-20071127/configs/linux-osmesa.selinux-awareness mesa-20071127/configs/linux-osmesa
--- mesa-20071127/configs/linux-osmesa.selinux-awareness 2007-11-27 14:33:53.000000000 -0500
+++ mesa-20071127/configs/linux-osmesa 2007-11-27 14:34:34.000000000 -0500
@@ -23,6 +23,6 @@ PROGRAM_DIRS = osdemos
# Dependencies
-OSMESA_LIB_DEPS = -lm -lpthread
+OSMESA_LIB_DEPS = -lm -lpthread -lselinux
GLU_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(OSMESA_LIB)
APP_LIB_DEPS = -lOSMesa -lGLU
diff -up mesa-20071127/configs/linux-osmesa32.selinux-awareness mesa-20071127/configs/linux-osmesa32
--- mesa-20071127/configs/linux-osmesa32.selinux-awareness 2007-11-27 14:33:53.000000000 -0500
+++ mesa-20071127/configs/linux-osmesa32 2007-11-27 14:34:34.000000000 -0500
@@ -26,6 +26,6 @@ PROGRAM_DIRS =
# Dependencies
-OSMESA_LIB_DEPS = -lm -lpthread
+OSMESA_LIB_DEPS = -lm -lpthread -lselinux
GLU_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(OSMESA_LIB)
APP_LIB_DEPS = -lOSMesa32
diff -up mesa-20071127/configs/linux-osmesa16.selinux-awareness mesa-20071127/configs/linux-osmesa16
--- mesa-20071127/configs/linux-osmesa16.selinux-awareness 2007-11-27 14:33:53.000000000 -0500
+++ mesa-20071127/configs/linux-osmesa16 2007-11-27 14:34:34.000000000 -0500
@@ -26,6 +26,6 @@ PROGRAM_DIRS =
# Dependencies
-OSMESA_LIB_DEPS = -lm -lpthread
+OSMESA_LIB_DEPS = -lm -lpthread -lselinux
GLU_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(OSMESA_LIB)
APP_LIB_DEPS = -lOSMesa16
diff -up mesa-20071127/configs/linux-dri.selinux-awareness mesa-20071127/configs/linux-dri
--- mesa-20071127/configs/linux-dri.selinux-awareness 2007-11-27 14:34:34.000000000 -0500
+++ mesa-20071127/configs/linux-dri 2007-11-27 14:34:34.000000000 -0500
@@ -45,7 +45,8 @@ EXTRA_LIB_PATH=-L/usr/X11R6/lib
LIBDRM_CFLAGS = `pkg-config --cflags libdrm`
LIBDRM_LIB = `pkg-config --libs libdrm`
-DRI_LIB_DEPS = $(EXTRA_LIB_PATH) -lm -lpthread -lexpat -ldl $(LIBDRM_LIB)
+DRI_LIB_DEPS = $(EXTRA_LIB_PATH) -lm -lpthread -lexpat -ldl $(LIBDRM_LIB) \
+ -lselinux
GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lXdamage -lXfixes \
-lm -lpthread -ldl \
$(LIBDRM_LIB)

View File

@ -1,12 +0,0 @@
diff -up mesa-20070725/src/mesa/drivers/dri/Makefile.template.jx mesa-20070725/src/mesa/drivers/dri/Makefile.template
--- mesa-20070725/src/mesa/drivers/dri/Makefile.template.jx 2007-07-25 09:36:04.000000000 -0400
+++ mesa-20070725/src/mesa/drivers/dri/Makefile.template 2007-07-26 10:09:54.000000000 -0400
@@ -70,7 +70,7 @@ SHARED_INCLUDES = \
##### TARGETS #####
-default: depend symlinks $(LIBNAME) $(TOP)/$(LIB_DIR)/$(LIBNAME)
+default: symlinks depend $(LIBNAME) $(TOP)/$(LIB_DIR)/$(LIBNAME)
$(LIBNAME): $(OBJECTS) $(MESA_MODULES) $(WINOBJ) Makefile $(TOP)/src/mesa/drivers/dri/Makefile.template

View File

@ -1,12 +0,0 @@
diff -up Mesa-7.1pre/configs/default.da Mesa-7.1pre/configs/default
--- Mesa-7.1pre/configs/default.da 2007-11-07 08:44:17.000000000 +1000
+++ Mesa-7.1pre/configs/default 2007-11-07 08:44:28.000000000 +1000
@@ -82,7 +82,7 @@ APP_LIB_DEPS = -lm
# Installation directories (for make install)
INSTALL_DIR = /usr/local
-DRI_DRIVER_INSTALL_DIR = /usr/X11R6/lib/modules/dri
+DRI_DRIVER_INSTALL_DIR = $(DRI_DRIVER_DIR)
# Where libGL will look for DRI hardware drivers
DRI_DRIVER_SEARCH_DIR = $(DRI_DRIVER_INSTALL_DIR)

View File

@ -1,35 +0,0 @@
diff -up mesa-20071127/src/mesa/drivers/dri/i915/intel_screen.c.e7221 mesa-20071127/src/mesa/drivers/dri/i915/intel_screen.c
--- mesa-20071127/src/mesa/drivers/dri/i915/intel_screen.c.e7221 2007-11-27 14:33:54.000000000 -0500
+++ mesa-20071127/src/mesa/drivers/dri/i915/intel_screen.c 2008-01-22 13:26:07.000000000 -0500
@@ -735,6 +735,7 @@ intelCreateContext(const __GLcontextMode
return i830CreateContext(mesaVis, driContextPriv, sharedContextPrivate);
case PCI_CHIP_I915_G:
+ case PCI_CHIP_E7221_G:
case PCI_CHIP_I915_GM:
case PCI_CHIP_I945_G:
case PCI_CHIP_I945_GM:
diff -up mesa-20071127/src/mesa/drivers/dri/i915/intel_context.h.e7221 mesa-20071127/src/mesa/drivers/dri/i915/intel_context.h
--- mesa-20071127/src/mesa/drivers/dri/i915/intel_context.h.e7221 2007-11-27 14:33:54.000000000 -0500
+++ mesa-20071127/src/mesa/drivers/dri/i915/intel_context.h 2008-01-22 13:26:07.000000000 -0500
@@ -324,6 +324,7 @@ extern int INTEL_DEBUG;
#define PCI_CHIP_I855_GM 0x3582
#define PCI_CHIP_I865_G 0x2572
#define PCI_CHIP_I915_G 0x2582
+#define PCI_CHIP_E7221_G 0x258A
#define PCI_CHIP_I915_GM 0x2592
#define PCI_CHIP_I945_G 0x2772
#define PCI_CHIP_I945_GM 0x27A2
diff -up mesa-20071127/src/mesa/drivers/dri/i915/intel_context.c.e7221 mesa-20071127/src/mesa/drivers/dri/i915/intel_context.c
--- mesa-20071127/src/mesa/drivers/dri/i915/intel_context.c.e7221 2007-11-27 14:33:54.000000000 -0500
+++ mesa-20071127/src/mesa/drivers/dri/i915/intel_context.c 2008-01-22 13:27:10.000000000 -0500
@@ -125,6 +125,9 @@ intelGetString(GLcontext * ctx, GLenum n
case PCI_CHIP_I915_GM:
chipset = "Intel(R) 915GM";
break;
+ case PCI_CHIP_E7221_G:
+ chipset = "Intel(R) E7221G (i915)";
+ break;
case PCI_CHIP_I945_G:
chipset = "Intel(R) 945G";
break;

View File

@ -1,21 +0,0 @@
diff -up mesa-20071127/src/mesa/drivers/dri/i915/intel_tex.c.jx mesa-20071127/src/mesa/drivers/dri/i915/intel_tex.c
--- mesa-20071127/src/mesa/drivers/dri/i915/intel_tex.c.jx 2007-11-27 14:33:54.000000000 -0500
+++ mesa-20071127/src/mesa/drivers/dri/i915/intel_tex.c 2008-02-11 15:49:16.000000000 -0500
@@ -98,7 +98,7 @@ do_memcpy(void *dest, const void *src, s
}
-#if DO_DEBUG
+#if defined(DO_DEBUG) && !defined(__ia64__)
#ifndef __x86_64__
static unsigned
@@ -183,7 +183,7 @@ intelInitTextureFuncs(struct dd_function
functions->UpdateTexturePalette = 0;
functions->IsTextureResident = intelIsTextureResident;
-#if DO_DEBUG
+#if defined(DO_DEBUG) && !defined(__ia64__)
if (INTEL_DEBUG & DEBUG_BUFMGR)
functions->TextureMemCpy = timed_memcpy;
else

View File

@ -1,40 +0,0 @@
diff -up Mesa-7.1pre/configs/default.da Mesa-7.1pre/configs/default
--- Mesa-7.1pre/configs/default.da 2007-11-01 16:24:30.000000000 +1000
+++ Mesa-7.1pre/configs/default 2007-11-01 16:24:37.000000000 +1000
@@ -60,7 +60,7 @@ GLW_SOURCES = GLwDrawA.c
# Directories to build
LIB_DIR = lib
-SRC_DIRS = mesa glu glut/glx glw
+SRC_DIRS = mesa glu glut/glx
GLU_DIRS = sgi
DRIVER_DIRS = x11 osmesa
# Which subdirs under $(TOP)/progs/ to enter:
diff -up Mesa-7.1pre/configs/linux-indirect.da Mesa-7.1pre/configs/linux-indirect
--- Mesa-7.1pre/configs/linux-indirect.da 2007-11-01 16:23:32.000000000 +1000
+++ Mesa-7.1pre/configs/linux-indirect 2007-11-01 16:23:39.000000000 +1000
@@ -47,7 +47,7 @@ GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11
# Directories
-SRC_DIRS = glx/x11 glu glut/glx glw
+SRC_DIRS = glx/x11 glu
DRIVER_DIRS =
PROGRAM_DIRS =
WINDOW_SYSTEM=dri
diff -up Mesa-7.1pre/configs/linux-dri.da Mesa-7.1pre/configs/linux-dri
--- Mesa-7.1pre/configs/linux-dri.da 2007-11-01 16:24:00.000000000 +1000
+++ Mesa-7.1pre/configs/linux-dri 2007-11-01 16:24:12.000000000 +1000
@@ -60,10 +60,10 @@ USING_EGL=0
# Directories
ifeq ($(USING_EGL), 1)
-SRC_DIRS = egl glx/x11 mesa glu glut/glx glw
+SRC_DIRS = egl glx/x11 mesa glu glut/glx
PROGRAM_DIRS = egl xdemos
else
-SRC_DIRS = glx/x11 mesa glu glut/glx glw
+SRC_DIRS = glx/x11 mesa glu glut/glx
PROGRAM_DIRS = xdemos
endif

View File

@ -1,24 +0,0 @@
diff -up mesa-20071127/src/mesa/drivers/dri/intel/intel_fbo.c.da mesa-20071127/src/mesa/drivers/dri/intel/intel_fbo.c
--- mesa-20071127/src/mesa/drivers/dri/intel/intel_fbo.c.da 2007-12-04 11:20:24.000000000 +1000
+++ mesa-20071127/src/mesa/drivers/dri/intel/intel_fbo.c 2007-12-04 11:20:36.000000000 +1000
@@ -615,11 +615,6 @@ intel_render_texture(GLcontext * ctx,
}
}
- DBG("Begin render texture tid %x tex=%u w=%d h=%d refcount=%d\n",
- _glthread_GetID(),
- att->Texture->Name, newImage->Width, newImage->Height,
- irb->Base.RefCount);
-
/* point the renderbufer's region to the texture image region */
intel_image = intel_texture_image(newImage);
if (irb->region != intel_image->mt->region) {
@@ -656,8 +651,6 @@ intel_finish_render_texture(GLcontext *
{
struct intel_renderbuffer *irb = intel_renderbuffer(att->Renderbuffer);
- DBG("End render texture (tid %x) tex %u\n", _glthread_GetID(), att->Texture->Name);
-
if (irb) {
/* just release the region */
intel_region_release(&irb->region);

View File

@ -1,12 +0,0 @@
diff -up mesa-20071127/src/mesa/drivers/dri/sis/sis_context.h.broken mesa-20071127/src/mesa/drivers/dri/sis/sis_context.h
--- mesa-20071127/src/mesa/drivers/dri/sis/sis_context.h.broken 2008-02-11 20:22:25.000000000 -0500
+++ mesa-20071127/src/mesa/drivers/dri/sis/sis_context.h 2008-02-11 20:23:38.000000000 -0500
@@ -403,6 +403,8 @@ struct sis_context
#if defined(__i386__) || defined(__amd64__)
#define MMIO_WMB() __asm __volatile("" : : : "memory")
+#elif defined (__ia64__)
+#define MMIO_WMB() __asm __volatile ("mf" : : : "memory")
#else
#error platform needs WMB
#endif

180
mesa.spec
View File

@ -1,41 +1,21 @@
# When bootstrapping an arch, omit the -demos subpackage.
# Architechture specific configuration. FIXME: Should build with DRI support
# everywhere, and select target is some other more pleasant fashion.
# S390 doesn't have video cards, so it's not much use building DRI there.
%ifarch s390 s390x
%define with_dri 0
%define dri_target linux-indirect
%define src_dirs SRC_DIRS="glx/x11 glu"
%define driver xlib
%else
%define with_dri 1
%define src_dirs SRC_DIRS="glx/x11 mesa glu"
%endif
%ifarch %{ix86}
%define dri_target linux-dri-x86
%endif
%ifarch x86_64
%define dri_target linux-dri-x86-64
%endif
%ifarch ppc ppc64
%define dri_target linux-dri-ppc
%endif
# rpm sure has a funny way of spelling %ifndef. This is the default case.
%if 0%{!?dri_target:1}
%define dri_target linux-dri
%define driver dri
%endif
%define manpages gl-manpages-1.0.1
%define gitdate 20071127
%define gitdate 20080215
Summary: Mesa graphics libraries
Name: mesa
Version: 7.1
Release: 0.10%{?dist}
Release: 0.11%{?dist}
License: MIT
Group: System Environment/Libraries
URL: http://www.mesa3d.org
@ -43,23 +23,16 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
#Source0: http://internap.dl.sourceforge.net/sourceforge/mesa3d/MesaLib-7.1pre.tar.bz2
#Source1: http://internap.dl.sourceforge.net/sourceforge/mesa3d/MesaDemos-7.1pre.tar.bz2
Source0: mesa-%{gitdate}.tar.bz2
Source0: %{name}-%{gitdate}.tar.bz2
Source2: %{manpages}.tar.bz2
Source3: make-git-snapshot.sh
Patch1: mesa-7.1-kill-glw.patch
Patch2: mesa-7.1pre-osmesa-version.patch
Patch3: mesa-7.1-dri-driver-dir.patch
Patch4: mesa-6.5-dont-libglut-me-harder-ok-thx-bye.patch
Patch18: mesa-7.0-selinux-awareness.patch
Patch25: mesa-7.0-symlinks-before-depend.patch
Patch26: mesa-7.1-remove-getid-i915.patch
Patch27: mesa-7.1-e7221.patch
Patch28: mesa-7.1-ia64-build-fix.patch
Patch29: mesa-7.1-sis-ia64.patch
Patch0: mesa-7.1pre-osmesa-version.patch
BuildRequires: pkgconfig
BuildRequires: pkgconfig autoconf
%if %{with_dri}
BuildRequires: libdrm-devel >= 2.4.0-0.2
BuildRequires: libdrm-devel >= 2.4.0-0.4
%endif
BuildRequires: libXxf86vm-devel
BuildRequires: expat-devel >= 2.0
@ -176,18 +149,7 @@ This package provides some demo applications for testing Mesa.
%prep
#%setup -q -n Mesa-%{version}pre -b1 -b2
%setup -q -n mesa-%{gitdate} -b2
chmod a-x progs/demos/glslnoise.c
%patch1 -p1 -b .kill-glw
%patch2 -p1 -b .osmesa-version
%patch3 -p1 -b .dri-driver-dir
%patch4 -p0 -b .dont-libglut-me-harder-ok-thx-bye
%patch18 -p1 -b .selinux-awareness
%patch25 -p1 -b .makej
%patch26 -p1 -b .fixi915
%patch27 -p1 -b .e7221
%patch28 -p1 -b .ia64
%patch29 -p1 -b .sis
%patch -p1 -b .osmesa
# WARNING: The following files are copyright "Mark J. Kilgard" under the GLUT
# license and are not open source/free software, so we remove them.
@ -200,76 +162,85 @@ sed -i 's,isosurf.dat,%{_libdir}/mesa-demos-data/&,' progs/demos/isosurf.c
sed -i 's,terrain.dat,%{_libdir}/mesa-demos-data/&,' progs/demos/terrain.c
%build
autoreconf --install
# The i965 DRI driver breaks if compiled with -O2. It appears to be
# an aliasing problem, so we add -fno-strict-aliasing to the flags.
export OPT_FLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing -fvisibility=hidden -fPIC"
export DRI_DRIVER_DIR="%{_libdir}/dri"
# first, build the osmesa variants
%configure --with-driver=osmesa --with-osmesa-bits=8
make %{_smp_mflags} SRC_DIRS=mesa
mv lib osmesa8
make clean
mkdir preserve
%configure --with-driver=osmesa --with-osmesa-bits=16
make %{_smp_mflags} SRC_DIRS=mesa
mv lib osmesa16
make clean
for t in osmesa osmesa16 osmesa32; do
echo "Building $t"
make %{?_smp_mflags} linux-$t OPT_FLAGS="${OPT_FLAGS}" LIB_DIR=lib
mv lib/* preserve
make -s realclean LIB_DIR=lib
done
%configure --with-driver=osmesa --with-osmesa-bits=32
make %{_smp_mflags} SRC_DIRS=mesa
mv lib osmesa32
make clean
echo "Building %{dri_target}"
make %{?_smp_mflags} %{dri_target} OPT_FLAGS="${OPT_FLAGS}" LIB_DIR=lib %{src_dirs}
# We shouldn't built this libglut, but just to make sure...
make -C progs/xdemos glxgears glxinfo OPT_FLAGS="${OPT_FLAGS}" LIB_DIR=lib
make -C progs/demos OPT_FLAGS="${OPT_FLAGS}" LIB_DIR=lib
mv preserve/* lib
ln -s libOSMesa.so.6 lib/libOSMesa.so
ln -s libOSMesa16.so.6 lib/libOSMesa16.so
ln -s libOSMesa32.so.6 lib/libOSMesa32.so
# just to be sure...
[ `find . -name \*.o | wc -l` -eq 0 ] || exit "make cleaner dammit"
pushd .
cd ../%{manpages}
# now build the rest of mesa
%configure \
--disable-glw \
--disable-glut \
--disable-gl-osmesa \
--with-driver=%{driver} \
--with-dri-driverdir=%{_libdir}/dri
make %{?_smp_mflags}
make -C progs/xdemos glxgears glxinfo
make %{?_smp_mflags} -C progs/demos
pushd ../%{manpages}
%configure
make %{?_smp_mflags}
popd
%install
rm -rf $RPM_BUILD_ROOT
# The mesa build system is broken beyond repair. The lines below just
# handpick and manually install the parts we want.
# core libs and headers, but not drivers.
make install DESTDIR=$RPM_BUILD_ROOT DRI_DIRS=
rm include/GL/glut*.h
install -d $RPM_BUILD_ROOT%{_includedir}/GL
install -m 644 include/GL/{gl,o,x}*.h $RPM_BUILD_ROOT%{_includedir}/GL
install -d $RPM_BUILD_ROOT%{_includedir}/GL/internal
install -m 644 include/GL/internal/dri_interface.h $RPM_BUILD_ROOT%{_includedir}/GL/internal
rm -f $RPM_BUILD_ROOT%{_includedir}/GL/glfbdev.h
# just the DRI drivers that are sane
%if %{with_dri}
install -d $RPM_BUILD_ROOT%{_libdir}/dri
for f in i810 i915 i965 mach64 mga r128 r200 r300 radeon savage sis tdfx unichrome; do
so=lib/${f}_dri.so
test -e $so && echo $so
done | xargs install -m 0755 -t $RPM_BUILD_ROOT%{_libdir}/dri >& /dev/null || :
%endif
install -d $RPM_BUILD_ROOT%{_libdir}
cp -d -f lib/lib* $RPM_BUILD_ROOT%{_libdir}
# strip out undesirable headers
pushd $RPM_BUILD_ROOT%{_includedir}/GL
rm [a-fh-np-wyz]*.h gg*.h glf*.h glut*.h
popd
# XXX demos, since they don't install automatically. should fix that.
install -d $RPM_BUILD_ROOT%{_bindir}
install -m 0755 progs/xdemos/glxgears $RPM_BUILD_ROOT%{_bindir}
install -m 0755 progs/xdemos/glxinfo $RPM_BUILD_ROOT%{_bindir}
find progs/demos/ -type f -perm /0111 |
xargs install -m 0755 -t $RPM_BUILD_ROOT/%{_bindir}
install -d $RPM_BUILD_ROOT/%{_libdir}/mesa-demos-data
install -m 0644 progs/images/*.rgb $RPM_BUILD_ROOT/%{_libdir}/mesa-demos-data
install -m 0644 progs/demos/*.dat $RPM_BUILD_ROOT/%{_libdir}/mesa-demos-data
%if %{with_dri}
install -d $RPM_BUILD_ROOT%{_libdir}/dri
for f in i810 i915 i915tex i965 mach64 mga r128 r200 r300 radeon savage sis tdfx unichrome; do
so=lib/${f}_dri.so
test -e $so && echo $so
done | xargs install -m 0755 -t $RPM_BUILD_ROOT%{_libdir}/dri >& /dev/null || :
%endif
# and osmesa
install -m 0755 -t $RPM_BUILD_ROOT%{_libdir} osmesa*/*.so.?
pushd $RPM_BUILD_ROOT%{_libdir}
for i in libOSMesa* ; do
ln -s $i $(basename $i .6)
done
popd
# Install man pages
pushd .
cd ../%{manpages}
make install DESTDIR=$RPM_BUILD_ROOT
# man pages
pushd ../%{manpages}
make %{?_smp_mflags} install DESTDIR=$RPM_BUILD_ROOT
popd
# Install the source needed to build the X server. The egreps are just
@ -284,11 +255,9 @@ mkdir -p $RPM_BUILD_ROOT/%{mesasourcedir}
xargs tar cf - --mode a=r |
(cd $RPM_BUILD_ROOT/%{mesasourcedir} && tar xf -)
%clean
rm -rf $RPM_BUILD_ROOT
%check
%post libGL -p /sbin/ldconfig
@ -302,7 +271,6 @@ rm -rf $RPM_BUILD_ROOT
%defattr(-,root,root,-)
%{_libdir}/libGL.so.1
%{_libdir}/libGL.so.1.2
%if %{with_dri}
%dir %{_libdir}/dri
%{_libdir}/dri/*_dri.so
@ -322,8 +290,9 @@ rm -rf $RPM_BUILD_ROOT
%dir %{_includedir}/GL/internal
%{_includedir}/GL/internal/dri_interface.h
%{_libdir}/libGL.so
%{_datadir}/man/man3/gl[^uX]*.3gl.gz
%{_datadir}/man/man3/glX*.3gl.gz
%{_libdir}/pkgconfig/gl.pc
%{_datadir}/man/man3/gl[^uX]*.3gl*
%{_datadir}/man/man3/glX*.3gl*
%files libGLU
%defattr(-,root,root,-)
@ -333,18 +302,16 @@ rm -rf $RPM_BUILD_ROOT
%files libGLU-devel
%defattr(-,root,root,-)
%{_libdir}/libGLU.so
%{_libdir}/pkgconfig/glu.pc
%{_includedir}/GL/glu.h
%{_includedir}/GL/glu_mangle.h
%{_datadir}/man/man3/glu*.3gl.gz
%{_datadir}/man/man3/glu*.3gl*
%files libOSMesa
%defattr(-,root,root,-)
%{_libdir}/libOSMesa.so.6
%{_libdir}/libOSMesa.so.6.5.3
%{_libdir}/libOSMesa16.so.6
%{_libdir}/libOSMesa16.so.6.5.3
%{_libdir}/libOSMesa32.so.6
%{_libdir}/libOSMesa32.so.6.5.3
%files libOSMesa-devel
%defattr(-,root,root,-)
@ -394,6 +361,7 @@ rm -rf $RPM_BUILD_ROOT
%{_bindir}/multiarb
%{_bindir}/paltex
%{_bindir}/pointblast
%{_bindir}/rain
%{_bindir}/ray
%{_bindir}/readpix
%{_bindir}/reflect
@ -419,6 +387,10 @@ rm -rf $RPM_BUILD_ROOT
%{_libdir}/mesa-demos-data
%changelog
* Fri Feb 15 2008 Adam Jackson <ajax@redhat.com> 7.1-0.11
- Today's git snapshot.
- Massive spec overhaul to use new buildsystem.
* Tue Feb 12 2008 Adam Jackson <ajax@redhat.com> 7.1-0.10
- mesa-7.1-sis-ia64.patch: Fix sis driver on ia64. (#432428)

View File

@ -1,2 +1,2 @@
6ae05158e678f4594343f32c2ca50515 gl-manpages-1.0.1.tar.bz2
f2b90e43026e39ddbc027848c1dff0f2 mesa-20071127.tar.bz2
fd86d11f88e1cb43057e87629ac36ab1 mesa-20080215.tar.bz2