summaryrefslogtreecommitdiffstats
path: root/package/xorg
diff options
context:
space:
mode:
Diffstat (limited to 'package/xorg')
-rw-r--r--package/xorg/fontfile.patch11
-rw-r--r--package/xorg/freetype.patch22
-rw-r--r--package/xorg/xorg-config.patch37
-rw-r--r--package/xorg/xorg-x11-6.8.2-gcc4-fix.patch148
-rw-r--r--package/xorg/xorg.mk10
5 files changed, 223 insertions, 5 deletions
diff --git a/package/xorg/fontfile.patch b/package/xorg/fontfile.patch
new file mode 100644
index 000000000..ed39bf45d
--- /dev/null
+++ b/package/xorg/fontfile.patch
@@ -0,0 +1,11 @@
+--- xc/lib/font/fontfile/Imakefile.old 2005-06-03 20:09:53.000000000 +0100
++++ xc/lib/font/fontfile/Imakefile 2005-06-03 20:09:57.000000000 +0100
+@@ -14,7 +14,7 @@
+ #endif
+
+ INCLUDES = -I$(FONTINCSRC) -I../include -I$(SERVERSRC)/include \
+- -I$(INCLUDESRC)
++ -I$(INCLUDESRC) $(CC_STAGING)
+ HEADERS =
+ #ifdef FontFormatDefines
+ FORMAT_DEFS = FontFormatDefines
diff --git a/package/xorg/freetype.patch b/package/xorg/freetype.patch
new file mode 100644
index 000000000..0ba3dd562
--- /dev/null
+++ b/package/xorg/freetype.patch
@@ -0,0 +1,22 @@
+--- xc/lib/font/FreeType/Imakefile.old 2005-06-03 20:18:51.000000000 +0100
++++ xc/lib/font/FreeType/Imakefile 2005-06-03 20:18:52.000000000 +0100
+@@ -20,7 +20,7 @@
+
+ INCLUDES = $(FT2INCS) -I. -I$(FONTINCSRC) -I../include -I$(XINCLUDESRC) \
+ -I$(SERVERSRC)/include $(EXTRAINCLUDES) \
+- -I$(INCLUDESRC)
++ -I$(INCLUDESRC) $(CC_STAGING)
+
+ SRCS = xttcap.c ftfuncs.c ftenc.c fttools.c
+ OBJS = xttcap.o ftfuncs.o ftenc.o fttools.o
+--- xc/config/cf/X11.tmpl.old 2005-06-03 20:40:24.000000000 +0100
++++ xc/config/cf/X11.tmpl 2005-06-03 20:40:40.000000000 +0100
+@@ -3371,7 +3371,7 @@
+
+ #if BuildFreetype2Library || HasFreetype2
+ #if Freetype2IncDirStandard
+-FREETYPE2INCLUDES = -I$(FREETYPE2INCDIR)/freetype2 -I$(FREETYPE2INCDIR)/freetype2/config
++FREETYPE2INCLUDES = `pkg-config --cflags freetype2`
+ #else
+ FREETYPE2INCLUDES = -I$(FREETYPE2INCDIR) -I$(FREETYPE2INCDIR)/freetype2 -I$(FREETYPE2INCDIR)/freetype2/config
+ #endif
diff --git a/package/xorg/xorg-config.patch b/package/xorg/xorg-config.patch
index b5a4b2353..ea051c589 100644
--- a/package/xorg/xorg-config.patch
+++ b/package/xorg/xorg-config.patch
@@ -1,6 +1,6 @@
--- xc/config/cf/host.def~ Thu May 12 15:28:01 MDT 2005
+++ xc/config/cf/host.def Thu May 12 15:28:01 MDT 2005
-@@ -0,0 +1,38 @@
+@@ -0,0 +1,42 @@
+#define KDriveXServer YES
+#define TinyXServer YES
+#define XfbdevServer YES
@@ -13,6 +13,10 @@
+#define HasFontconfig NO
+#define HasLibpng YES
+#define HasZlib YES
++#define HaveLib64 NO
++#define LibDirName lib
++#define SystemUsrLibDir /usr/lib
++#define TkLibDir /usr/lib
+
+#define HasExpat NO
+#define XprtServer NO
@@ -105,3 +109,34 @@
#define HostCcCmd cc
-#endif
#include <cross.rules>
+--- xc/include/Xfuncs.h.orig 2006-07-07 17:09:16.000000000 -0600
++++ xc/include/Xfuncs.h 2006-07-07 17:11:33.000000000 -0600
+@@ -44,18 +44,28 @@
+ #if defined(SYSV) && !defined(SCO325) && !defined(sun)
+ #include <memory.h>
+ void bcopy();
++#ifndef bzero
+ #define bzero(b,len) memset(b, 0, len)
++#endif
++#ifndef bcmp
+ #define bcmp(b1,b2,len) memcmp(b1, b2, len)
++#endif
+ #else
+ #include <string.h>
+ #if defined(SCO325) || defined(sun)
+ #include <strings.h>
+ #endif
+ #define _XFUNCS_H_INCLUDED_STRING_H
++#ifndef bcopy
+ #define bcopy(b1,b2,len) memmove(b2, b1, (size_t)(len))
++#endif
++#ifndef bzero
+ #define bzero(b,len) memset(b, 0, (size_t)(len))
++#endif
++#ifndef bcmp
+ #define bcmp(b1,b2,len) memcmp(b1, b2, (size_t)(len))
+ #endif
++#endif
+ #endif /* X_USEBFUNCS */
+
+ /* the new Xfuncs.h */
diff --git a/package/xorg/xorg-x11-6.8.2-gcc4-fix.patch b/package/xorg/xorg-x11-6.8.2-gcc4-fix.patch
new file mode 100644
index 000000000..6062dba7f
--- /dev/null
+++ b/package/xorg/xorg-x11-6.8.2-gcc4-fix.patch
@@ -0,0 +1,148 @@
+--- xc/programs/Xserver/fb/fbmmx.c.orig 2005-03-01 19:01:35.401903000 -0500
++++ xc/programs/Xserver/fb/fbmmx.c 2005-03-01 19:01:39.330305792 -0500
+@@ -29,6 +29,8 @@
+
+ #ifdef RENDER
+
++#include <mmintrin.h>
++
+ #include "picturestr.h"
+ #include "mipict.h"
+ #include "fbpict.h"
+@@ -48,6 +50,10 @@
+ #define CHECKPOINT()
+ #endif
+
++#define mmx_and(a,b) ((Vector1x64)_mm_and_si64((__m64)(a),(__m64)(b)))
++#define mmx_or(a,b) ((Vector1x64)_mm_or_si64((__m64)(a),(__m64)(b)))
++#define mmx_xor(a,b) ((Vector1x64)_mm_xor_si64((__m64)(a),(__m64)(b)))
++
+ typedef struct
+ {
+ ullong mmx_zero;
+@@ -102,7 +108,7 @@
+ static __inline__ Vector4x16
+ negate (Vector4x16 mask)
+ {
+- return (Vector4x16)__builtin_ia32_pxor (
++ return (Vector4x16)mmx_xor (
+ (Vector1x64)mask,
+ (Vector1x64)c.mmx_4x00ff);
+ }
+@@ -163,9 +169,9 @@
+
+ t1 = shift ((Vector1x64)pixel, -48);
+ t2 = shift (t1, 16);
+- t1 = __builtin_ia32_por (t1, t2);
++ t1 = mmx_or (t1, t2);
+ t2 = shift (t1, 32);
+- t1 = __builtin_ia32_por (t1, t2);
++ t1 = mmx_or (t1, t2);
+
+ return (Vector4x16)t1;
+ }
+@@ -178,9 +184,9 @@
+ t1 = shift ((Vector1x64)pixel, 48);
+ t1 = shift (t1, -48);
+ t2 = shift (t1, 16);
+- t1 = __builtin_ia32_por (t1, t2);
++ t1 = mmx_or (t1, t2);
+ t2 = shift (t1, 32);
+- t1 = __builtin_ia32_por (t1, t2);
++ t1 = mmx_or (t1, t2);
+
+ return (Vector4x16)t1;
+ }
+@@ -192,15 +198,15 @@
+
+ x = y = z = (Vector1x64)pixel;
+
+- x = __builtin_ia32_pand (x, (Vector1x64)c.mmx_ffff0000ffff0000);
+- y = __builtin_ia32_pand (y, (Vector1x64)c.mmx_000000000000ffff);
+- z = __builtin_ia32_pand (z, (Vector1x64)c.mmx_0000ffff00000000);
++ x = mmx_and (x, (Vector1x64)c.mmx_ffff0000ffff0000);
++ y = mmx_and (y, (Vector1x64)c.mmx_000000000000ffff);
++ z = mmx_and (z, (Vector1x64)c.mmx_0000ffff00000000);
+
+ y = shift (y, 32);
+ z = shift (z, -32);
+
+- x = __builtin_ia32_por (x, y);
+- x = __builtin_ia32_por (x, z);
++ x = mmx_or (x, y);
++ x = mmx_or (x, z);
+
+ return (Vector4x16)x;
+ }
+@@ -234,7 +240,7 @@
+ over_rev_non_pre (Vector4x16 src, Vector4x16 dest)
+ {
+ Vector4x16 srca = expand_alpha (src);
+- Vector4x16 srcfaaa = (Vector4x16)__builtin_ia32_por((Vector1x64)srca, (Vector1x64)c.mmx_full_alpha);
++ Vector4x16 srcfaaa = (Vector4x16)mmx_or((Vector1x64)srca, (Vector1x64)c.mmx_full_alpha);
+
+ return over(pix_multiply(invert_colors(src), srcfaaa), srca, dest);
+ }
+@@ -300,9 +306,9 @@
+ Vector1x64 t1 = shift (p, 36 - 11);
+ Vector1x64 t2 = shift (p, 16 - 5);
+
+- p = __builtin_ia32_por (t1, p);
+- p = __builtin_ia32_por (t2, p);
+- p = __builtin_ia32_pand (p, (Vector1x64)c.mmx_565_rgb);
++ p = mmx_or (t1, p);
++ p = mmx_or (t2, p);
++ p = mmx_and (p, (Vector1x64)c.mmx_565_rgb);
+
+ pixel = __builtin_ia32_pmullw ((Vector4x16)p, (Vector4x16)c.mmx_565_unpack_multiplier);
+ return __builtin_ia32_psrlw (pixel, 8);
+@@ -324,27 +330,27 @@
+ Vector1x64 t = (Vector1x64)target;
+ Vector1x64 r, g, b;
+
+- r = __builtin_ia32_pand (p, (Vector1x64)c.mmx_565_r);
+- g = __builtin_ia32_pand (p, (Vector1x64)c.mmx_565_g);
+- b = __builtin_ia32_pand (p, (Vector1x64)c.mmx_565_b);
++ r = mmx_and (p, (Vector1x64)c.mmx_565_r);
++ g = mmx_and (p, (Vector1x64)c.mmx_565_g);
++ b = mmx_and (p, (Vector1x64)c.mmx_565_b);
+
+ r = shift (r, - (32 - 8) + pos * 16);
+ g = shift (g, - (16 - 3) + pos * 16);
+ b = shift (b, - (0 + 3) + pos * 16);
+
+ if (pos == 0)
+- t = __builtin_ia32_pand (t, (Vector1x64)c.mmx_mask_0);
++ t = mmx_and (t, (Vector1x64)c.mmx_mask_0);
+ else if (pos == 1)
+- t = __builtin_ia32_pand (t, (Vector1x64)c.mmx_mask_1);
++ t = mmx_and (t, (Vector1x64)c.mmx_mask_1);
+ else if (pos == 2)
+- t = __builtin_ia32_pand (t, (Vector1x64)c.mmx_mask_2);
++ t = mmx_and (t, (Vector1x64)c.mmx_mask_2);
+ else if (pos == 3)
+- t = __builtin_ia32_pand (t, (Vector1x64)c.mmx_mask_3);
++ t = mmx_and (t, (Vector1x64)c.mmx_mask_3);
+
+- p = __builtin_ia32_por (r, t);
+- p = __builtin_ia32_por (g, p);
++ p = mmx_or (r, t);
++ p = mmx_or (g, p);
+
+- return (Vector4x16)__builtin_ia32_por (b, p);
++ return (Vector4x16)mmx_or (b, p);
+ }
+
+ static __inline__ void
+--- xc/programs/Xserver/hw/xfree86/drivers/ati/radeon_probe.h.orig 2006-07-07 17:38:25.000000000 -0600
++++ xc/programs/Xserver/hw/xfree86/drivers/ati/radeon_probe.h 2006-07-07 17:38:34.000000000 -0600
+@@ -146,9 +146,6 @@
+ extern Bool RADEONProbe
+ FunctionPrototype((DriverPtr, int));
+
+-extern SymTabRec RADEONChipsets[];
+-extern PciChipsets RADEONPciChipsets[];
+-
+ /* radeon_driver.c */
+ extern void RADEONLoaderRefSymLists
+ FunctionPrototype((void));
diff --git a/package/xorg/xorg.mk b/package/xorg/xorg.mk
index 7d98b0e87..46220eb58 100644
--- a/package/xorg/xorg.mk
+++ b/package/xorg/xorg.mk
@@ -51,7 +51,7 @@ $(DL_DIR)/$(XORG_SOURCE):
$(XORG_DIR)/.configure: $(DL_DIR)/$(XORG_SOURCE)
$(XORG_CAT) $(DL_DIR)/$(XORG_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
- toolchain/patch-kernel.sh $(XORG_DIR) package/xorg/ xorg\*.patch
+ toolchain/patch-kernel.sh $(XORG_DIR) package/xorg/ \*.patch
$(SED) 's:REPLACE_STAGING_DIR:$(STAGING_DIR):g' $(XORG_HOST_DEF)
$(SED) 's:REPLACE_HAS_FREETYPE2:$(HAS_FREETYPE2):g' $(XORG_HOST_DEF)
$(SED) 's:REPLACE_GCCINC_DIR:$(shell $(TARGET_CROSS)gcc -print-file-name=include):g' $(XORG_CF)
@@ -67,7 +67,9 @@ $(XORG_DIR)/.configure: $(DL_DIR)/$(XORG_SOURCE)
$(XORG_XSERVER): $(XORG_DIR)/.configure
rm -f $(TARGET_XSERVER) $(XORG_XSERVER)
- ( cd $(XORG_DIR) ; $(MAKE) World XCURSORGEN=xcursorgen MKFONTSCALE=mkfontscale )
+ ( cd $(XORG_DIR) ; $(MAKE) \
+ PKG_CONFIG=$(STAGING_DIR)/$(PKGCONFIG_TARGET_BINARY) \
+ World XCURSORGEN=xcursorgen MKFONTSCALE=mkfontscale )
$(TARGET_XSERVER): $(XORG_XSERVER)
-mkdir -p $(XORG_BINX)
@@ -81,10 +83,10 @@ $(TARGET_XSERVER): $(XORG_XSERVER)
$(STRIP) $(TARGET_XSERVER)
mkdir -p $(XORG_LIBX)/modules
cp -LRf $(XORG_DIR)/exports/lib/modules/ $(XORG_LIBX)/
- ( cd $(XORG_DIR)/fonts ; $(MAKE) DESTDIR=$(TARGET_DIR) install XCURSORGEN=xcursorgen MKFONTSCALE=mkfontscale )
+ ( cd $(XORG_DIR)/fonts ; $(MAKE) \
+ DESTDIR=$(TARGET_DIR) install XCURSORGEN=xcursorgen MKFONTSCALE=mkfontscale )
cp -LRf $(XORG_DIR)/fonts/bdf/misc/*.bdf $(XORG_LIBX)/X11/fonts/misc/
( cd $(XORG_LIBX)/X11/fonts/misc/; mkfontdir )
- #( cd $(XORG_DIR) ; $(MAKE) DESTDIR=$(TARGET_DIR) install XCURSORGEN=xcursorgen MKFONTSCALE=mkfontscale )
(cd $(TARGET_DIR)/usr/bin; ln -snf $(TARGET_BINX) X11)
$(XORG_LIBX)/libX11.so.6.2: $(XORG_XSERVER)