Make sure code is only compiled if the appropriate subsystem is enabled

This commit is contained in:
Sam Lantinga
2006-04-14 04:46:47 +00:00
parent 3ca6badbcf
commit 4ffa1daabc
54 changed files with 173 additions and 6 deletions

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_AMIGA
#include <stdio.h>
#include <time.h>
#include <signal.h>
@@ -261,3 +263,5 @@ void SDL_SYS_StopTimer(void)
{
return;
}
#endif /* SDL_TIMER_AMIGA */

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_BEOS
#include <be/kernel/OS.h>
#include "SDL_thread.h"
@@ -89,3 +91,5 @@ void SDL_SYS_StopTimer(void)
{
return;
}
#endif /* SDL_TIMER_BEOS */

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_DC
#include <kos.h>
#include "SDL_thread.h"
@@ -94,3 +96,5 @@ void SDL_SYS_StopTimer(void)
{
return;
}
#endif /* SDL_TIMER_DC */

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#if defined(SDL_TIMER_DUMMY) || defined(SDL_TIMERS_DISABLED)
#include "SDL_timer.h"
#include "../SDL_timer_c.h"
@@ -85,3 +87,5 @@ void SDL_SYS_StopTimer(void)
{
return;
}
#endif /* SDL_TIMER_DUMMY || SDL_TIMERS_DISABLED */

View File

@@ -19,6 +19,9 @@
Sam Lantinga
slouken@libsdl.org
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_EPOC
/*
SDL_systimer.cpp
@@ -109,3 +112,5 @@ void SDL_SYS_StopTimer(void)
}
}; // extern "C"
#endif /* SDL_TIMER_EPOC */

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_MACOS
#include <Types.h>
#include <Timer.h>
#include <OSUtils.h>
@@ -146,3 +148,5 @@ void SDL_SYS_StopTimer(void)
{
RmvTime((QElemPtr)&gExtendedTimerRec.tmTask);
}
#endif /* SDL_TIMER_MACOS */

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_MACOS
#include <Types.h>
#include <Timer.h>
#include <OSUtils.h>
@@ -172,3 +174,5 @@ void SDL_SYS_StopTimer(void)
{
RmvTime((QElemPtr)&gExtendedTimerRec.tmTask);
}
#endif /* SDL_TIMER_MACOS */

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_MINT
/*
* TOS/MiNT timer driver
* based on vbl vector
@@ -151,3 +153,5 @@ void SDL_SYS_StopTimer(void)
{
return;
}
#endif /* SDL_TIMER_MINT */

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_OS2
#define INCL_DOSMISC
#define INCL_DOSERRORS
#define INCL_DOSSEMAPHORES
@@ -222,4 +224,4 @@ void SDL_SYS_StopTimer(void)
return;
}
#endif /* SDL_TIMER_OS2 */

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_RISCOS
#include <stdio.h>
#include <time.h>
#include <sys/time.h>
@@ -227,3 +229,5 @@ void SDL_SYS_StopTimer(void)
}
#endif /* SDL_THREADS_DISABLED */
#endif /* SDL_TIMER_RISCOS */

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_UNIX
#include <stdio.h>
#include <sys/time.h>
#include <signal.h>
@@ -234,3 +236,5 @@ void SDL_SYS_StopTimer(void)
}
#endif /* USE_ITIMER */
#endif /* SDL_TIMER_UNIX */

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_WIN32
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#include <mmsystem.h>
@@ -155,3 +157,4 @@ void SDL_SYS_StopTimer(void)
return;
}
#endif /* SDL_TIMER_WIN32 */

View File

@@ -21,6 +21,8 @@
*/
#include "SDL_config.h"
#ifdef SDL_TIMER_WINCE
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#include <mmsystem.h>
@@ -192,3 +194,5 @@ void SDL_SYS_StopTimer(void)
{
return;
}
#endif /* SDL_TIMER_WINCE */