From 678ec75aa1bcd3d3a5687295ddcac62c59def1dd Mon Sep 17 00:00:00 2001 From: Jamie Wilkinson Date: Wed, 15 May 2002 13:00:42 +0000 Subject: [PATCH] Trying to suss out the FPE in ref_softx.so - Commented out USE_ASM in the .S files -- in theory they're only built when USE_ASM is enabled anyway... - vid_so.c had some bad typecasts hidden away in some dead code that became activated during this FPE crusade, and though it's still dead, I thought I'd leave it as it is now. --- src/d_polysa.S | 4 ++-- src/math.S | 4 ++-- src/r_aclipa.S | 4 ++-- src/r_draw16.S | 4 ++-- src/r_drawa.S | 4 ++-- src/r_edgea.S | 4 ++-- src/r_main.c | 6 +++++- src/r_scana.S | 4 ++-- src/r_spr8.S | 4 ++-- src/r_surf8.S | 4 ++-- src/r_varsa.S | 4 ++-- src/snd_mixa.S | 4 ++-- src/vid_so.c | 4 ++-- 13 files changed, 29 insertions(+), 25 deletions(-) diff --git a/src/d_polysa.S b/src/d_polysa.S index ba4191a..edce241 100644 --- a/src/d_polysa.S +++ b/src/d_polysa.S @@ -27,7 +27,7 @@ #include "qasm.h" #include "d_ifacea.h" -#if USE_ASM +/* #if USE_ASM */ // !!! if this is changed, it must be changed in d_polyse.c too !!! #define DPS_MAXSPANS MAXHEIGHT+1 @@ -1267,5 +1267,5 @@ LSkip2: popl %ebp ret -#endif /* USE_ASM */ +/* #endif */ /* USE_ASM */ diff --git a/src/math.S b/src/math.S index fa492a6..a2b1d93 100644 --- a/src/math.S +++ b/src/math.S @@ -11,7 +11,7 @@ #include "qasm.h" -#if USE_ASM +// #if USE_ASM .data @@ -405,4 +405,4 @@ Lerror: #endif -#endif /* USE_ASM */ +// #endif /* USE_ASM */ diff --git a/src/r_aclipa.S b/src/r_aclipa.S index ab5bd50..d46059d 100644 --- a/src/r_aclipa.S +++ b/src/r_aclipa.S @@ -10,7 +10,7 @@ #include "qasm.h" #include "d_ifacea.h" -#ifdef USE_ASM +// #ifdef USE_ASM .data Ltemp0: .long 0 @@ -195,5 +195,5 @@ C(R_Alias_clip_left): jmp LRightLeftEntry -#endif /* USE_ASM */ +// #endif /* USE_ASM */ diff --git a/src/r_draw16.S b/src/r_draw16.S index 221de35..dc45f61 100644 --- a/src/r_draw16.S +++ b/src/r_draw16.S @@ -11,7 +11,7 @@ #include "qasm.h" #include "d_ifacea.h" -#ifdef USE_ASM +// #ifdef USE_ASM //---------------------------------------------------------------------- // 8-bpp horizontal span drawing code for polygons, with no transparency and @@ -1227,5 +1227,5 @@ LFDone: popl %ebp // restore the caller's stack frame ret -#endif /* USE_ASM */ +// #endif /* USE_ASM */ diff --git a/src/r_drawa.S b/src/r_drawa.S index 24cf5a6..2ee54a9 100644 --- a/src/r_drawa.S +++ b/src/r_drawa.S @@ -10,7 +10,7 @@ #include "qasm.h" #include "d_ifacea.h" -#ifdef USE_ASM +/* #ifdef USE_ASM */ // !!! if these are changed, they must be changed in r_draw.c too !!! #define FULLY_CLIPPED_CACHED 0x80000000 @@ -817,5 +817,5 @@ LClampP2: LClampP3: ret -#endif /* USE_ASM */ +/* #endif */ /* USE_ASM */ diff --git a/src/r_edgea.S b/src/r_edgea.S index fe92248..f6f5840 100644 --- a/src/r_edgea.S +++ b/src/r_edgea.S @@ -10,7 +10,7 @@ #include "qasm.h" -#ifdef USE_ASM +// #ifdef USE_ASM .data Ltemp: .long 0 @@ -730,5 +730,5 @@ C(R_SurfacePatch): ret -#endif /* USE_ASM */ +// #endif /* USE_ASM */ diff --git a/src/r_main.c b/src/r_main.c index fb09457..d76dc86 100644 --- a/src/r_main.c +++ b/src/r_main.c @@ -1,4 +1,6 @@ /* $Id$ + * + * main for vid refreshers * * Copyright (C) 1997-2001 Id Software, Inc. * Copyright (c) 2002 The Quakeforge Project. @@ -19,7 +21,9 @@ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -// r_main.c +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif #include "r_local.h" diff --git a/src/r_scana.S b/src/r_scana.S index 4330d03..8914ade 100644 --- a/src/r_scana.S +++ b/src/r_scana.S @@ -10,7 +10,7 @@ #include "qasm.h" #include "d_ifacea.h" -#ifdef USE_ASM +// #ifdef USE_ASM .data @@ -68,5 +68,5 @@ Llp: popl %ebp // restore caller's stack frame pointer ret -#endif /* USE_ASM */ +// #endif /* USE_ASM */ diff --git a/src/r_spr8.S b/src/r_spr8.S index 0d8ca1d..ee99408 100644 --- a/src/r_spr8.S +++ b/src/r_spr8.S @@ -9,7 +9,7 @@ #include "qasm.h" -#ifdef USE_ASM +// #ifdef // USE_ASM //---------------------------------------------------------------------- // 8-bpp horizontal span drawing code for polygons, with transparency. @@ -880,4 +880,4 @@ LNextSpan: popl %ebp // restore the caller's stack frame ret -#endif /* USE_ASM */ +// #endif /* USE_ASM */ diff --git a/src/r_surf8.S b/src/r_surf8.S index 3d685fe..5091146 100644 --- a/src/r_surf8.S +++ b/src/r_surf8.S @@ -9,7 +9,7 @@ #include "qasm.h" -#ifdef USE_ASM +// #ifdef USE_ASM .data @@ -763,4 +763,4 @@ LPatchLoop8: ret -#endif /* USE_ASM */ +// #endif /* USE_ASM */ diff --git a/src/r_varsa.S b/src/r_varsa.S index 48e1f1e..088004b 100644 --- a/src/r_varsa.S +++ b/src/r_varsa.S @@ -8,7 +8,7 @@ #include "qasm.h" #include "d_ifacea.h" -#ifdef USE_ASM +// #ifdef USE_ASM .data @@ -221,4 +221,4 @@ entryvec_table: .long 0, Entry2_8, Entry3_8, Entry4_8 spr8entryvec_table: .long 0, Spr8Entry2_8, Spr8Entry3_8, Spr8Entry4_8 .long Spr8Entry5_8, Spr8Entry6_8, Spr8Entry7_8, Spr8Entry8_8 -#endif /* USE_ASM */ +// #endif /* USE_ASM */ diff --git a/src/snd_mixa.S b/src/snd_mixa.S index c1c3ea8..40d108a 100644 --- a/src/snd_mixa.S +++ b/src/snd_mixa.S @@ -9,7 +9,7 @@ #include "qasm.h" -#if USE_ASM +// #if USE_ASM .text @@ -193,5 +193,5 @@ LClampDone2: ret -#endif /* USE_ASM */ +//#endif /* USE_ASM */ diff --git a/src/vid_so.c b/src/vid_so.c index c8e94ef..c59b566 100644 --- a/src/vid_so.c +++ b/src/vid_so.c @@ -370,7 +370,7 @@ qboolean VID_LoadRefresh( char *name ) RW_IN_Init_fp = RW_IN_Init; RW_IN_Shutdown_fp = RW_IN_Shutdown; - RW_IN_Activate_fp = RW_IN_Activate; + RW_IN_Activate_fp = (void(*)(qboolean))RW_IN_Activate; RW_IN_Commands_fp = RW_IN_Commands; RW_IN_Move_fp = RW_IN_Move; RW_IN_Frame_fp = RW_IN_Frame; @@ -403,7 +403,7 @@ qboolean VID_LoadRefresh( char *name ) void KBD_Update(void); void KBD_Close(void); - KBD_Init_fp = KBD_Init; + KBD_Init_fp = (void(*)(Key_Event_fp_t))KBD_Init; KBD_Update_fp = KBD_Update; KBD_Close_fp = KBD_Close; }