mirror of
https://src.fedoraproject.org/rpms/mesa.git
synced 2024-11-28 02:54:51 +00:00
Fix build on PPC/PPC64
Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
This commit is contained in:
parent
7530e4cd03
commit
f95befaea6
6 changed files with 7 additions and 228 deletions
|
@ -1,6 +0,0 @@
|
|||
# Mom, Dad, if you're reading this, I'm very sorry.
|
||||
|
||||
include configs/linux-llvm.llvmcore
|
||||
|
||||
llvmcore:
|
||||
g++ -fPIC -shared -o libllvmcore-$(shell llvm-config --version).so -Wl,--whole-archive $(shell llvm-config --ldflags) $(LLVM_LIBS) -Wl,--no-whole-archive
|
|
@ -1,22 +0,0 @@
|
|||
#!/bin/sh
|
||||
|
||||
# Usage: ./make-git-snapshot.sh [COMMIT]
|
||||
#
|
||||
# to make a snapshot of the given tag/branch. Defaults to HEAD.
|
||||
# Point env var REF to a local mesa repo to reduce clone time.
|
||||
|
||||
DIRNAME=mesa-demos-$( date +%Y%m%d )
|
||||
|
||||
echo REF ${REF:+--reference $REF}
|
||||
echo DIRNAME $DIRNAME
|
||||
echo HEAD ${1:-HEAD}
|
||||
|
||||
rm -rf $DIRNAME
|
||||
|
||||
git clone ${REF:+--reference $REF} \
|
||||
git://git.freedesktop.org/git/mesa/demos $DIRNAME
|
||||
|
||||
GIT_DIR=$DIRNAME/.git git archive --format=tar --prefix=$DIRNAME/ ${1:-HEAD} \
|
||||
| bzip2 > $DIRNAME.tar.bz2
|
||||
|
||||
# rm -rf $DIRNAME
|
|
@ -1,101 +0,0 @@
|
|||
diff -up mesa-20091221/src/mesa/drivers/dri/Makefile.da mesa-20091221/src/mesa/drivers/dri/Makefile
|
||||
--- mesa-20091221/src/mesa/drivers/dri/Makefile.da 2009-12-21 08:09:11.000000000 +1000
|
||||
+++ mesa-20091221/src/mesa/drivers/dri/Makefile 2009-12-21 08:43:03.000000000 +1000
|
||||
@@ -6,12 +6,17 @@ include $(TOP)/configs/current
|
||||
|
||||
|
||||
|
||||
-default: $(TOP)/$(LIB_DIR) subdirs dri.pc
|
||||
+default: $(TOP)/$(LIB_DIR) $(TOP)/$(LIB_DIR)/libdricore.so subdirs dri.pc
|
||||
|
||||
|
||||
$(TOP)/$(LIB_DIR):
|
||||
-mkdir $(TOP)/$(LIB_DIR)
|
||||
|
||||
+libdricore.so:
|
||||
+ gcc -shared -o libdricore.so -Wl,--whole-archive ../../libmesa.a -Wl,--no-whole-archive -lm -lpthread -lc
|
||||
+
|
||||
+$(TOP)/$(LIB_DIR)/libdricore.so: $(TOP)/$(LIB_DIR) libdricore.so
|
||||
+ $(INSTALL) libdricore.so $(TOP)/$(LIB_DIR)
|
||||
|
||||
subdirs:
|
||||
@for dir in $(DRI_DIRS) ; do \
|
||||
@@ -32,12 +37,14 @@ dri.pc: dri.pc.in
|
||||
$(pcedit) $< > $@
|
||||
|
||||
|
||||
-install: dri.pc
|
||||
+install: dri.pc $(TOP)/$(LIB_DIR)/libdricore.so
|
||||
@for dir in $(DRI_DIRS) ; do \
|
||||
if [ -d $$dir ] ; then \
|
||||
(cd $$dir && $(MAKE) install) || exit 1 ; \
|
||||
fi \
|
||||
done
|
||||
+ $(INSTALL) -d $(DESTDIR)$(DRI_DRIVER_INSTALL_DIR)
|
||||
+ $(INSTALL) -m 755 $(TOP)/$(LIB_DIR)/libdricore.so $(DESTDIR)$(DRI_DRIVER_INSTALL_DIR)
|
||||
$(INSTALL) -d $(DESTDIR)$(INSTALL_INC_DIR)/GL/internal
|
||||
$(INSTALL) -m 0644 $(TOP)/include/GL/internal/dri_interface.h \
|
||||
$(DESTDIR)$(INSTALL_INC_DIR)/GL/internal
|
||||
@@ -51,5 +58,6 @@ clean:
|
||||
(cd $$dir && $(MAKE) clean) ; \
|
||||
fi \
|
||||
done
|
||||
+ -rm -f libdricore.so $(TOP)/$(LIB_DIR)/libdricore.so
|
||||
-rm -f common/*.o
|
||||
-rm -f *.pc
|
||||
diff -up mesa-20091221/src/mesa/drivers/dri/Makefile.template.da mesa-20091221/src/mesa/drivers/dri/Makefile.template
|
||||
--- mesa-20091221/src/mesa/drivers/dri/Makefile.template.da 2009-12-21 08:09:11.000000000 +1000
|
||||
+++ mesa-20091221/src/mesa/drivers/dri/Makefile.template 2009-12-21 08:43:40.000000000 +1000
|
||||
@@ -1,6 +1,6 @@
|
||||
# -*-makefile-*-
|
||||
|
||||
-MESA_MODULES = $(TOP)/src/mesa/libmesa.a
|
||||
+MESA_MODULES = $(TOP)/$(LIB_DIR)/libdricore.so
|
||||
|
||||
COMMON_GALLIUM_SOURCES = \
|
||||
../common/utils.c \
|
||||
@@ -70,7 +70,8 @@ lib: symlinks subdirs depend
|
||||
$(LIBNAME): $(OBJECTS) $(MESA_MODULES) $(EXTRA_MODULES) $(WINOBJ) Makefile \
|
||||
$(TOP)/src/mesa/drivers/dri/Makefile.template
|
||||
$(MKLIB) -o $@ -noprefix -linker '$(CC)' -ldflags '$(LDFLAGS)' \
|
||||
- $(OBJECTS) $(MESA_MODULES) $(EXTRA_MODULES) $(WINOBJ) \
|
||||
+ $(OBJECTS) $(EXTRA_MODULES) $(WINOBJ) \
|
||||
+ -L$(TOP)/$(LIB_DIR) -Wl,-R$(DRI_DRIVER_INSTALL_DIR) -ldricore \
|
||||
$(DRI_LIB_DEPS)
|
||||
|
||||
|
||||
diff -up mesa-20091221/src/mesa/x86/read_rgba_span_x86.S.da mesa-20091221/src/mesa/x86/read_rgba_span_x86.S
|
||||
--- mesa-20091221/src/mesa/x86/read_rgba_span_x86.S.da 2009-12-21 08:09:11.000000000 +1000
|
||||
+++ mesa-20091221/src/mesa/x86/read_rgba_span_x86.S 2009-12-21 08:43:03.000000000 +1000
|
||||
@@ -77,7 +77,6 @@
|
||||
*/
|
||||
|
||||
.globl _generic_read_RGBA_span_BGRA8888_REV_MMX
|
||||
-.hidden _generic_read_RGBA_span_BGRA8888_REV_MMX
|
||||
.type _generic_read_RGBA_span_BGRA8888_REV_MMX, @function
|
||||
_generic_read_RGBA_span_BGRA8888_REV_MMX:
|
||||
pushl %ebx
|
||||
@@ -172,7 +171,6 @@ _generic_read_RGBA_span_BGRA8888_REV_MMX
|
||||
*/
|
||||
|
||||
.globl _generic_read_RGBA_span_BGRA8888_REV_SSE
|
||||
-.hidden _generic_read_RGBA_span_BGRA8888_REV_SSE
|
||||
.type _generic_read_RGBA_span_BGRA8888_REV_SSE, @function
|
||||
_generic_read_RGBA_span_BGRA8888_REV_SSE:
|
||||
pushl %esi
|
||||
@@ -335,7 +333,6 @@ _generic_read_RGBA_span_BGRA8888_REV_SSE
|
||||
|
||||
.text
|
||||
.globl _generic_read_RGBA_span_BGRA8888_REV_SSE2
|
||||
-.hidden _generic_read_RGBA_span_BGRA8888_REV_SSE2
|
||||
.type _generic_read_RGBA_span_BGRA8888_REV_SSE2, @function
|
||||
_generic_read_RGBA_span_BGRA8888_REV_SSE2:
|
||||
pushl %esi
|
||||
@@ -494,7 +491,6 @@ _generic_read_RGBA_span_BGRA8888_REV_SSE
|
||||
|
||||
.text
|
||||
.globl _generic_read_RGBA_span_RGB565_MMX
|
||||
- .hidden _generic_read_RGBA_span_RGB565_MMX
|
||||
.type _generic_read_RGBA_span_RGB565_MMX, @function
|
||||
|
||||
_generic_read_RGBA_span_RGB565_MMX:
|
|
@ -1,96 +0,0 @@
|
|||
From 9882bff4ce5843b4122a0348acecc7523b9aee22 Mon Sep 17 00:00:00 2001
|
||||
From: Dave Airlie <airlied@redhat.com>
|
||||
Date: Tue, 12 Apr 2011 21:20:48 +1000
|
||||
Subject: [PATCH] nouveau_vieux: fix build since sampler objects merge
|
||||
|
||||
---
|
||||
src/mesa/drivers/dri/nouveau/nv04_state_tex.c | 8 ++++----
|
||||
src/mesa/drivers/dri/nouveau/nv10_state_tex.c | 8 ++++----
|
||||
src/mesa/drivers/dri/nouveau/nv20_state_tex.c | 8 ++++----
|
||||
3 files changed, 12 insertions(+), 12 deletions(-)
|
||||
|
||||
diff --git a/src/mesa/drivers/dri/nouveau/nv04_state_tex.c b/src/mesa/drivers/dri/nouveau/nv04_state_tex.c
|
||||
index 6c96e58..648d6b1 100644
|
||||
--- a/src/mesa/drivers/dri/nouveau/nv04_state_tex.c
|
||||
+++ b/src/mesa/drivers/dri/nouveau/nv04_state_tex.c
|
||||
@@ -82,11 +82,11 @@ nv04_emit_tex_obj(struct gl_context *ctx, int emit)
|
||||
|
||||
if (t->Sampler.MinFilter != GL_NEAREST &&
|
||||
t->Sampler.MinFilter != GL_LINEAR) {
|
||||
- lod_max = CLAMP(MIN2(t->MaxLod, t->_MaxLambda),
|
||||
+ lod_max = CLAMP(MIN2(t->Sampler.MaxLod, t->_MaxLambda),
|
||||
0, 15) + 1;
|
||||
|
||||
lod_bias = CLAMP(ctx->Texture.Unit[i].LodBias +
|
||||
- t->LodBias, -16, 15) * 8;
|
||||
+ t->Sampler.LodBias, -16, 15) * 8;
|
||||
}
|
||||
|
||||
format |= nvgl_wrap_mode(t->Sampler.WrapT) << 28 |
|
||||
@@ -96,9 +96,9 @@ nv04_emit_tex_obj(struct gl_context *ctx, int emit)
|
||||
lod_max << 12 |
|
||||
get_tex_format(ti);
|
||||
|
||||
- filter |= log2i(t->MaxAnisotropy) << 31 |
|
||||
+ filter |= log2i(t->Sampler.MaxAnisotropy) << 31 |
|
||||
nvgl_filter_mode(t->Sampler.MagFilter) << 28 |
|
||||
- log2i(t->MaxAnisotropy) << 27 |
|
||||
+ log2i(t->Sampler.MaxAnisotropy) << 27 |
|
||||
nvgl_filter_mode(t->Sampler.MinFilter) << 24 |
|
||||
(lod_bias & 0xff) << 16;
|
||||
|
||||
diff --git a/src/mesa/drivers/dri/nouveau/nv10_state_tex.c b/src/mesa/drivers/dri/nouveau/nv10_state_tex.c
|
||||
index 1d98b19..620a686 100644
|
||||
--- a/src/mesa/drivers/dri/nouveau/nv10_state_tex.c
|
||||
+++ b/src/mesa/drivers/dri/nouveau/nv10_state_tex.c
|
||||
@@ -183,7 +183,7 @@ nv10_emit_tex_obj(struct gl_context *ctx, int emit)
|
||||
| nvgl_filter_mode(t->Sampler.MinFilter) << 24;
|
||||
|
||||
tx_enable = NV10_3D_TEX_ENABLE_ENABLE
|
||||
- | log2i(t->MaxAnisotropy) << 4;
|
||||
+ | log2i(t->Sampler.MaxAnisotropy) << 4;
|
||||
|
||||
if (t->Target == GL_TEXTURE_RECTANGLE) {
|
||||
BEGIN_RING(chan, celsius, NV10_3D_TEX_NPOT_PITCH(i), 1);
|
||||
@@ -198,9 +198,9 @@ nv10_emit_tex_obj(struct gl_context *ctx, int emit)
|
||||
|
||||
if (t->Sampler.MinFilter != GL_NEAREST &&
|
||||
t->Sampler.MinFilter != GL_LINEAR) {
|
||||
- int lod_min = t->MinLod;
|
||||
- int lod_max = MIN2(t->MaxLod, t->_MaxLambda);
|
||||
- int lod_bias = t->LodBias
|
||||
+ int lod_min = t->Sampler.MinLod;
|
||||
+ int lod_max = MIN2(t->Sampler.MaxLod, t->_MaxLambda);
|
||||
+ int lod_bias = t->Sampler.LodBias
|
||||
+ ctx->Texture.Unit[i].LodBias;
|
||||
|
||||
lod_max = CLAMP(lod_max, 0, 15);
|
||||
diff --git a/src/mesa/drivers/dri/nouveau/nv20_state_tex.c b/src/mesa/drivers/dri/nouveau/nv20_state_tex.c
|
||||
index fdbfdf4..eab74ae 100644
|
||||
--- a/src/mesa/drivers/dri/nouveau/nv20_state_tex.c
|
||||
+++ b/src/mesa/drivers/dri/nouveau/nv20_state_tex.c
|
||||
@@ -195,7 +195,7 @@ nv20_emit_tex_obj(struct gl_context *ctx, int emit)
|
||||
| 2 << 12;
|
||||
|
||||
tx_enable = NV20_3D_TEX_ENABLE_ENABLE
|
||||
- | log2i(t->MaxAnisotropy) << 4;
|
||||
+ | log2i(t->Sampler.MaxAnisotropy) << 4;
|
||||
|
||||
if (t->Target == GL_TEXTURE_RECTANGLE) {
|
||||
BEGIN_RING(chan, kelvin, NV20_3D_TEX_NPOT_PITCH(i), 1);
|
||||
@@ -210,9 +210,9 @@ nv20_emit_tex_obj(struct gl_context *ctx, int emit)
|
||||
|
||||
if (t->Sampler.MinFilter != GL_NEAREST &&
|
||||
t->Sampler.MinFilter != GL_LINEAR) {
|
||||
- int lod_min = t->MinLod;
|
||||
- int lod_max = MIN2(t->MaxLod, t->_MaxLambda);
|
||||
- int lod_bias = t->LodBias
|
||||
+ int lod_min = t->Sampler.MinLod;
|
||||
+ int lod_max = MIN2(t->Sampler.MaxLod, t->_MaxLambda);
|
||||
+ int lod_bias = t->Sampler.LodBias
|
||||
+ ctx->Texture.Unit[i].LodBias;
|
||||
|
||||
lod_max = CLAMP(lod_max, 0, 15);
|
||||
--
|
||||
1.7.4.2
|
||||
|
|
@ -15,7 +15,7 @@
|
|||
Summary: Mesa graphics libraries
|
||||
Name: mesa
|
||||
Version: 7.11
|
||||
Release: 0.15.%{gitdate}.0%{?dist}
|
||||
Release: 0.16.%{gitdate}.0%{?dist}
|
||||
License: MIT
|
||||
Group: System Environment/Libraries
|
||||
URL: http://www.mesa3d.org
|
||||
|
@ -360,12 +360,14 @@ rm -rf $RPM_BUILD_ROOT
|
|||
%endif
|
||||
%{_libdir}/dri/r128_dri.so
|
||||
%ifnarch %{sparc}
|
||||
%ifnarch ppc ppc64
|
||||
# we no much hardware....
|
||||
%{_libdir}/dri/mga_dri.so
|
||||
%{_libdir}/dri/savage_dri.so
|
||||
%{_libdir}/dri/tdfx_dri.so
|
||||
%{_libdir}/dri/unichrome_dri.so
|
||||
%endif
|
||||
%{_libdir}/dri/tdfx_dri.so
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%files libGL-devel
|
||||
|
@ -438,6 +440,9 @@ rm -rf $RPM_BUILD_ROOT
|
|||
%{_libdir}/pkgconfig/osmesa.pc
|
||||
|
||||
%changelog
|
||||
* Thu Jul 07 2011 Peter Lemenkov <lemenkov@gmail.com> - 7.11-0.16.20110620.0
|
||||
- Fix building on ppc (some dri1 drivers are missing)
|
||||
|
||||
* Wed Jul 6 2011 Ville Skyttä <ville.skytta@iki.fi> - 7.11-0.15.20110620.0
|
||||
- More include dir ownership fixes (#682357).
|
||||
|
||||
|
|
1
sources
1
sources
|
@ -1,3 +1,2 @@
|
|||
6ae05158e678f4594343f32c2ca50515 gl-manpages-1.0.1.tar.bz2
|
||||
b8a15e6f9892d004c3407d6a0659fb5b mesa-20110412.tar.xz
|
||||
ee6c00d4c596e4a9dee0cb9599054b81 mesa-20110620.tar.xz
|
||||
|
|
Loading…
Reference in a new issue