Skip to content

Commit

Permalink
optionally remove cdrom support
Browse files Browse the repository at this point in the history
  • Loading branch information
timfel committed Mar 3, 2011
1 parent 9752e47 commit 8c8c07b
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
12 changes: 12 additions & 0 deletions configure.in
Expand Up @@ -355,6 +355,18 @@ AH_TEMPLATE(C_MODEM,[Define to 1 to enable internal modem support, requires SDL_
AH_TEMPLATE(C_IPX,[Define to 1 to enable IPX over Internet networking, requires SDL_net])
AC_CHECK_HEADER(SDL_net.h,have_sdl_net_h=yes,)

dnl enable disable sdl cdrom support
AC_ARG_ENABLE(cdrom,
AC_HELP_STRING([--enable-cdrom],[compile with SDL CD-ROM support (default yes)]),
[ case "${enableval}" in
yes) sdl_cdrom=true;;
no) sdl_cdrom=false;;
esac],
[sdl_cdrom=true])
if test x$sdl_cdrom = xtrue ; then
AC_DEFINE(USE_SDL_CDROM,1,[Define to 1 to enable CDROM support])
fi

if test x$host = xi386-pc-os2-emx ; then
AC_MSG_CHECKING(for SDLNet_Init in SDL_net);
LIBS_BACKUP=$LIBS;
Expand Down
6 changes: 4 additions & 2 deletions src/gui/sdlmain.cpp
Expand Up @@ -1772,8 +1772,10 @@ int main(int argc, char* argv[]) {
#if SDL_VERSION_ATLEAST(1, 2, 14)
putenv(const_cast<char*>("SDL_DISABLE_LOCK_KEYS=1"));
#endif
if ( SDL_Init( SDL_INIT_AUDIO|SDL_INIT_VIDEO|SDL_INIT_TIMER|SDL_INIT_CDROM
|SDL_INIT_NOPARACHUTE
if ( SDL_Init( SDL_INIT_AUDIO|SDL_INIT_VIDEO|SDL_INIT_TIMER|SDL_INIT_NOPARACHUTE
#ifdef USE_SDL_CDROM
|SDL_CDROM
#endif
) < 0 ) E_Exit("Can't init SDL %s",SDL_GetError());
sdl.inited = true;

Expand Down

0 comments on commit 8c8c07b

Please sign in to comment.