compile fixes for true64

This commit is contained in:
Bill Currie 2001-05-30 22:22:58 +00:00
parent e0b00dfda0
commit cf16e6c5d7
2 changed files with 25 additions and 17 deletions

View file

@ -33,6 +33,9 @@
#include "qtypes.h" #include "qtypes.h"
#ifndef __GNUC__ #ifndef __GNUC__
# if defined (__DECC) && defined (__ALPHA)
# pragma nomember_alignment
# else
# if defined (__BORLANDC__) || defined (_MSC_VER) # if defined (__BORLANDC__) || defined (_MSC_VER)
# if (defined(__BORLANDC__) && (__BORLANDC__ < 0x550)) # if (defined(__BORLANDC__) && (__BORLANDC__ < 0x550))
# pragma option -a1 # pragma option -a1
@ -43,6 +46,7 @@
# else # else
# error do some data packing magic here (#pragma pack?) # error do some data packing magic here (#pragma pack?)
# endif # endif
# endif
#endif #endif
typedef struct _TargaHeader { typedef struct _TargaHeader {
@ -66,6 +70,10 @@ typedef struct _TargaHeader {
# else # else
# pragma pack(pop, tgainclude) # pragma pack(pop, tgainclude)
# endif # endif
#else
# if defined (__DECC) && defined (__ALPHA)
# pragma member_alignment
# endif
#endif #endif
byte *LoadTGA (QFile *fin); byte *LoadTGA (QFile *fin);

View file

@ -143,7 +143,7 @@ SNDDMA_InitWav ( void )
if ((format = (LPPCMWAVEFORMAT) if ((format = (LPPCMWAVEFORMAT)
mmeAllocMem(sizeof(*format))) == NULL) { mmeAllocMem(sizeof(*format))) == NULL) {
Con_SafePrintf("Failed to allocate PCMWAVEFORMAT struct\n"); Con_Printf("Failed to allocate PCMWAVEFORMAT struct\n");
return false; return false;
} }
@ -175,10 +175,10 @@ SNDDMA_InitWav ( void )
{ {
if (hr != MMSYSERR_ALLOCATED) { if (hr != MMSYSERR_ALLOCATED) {
mmeFreeMem(format); mmeFreeMem(format);
Con_SafePrintf ("waveOutOpen failed: %d\n", hr); Con_Printf ("waveOutOpen failed: %d\n", hr);
return false; return false;
} else { } else {
Con_SafePrintf ("waveOutOpen failed 2222\n"); Con_Printf ("waveOutOpen failed 2222\n");
} }
} }
mmeFreeMem(format); mmeFreeMem(format);
@ -192,7 +192,7 @@ SNDDMA_InitWav ( void )
gSndBufSize = WAV_BUFFERS*WAV_BUFFER_SIZE; gSndBufSize = WAV_BUFFERS*WAV_BUFFER_SIZE;
lpData = mmeAllocBuffer(gSndBufSize); lpData = mmeAllocBuffer(gSndBufSize);
if (!lpData) { if (!lpData) {
Con_SafePrintf ("Sound: Out of memory.\n"); Con_Printf ("Sound: Out of memory.\n");
FreeSound (); FreeSound ();
return false; return false;
} }
@ -207,7 +207,7 @@ SNDDMA_InitWav ( void )
if (lpWaveHdr == NULL) if (lpWaveHdr == NULL)
{ {
Con_SafePrintf ("Sound: Failed to Alloc header.\n"); Con_Printf ("Sound: Failed to Alloc header.\n");
FreeSound (); FreeSound ();
return false; return false;
} }
@ -253,9 +253,9 @@ SNDDMA_Init ( void )
if (snd_iswave) { if (snd_iswave) {
if (snd_firsttime) if (snd_firsttime)
Con_SafePrintf ("Wave sound initialized\n"); Con_Printf ("Wave sound initialized\n");
} else { } else {
Con_SafePrintf ("Wave sound failed to init\n"); Con_Printf ("Wave sound failed to init\n");
} }
} }
@ -263,7 +263,7 @@ SNDDMA_Init ( void )
if (!wav_init) { if (!wav_init) {
if (snd_firsttime) if (snd_firsttime)
Con_SafePrintf ("No sound device initialized\n"); Con_Printf ("No sound device initialized\n");
return 0; return 0;
} }
@ -339,7 +339,7 @@ SNDDMA_Submit ( void )
if (wResult != MMSYSERR_NOERROR) if (wResult != MMSYSERR_NOERROR)
{ {
Con_SafePrintf ("Failed to write block to device\n"); Con_Printf ("Failed to write block to device\n");
FreeSound (); FreeSound ();
return; return;
} }