* (bug #3729) server dependencies on client.h (Ben Millwood)

* (bug #3731) BUILD_MISSIONPACK flag in Makefile (Gabriel Schnoering
  <gabriel.schnoering@gmail.com>)
* (bug #3756) Q3VM crashes on unaligned block copy with SIGBUS (Patrick Baggett
  <baggett.patrick@figglesoftware.com>) and...
* (bug #3755) IOQuake3 shouldn't use GCC-specific __FUNCTION__
This commit is contained in:
Tim Angus 2008-08-22 22:47:26 +00:00
parent acbf982689
commit b555d68b3f
13 changed files with 36 additions and 32 deletions

View file

@ -41,6 +41,9 @@ endif
ifndef BUILD_GAME_QVM ifndef BUILD_GAME_QVM
BUILD_GAME_QVM = BUILD_GAME_QVM =
endif endif
ifndef BUILD_MISSIONPACK
BUILD_MISSIONPACK=
endif
ifneq ($(PLATFORM),darwin) ifneq ($(PLATFORM),darwin)
BUILD_CLIENT_SMP = 0 BUILD_CLIENT_SMP = 0
@ -786,23 +789,29 @@ ifneq ($(BUILD_GAME_SO),0)
TARGETS += \ TARGETS += \
$(B)/baseq3/cgame$(ARCH).$(SHLIBEXT) \ $(B)/baseq3/cgame$(ARCH).$(SHLIBEXT) \
$(B)/baseq3/qagame$(ARCH).$(SHLIBEXT) \ $(B)/baseq3/qagame$(ARCH).$(SHLIBEXT) \
$(B)/baseq3/ui$(ARCH).$(SHLIBEXT) \ $(B)/baseq3/ui$(ARCH).$(SHLIBEXT)
ifneq ($(BUILD_MISSIONPACK),0)
TARGETS += \
$(B)/missionpack/cgame$(ARCH).$(SHLIBEXT) \ $(B)/missionpack/cgame$(ARCH).$(SHLIBEXT) \
$(B)/missionpack/qagame$(ARCH).$(SHLIBEXT) \ $(B)/missionpack/qagame$(ARCH).$(SHLIBEXT) \
$(B)/missionpack/ui$(ARCH).$(SHLIBEXT) $(B)/missionpack/ui$(ARCH).$(SHLIBEXT)
endif endif
endif
ifneq ($(BUILD_GAME_QVM),0) ifneq ($(BUILD_GAME_QVM),0)
ifneq ($(CROSS_COMPILING),1) ifneq ($(CROSS_COMPILING),1)
TARGETS += \ TARGETS += \
$(B)/baseq3/vm/cgame.qvm \ $(B)/baseq3/vm/cgame.qvm \
$(B)/baseq3/vm/qagame.qvm \ $(B)/baseq3/vm/qagame.qvm \
$(B)/baseq3/vm/ui.qvm \ $(B)/baseq3/vm/ui.qvm
ifneq ($(BUILD_MISSIONPACK),0)
TARGETS += \
$(B)/missionpack/vm/qagame.qvm \ $(B)/missionpack/vm/qagame.qvm \
$(B)/missionpack/vm/cgame.qvm \ $(B)/missionpack/vm/cgame.qvm \
$(B)/missionpack/vm/ui.qvm $(B)/missionpack/vm/ui.qvm
endif endif
endif endif
endif
ifeq ($(USE_MUMBLE),1) ifeq ($(USE_MUMBLE),1)
BASE_CFLAGS += -DUSE_MUMBLE BASE_CFLAGS += -DUSE_MUMBLE
@ -2048,6 +2057,7 @@ ifneq ($(BUILD_GAME_SO),0)
$(COPYDIR)/baseq3/. $(COPYDIR)/baseq3/.
$(INSTALL) -s -m 0755 $(BR)/baseq3/ui$(ARCH).$(SHLIBEXT) \ $(INSTALL) -s -m 0755 $(BR)/baseq3/ui$(ARCH).$(SHLIBEXT) \
$(COPYDIR)/baseq3/. $(COPYDIR)/baseq3/.
ifneq ($(BUILD_MISSIONPACK),0)
-$(MKDIR) -p -m 0755 $(COPYDIR)/missionpack -$(MKDIR) -p -m 0755 $(COPYDIR)/missionpack
$(INSTALL) -s -m 0755 $(BR)/missionpack/cgame$(ARCH).$(SHLIBEXT) \ $(INSTALL) -s -m 0755 $(BR)/missionpack/cgame$(ARCH).$(SHLIBEXT) \
$(COPYDIR)/missionpack/. $(COPYDIR)/missionpack/.
@ -2056,6 +2066,7 @@ ifneq ($(BUILD_GAME_SO),0)
$(INSTALL) -s -m 0755 $(BR)/missionpack/ui$(ARCH).$(SHLIBEXT) \ $(INSTALL) -s -m 0755 $(BR)/missionpack/ui$(ARCH).$(SHLIBEXT) \
$(COPYDIR)/missionpack/. $(COPYDIR)/missionpack/.
endif endif
endif
clean: clean-debug clean-release clean: clean-debug clean-release
ifeq ($(PLATFORM),mingw32) ifeq ($(PLATFORM),mingw32)

View file

@ -44,7 +44,6 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
#include "be_aas_funcs.h" #include "be_aas_funcs.h"
#include "be_aas_def.h" #include "be_aas_def.h"
extern botlib_import_t botimport;
//#define AAS_SAMPLE_DEBUG //#define AAS_SAMPLE_DEBUG

View file

@ -135,7 +135,6 @@ static int currentHandle = -1;
static int CL_handle = -1; static int CL_handle = -1;
extern int s_soundtime; // sample PAIRS extern int s_soundtime; // sample PAIRS
extern int s_paintedtime; // sample PAIRS
void CIN_CloseAllVideos(void) { void CIN_CloseAllVideos(void) {

View file

@ -490,8 +490,6 @@ void CL_VerifyCode( void );
float CL_KeyState (kbutton_t *key); float CL_KeyState (kbutton_t *key);
char *Key_KeynumToString (int keynum); char *Key_KeynumToString (int keynum);
int Key_GetCatcher( void );
void Key_SetCatcher( int catcher );
// //
// cl_parse.c // cl_parse.c

View file

@ -38,7 +38,6 @@ void S_SoundList_f(void);
void S_Music_f(void); void S_Music_f(void);
void S_Update_( void ); void S_Update_( void );
void S_UpdateBackgroundTrack( void );
void S_Base_StopAllSounds(void); void S_Base_StopAllSounds(void);
void S_Base_StopBackgroundTrack( void ); void S_Base_StopBackgroundTrack( void );

View file

@ -20,7 +20,8 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
=========================================================================== ===========================================================================
*/ */
#include "../client/client.h" #include "../qcommon/q_shared.h"
#include "../qcommon/qcommon.h"
cvar_t *cl_shownet; cvar_t *cl_shownet;

View file

@ -19,7 +19,6 @@ along with Quake III Arena source code; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
=========================================================================== ===========================================================================
*/ */
#include "../client/client.h"
void IN_Init( void ) { void IN_Init( void ) {
} }

View file

@ -23,7 +23,8 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
// snddma_null.c // snddma_null.c
// all other sound mixing is portable // all other sound mixing is portable
#include "../client/client.h" #include "../qcommon/q_shared.h"
#include "../qcommon/qcommon.h"
qboolean SNDDMA_Init(void) qboolean SNDDMA_Init(void)
{ {

View file

@ -298,6 +298,11 @@ char lastValidGame[MAX_OSPATH];
FILE* missingFiles = NULL; FILE* missingFiles = NULL;
#endif #endif
/* C99 defines __func__ */
#ifndef __func__
#define __func__ "(unknown)"
#endif
/* /*
============== ==============
FS_Initialized FS_Initialized
@ -526,7 +531,7 @@ static void FS_CopyFile( char *fromOSPath, char *toOSPath ) {
Com_Printf( "copy %s to %s\n", fromOSPath, toOSPath ); Com_Printf( "copy %s to %s\n", fromOSPath, toOSPath );
FS_FilenameIsExecutable( toOSPath, __FUNCTION__ ); FS_FilenameIsExecutable( toOSPath, __func__ );
if (strstr(fromOSPath, "journal.dat") || strstr(fromOSPath, "journaldata.dat")) { if (strstr(fromOSPath, "journal.dat") || strstr(fromOSPath, "journaldata.dat")) {
Com_Printf( "Ignoring journal files\n"); Com_Printf( "Ignoring journal files\n");
@ -569,7 +574,7 @@ FS_Remove
=========== ===========
*/ */
void FS_Remove( const char *osPath ) { void FS_Remove( const char *osPath ) {
FS_FilenameIsExecutable( osPath, __FUNCTION__ ); FS_FilenameIsExecutable( osPath, __func__ );
remove( osPath ); remove( osPath );
} }
@ -581,7 +586,7 @@ FS_HomeRemove
=========== ===========
*/ */
void FS_HomeRemove( const char *homePath ) { void FS_HomeRemove( const char *homePath ) {
FS_FilenameIsExecutable( homePath, __FUNCTION__ ); FS_FilenameIsExecutable( homePath, __func__ );
remove( FS_BuildOSPath( fs_homepath->string, remove( FS_BuildOSPath( fs_homepath->string,
fs_gamedir, homePath ) ); fs_gamedir, homePath ) );
@ -660,7 +665,7 @@ fileHandle_t FS_SV_FOpenFileWrite( const char *filename ) {
Com_Printf( "FS_SV_FOpenFileWrite: %s\n", ospath ); Com_Printf( "FS_SV_FOpenFileWrite: %s\n", ospath );
} }
FS_FilenameIsExecutable( ospath, __FUNCTION__ ); FS_FilenameIsExecutable( ospath, __func__ );
if( FS_CreatePath( ospath ) ) { if( FS_CreatePath( ospath ) ) {
return 0; return 0;
@ -771,7 +776,7 @@ void FS_SV_Rename( const char *from, const char *to ) {
Com_Printf( "FS_SV_Rename: %s --> %s\n", from_ospath, to_ospath ); Com_Printf( "FS_SV_Rename: %s --> %s\n", from_ospath, to_ospath );
} }
FS_FilenameIsExecutable( to_ospath, __FUNCTION__ ); FS_FilenameIsExecutable( to_ospath, __func__ );
if (rename( from_ospath, to_ospath )) { if (rename( from_ospath, to_ospath )) {
// Failed, try copying it and deleting the original // Failed, try copying it and deleting the original
@ -805,7 +810,7 @@ void FS_Rename( const char *from, const char *to ) {
Com_Printf( "FS_Rename: %s --> %s\n", from_ospath, to_ospath ); Com_Printf( "FS_Rename: %s --> %s\n", from_ospath, to_ospath );
} }
FS_FilenameIsExecutable( to_ospath, __FUNCTION__ ); FS_FilenameIsExecutable( to_ospath, __func__ );
if (rename( from_ospath, to_ospath )) { if (rename( from_ospath, to_ospath )) {
// Failed, try copying it and deleting the original // Failed, try copying it and deleting the original
@ -868,7 +873,7 @@ fileHandle_t FS_FOpenFileWrite( const char *filename ) {
Com_Printf( "FS_FOpenFileWrite: %s\n", ospath ); Com_Printf( "FS_FOpenFileWrite: %s\n", ospath );
} }
FS_FilenameIsExecutable( ospath, __FUNCTION__ ); FS_FilenameIsExecutable( ospath, __func__ );
if( FS_CreatePath( ospath ) ) { if( FS_CreatePath( ospath ) ) {
return 0; return 0;
@ -916,7 +921,7 @@ fileHandle_t FS_FOpenFileAppend( const char *filename ) {
Com_Printf( "FS_FOpenFileAppend: %s\n", ospath ); Com_Printf( "FS_FOpenFileAppend: %s\n", ospath );
} }
FS_FilenameIsExecutable( ospath, __FUNCTION__ ); FS_FilenameIsExecutable( ospath, __func__ );
if( FS_CreatePath( ospath ) ) { if( FS_CreatePath( ospath ) ) {
return 0; return 0;

View file

@ -992,8 +992,6 @@ If the delta removes the entity, entityState_t->number will be set to MAX_GENTIT
Can go from either a baseline or a previous packet_entity Can go from either a baseline or a previous packet_entity
================== ==================
*/ */
extern cvar_t *cl_shownet;
void MSG_ReadDeltaEntity( msg_t *msg, entityState_t *from, entityState_t *to, void MSG_ReadDeltaEntity( msg_t *msg, entityState_t *from, entityState_t *to,
int number) { int number) {
int i, lc; int i, lc;

View file

@ -597,7 +597,6 @@ fileHandle_t FS_FOpenFileWrite( const char *qpath );
fileHandle_t FS_FOpenFileAppend( const char *filename ); fileHandle_t FS_FOpenFileAppend( const char *filename );
// will properly create any needed paths and deal with seperater character issues // will properly create any needed paths and deal with seperater character issues
int FS_filelength( fileHandle_t f );
fileHandle_t FS_SV_FOpenFileWrite( const char *filename ); fileHandle_t FS_SV_FOpenFileWrite( const char *filename );
int FS_SV_FOpenFileRead( const char *filename, fileHandle_t *fp ); int FS_SV_FOpenFileRead( const char *filename, fileHandle_t *fp );
void FS_SV_Rename( const char *from, const char *to ); void FS_SV_Rename( const char *from, const char *to );

View file

@ -7,7 +7,8 @@
* *
*****************************************************************************/ *****************************************************************************/
#include "../client/client.h" #include "../qcommon/q_shared.h"
#include "../qcommon/qcommon.h"
#include "unzip.h" #include "unzip.h"
/* unzip.h -- IO for uncompress .zip files using zlib /* unzip.h -- IO for uncompress .zip files using zlib

View file

@ -489,16 +489,10 @@ nextInstruction2:
count = ((srci + count) & dataMask) - srci; count = ((srci + count) & dataMask) - srci;
count = ((desti + count) & dataMask) - desti; count = ((desti + count) & dataMask) - desti;
src = (int *)&image[ r0&dataMask ]; src = (int *)&image[ srci ];
dest = (int *)&image[ r1&dataMask ]; dest = (int *)&image[ desti ];
if ( ( (intptr_t)src | (intptr_t)dest | count ) & 3 ) {
// happens in westernq3 memcpy(dest, src, count);
Com_Printf( S_COLOR_YELLOW "Warning: OP_BLOCK_COPY not dword aligned\n");
}
count >>= 2;
for ( i = count-1 ; i>= 0 ; i-- ) {
dest[i] = src[i];
}
programCounter += 4; programCounter += 4;
opStack -= 2; opStack -= 2;
} }