Make sure code is only compiled if the appropriate subsystem is enabled
authorSam Lantinga <slouken@libsdl.org>
Fri, 14 Apr 2006 04:46:47 +0000
changeset 163592947e3a18db
parent 1634 14f302c5b32c
child 1636 3d0dec74ad01
Make sure code is only compiled if the appropriate subsystem is enabled
include/SDL_config.h.in
src/cdrom/aix/SDL_syscdrom.c
src/cdrom/beos/SDL_syscdrom.cc
src/cdrom/bsdi/SDL_syscdrom.c
src/cdrom/dc/SDL_syscdrom.c
src/cdrom/dummy/SDL_syscdrom.c
src/cdrom/freebsd/SDL_syscdrom.c
src/cdrom/linux/SDL_syscdrom.c
src/cdrom/macos/SDL_syscdrom.c
src/cdrom/macosx/SDL_syscdrom.c
src/cdrom/mint/SDL_syscdrom.c
src/cdrom/openbsd/SDL_syscdrom.c
src/cdrom/os2/SDL_syscdrom.c
src/cdrom/osf/SDL_syscdrom.c
src/cdrom/qnx/SDL_syscdrom.c
src/cdrom/win32/SDL_syscdrom.c
src/joystick/amigaos/SDL_sysjoystick.c
src/joystick/beos/SDL_bejoystick.cc
src/joystick/bsd/SDL_sysjoystick.c
src/joystick/darwin/SDL_sysjoystick.c
src/joystick/dc/SDL_sysjoystick.c
src/joystick/dummy/SDL_sysjoystick.c
src/joystick/linux/SDL_sysjoystick.c
src/joystick/macos/SDL_sysjoystick.c
src/joystick/mint/SDL_sysjoystick.c
src/joystick/os2/SDL_sysjoystick.c
src/joystick/riscos/SDL_sysjoystick.c
src/joystick/win32/SDL_mmjoystick.c
src/loadso/beos/SDL_sysloadso.c
src/loadso/dlopen/SDL_sysloadso.c
src/loadso/dummy/SDL_sysloadso.c
src/loadso/macos/SDL_sysloadso.c
src/loadso/macosx/SDL_sysloadso.c
src/loadso/mint/SDL_sysloadso.c
src/loadso/os2/SDL_sysloadso.c
src/loadso/win32/SDL_sysloadso.c
src/thread/epoc/SDL_sysmutex.cpp
src/thread/epoc/SDL_syssem.cpp
src/thread/epoc/SDL_systhread.cpp
src/timer/amigaos/SDL_systimer.c
src/timer/beos/SDL_systimer.c
src/timer/dc/SDL_systimer.c
src/timer/dummy/SDL_systimer.c
src/timer/epoc/SDL_systimer.cpp
src/timer/macos/SDL_MPWtimer.c
src/timer/macos/SDL_systimer.c
src/timer/mint/SDL_systimer.c
src/timer/os2/SDL_systimer.c
src/timer/riscos/SDL_systimer.c
src/timer/unix/SDL_systimer.c
src/timer/win32/SDL_systimer.c
src/timer/wince/SDL_systimer.c
src/video/epoc/SDL_epocevents.cpp
src/video/epoc/SDL_epocvideo.cpp
     1.1 --- a/include/SDL_config.h.in	Fri Apr 14 03:56:31 2006 +0000
     1.2 +++ b/include/SDL_config.h.in	Fri Apr 14 04:46:47 2006 +0000
     1.3 @@ -214,6 +214,7 @@
     1.4  #undef SDL_LOADSO_BEOS
     1.5  #undef SDL_LOADSO_DLCOMPAT
     1.6  #undef SDL_LOADSO_DLOPEN
     1.7 +#undef SDL_LOADSO_DUMMY
     1.8  #undef SDL_LOADSO_LDG
     1.9  #undef SDL_LOADSO_MACOS
    1.10  #undef SDL_LOADSO_OS2
    1.11 @@ -236,6 +237,7 @@
    1.12  #undef SDL_TIMER_AMIGA
    1.13  #undef SDL_TIMER_BEOS
    1.14  #undef SDL_TIMER_DC
    1.15 +#undef SDL_TIMER_DUMMY
    1.16  #undef SDL_TIMER_EPOC
    1.17  #undef SDL_TIMER_MACOS
    1.18  #undef SDL_TIMER_MINT
     2.1 --- a/src/cdrom/aix/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
     2.2 +++ b/src/cdrom/aix/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
     2.3 @@ -23,6 +23,8 @@
     2.4  */
     2.5  #include "SDL_config.h"
     2.6  
     2.7 +#ifdef SDL_CDROM_AIX
     2.8 +
     2.9  /* Functions for system-level CD-ROM audio control */
    2.10  
    2.11  /*#define DEBUG_CDROM 1*/
    2.12 @@ -655,3 +657,4 @@
    2.13  	}
    2.14  }
    2.15  
    2.16 +#endif /* SDL_CDROM_AIX */
     3.1 --- a/src/cdrom/beos/SDL_syscdrom.cc	Fri Apr 14 03:56:31 2006 +0000
     3.2 +++ b/src/cdrom/beos/SDL_syscdrom.cc	Fri Apr 14 04:46:47 2006 +0000
     3.3 @@ -21,6 +21,8 @@
     3.4  */
     3.5  #include "SDL_config.h"
     3.6  
     3.7 +#ifdef SDL_CDROM_BEOS
     3.8 +
     3.9  /* Functions for system-level CD-ROM audio control on BeOS
    3.10     (not completely implemented yet)
    3.11   */
    3.12 @@ -407,3 +409,4 @@
    3.13  	}
    3.14  }
    3.15  
    3.16 +#endif /* SDL_CDROM_BEOS */
     4.1 --- a/src/cdrom/bsdi/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
     4.2 +++ b/src/cdrom/bsdi/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
     4.3 @@ -21,6 +21,8 @@
     4.4  */
     4.5  #include "SDL_config.h"
     4.6  
     4.7 +#ifdef SDL_CDROM_BSDI
     4.8 +
     4.9  /*
    4.10   * Functions for system-level CD-ROM audio control for BSD/OS 4.x
    4.11   * This started life out as a copy of the freebsd/SDL_cdrom.c file but was
    4.12 @@ -536,3 +538,5 @@
    4.13  		}
    4.14  	SDL_numcds = 0;
    4.15  }
    4.16 +
    4.17 +#endif /* SDL_CDROM_BSDI */
     5.1 --- a/src/cdrom/dc/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
     5.2 +++ b/src/cdrom/dc/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
     5.3 @@ -21,6 +21,8 @@
     5.4  */
     5.5  #include "SDL_config.h"
     5.6  
     5.7 +#ifdef SDL_CDROM_DC
     5.8 +
     5.9  /* Functions for system-level CD-ROM audio control */
    5.10  
    5.11  #include <dc/cdrom.h>
    5.12 @@ -161,3 +163,5 @@
    5.13  {
    5.14  
    5.15  }
    5.16 +
    5.17 +#endif /* SDL_CDROM_DC */
     6.1 --- a/src/cdrom/dummy/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
     6.2 +++ b/src/cdrom/dummy/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
     6.3 @@ -21,6 +21,8 @@
     6.4  */
     6.5  #include "SDL_config.h"
     6.6  
     6.7 +#if defined(SDL_CDROM_DUMMY) || defined(SDL_CDROM_DISABLED)
     6.8 +
     6.9  /* Stub functions for system-level CD-ROM audio control */
    6.10  
    6.11  #include "SDL_cdrom.h"
    6.12 @@ -36,3 +38,4 @@
    6.13  	return;
    6.14  }
    6.15  
    6.16 +#endif /* SDL_CDROM_DUMMY || SDL_CDROM_DISABLED */
     7.1 --- a/src/cdrom/freebsd/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
     7.2 +++ b/src/cdrom/freebsd/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
     7.3 @@ -21,6 +21,8 @@
     7.4  */
     7.5  #include "SDL_config.h"
     7.6  
     7.7 +#ifdef SDL_CDROM_FREEBSD
     7.8 +
     7.9  /* Functions for system-level CD-ROM audio control */
    7.10  
    7.11  #include <sys/types.h>
    7.12 @@ -401,3 +403,4 @@
    7.13  	}
    7.14  }
    7.15  
    7.16 +#endif /* SDL_CDROM_FREEBSD */
     8.1 --- a/src/cdrom/linux/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
     8.2 +++ b/src/cdrom/linux/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
     8.3 @@ -21,6 +21,8 @@
     8.4  */
     8.5  #include "SDL_config.h"
     8.6  
     8.7 +#ifdef SDL_CDROM_LINUX
     8.8 +
     8.9  /* Functions for system-level CD-ROM audio control */
    8.10  
    8.11  #include <string.h>	/* For strerror() */
    8.12 @@ -559,3 +561,4 @@
    8.13  	}
    8.14  }
    8.15  
    8.16 +#endif /* SDL_CDROM_LINUX */
     9.1 --- a/src/cdrom/macos/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
     9.2 +++ b/src/cdrom/macos/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
     9.3 @@ -21,6 +21,8 @@
     9.4  */
     9.5  #include "SDL_config.h"
     9.6  
     9.7 +#ifdef SDL_CDROM_MACOS
     9.8 +
     9.9  /* MacOS functions for system-level CD-ROM audio control */
    9.10  
    9.11  #include <Devices.h>
    9.12 @@ -520,3 +522,4 @@
    9.13  		SDL_memset(SDL_cdlist + SDL_numcds, 0, sizeof(SDL_cdlist[0]));
    9.14  }
    9.15  
    9.16 +#endif /* SDL_CDROM_MACOS */
    10.1 --- a/src/cdrom/macosx/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
    10.2 +++ b/src/cdrom/macosx/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
    10.3 @@ -21,6 +21,8 @@
    10.4  */
    10.5  #include "SDL_config.h"
    10.6  
    10.7 +#ifdef SDL_CDROM_MACOSX
    10.8 +
    10.9  #include "SDL_syscdrom_c.h"
   10.10  
   10.11  #pragma mark -- Globals --
   10.12 @@ -502,3 +504,4 @@
   10.13      return;
   10.14  }
   10.15  
   10.16 +#endif /* SDL_CDROM_MACOSX */
    11.1 --- a/src/cdrom/mint/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
    11.2 +++ b/src/cdrom/mint/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
    11.3 @@ -21,6 +21,8 @@
    11.4  */
    11.5  #include "SDL_config.h"
    11.6  
    11.7 +#ifdef SDL_CDROM_MINT
    11.8 +
    11.9  /*
   11.10  	Atari MetaDOS CD-ROM functions
   11.11  
   11.12 @@ -311,3 +313,5 @@
   11.13  {
   11.14  	return SDL_SYS_CDioctl(cdrom->id, CDROMEJECT, 0);
   11.15  }
   11.16 +
   11.17 +#endif /* SDL_CDROM_MINT */
    12.1 --- a/src/cdrom/openbsd/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
    12.2 +++ b/src/cdrom/openbsd/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
    12.3 @@ -21,6 +21,8 @@
    12.4  */
    12.5  #include "SDL_config.h"
    12.6  
    12.7 +#ifdef SDL_CDROM_OPENBSD
    12.8 +
    12.9  /* Functions for system-level CD-ROM audio control */
   12.10  
   12.11  #include <sys/types.h>
   12.12 @@ -410,3 +412,4 @@
   12.13  	}
   12.14  }
   12.15  
   12.16 +#endif /* SDL_CDROM_OPENBSD */
    13.1 --- a/src/cdrom/os2/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
    13.2 +++ b/src/cdrom/os2/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
    13.3 @@ -21,6 +21,8 @@
    13.4  */
    13.5  #include "SDL_config.h"
    13.6  
    13.7 +#ifdef SDL_CDROM_OS2
    13.8 +
    13.9  /* Functions for system-level CD-ROM audio control */
   13.10  
   13.11  #define INCL_MCIOS2
   13.12 @@ -388,3 +390,4 @@
   13.13  	}
   13.14  }
   13.15  
   13.16 +#endif /* SDL_CDROM_OS2 */
    14.1 --- a/src/cdrom/osf/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
    14.2 +++ b/src/cdrom/osf/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
    14.3 @@ -20,6 +20,8 @@
    14.4  */
    14.5  #include "SDL_config.h"
    14.6  
    14.7 +#ifdef SDL_CDROM_OSF
    14.8 +
    14.9  /* Functions for system-level CD-ROM audio control */
   14.10  
   14.11  /* #define DEBUG_CDROM 1 */
   14.12 @@ -439,4 +441,4 @@
   14.13      }
   14.14  }
   14.15  
   14.16 -
   14.17 +#endif /* SDL_CDROM_OSF */
    15.1 --- a/src/cdrom/qnx/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
    15.2 +++ b/src/cdrom/qnx/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
    15.3 @@ -21,6 +21,8 @@
    15.4  */
    15.5  #include "SDL_config.h"
    15.6  
    15.7 +#ifdef SDL_CDROM_QNX
    15.8 +
    15.9  /* Functions for system-level CD-ROM audio control */
   15.10  
   15.11  #include <sys/types.h>
   15.12 @@ -545,3 +547,5 @@
   15.13          SDL_numcds = 0;
   15.14      }
   15.15  }
   15.16 +
   15.17 +#endif /* SDL_CDROM_QNX */
    16.1 --- a/src/cdrom/win32/SDL_syscdrom.c	Fri Apr 14 03:56:31 2006 +0000
    16.2 +++ b/src/cdrom/win32/SDL_syscdrom.c	Fri Apr 14 04:46:47 2006 +0000
    16.3 @@ -21,6 +21,8 @@
    16.4  */
    16.5  #include "SDL_config.h"
    16.6  
    16.7 +#ifdef SDL_CDROM_WIN32
    16.8 +
    16.9  /* Functions for system-level CD-ROM audio control */
   16.10  
   16.11  #define WIN32_LEAN_AND_MEAN
   16.12 @@ -379,3 +381,5 @@
   16.13  		SDL_numcds = 0;
   16.14  	}
   16.15  }
   16.16 +
   16.17 +#endif /* SDL_CDROM_WIN32 */
    17.1 --- a/src/joystick/amigaos/SDL_sysjoystick.c	Fri Apr 14 03:56:31 2006 +0000
    17.2 +++ b/src/joystick/amigaos/SDL_sysjoystick.c	Fri Apr 14 04:46:47 2006 +0000
    17.3 @@ -21,6 +21,8 @@
    17.4  */
    17.5  #include "SDL_config.h"
    17.6  
    17.7 +#ifdef SDL_JOYSTICK_AMIGA
    17.8 +
    17.9  /* This is the system specific header for the SDL joystick API */
   17.10  
   17.11  #include <libraries/lowlevel.h>
   17.12 @@ -225,7 +227,7 @@
   17.13  		LowLevelBase=NULL;
   17.14  		SDL_numjoysticks=0;
   17.15  	}
   17.16 -
   17.17  	return;
   17.18  }
   17.19  
   17.20 +#endif /* SDL_JOYSTICK_AMIGA */
    18.1 --- a/src/joystick/beos/SDL_bejoystick.cc	Fri Apr 14 03:56:31 2006 +0000
    18.2 +++ b/src/joystick/beos/SDL_bejoystick.cc	Fri Apr 14 04:46:47 2006 +0000
    18.3 @@ -21,6 +21,8 @@
    18.4  */
    18.5  #include "SDL_config.h"
    18.6  
    18.7 +#ifdef SDL_JOYSTICK_BEOS
    18.8 +
    18.9  /* This is the system specific header for the SDL joystick API */
   18.10  
   18.11  #include <be/support/String.h>
   18.12 @@ -231,3 +233,5 @@
   18.13  }
   18.14  
   18.15  }; // extern "C"
   18.16 +
   18.17 +#endif /* SDL_JOYSTICK_BEOS */
    19.1 --- a/src/joystick/bsd/SDL_sysjoystick.c	Fri Apr 14 03:56:31 2006 +0000
    19.2 +++ b/src/joystick/bsd/SDL_sysjoystick.c	Fri Apr 14 04:46:47 2006 +0000
    19.3 @@ -21,6 +21,8 @@
    19.4  */
    19.5  #include "SDL_config.h"
    19.6  
    19.7 +#ifdef SDL_JOYSTICK_USBHID
    19.8 +
    19.9  /*
   19.10   * Joystick driver for the uhid(4) interface found in OpenBSD,
   19.11   * NetBSD and FreeBSD.
   19.12 @@ -575,3 +577,4 @@
   19.13  	r->status = SREPORT_UNINIT;
   19.14  }
   19.15  
   19.16 +#endif /* SDL_JOYSTICK_USBHID */
    20.1 --- a/src/joystick/darwin/SDL_sysjoystick.c	Fri Apr 14 03:56:31 2006 +0000
    20.2 +++ b/src/joystick/darwin/SDL_sysjoystick.c	Fri Apr 14 04:46:47 2006 +0000
    20.3 @@ -21,6 +21,8 @@
    20.4  */
    20.5  #include "SDL_config.h"
    20.6  
    20.7 +#ifdef SDL_JOYSTICK_IOKIT
    20.8 +
    20.9  /* SDL joystick driver for Darwin / Mac OS X, based on the IOKit HID API */
   20.10  /* Written 2001 by Max Horn */
   20.11  
   20.12 @@ -836,3 +838,5 @@
   20.13  	while (NULL != gpDeviceList)
   20.14  		gpDeviceList = HIDDisposeDevice (&gpDeviceList);
   20.15  }
   20.16 +
   20.17 +#endif /* SDL_JOYSTICK_IOKIT */
    21.1 --- a/src/joystick/dc/SDL_sysjoystick.c	Fri Apr 14 03:56:31 2006 +0000
    21.2 +++ b/src/joystick/dc/SDL_sysjoystick.c	Fri Apr 14 04:46:47 2006 +0000
    21.3 @@ -21,6 +21,8 @@
    21.4  */
    21.5  #include "SDL_config.h"
    21.6  
    21.7 +#ifdef SDL_JOYSTICK_DC
    21.8 +
    21.9  #include "SDL_events.h"
   21.10  #include "SDL_joystick.h"
   21.11  #include "../SDL_sysjoystick.h"
   21.12 @@ -187,3 +189,5 @@
   21.13  {
   21.14  	return;
   21.15  }
   21.16 +
   21.17 +#endif /* SDL_JOYSTICK_DC */
    22.1 --- a/src/joystick/dummy/SDL_sysjoystick.c	Fri Apr 14 03:56:31 2006 +0000
    22.2 +++ b/src/joystick/dummy/SDL_sysjoystick.c	Fri Apr 14 04:46:47 2006 +0000
    22.3 @@ -21,6 +21,8 @@
    22.4  */
    22.5  #include "SDL_config.h"
    22.6  
    22.7 +#if defined(SDL_JOYSTICK_DUMMY) || defined(SDL_JOYSTICK_DISABLED)
    22.8 +
    22.9  /* This is the system specific header for the SDL joystick API */
   22.10  
   22.11  #include "SDL_joystick.h"
   22.12 @@ -78,3 +80,4 @@
   22.13  	return;
   22.14  }
   22.15  
   22.16 +#endif /* SDL_JOYSTICK_DUMMY || SDL_JOYSTICK_DISABLED */
    23.1 --- a/src/joystick/linux/SDL_sysjoystick.c	Fri Apr 14 03:56:31 2006 +0000
    23.2 +++ b/src/joystick/linux/SDL_sysjoystick.c	Fri Apr 14 04:46:47 2006 +0000
    23.3 @@ -21,6 +21,8 @@
    23.4  */
    23.5  #include "SDL_config.h"
    23.6  
    23.7 +#ifdef SDL_JOYSTICK_LINUX
    23.8 +
    23.9  /* This is the system specific header for the SDL joystick API */
   23.10  
   23.11  #include <sys/stat.h>
   23.12 @@ -1195,3 +1197,4 @@
   23.13  	SDL_joylist[0].fname = NULL;
   23.14  }
   23.15  
   23.16 +#endif /* SDL_JOYSTICK_LINUX */
    24.1 --- a/src/joystick/macos/SDL_sysjoystick.c	Fri Apr 14 03:56:31 2006 +0000
    24.2 +++ b/src/joystick/macos/SDL_sysjoystick.c	Fri Apr 14 04:46:47 2006 +0000
    24.3 @@ -21,6 +21,8 @@
    24.4  */
    24.5  #include "SDL_config.h"
    24.6  
    24.7 +#ifdef SDL_JOYSTICK_MACOS
    24.8 +
    24.9  /*  SDL stuff  --  "SDL_sysjoystick.c"
   24.10      MacOS joystick functions by Frederick Reitberger
   24.11  
   24.12 @@ -315,3 +317,4 @@
   24.13      ISpShutdown();
   24.14  }
   24.15  
   24.16 +#endif /* SDL_JOYSTICK_MACOS */
    25.1 --- a/src/joystick/mint/SDL_sysjoystick.c	Fri Apr 14 03:56:31 2006 +0000
    25.2 +++ b/src/joystick/mint/SDL_sysjoystick.c	Fri Apr 14 04:46:47 2006 +0000
    25.3 @@ -21,6 +21,8 @@
    25.4  */
    25.5  #include "SDL_config.h"
    25.6  
    25.7 +#ifdef SDL_JOYSTICK_MINT
    25.8 +
    25.9  /*
   25.10   *	Atari Joystick/Joypad drivers
   25.11   *
   25.12 @@ -627,3 +629,5 @@
   25.13  	JOYPAD_IO.directions=0xff7f;
   25.14  	jp_joypads[1] |= (((~(JOYPAD_IO.directions))>>12) & 15)<<12;
   25.15  }
   25.16 +
   25.17 +#endif /* SDL_JOYSTICK_MINT */
    26.1 --- a/src/joystick/os2/SDL_sysjoystick.c	Fri Apr 14 03:56:31 2006 +0000
    26.2 +++ b/src/joystick/os2/SDL_sysjoystick.c	Fri Apr 14 04:46:47 2006 +0000
    26.3 @@ -21,6 +21,8 @@
    26.4  */
    26.5  #include "SDL_config.h"
    26.6  
    26.7 +#ifdef SDL_JOYSTICK_OS2
    26.8 +
    26.9  /* OS/2 Joystick driver, contributed by Daniel Caetano */
   26.10  
   26.11  #include <mem.h>
   26.12 @@ -663,4 +665,4 @@
   26.13  return chcnt;
   26.14  }
   26.15  
   26.16 -
   26.17 +#endif /* SDL_JOYSTICK_OS2 */
    27.1 --- a/src/joystick/riscos/SDL_sysjoystick.c	Fri Apr 14 03:56:31 2006 +0000
    27.2 +++ b/src/joystick/riscos/SDL_sysjoystick.c	Fri Apr 14 04:46:47 2006 +0000
    27.3 @@ -21,6 +21,8 @@
    27.4  */
    27.5  #include "SDL_config.h"
    27.6  
    27.7 +#ifdef SDL_JOYSTICK_RISCOS
    27.8 +
    27.9  /*
   27.10     RISC OS - Joystick support by Alan Buckley (alan_baa@hotmail.com) - 10 April 2003
   27.11  
   27.12 @@ -171,3 +173,4 @@
   27.13  	return;
   27.14  }
   27.15  
   27.16 +#endif /* SDL_JOYSTICK_RISCOS */
    28.1 --- a/src/joystick/win32/SDL_mmjoystick.c	Fri Apr 14 03:56:31 2006 +0000
    28.2 +++ b/src/joystick/win32/SDL_mmjoystick.c	Fri Apr 14 04:46:47 2006 +0000
    28.3 @@ -21,6 +21,8 @@
    28.4  */
    28.5  #include "SDL_config.h"
    28.6  
    28.7 +#ifdef SDL_JOYSTICK_WINMM
    28.8 +
    28.9  /* Win32 MultiMedia Joystick driver, contributed by Andrei de A. Formiga */
   28.10  
   28.11  #define WIN32_LEAN_AND_MEAN
   28.12 @@ -416,3 +418,5 @@
   28.13  	}
   28.14  	SDL_SetError("%s", errbuf);
   28.15  }
   28.16 +
   28.17 +#endif /* SDL_JOYSTICK_WINMM */
    29.1 --- a/src/loadso/beos/SDL_sysloadso.c	Fri Apr 14 03:56:31 2006 +0000
    29.2 +++ b/src/loadso/beos/SDL_sysloadso.c	Fri Apr 14 04:46:47 2006 +0000
    29.3 @@ -21,6 +21,8 @@
    29.4  */
    29.5  #include "SDL_config.h"
    29.6  
    29.7 +#ifdef SDL_LOADSO_BEOS
    29.8 +
    29.9  /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
   29.10  /* System dependent library loading routines                           */
   29.11  
   29.12 @@ -71,3 +73,4 @@
   29.13  	}
   29.14  }
   29.15  
   29.16 +#endif /* SDL_LOADSO_BEOS */
    30.1 --- a/src/loadso/dlopen/SDL_sysloadso.c	Fri Apr 14 03:56:31 2006 +0000
    30.2 +++ b/src/loadso/dlopen/SDL_sysloadso.c	Fri Apr 14 04:46:47 2006 +0000
    30.3 @@ -21,6 +21,8 @@
    30.4  */
    30.5  #include "SDL_config.h"
    30.6  
    30.7 +#ifdef SDL_LOADSO_DLOPEN
    30.8 +
    30.9  /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
   30.10  /* System dependent library loading routines                           */
   30.11  
   30.12 @@ -63,3 +65,4 @@
   30.13  	}
   30.14  }
   30.15  
   30.16 +#endif /* SDL_LOADSO_DLOPEN */
    31.1 --- a/src/loadso/dummy/SDL_sysloadso.c	Fri Apr 14 03:56:31 2006 +0000
    31.2 +++ b/src/loadso/dummy/SDL_sysloadso.c	Fri Apr 14 04:46:47 2006 +0000
    31.3 @@ -21,6 +21,8 @@
    31.4  */
    31.5  #include "SDL_config.h"
    31.6  
    31.7 +#if defined(SDL_LOADSO_DUMMY) || defined(SDL_LOADSO_DISABLED)
    31.8 +
    31.9  /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
   31.10  /* System dependent library loading routines                           */
   31.11  
   31.12 @@ -45,3 +47,4 @@
   31.13      /* no-op. */
   31.14  }
   31.15  
   31.16 +#endif /* SDL_LOADSO_DUMMY || SDL_LOADSO_DISABLED */
    32.1 --- a/src/loadso/macos/SDL_sysloadso.c	Fri Apr 14 03:56:31 2006 +0000
    32.2 +++ b/src/loadso/macos/SDL_sysloadso.c	Fri Apr 14 04:46:47 2006 +0000
    32.3 @@ -21,6 +21,8 @@
    32.4  */
    32.5  #include "SDL_config.h"
    32.6  
    32.7 +#ifdef SDL_LOADSO_MACOS
    32.8 +
    32.9  /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
   32.10  /* System dependent library loading routines                           */
   32.11  
   32.12 @@ -101,3 +103,4 @@
   32.13  	}
   32.14  }
   32.15  
   32.16 +#endif /* SDL_LOADSO_MACOS */
    33.1 --- a/src/loadso/macosx/SDL_sysloadso.c	Fri Apr 14 03:56:31 2006 +0000
    33.2 +++ b/src/loadso/macosx/SDL_sysloadso.c	Fri Apr 14 04:46:47 2006 +0000
    33.3 @@ -21,6 +21,8 @@
    33.4  */
    33.5  #include "SDL_config.h"
    33.6  
    33.7 +#ifdef SDL_LOADSO_DLCOMPAT
    33.8 +
    33.9  /* Please note that dlcompat apparently ships in current Mac OS X versions
   33.10   *  as a system library that provides compatibility with the Unix "dlopen"
   33.11   *  interface. In order to allow SDL to work on older OS X releases and also
   33.12 @@ -1399,3 +1401,4 @@
   33.13  	}
   33.14  }
   33.15  
   33.16 +#endif /* SDL_LOADSO_DLCOMPAT */
    34.1 --- a/src/loadso/mint/SDL_sysloadso.c	Fri Apr 14 03:56:31 2006 +0000
    34.2 +++ b/src/loadso/mint/SDL_sysloadso.c	Fri Apr 14 04:46:47 2006 +0000
    34.3 @@ -21,6 +21,8 @@
    34.4  */
    34.5  #include "SDL_config.h"
    34.6  
    34.7 +#ifdef SDL_LOADSO_LDG
    34.8 +
    34.9  /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
   34.10  /* System dependent library loading routines                           */
   34.11  
   34.12 @@ -57,3 +59,4 @@
   34.13  	}
   34.14  }
   34.15  
   34.16 +#endif /* SDL_LOADSO_LDG */
    35.1 --- a/src/loadso/os2/SDL_sysloadso.c	Fri Apr 14 03:56:31 2006 +0000
    35.2 +++ b/src/loadso/os2/SDL_sysloadso.c	Fri Apr 14 04:46:47 2006 +0000
    35.3 @@ -21,6 +21,8 @@
    35.4  */
    35.5  #include "SDL_config.h"
    35.6  
    35.7 +#ifdef SDL_LOADSO_OS2
    35.8 +
    35.9  /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
   35.10  /* System dependent library loading routines                           */
   35.11  
   35.12 @@ -66,3 +68,4 @@
   35.13          DosFreeModule((HMODULE) handle);
   35.14  }
   35.15  
   35.16 +#endif /* SDL_LOADSO_OS2 */
    36.1 --- a/src/loadso/win32/SDL_sysloadso.c	Fri Apr 14 03:56:31 2006 +0000
    36.2 +++ b/src/loadso/win32/SDL_sysloadso.c	Fri Apr 14 04:46:47 2006 +0000
    36.3 @@ -21,6 +21,8 @@
    36.4  */
    36.5  #include "SDL_config.h"
    36.6  
    36.7 +#ifdef SDL_LOADSO_WIN32
    36.8 +
    36.9  /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
   36.10  /* System dependent library loading routines                           */
   36.11  
   36.12 @@ -134,3 +136,4 @@
   36.13  	}
   36.14  }
   36.15  
   36.16 +#endif /* SDL_LOADSO_WIN32 */
    37.1 --- a/src/thread/epoc/SDL_sysmutex.cpp	Fri Apr 14 03:56:31 2006 +0000
    37.2 +++ b/src/thread/epoc/SDL_sysmutex.cpp	Fri Apr 14 04:46:47 2006 +0000
    37.3 @@ -19,6 +19,7 @@
    37.4      Sam Lantinga
    37.5      slouken@libsdl.org
    37.6  */
    37.7 +#include "SDL_config.h"
    37.8  
    37.9  /*
   37.10      SDL_sysmutex.cpp
    38.1 --- a/src/thread/epoc/SDL_syssem.cpp	Fri Apr 14 03:56:31 2006 +0000
    38.2 +++ b/src/thread/epoc/SDL_syssem.cpp	Fri Apr 14 04:46:47 2006 +0000
    38.3 @@ -19,6 +19,7 @@
    38.4      Sam Lantinga
    38.5      slouken@libsdl.org
    38.6  */
    38.7 +#include "SDL_config.h"
    38.8  
    38.9  /*
   38.10      SDL_syssem.cpp
    39.1 --- a/src/thread/epoc/SDL_systhread.cpp	Fri Apr 14 03:56:31 2006 +0000
    39.2 +++ b/src/thread/epoc/SDL_systhread.cpp	Fri Apr 14 04:46:47 2006 +0000
    39.3 @@ -19,6 +19,7 @@
    39.4      Sam Lantinga
    39.5      slouken@libsdl.org
    39.6  */
    39.7 +#include "SDL_config.h"
    39.8  
    39.9  /*
   39.10      SDL_systhread.cpp
    40.1 --- a/src/timer/amigaos/SDL_systimer.c	Fri Apr 14 03:56:31 2006 +0000
    40.2 +++ b/src/timer/amigaos/SDL_systimer.c	Fri Apr 14 04:46:47 2006 +0000
    40.3 @@ -21,6 +21,8 @@
    40.4  */
    40.5  #include "SDL_config.h"
    40.6  
    40.7 +#ifdef SDL_TIMER_AMIGA
    40.8 +
    40.9  #include <stdio.h>
   40.10  #include <time.h>
   40.11  #include <signal.h>
   40.12 @@ -261,3 +263,5 @@
   40.13  {
   40.14  	return;
   40.15  }
   40.16 +
   40.17 +#endif /* SDL_TIMER_AMIGA */
    41.1 --- a/src/timer/beos/SDL_systimer.c	Fri Apr 14 03:56:31 2006 +0000
    41.2 +++ b/src/timer/beos/SDL_systimer.c	Fri Apr 14 04:46:47 2006 +0000
    41.3 @@ -21,6 +21,8 @@
    41.4  */
    41.5  #include "SDL_config.h"
    41.6  
    41.7 +#ifdef SDL_TIMER_BEOS
    41.8 +
    41.9  #include <be/kernel/OS.h>
   41.10  
   41.11  #include "SDL_thread.h"
   41.12 @@ -89,3 +91,5 @@
   41.13  {
   41.14  	return;
   41.15  }
   41.16 +
   41.17 +#endif /* SDL_TIMER_BEOS */
    42.1 --- a/src/timer/dc/SDL_systimer.c	Fri Apr 14 03:56:31 2006 +0000
    42.2 +++ b/src/timer/dc/SDL_systimer.c	Fri Apr 14 04:46:47 2006 +0000
    42.3 @@ -21,6 +21,8 @@
    42.4  */
    42.5  #include "SDL_config.h"
    42.6  
    42.7 +#ifdef SDL_TIMER_DC
    42.8 +
    42.9  #include <kos.h>
   42.10  
   42.11  #include "SDL_thread.h"
   42.12 @@ -94,3 +96,5 @@
   42.13  {
   42.14  	return;
   42.15  }
   42.16 +
   42.17 +#endif /* SDL_TIMER_DC */
    43.1 --- a/src/timer/dummy/SDL_systimer.c	Fri Apr 14 03:56:31 2006 +0000
    43.2 +++ b/src/timer/dummy/SDL_systimer.c	Fri Apr 14 04:46:47 2006 +0000
    43.3 @@ -21,6 +21,8 @@
    43.4  */
    43.5  #include "SDL_config.h"
    43.6  
    43.7 +#if defined(SDL_TIMER_DUMMY) || defined(SDL_TIMERS_DISABLED)
    43.8 +
    43.9  #include "SDL_timer.h"
   43.10  #include "../SDL_timer_c.h"
   43.11  
   43.12 @@ -85,3 +87,5 @@
   43.13  {
   43.14  	return;
   43.15  }
   43.16 +
   43.17 +#endif /* SDL_TIMER_DUMMY || SDL_TIMERS_DISABLED */
    44.1 --- a/src/timer/epoc/SDL_systimer.cpp	Fri Apr 14 03:56:31 2006 +0000
    44.2 +++ b/src/timer/epoc/SDL_systimer.cpp	Fri Apr 14 04:46:47 2006 +0000
    44.3 @@ -19,6 +19,9 @@
    44.4      Sam Lantinga
    44.5      slouken@libsdl.org
    44.6  */
    44.7 +#include "SDL_config.h"
    44.8 +
    44.9 +#ifdef SDL_TIMER_EPOC
   44.10  
   44.11  /*
   44.12      SDL_systimer.cpp
   44.13 @@ -109,3 +112,5 @@
   44.14  }
   44.15  
   44.16  }; // extern "C"
   44.17 +
   44.18 +#endif /* SDL_TIMER_EPOC */
    45.1 --- a/src/timer/macos/SDL_MPWtimer.c	Fri Apr 14 03:56:31 2006 +0000
    45.2 +++ b/src/timer/macos/SDL_MPWtimer.c	Fri Apr 14 04:46:47 2006 +0000
    45.3 @@ -21,6 +21,8 @@
    45.4  */
    45.5  #include "SDL_config.h"
    45.6  
    45.7 +#ifdef SDL_TIMER_MACOS
    45.8 +
    45.9  #include <Types.h>
   45.10  #include <Timer.h>
   45.11  #include <OSUtils.h>
   45.12 @@ -146,3 +148,5 @@
   45.13  {
   45.14  	RmvTime((QElemPtr)&gExtendedTimerRec.tmTask);
   45.15  }
   45.16 +
   45.17 +#endif /* SDL_TIMER_MACOS */
    46.1 --- a/src/timer/macos/SDL_systimer.c	Fri Apr 14 03:56:31 2006 +0000
    46.2 +++ b/src/timer/macos/SDL_systimer.c	Fri Apr 14 04:46:47 2006 +0000
    46.3 @@ -21,6 +21,8 @@
    46.4  */
    46.5  #include "SDL_config.h"
    46.6  
    46.7 +#ifdef SDL_TIMER_MACOS
    46.8 +
    46.9  #include <Types.h>
   46.10  #include <Timer.h>
   46.11  #include <OSUtils.h>
   46.12 @@ -172,3 +174,5 @@
   46.13  {
   46.14  	RmvTime((QElemPtr)&gExtendedTimerRec.tmTask);
   46.15  }
   46.16 +
   46.17 +#endif /* SDL_TIMER_MACOS */
    47.1 --- a/src/timer/mint/SDL_systimer.c	Fri Apr 14 03:56:31 2006 +0000
    47.2 +++ b/src/timer/mint/SDL_systimer.c	Fri Apr 14 04:46:47 2006 +0000
    47.3 @@ -21,6 +21,8 @@
    47.4  */
    47.5  #include "SDL_config.h"
    47.6  
    47.7 +#ifdef SDL_TIMER_MINT
    47.8 +
    47.9  /*
   47.10   *	TOS/MiNT timer driver
   47.11   *	based on vbl vector
   47.12 @@ -151,3 +153,5 @@
   47.13  {
   47.14  	return;
   47.15  }
   47.16 +
   47.17 +#endif /* SDL_TIMER_MINT */
    48.1 --- a/src/timer/os2/SDL_systimer.c	Fri Apr 14 03:56:31 2006 +0000
    48.2 +++ b/src/timer/os2/SDL_systimer.c	Fri Apr 14 04:46:47 2006 +0000
    48.3 @@ -21,6 +21,8 @@
    48.4  */
    48.5  #include "SDL_config.h"
    48.6  
    48.7 +#ifdef SDL_TIMER_OS2
    48.8 +
    48.9  #define INCL_DOSMISC
   48.10  #define INCL_DOSERRORS
   48.11  #define INCL_DOSSEMAPHORES
   48.12 @@ -222,4 +224,4 @@
   48.13          return;
   48.14  }
   48.15  
   48.16 -
   48.17 +#endif /* SDL_TIMER_OS2 */
    49.1 --- a/src/timer/riscos/SDL_systimer.c	Fri Apr 14 03:56:31 2006 +0000
    49.2 +++ b/src/timer/riscos/SDL_systimer.c	Fri Apr 14 04:46:47 2006 +0000
    49.3 @@ -21,6 +21,8 @@
    49.4  */
    49.5  #include "SDL_config.h"
    49.6  
    49.7 +#ifdef SDL_TIMER_RISCOS
    49.8 +
    49.9  #include <stdio.h>
   49.10  #include <time.h>
   49.11  #include <sys/time.h>
   49.12 @@ -227,3 +229,5 @@
   49.13  }
   49.14  
   49.15  #endif /* SDL_THREADS_DISABLED */
   49.16 +
   49.17 +#endif /* SDL_TIMER_RISCOS */
    50.1 --- a/src/timer/unix/SDL_systimer.c	Fri Apr 14 03:56:31 2006 +0000
    50.2 +++ b/src/timer/unix/SDL_systimer.c	Fri Apr 14 04:46:47 2006 +0000
    50.3 @@ -21,6 +21,8 @@
    50.4  */
    50.5  #include "SDL_config.h"
    50.6  
    50.7 +#ifdef SDL_TIMER_UNIX
    50.8 +
    50.9  #include <stdio.h>
   50.10  #include <sys/time.h>
   50.11  #include <signal.h>
   50.12 @@ -234,3 +236,5 @@
   50.13  }
   50.14  
   50.15  #endif /* USE_ITIMER */
   50.16 +
   50.17 +#endif /* SDL_TIMER_UNIX */
    51.1 --- a/src/timer/win32/SDL_systimer.c	Fri Apr 14 03:56:31 2006 +0000
    51.2 +++ b/src/timer/win32/SDL_systimer.c	Fri Apr 14 04:46:47 2006 +0000
    51.3 @@ -21,6 +21,8 @@
    51.4  */
    51.5  #include "SDL_config.h"
    51.6  
    51.7 +#ifdef SDL_TIMER_WIN32
    51.8 +
    51.9  #define WIN32_LEAN_AND_MEAN
   51.10  #include <windows.h>
   51.11  #include <mmsystem.h>
   51.12 @@ -155,3 +157,4 @@
   51.13  	return;
   51.14  }
   51.15  
   51.16 +#endif /* SDL_TIMER_WIN32 */
    52.1 --- a/src/timer/wince/SDL_systimer.c	Fri Apr 14 03:56:31 2006 +0000
    52.2 +++ b/src/timer/wince/SDL_systimer.c	Fri Apr 14 04:46:47 2006 +0000
    52.3 @@ -21,6 +21,8 @@
    52.4  */
    52.5  #include "SDL_config.h"
    52.6  
    52.7 +#ifdef SDL_TIMER_WINCE
    52.8 +
    52.9  #define WIN32_LEAN_AND_MEAN
   52.10  #include <windows.h>
   52.11  #include <mmsystem.h>
   52.12 @@ -192,3 +194,5 @@
   52.13  {
   52.14  	return;
   52.15  }
   52.16 +
   52.17 +#endif /* SDL_TIMER_WINCE */
    53.1 --- a/src/video/epoc/SDL_epocevents.cpp	Fri Apr 14 03:56:31 2006 +0000
    53.2 +++ b/src/video/epoc/SDL_epocevents.cpp	Fri Apr 14 04:46:47 2006 +0000
    53.3 @@ -19,6 +19,7 @@
    53.4      Sam Lantinga
    53.5      slouken@libsdl.org
    53.6  */
    53.7 +#include "SDL_config.h"
    53.8  
    53.9  /*
   53.10      SDL_epocevents.cpp
    54.1 --- a/src/video/epoc/SDL_epocvideo.cpp	Fri Apr 14 03:56:31 2006 +0000
    54.2 +++ b/src/video/epoc/SDL_epocvideo.cpp	Fri Apr 14 04:46:47 2006 +0000
    54.3 @@ -19,6 +19,7 @@
    54.4      Sam Lantinga
    54.5      slouken@libsdl.org
    54.6  */
    54.7 +#include "SDL_config.h"
    54.8  
    54.9  /*
   54.10      SDL_epocvideo.cpp
   54.11 @@ -27,8 +28,6 @@
   54.12      Epoc version by Hannu Viitala (hannu.j.viitala@mbnet.fi)
   54.13  */
   54.14  
   54.15 -
   54.16 -
   54.17  extern "C" {
   54.18  #include "SDL_timer.h"
   54.19  #include "SDL_video.h"