diff --git a/acconfig.h b/acconfig.h index 49335b9..d3b9e5c 100644 --- a/acconfig.h +++ b/acconfig.h @@ -31,6 +31,9 @@ /* Define this to use experimental code */ #undef _EXPERIMENTAL_ +/* Define this if you want to use Intel assembly optimizations */ +#undef USE_INTEL_ASM + /* Define this if you have a Linux-style CD-ROM API */ #undef USE_LINUX_CD @@ -82,8 +85,5 @@ /* If your version of OpenGL uses APIENTRY, define GLAPIENTRY to be APIENTRY */ #undef GLAPIENTRY -/* Define this to something sane if you don't have stricmp */ -#undef stricmp - @BOTTOM@ #endif // _CONFIG_H diff --git a/configure.in b/configure.in index 5207924..d7eef9c 100644 --- a/configure.in +++ b/configure.in @@ -78,22 +78,17 @@ dnl ================================================================== dnl Checks for typedefs, structures, and compiler characteristics dnl ================================================================== -dnl call AC_PROG_CC_CONST before AC_C_CONST to avoid warnings - -AC_PROG_CC_STDC AC_C_CONST AC_C_INLINE AC_TYPE_SIZE_T AC_STRUCT_ST_BLKSIZE AC_HEADER_TIME AC_STRUCT_TM -AC_C_BIGENDIAN AC_TRY_COMPILE( [#include ], [ socklen_t x = 0;], - AC_DEFINE(HAVE_SOCKLEN_T) AC_MSG_RESULT(yes), - AC_MSG_RESULT(no) + AC_DEFINE(HAVE_SOCKLEN_T) dnl FreeBSD 4.0 has it in sys/socket.h AC_MSG_CHECKING(for socklen_t in sys/socket.h) AC_TRY_COMPILE( @@ -467,13 +462,13 @@ case "${host}" in [ --disable-asmopt disable assembler optimization], ASM_ARCH=none AC_MSG_RESULT(yes), - ASM_ARCH=yes + AC_DEFINE(USE_INTEL_ASM) AC_MSG_RESULT(no) ) ;; *) AC_MSG_RESULT(no) esac -AM_CONDITIONAL(ASM_ARCH, test "$ASM_ARCH" = "yes") +AC_SUBST(ASM_ARCH) dnl ================================================================== dnl Checks for sound @@ -551,15 +546,6 @@ QF_maGiC_VALUE ], SNDTYPE="WIN32" SOUND_LIBS="-lwinmm") fi -dnl Sun -if test -z "$SNDTYPE" -a "x$ac_cv_header_sys_audioio_h" = "xyes"; then - AC_EGREP_CPP([QF_maGiC_VALUE],[ -#include -#ifdef AUDIO_SETINFO -QF_maGiC_VALUE -#endif - ], SNDTYPE="SUN") -fi AC_MSG_RESULT([yes ($SNDTYPE)]) AC_SUBST(SOUND_LIBS) @@ -567,7 +553,8 @@ AM_CONDITIONAL(SNDTYPE_MME, test "$SNDTYPE" = "MME") AM_CONDITIONAL(SNDTYPE_OSS, test "$SNDTYPE" = "OSS") AM_CONDITIONAL(SNDTYPE_ALSA, test "$SNDTYPE" = "ALSA") AM_CONDITIONAL(SNDTYPE_WIN32, test "$SNDTYPE" = "WIN32") -AM_CONDITIONAL(SNDTYPE_SUN, test "$SNDTYPE" = "SUN") +AM_CONDITIONAL(SNDTYPE_NULL, test "$SNDTYPE" != "WIN32" -a "$SNDTYPE" != "ALSA" -a "$SNDTYPE" != "OSS" -a "$SNDTYPE" != "MME") + dnl ================================================================== dnl Checks for CD-ROM @@ -608,43 +595,7 @@ dnl ================================================================== dnl Checks for networking dnl ================================================================== -if test "x$ac_cv_func_connect" != "xyes"; then - AC_CHECK_LIB(socket,connect, - NET_LIBS="$NET_LIBS -lsocket" - ac_cv_func_connect=yes) -fi -if test "x$ac_cv_func_gethostbyname" != "xyes"; then - AC_CHECK_LIB(nsl,gethostbyname, - NET_LIBS="$NET_LIBS -lnsl" - ac_cv_func_gethostbyname=yes) -fi - -AC_MSG_CHECKING([for connect in -lwsock32]) -SAVELIBS="$LIBS" -LIBS="$LIBS -lwsock32" -AC_TRY_LINK([ -#include -],[ -connect(0, NULL, 42); -], - NET_LIBS="$NET_LIBS -lwsock32 -lwinmm" - ac_cv_func_connect=yes - ac_cv_func_gethostbyname=yes - HAVE_WSOCK=yes - AC_MSG_RESULT(yes), - AC_MSG_RESULT(no)) -LIBS="$SAVELIBS" - -AC_MSG_CHECKING(for UDP support) -if test "x$ac_cv_func_connect" = "xyes" -a \ - "x$ac_cv_func_gethostbyname" = "xyes"; then - HAVE_UDP=yes - AC_MSG_RESULT(yes) -else - AC_MSG_RESULT(no) -fi - - +NET_LIBS="" if test "x$ac_cv_func_connect" != "xyes"; then AC_MSG_CHECKING([for connect in -lwsock32]) SAVELIBS="$LIBS" diff --git a/source/Makefile.am b/source/Makefile.am index 45d003e..158a658 100644 --- a/source/Makefile.am +++ b/source/Makefile.am @@ -17,35 +17,21 @@ libqfsys_cl_a_SOURCES = sys_unix.c cl_sys_unix.c libqfsys_sv_a_SOURCES = sys_unix.c sv_sys_unix.c endif -if ASM_ARCH -MATH_ASM = math.S -WORLDA_ASM = worlda.S -CL_ASM = snd_mixa.S cl_math.S sys_x86.S -SOFT_ASM = d_draw.S d_draw16.S d_parta.S d_polysa.S d_scana.S \ - d_spr8.S d_varsa.S r_aclipa.S r_aliasa.S r_drawa.S r_edgea.S \ - r_varsa.S surf16.S surf8.S -endif - EXTRA_libqfsys_cl_a_SOURCES = cl_sys_unix.c cl_sys_win.c sys_win.c sys_unix.c fnmatch.c dirent.c EXTRA_libqfsys_sv_a_SOURCES = sv_sys_unix.c sv_sys_win.c sys_win.c sys_unix.c fnmatch.c dirent.c if SNDTYPE_WIN32 -libqfsnd_a_SOURCES = snd_win.c snd_dma.c snd_mem.c snd_mix.c -else +libqfsnd_a_SOURCES = snd_dma.c snd_win.c +endif if SNDTYPE_OSS -libqfsnd_a_SOURCES = snd_oss.c snd_dma.c snd_mem.c snd_mix.c -else +libqfsnd_a_SOURCES = snd_dma.c snd_oss.c +endif if SNDTYPE_ALSA -libqfsnd_a_SOURCES = snd_alsa.c snd_dma.c snd_mem.c snd_mix.c -else -if SNDTYPE_SUN -libqfsnd_a_SOURCES = snd_sun.c snd_dma.c snd_mem.c snd_mix.c -else +libqfsnd_a_SOURCES = snd_dma.c snd_alsa.c +endif +if SNDTYPE_NULL libqfsnd_a_SOURCES = snd_null.c endif -endif -endif -endif EXTRA_libqfsnd_a_SOURCES = snd_dma.c snd_win.c snd_oss.c snd_alsa.c snd_null.c if CDTYPE_WIN32 @@ -60,23 +46,26 @@ endif EXTRA_libqfcd_a_SOURCES = cd_win.c cd_linux.c cd_null.c common_SOURCES= net_chan.c net_com.c net_udp.c pmove.c pmovetst.c zone.c \ - mdfour.c mathlib.c cvar.c crc.c model.c cmd.c \ + mdfour.c mathlib.c math.S cvar.c crc.c model.c cmd.c \ qargs.c qendian.c quakefs.c quakeio.c msg.c sizebuf.c info.c \ - checksum.c link.c buildnum.c va.c com.c $(MATH_ASM) + checksum.c link.c buildnum.c va.c com.c server_SOURCES= pr_cmds.c pr_edict.c pr_exec.c sv_init.c sv_main.c sv_misc.c \ sv_model.c sv_nchan.c sv_ents.c sv_send.c sv_move.c sv_phys.c \ - sv_user.c sv_ccmds.c world.c sv_cvar.c $(WORLDA_ASM) + sv_user.c sv_ccmds.c world.c worlda.S sv_cvar.c client_SOURCES= cl_cmd.c cl_cvar.c cl_demo.c cl_ents.c cl_input.c cl_main.c \ - cl_misc.c cl_parse.c cl_pred.c cl_tent.c cl_cam.c \ - r_view.c wad.c \ + cl_math.S cl_misc.c cl_parse.c cl_pred.c cl_tent.c cl_cam.c \ + r_view.c wad.c snd_mem.c snd_mix.c snd_mixa.S \ skin.c sbar.c nonintel.c menu.c keys.c console.c \ - cl_slist.c $(CL_ASM) + sys_x86.S cl_slist.c soft_SOURCES= cl_model.c cl_trans.c d_edge.c d_fill.c d_init.c d_modech.c \ d_part.c d_polyse.c d_scan.c d_sky.c d_sprite.c d_surf.c \ d_vars.c d_zpoint.c draw.c r_aclip.c r_alias.c r_bsp.c \ r_draw.c r_edge.c r_efrag.c r_light.c r_main.c r_misc.c \ r_part.c r_sky.c r_sprite.c r_surf.c r_vars.c sw_view.c \ - screen.c $(SOFT_ASM) + screen.c \ + d_draw.S d_draw16.S d_parta.S d_polysa.S d_scana.S \ + d_spr8.S d_varsa.S r_aclipa.S r_aliasa.S r_drawa.S r_edgea.S \ + r_varsa.S surf16.S surf8.S ogl_SOURCES= gl_draw.c gl_mesh.c gl_model.c gl_ngraph.c gl_part.c \ gl_refrag.c gl_rlight.c gl_rmain.c gl_rmisc.c gl_rsurf.c \ gl_screen.c gl_trans.c gl_view.c gl_warp.c diff --git a/source/buildnum.c b/source/buildnum.c index 568b7c8..cecfc74 100644 --- a/source/buildnum.c +++ b/source/buildnum.c @@ -32,9 +32,6 @@ #include #include -#ifdef HAVE_STRINGS_H -#include -#endif //char *date = "Dec 21 1999"; static char *date = __DATE__ ; diff --git a/source/cl_cmd.c b/source/cl_cmd.c index 7839dd1..855b539 100644 --- a/source/cl_cmd.c +++ b/source/cl_cmd.c @@ -35,9 +35,6 @@ #include "msg.h" #include -#ifdef HAVE_STRINGS_H -#include -#endif /* =================== diff --git a/source/cl_main.c b/source/cl_main.c index 11206b6..2b4f6a2 100644 --- a/source/cl_main.c +++ b/source/cl_main.c @@ -58,12 +58,6 @@ #include "draw.h" #include "qargs.h" #include "cdaudio.h" - -#ifdef __sun -/* Sun's model_t in sys/model.h conflicts w/ Quake's model_t */ -#define model_t sunmodel_t -#endif - #ifdef _WIN32 #include "winquake.h" #include "winsock.h" @@ -71,15 +65,7 @@ #else #include #endif - -#ifdef __sun -#undef model_t -#endif - #include -#ifdef HAVE_STRINGS_H -#include -#endif // we need to declare some mouse variables here, because the menu system diff --git a/source/cl_math.S b/source/cl_math.S index d28046d..1666700 100644 --- a/source/cl_math.S +++ b/source/cl_math.S @@ -29,11 +29,12 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" + +#ifdef USE_INTEL_ASM + .data .text diff --git a/source/cl_model.c b/source/cl_model.c index 44b02b2..cc7df45 100644 --- a/source/cl_model.c +++ b/source/cl_model.c @@ -32,9 +32,6 @@ #ifdef HAVE_CONFIG_H # include #endif -#ifdef HAVE_STRING_H -#include -#endif #include "model.h" #include "crc.h" #include "msg.h" diff --git a/source/cl_parse.c b/source/cl_parse.c index 89af99c..aae7487 100644 --- a/source/cl_parse.c +++ b/source/cl_parse.c @@ -40,9 +40,6 @@ #include "msg.h" #include "pmove.h" #include "sbar.h" -#ifdef HAVE_STRINGS_H -#include -#endif extern cvar_t *gl_flashblend; extern cvar_t *cl_autoexec; diff --git a/source/cl_tent.c b/source/cl_tent.c index 7e7299a..cd8fdf8 100644 --- a/source/cl_tent.c +++ b/source/cl_tent.c @@ -39,9 +39,6 @@ #include #include -#ifdef HAVE_STRING_H -#include -#endif #define MAX_BEAMS 8 typedef struct diff --git a/source/cl_trans.c b/source/cl_trans.c index 0451ceb..e0ed87b 100644 --- a/source/cl_trans.c +++ b/source/cl_trans.c @@ -34,9 +34,6 @@ #include "client.h" #include -#ifdef HAVE_STRINGS_H -#include -#endif /* ===================== diff --git a/source/cmd.c b/source/cmd.c index 7e1a4c4..95decd6 100644 --- a/source/cmd.c +++ b/source/cmd.c @@ -41,9 +41,6 @@ #include #include -#ifdef HAVE_STRINGS_H -#include -#endif void Cmd_ForwardToServer (void); diff --git a/source/com.c b/source/com.c index 4c575ef..b8a5807 100644 --- a/source/com.c +++ b/source/com.c @@ -88,7 +88,7 @@ COM_Init */ void COM_Init (void) { -#ifndef WORDS_BIGENDIAN +#ifndef WORDS_BIGENDIEN bigendien = false; BigShort = ShortSwap; LittleShort = ShortNoSwap; diff --git a/source/d_copy.S b/source/d_copy.S index e11b2ef..68e932e 100644 --- a/source/d_copy.S +++ b/source/d_copy.S @@ -29,11 +29,11 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" + +#ifdef USE_INTEL_ASM .data LCopyWidth: .long 0 diff --git a/source/d_draw.S b/source/d_draw.S index 6fe35a2..0792617 100644 --- a/source/d_draw.S +++ b/source/d_draw.S @@ -29,13 +29,13 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" #include "d_ifacea.h" +#ifdef USE_INTEL_ASM + //---------------------------------------------------------------------- // 8-bpp horizontal span drawing code for polygons, with no transparency. // diff --git a/source/d_draw16.S b/source/d_draw16.S index 82cc00a..46d575c 100644 --- a/source/d_draw16.S +++ b/source/d_draw16.S @@ -30,13 +30,13 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" #include "d_ifacea.h" +#ifdef USE_INTEL_ASM + //---------------------------------------------------------------------- // 8-bpp horizontal span drawing code for polygons, with no transparency and // 16-pixel subdivision. diff --git a/source/d_parta.S b/source/d_parta.S index d563001..2ea8d03 100644 --- a/source/d_parta.S +++ b/source/d_parta.S @@ -29,13 +29,13 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "d_ifacea.h" #include "asm_draw.h" +#ifdef USE_INTEL_ASM + //---------------------------------------------------------------------- // 8-bpp particle drawing code. //---------------------------------------------------------------------- diff --git a/source/d_polysa.S b/source/d_polysa.S index efb073d..60a17c1 100644 --- a/source/d_polysa.S +++ b/source/d_polysa.S @@ -29,13 +29,13 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" #include "d_ifacea.h" +#ifdef USE_INTEL_ASM + // !!! if this is changed, it must be changed in d_polyse.c too !!! #define DPS_MAXSPANS MAXHEIGHT+1 // 1 extra for spanpackage that marks end diff --git a/source/d_scana.S b/source/d_scana.S index aa6c556..7487928 100644 --- a/source/d_scana.S +++ b/source/d_scana.S @@ -29,13 +29,13 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" #include "d_ifacea.h" +#ifdef USE_INTEL_ASM + .data .text diff --git a/source/d_spr8.S b/source/d_spr8.S index b0f4e06..9a38632 100644 --- a/source/d_spr8.S +++ b/source/d_spr8.S @@ -29,12 +29,12 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" +#ifdef USE_INTEL_ASM + //---------------------------------------------------------------------- // 8-bpp horizontal span drawing code for polygons, with transparency. //---------------------------------------------------------------------- diff --git a/source/d_varsa.S b/source/d_varsa.S index 5bc6b3e..f6441bc 100644 --- a/source/d_varsa.S +++ b/source/d_varsa.S @@ -29,13 +29,13 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" #include "d_ifacea.h" +#ifdef USE_INTEL_ASM + .data //------------------------------------------------------- diff --git a/source/gl_draw.c b/source/gl_draw.c index e8918ef..821b595 100644 --- a/source/gl_draw.c +++ b/source/gl_draw.c @@ -32,9 +32,6 @@ #include #include -#ifdef HAVE_STRINGS_H -#include -#endif #include "bothdefs.h" // needed by: common.h, net.h, client.h @@ -1243,12 +1240,7 @@ void GL_Upload8_EXT (byte *data, int width, int height, qboolean mipmap, qboole { if (!mipmap) { -/* FIXME - what if this extension isn't available? */ -#ifdef HAVE_GL_COLOR_INDEX8_EXT glTexImage2D (GL_TEXTURE_2D, 0, GL_COLOR_INDEX8_EXT, scaled_width, scaled_height, 0, GL_COLOR_INDEX , GL_UNSIGNED_BYTE, data); -#else - /* FIXME - should warn that this isn't available */ -#endif goto done; } memcpy (scaled, data, width*height); @@ -1256,12 +1248,7 @@ void GL_Upload8_EXT (byte *data, int width, int height, qboolean mipmap, qboole else GL_Resample8BitTexture (data, width, height, scaled, scaled_width, scaled_height); -// FIXME - what if this extension isn't available? -#ifdef HAVE_GL_COLOR_INDEX8_EXT glTexImage2D (GL_TEXTURE_2D, 0, GL_COLOR_INDEX8_EXT, scaled_width, scaled_height, 0, GL_COLOR_INDEX, GL_UNSIGNED_BYTE, scaled); -#else - /* FIXME - should warn that this isn't available */ -#endif if (mipmap) { int miplevel; @@ -1277,12 +1264,7 @@ void GL_Upload8_EXT (byte *data, int width, int height, qboolean mipmap, qboole if (scaled_height < 1) scaled_height = 1; miplevel++; -/* FIXME - what if this extension isn't available? */ -#ifdef HAVE_GL_COLOR_INDEX8_EXT glTexImage2D (GL_TEXTURE_2D, miplevel, GL_COLOR_INDEX8_EXT, scaled_width, scaled_height, 0, GL_COLOR_INDEX, GL_UNSIGNED_BYTE, scaled); -#else - /* FIXME - should warn that this isn't available */ -#endif } } done: ; @@ -1419,7 +1401,7 @@ void GL_SelectTexture (GLenum target) { if (!gl_mtexable) return; -#ifdef _WIN32 // FIXME - only multi-texture under Win32 +#ifndef __linux__ // no multitexture under Linux yet qglSelectTextureSGIS(target); #endif if (target == oldtarget) diff --git a/source/gl_rmisc.c b/source/gl_rmisc.c index fd852e6..1873a38 100644 --- a/source/gl_rmisc.c +++ b/source/gl_rmisc.c @@ -31,9 +31,6 @@ #endif #include #include -#ifdef HAVE_STRINGS_H -#include -#endif #include "bothdefs.h" // needed by: common.h, net.h, client.h diff --git a/source/gl_warp.c b/source/gl_warp.c index 055002f..c5a7727 100644 --- a/source/gl_warp.c +++ b/source/gl_warp.c @@ -34,9 +34,6 @@ #include #include #include -#ifdef HAVE_STRINGS_H -#include -#endif #include "bothdefs.h" #include "console.h" diff --git a/source/info.c b/source/info.c index e6e5349..587ab3e 100644 --- a/source/info.c +++ b/source/info.c @@ -34,9 +34,6 @@ #include #include #include -#ifdef HAVE_STRINGS_H -#include -#endif /* ===================================================================== diff --git a/source/keys.c b/source/keys.c index 7a174bd..b9e1ddb 100644 --- a/source/keys.c +++ b/source/keys.c @@ -35,9 +35,6 @@ #include #include -#ifdef HAVE_STRINGS_H -#include -#endif #include "qtypes.h" #include "sys.h" diff --git a/source/math.S b/source/math.S index 6642068..1061131 100644 --- a/source/math.S +++ b/source/math.S @@ -29,11 +29,12 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" // #include "quakeasm.h" + +#ifdef USE_INTEL_ASM + .data .align 4 diff --git a/source/mathlib.c b/source/mathlib.c index 4701a8e..2973852 100644 --- a/source/mathlib.c +++ b/source/mathlib.c @@ -29,9 +29,6 @@ #ifdef HAVE_CONFIG_H # include #endif -#ifdef HAVE_STRING_H -#include -#endif #include #include "qtypes.h" #include "mathlib.h" diff --git a/source/net_chan.c b/source/net_chan.c index f45aa32..90929c8 100644 --- a/source/net_chan.c +++ b/source/net_chan.c @@ -34,9 +34,6 @@ #else # include #endif -#ifdef HAVE_STRING_H -#include -#endif #include #include diff --git a/source/net_udp.c b/source/net_udp.c index ac1370e..08773e4 100644 --- a/source/net_udp.c +++ b/source/net_udp.c @@ -82,14 +82,6 @@ # define MAXHOSTNAMELEN 512 #endif -#ifndef HAVE_SOCKLEN_T -# ifdef HAVE_SIZE -typedef size_t socklen_t; -# else -typedef unsigned int socklen_t; -# endif -#endif - netadr_t net_local_adr; netadr_t net_from; @@ -238,13 +230,13 @@ qboolean NET_IsClientLegal(netadr_t *adr) qboolean NET_GetPacket (void) { - int ret; - struct sockaddr_in from; - socklen_t fromlen; + int ret; + struct sockaddr_in from; + int fromlen; fromlen = sizeof(from); - ret = recvfrom(net_socket, (void*)net_message_buffer, sizeof(net_message_buffer), 0, (struct sockaddr *)&from, &fromlen); - SockadrToNetadr (&from, &net_from); + ret = recvfrom(net_socket, net_message_buffer, sizeof(net_message_buffer), + 0, (struct sockaddr *)&from, &fromlen); SockadrToNetadr(&from, &net_from); if (ret == -1) { @@ -345,7 +337,7 @@ void NET_GetLocalAddress (void) { char buff[MAXHOSTNAMELEN]; struct sockaddr_in address; - socklen_t namelen; + int namelen; gethostname(buff, MAXHOSTNAMELEN); buff[MAXHOSTNAMELEN-1] = 0; diff --git a/source/pmovetst.c b/source/pmovetst.c index 4a89850..514e7f8 100644 --- a/source/pmovetst.c +++ b/source/pmovetst.c @@ -29,9 +29,6 @@ #ifdef HAVE_CONFIG_H # include #endif -#ifdef HAVE_STRING_H -#include -#endif #include "sys.h" #include "qtypes.h" #include "pmove.h" diff --git a/source/pr_edict.c b/source/pr_edict.c index 15effbd..2f07bcb 100644 --- a/source/pr_edict.c +++ b/source/pr_edict.c @@ -44,9 +44,6 @@ #include #include #include -#ifdef HAVE_STRINGS_H -#include -#endif void SV_Error (char *error, ...); diff --git a/source/r_aclipa.S b/source/r_aclipa.S index 61ef398..a3d0b81 100644 --- a/source/r_aclipa.S +++ b/source/r_aclipa.S @@ -30,13 +30,13 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" #include "d_ifacea.h" +#ifdef USE_INTEL_ASM + .data Ltemp0: .long 0 Ltemp1: .long 0 diff --git a/source/r_aliasa.S b/source/r_aliasa.S index 3602f13..0570525 100644 --- a/source/r_aliasa.S +++ b/source/r_aliasa.S @@ -29,13 +29,13 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" #include "d_ifacea.h" +#ifdef USE_INTEL_ASM + .data Lfloat_1: .single 1.0 diff --git a/source/r_drawa.S b/source/r_drawa.S index 5aa0afe..c2e7832 100644 --- a/source/r_drawa.S +++ b/source/r_drawa.S @@ -29,13 +29,13 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" #include "d_ifacea.h" +#ifdef USE_INTEL_ASM + // !!! if these are changed, they must be changed in r_draw.c too !!! #define FULLY_CLIPPED_CACHED 0x80000000 #define FRAMECOUNT_MASK 0x7FFFFFFF diff --git a/source/r_edgea.S b/source/r_edgea.S index 661dbb6..4e799e2 100644 --- a/source/r_edgea.S +++ b/source/r_edgea.S @@ -29,12 +29,12 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" +#ifdef USE_INTEL_ASM + .data Ltemp: .long 0 float_1_div_0100000h: .long 0x35800000 // 1.0/(float)0x100000 diff --git a/source/r_main.c b/source/r_main.c index d94f38c..a823e97 100644 --- a/source/r_main.c +++ b/source/r_main.c @@ -29,9 +29,6 @@ #ifdef HAVE_CONFIG_H # include #endif -#ifdef HAVE_STRING_H -#include -#endif #include "sys.h" #include "cmd.h" #include "bothdefs.h" diff --git a/source/r_varsa.S b/source/r_varsa.S index 368b4cf..0a253b8 100644 --- a/source/r_varsa.S +++ b/source/r_varsa.S @@ -29,13 +29,13 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" #include "d_ifacea.h" +#ifdef USE_INTEL_ASM + .data //------------------------------------------------------- diff --git a/source/snd_mix.c b/source/snd_mix.c index 7de7d53..4dc3dac 100644 --- a/source/snd_mix.c +++ b/source/snd_mix.c @@ -29,9 +29,6 @@ #ifdef HAVE_CONFIG_H # include #endif -#ifdef HAVE_STRING_H -#include -#endif #include "sound.h" #include "console.h" diff --git a/source/snd_mixa.S b/source/snd_mixa.S index cf4978b..3879d40 100644 --- a/source/snd_mixa.S +++ b/source/snd_mixa.S @@ -29,11 +29,11 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" // #include "quakeasm.h" +#ifdef USE_INTEL_ASM + .text .extern C(snd_scaletable) diff --git a/source/surf16.S b/source/surf16.S index 2ee4181..dec8993 100644 --- a/source/surf16.S +++ b/source/surf16.S @@ -29,12 +29,12 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" +#ifdef USE_INTEL_ASM + //---------------------------------------------------------------------- // Surface block drawer //---------------------------------------------------------------------- diff --git a/source/surf8.S b/source/surf8.S index 68cb271..50a59c0 100644 --- a/source/surf8.S +++ b/source/surf8.S @@ -30,11 +30,12 @@ # include "config.h" #endif -#ifdef USE_INTEL_ASM #include "asm_i386.h" #include "quakeasm.h" #include "asm_draw.h" +#ifdef USE_INTEL_ASM + .data sb_v: .long 0 diff --git a/source/sv_ccmds.c b/source/sv_ccmds.c index 2fbfc0e..fef8f46 100644 --- a/source/sv_ccmds.c +++ b/source/sv_ccmds.c @@ -45,9 +45,6 @@ #include #include -#ifdef HAVE_STRINGS_H -#include -#endif qboolean sv_allow_cheats; diff --git a/source/sv_ents.c b/source/sv_ents.c index 3c936d0..241af6c 100644 --- a/source/sv_ents.c +++ b/source/sv_ents.c @@ -29,9 +29,6 @@ #ifdef HAVE_CONFIG_H # include #endif -#ifdef HAVE_STRING_H -#include -#endif #include "server.h" #include "crc.h" #include "msg.h" diff --git a/source/sv_main.c b/source/sv_main.c index 495ad57..5df2697 100644 --- a/source/sv_main.c +++ b/source/sv_main.c @@ -45,9 +45,6 @@ #include #include #include -#ifdef HAVE_STRINGS_H -#include -#endif quakeparms_t host_parms; diff --git a/source/sv_nchan.c b/source/sv_nchan.c index de7c5dd..6270a01 100644 --- a/source/sv_nchan.c +++ b/source/sv_nchan.c @@ -29,9 +29,6 @@ #ifdef HAVE_CONFIG_H # include #endif -#ifdef HAVE_STRING_H -#include -#endif #include "server.h" #include "crc.h" #include "msg.h" diff --git a/source/sv_sys_unix.c b/source/sv_sys_unix.c index e40393a..33514dd 100644 --- a/source/sv_sys_unix.c +++ b/source/sv_sys_unix.c @@ -31,9 +31,6 @@ # include #endif #include -#ifdef HAVE_STRINGS_H -#include -#endif #include "qargs.h" #include "cvar.h" #include "server.h" @@ -49,9 +46,6 @@ #include #include #include -#ifdef HAVE_STRING_H -#include -#endif /* cvar_t sys_extrasleep = {"sys_extrasleep","0"}; diff --git a/source/sys_x86.S b/source/sys_x86.S index 94d04a6..b34494a 100644 --- a/source/sys_x86.S +++ b/source/sys_x86.S @@ -29,9 +29,10 @@ #ifdef HAVE_CONFIG_H # include #endif +#include "asm_i386.h" + #ifdef USE_INTEL_ASM -#include "asm_i386.h" .data .align 4 diff --git a/source/world.c b/source/world.c index c96fe75..9b4eaef 100644 --- a/source/world.c +++ b/source/world.c @@ -36,9 +36,6 @@ #include "console.h" #include -#ifdef HAVE_STRING_H -#include -#endif /* diff --git a/source/worlda.S b/source/worlda.S index 6b17021..cb06d48 100644 --- a/source/worlda.S +++ b/source/worlda.S @@ -29,12 +29,12 @@ #ifdef HAVE_CONFIG_H # include #endif - -#ifdef USE_INTEL_ASM #include "asm_i386.h" //#include "quakeasm.h" //include "d_ifacea.h" +#ifdef USE_INTEL_ASM + .data Ltemp: .long 0