]> git.pld-linux.org Git - packages/Glide_VG.git/blame - Glide_VG-morearchs.patch
- pass AR to remove 'l' option, which changed meaning
[packages/Glide_VG.git] / Glide_VG-morearchs.patch
CommitLineData
f30267f3
JB
1--- Glide_VG-2.46/sst1/init/initvg/sst1init.h.orig 1999-11-29 20:48:02.000000000 +0100
2+++ Glide_VG-2.46/sst1/init/initvg/sst1init.h 2004-01-18 11:13:11.026782482 +0100
3@@ -156,14 +156,24 @@
4
5 #define P6FENCE {_asm xchg eax, p6FenceVar}
6
7-#elif defined(__GNUC__)
8-#if defined(__i386__)
9+#elif defined(__GNUC__) && defined(__i386__)
10 #define P6FENCE asm("xchg %%eax,%0" \
11 : /* no outputs */ \
12 : "m" (p6FenceVar) \
13 : "eax" \
14 );
15-#endif
16+#elif defined(__ia64__)
17+#define P6FENCE asm volatile ("mf.a" ::: "memory");
18+#elif defined(__alpha__)
19+# define P6FENCE asm volatile("mb" ::: "memory");
20+#elif defined(__powerpc__)
21+# define P6FENCE asm volatile ("sync" ::: "memory");
22+#elif defined (__x86_64__)
23+# define P6FENCE asm volatile("mfence" ::: "memory");
24+#elif defined(__sparc64__)
25+# define P6FENCE asm volatile("membar #LoadLoad | #LoadStore | #StoreStore | #StoreLoad" ::: "memory");
26+#elif defined(__sparc__)
27+# define P6FENCE asm volatile("" ::: "memory");
28 #else
29 #error "P6 Fencing in-line assembler code needs to be added for this compiler"
30 #endif
31--- Glide_VG-2.46/swlibs/fxpci/pcilib/fxpci.c.orig 1999-11-29 20:48:02.000000000 +0100
32+++ Glide_VG-2.46/swlibs/fxpci/pcilib/fxpci.c 2004-01-18 11:00:53.731282699 +0100
33@@ -31,7 +31,6 @@
34 #include <fxdll.h>
35 #include "fxpci.h"
36 #ifdef __linux__
37-#include <asm/io.h>
38 #include "fxlinux.h"
39 #else
40 #include <fxmemmap.h>
41--- Glide_VG-2.46/swlibs/fxpci/pcilib/fxlinux.c.orig 1999-11-29 20:48:02.000000000 +0100
42+++ Glide_VG-2.46/swlibs/fxpci/pcilib/fxlinux.c 2004-01-18 11:04:05.617826712 +0100
43@@ -26,7 +26,17 @@
44 #include <sys/stat.h>
45 #include <sys/mman.h>
46 #include <sys/ioctl.h>
47-#include <asm/io.h>
48+#if defined(__powerpc__) || defined(__sparc__)
49+#define iopl(X) (-1)
50+#define inb(P) 0
51+#define inw(P) 0
52+#define inl(P) 0
53+#define outb(D,P)
54+#define outw(D,P)
55+#define outl(D,P)
56+#else
57+#include <sys/io.h>
58+#endif
59 #include <fcntl.h>
60 #include "fxpci.h"
61 #include "pcilib.h"
62--- Glide_VG-2.46/sst1/glide/src/cpudetect.c.orig 1999-11-29 20:48:01.000000000 +0100
63+++ Glide_VG-2.46/sst1/glide/src/cpudetect.c 2004-01-18 11:21:11.005578980 +0100
64@@ -22,6 +22,7 @@
65 #include <stdio.h>
66
67 int _cpu_detect_asm() {
68+#ifdef __i386__
69 struct utsname name;
70
71 uname(&name);
72@@ -31,17 +32,24 @@
73 if (!strcmp(name.machine, "i686")) return 6;
74 fprintf(stderr, "Couldn't determine cpu type. Using i586\n");
75 return 5;
76+#else
77+ return 0;
78+#endif
79 }
80
81 void single_precision_asm() {
82+#ifdef __i386__
83 asm("push %eax \n fnclex \n fstcw (%esp) \n movl (%esp), %eax \n "
84 "and $0x0000fcff, %eax \n movl %eax, (%esp) \n fldcw (%esp) \n pop %eax");
85+#endif
86 }
87
88
89 void double_precision_asm() {
7441da6e
JB
90- asm("push %eax \n fnclex \n fstcw (%esp) \n movw (%esp), %eax \n "
91- "and $0x0000fcff, %eax \n or $0x000002ff, %eax \n mov %eax, (%esp) \n "
f30267f3 92+#ifdef __i386__
7441da6e
JB
93+ asm("push %eax \n fnclex \n fstcw (%esp) \n movl (%esp), %eax \n "
94+ "and $0x0000fcff, %eax \n or $0x000002ff, %eax \n movl %eax, (%esp) \n "
f30267f3
JB
95 "fldcw (%esp) \n pop %eax");
96+#endif
97 }
98
This page took 0.089911 seconds and 4 git commands to generate.