r484 - in trunk: code/qcommon code/tools/lcc/cpp code/unix web/include

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Sun Jan 15 10:22:13 EST 2006


Author: tma
Date: 2006-01-15 10:22:13 -0500 (Sun, 15 Jan 2006)
New Revision: 484

Modified:
   trunk/code/qcommon/vm_x86.c
   trunk/code/tools/lcc/cpp/unix.c
   trunk/code/unix/ftola.s
   trunk/code/unix/qasm.h
   trunk/code/unix/snapvectora.s
   trunk/web/include/status.php
Log:
* x86 OS X support


Modified: trunk/code/qcommon/vm_x86.c
===================================================================
--- trunk/code/qcommon/vm_x86.c	2006-01-14 09:16:16 UTC (rev 483)
+++ trunk/code/qcommon/vm_x86.c	2006-01-15 15:22:13 UTC (rev 484)
@@ -170,7 +170,7 @@
 
 #else //!_MSC_VER
 
-#ifdef __MINGW32__ // _ is prepended to compiled symbols
+#if defined(__MINGW32__) || defined(MACOS_X) // _ is prepended to compiled symbols
 #define CMANG(sym) "_"#sym
 #else
 #define CMANG(sym) #sym
@@ -1174,13 +1174,13 @@
 		memOpStack      = opStack;     
 		memEntryPoint   = entryPoint;  
 		
-		__asm__("	pushal				\r\n" \
-				"	movl %0,%%esi		\r\n" \
-				"	movl %1,%%edi		\r\n" \
-				"	call *%2			\r\n" \
-				"	movl %%esi,%0		\r\n" \
-				"	movl %%edi,%1		\r\n" \
-				"	popal				\r\n" \
+		__asm__("	pushal				\n" \
+				"	movl %0,%%esi		\n" \
+				"	movl %1,%%edi		\n" \
+				"	call *%2			\n" \
+				"	movl %%esi,%0		\n" \
+				"	movl %%edi,%1		\n" \
+				"	popal				\n" \
 				: "=m" (memProgramStack), "=m" (memOpStack) \
 				: "m" (memEntryPoint), "m" (memProgramStack), "m" (memOpStack) \
 				: "si", "di" \

Modified: trunk/code/tools/lcc/cpp/unix.c
===================================================================
--- trunk/code/tools/lcc/cpp/unix.c	2006-01-14 09:16:16 UTC (rev 483)
+++ trunk/code/tools/lcc/cpp/unix.c	2006-01-15 15:22:13 UTC (rev 484)
@@ -93,6 +93,7 @@
 /* memmove is defined here because some vendors don't provide it at
    all and others do a terrible job (like calling malloc) */
 // -- ouch, that hurts -- ln
+#ifndef MACOS_X   /* always use the system memmove() on Mac OS X. --ryan. */
 #ifdef memmove
 #undef memmove
 #endif
@@ -118,3 +119,4 @@
 	}
 	return 0;
 }
+#endif

Modified: trunk/code/unix/ftola.s
===================================================================
--- trunk/code/unix/ftola.s	2006-01-14 09:16:16 UTC (rev 483)
+++ trunk/code/unix/ftola.s	2006-01-15 15:22:13 UTC (rev 484)
@@ -33,7 +33,7 @@
 
 .data
 
-temp:   .float    0.0
+temp:   .single   0.0
 fpucw:  .long     0
 
 // Precision Control Field , 2 bits / 0x0300
@@ -63,7 +63,7 @@
 // int qftol( void ) - default control word
 //
 
-.global C(qftol)
+.globl C(qftol)
 
 C(qftol):
         fistpl temp
@@ -75,7 +75,7 @@
 // int qftol027F( void ) - DirectX FPU
 //
 
-.global C(qftol027F)
+.globl C(qftol027F)
 
 C(qftol027F):
         fnstcw fpucw
@@ -89,7 +89,7 @@
 // int qftol037F( void ) - Linux FPU
 //
 
-.global C(qftol037F)
+.globl C(qftol037F)
 
 C(qftol037F):
         fnstcw fpucw
@@ -104,7 +104,7 @@
 // int qftol0F7F( void ) - ANSI
 //
 
-.global C(qftol0F7F)
+.globl C(qftol0F7F)
 
 C(qftol0F7F):
         fnstcw fpucw
@@ -118,7 +118,7 @@
 // int qftol0E7F( void )
 //
 
-.global C(qftol0E7F)
+.globl C(qftol0E7F)
 
 C(qftol0E7F):
         fnstcw fpucw
@@ -134,7 +134,7 @@
 // long Q_ftol( float q )
 //
 
-.global C(Q_ftol)
+.globl C(Q_ftol)
 
 C(Q_ftol):
         flds 4(%esp)
@@ -147,7 +147,7 @@
 // long qftol0F7F( float q ) - Linux FPU
 //
 
-.global C(Q_ftol0F7F)
+.globl C(Q_ftol0F7F)
 
 C(Q_ftol0F7F):
         fnstcw fpucw

Modified: trunk/code/unix/qasm.h
===================================================================
--- trunk/code/unix/qasm.h	2006-01-14 09:16:16 UTC (rev 483)
+++ trunk/code/unix/qasm.h	2006-01-15 15:22:13 UTC (rev 484)
@@ -24,7 +24,7 @@
 
 #include "../qcommon/q_platform.h"
 
-#ifdef __MINGW32__
+#if defined(__MINGW32__) || defined(MACOS_X)
 #undef ELF
 #endif
 

Modified: trunk/code/unix/snapvectora.s
===================================================================
--- trunk/code/unix/snapvectora.s	2006-01-14 09:16:16 UTC (rev 483)
+++ trunk/code/unix/snapvectora.s	2006-01-15 15:22:13 UTC (rev 484)
@@ -46,7 +46,7 @@
 .text
 
 // void Sys_SnapVector( float *v )
-.global C(Sys_SnapVector)
+.globl C(Sys_SnapVector)
 C(Sys_SnapVector):
         pushl   %eax
         pushl   %ebp
@@ -74,7 +74,7 @@
         ret
 
 // void Sys_SnapVectorCW( float *v, unsigned short int cw )
-.global C(Sys_SnapVectorCW)
+.globl C(Sys_SnapVectorCW)
 C(Sys_SnapVectorCW):
         pushl   %eax
         pushl   %ebp

Modified: trunk/web/include/status.php
===================================================================
--- trunk/web/include/status.php	2006-01-14 09:16:16 UTC (rev 483)
+++ trunk/web/include/status.php	2006-01-15 15:22:13 UTC (rev 484)
@@ -32,7 +32,7 @@
 		<td>gcc-ppc</td> <!--Platform-->
 		<td>working</td> <!--Status-->
 		<td></td> <!--LKWR-->
-		<td>Altivec build has similar problems to OS X G4 build.</td> <!--Notes-->
+		<td>JIT compiler does not work.</td> <!--Notes-->
 	</tr>
 	<tr>
 		<td>gcc-alpha</td> <!--Platform-->
@@ -54,19 +54,25 @@
 		<td></td> <!--Notes-->
 	</tr>
 	<tr>
-		<td scope="row" rowspan="2">Max OS X</td> <!--OS-->
-		<td>xcode-G3</td> <!--Platform-->
+		<td scope="row" rowspan="3">Max OS X</td> <!--OS-->
+		<td>gcc-ppcG3</td> <!--Platform-->
 		<td>working</td> <!--Status-->
 		<td></td> <!--LKWR-->
 		<td></td> <!--Notes-->
 	</tr>
 	<tr>
-		<td>xcode-G4</td> <!--Platform-->
+		<td>gcc-ppcG4</td> <!--Platform-->
 		<td>working</td> <!--Status-->
 		<td></td> <!--LKWR-->
-		<td>Client has severe graphical glitches.</td> <!--Notes-->
+		<td>JIT compiler does not work.</td> <!--Notes-->
 	</tr>
 	<tr>
+		<td>gcc-x86</td> <!--Platform-->
+		<td>working</td> <!--Status-->
+		<td></td> <!--LKWR-->
+		<td></td> <!--Notes-->
+	</tr>
+	<tr>
 		<td scope="row">FreeBSD</td> <!--OS-->
 		<td>gcc-x86</td> <!--Platform-->
 		<td>working</td> <!--Status-->




More information about the quake3-commits mailing list