Fixed some MSVC warnings in the debugger code.

This commit is contained in:
Volker Ruppert 2014-12-23 11:53:35 +00:00
parent c3b025e224
commit 5abc3e647f
4 changed files with 22 additions and 10 deletions

View File

@ -2,7 +2,7 @@
// $Id$
/////////////////////////////////////////////////////////////////////////
//
// Copyright (C) 2001-2009 The Bochs Project
// Copyright (C) 2001-2014 The Bochs Project
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
@ -282,7 +282,7 @@ int bx_dbg_symbol_command(const char* filename, bx_bool global, Bit32u offset)
// The file format should be
// address symbol (example '00002afe _StartLoseNT')
Bit32u context_id = (global) ? 0 : (BX_CPU(dbg_cpu)->cr3) >> 12;
Bit32u context_id = (global) ? 0 : ((Bit32u)BX_CPU(dbg_cpu)->cr3) >> 12;
context_t* cntx = context_t::get_context(context_id);

13
bochs/configure vendored
View File

@ -1,5 +1,5 @@
#! /bin/sh
# From configure.in Id: configure.in 12561 2014-12-12 18:45:32Z vruppert .
# From configure.in Id: configure.in 12572 2014-12-20 07:51:11Z vruppert .
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.69.
#
@ -24877,10 +24877,15 @@ case "$target" in
else
C_OPT="/O2" # optimize for speed, no fastcall
fi
if test "$bx_plugins" = 1; then
CFLAGS="/nologo /MD /W3 /EHs-c- /DNDEBUG /DWIN32 /D_WINDOWS /D_CRT_SECURE_NO_WARNINGS $C_OPT"
if test "$bx_debugger" = 1; then
C_OPT="$C_OPT /EHsc"
else
CFLAGS="/nologo /MT /W3 /EHs-c- /DNDEBUG /DWIN32 /D_WINDOWS /D_CRT_SECURE_NO_WARNINGS $C_OPT"
C_OPT="$C_OPT /EHs-c-"
fi
if test "$bx_plugins" = 1; then
CFLAGS="/nologo /MD /W3 /DNDEBUG /DWIN32 /D_WINDOWS /D_CRT_SECURE_NO_WARNINGS $C_OPT"
else
CFLAGS="/nologo /MT /W3 /DNDEBUG /DWIN32 /D_WINDOWS /D_CRT_SECURE_NO_WARNINGS $C_OPT"
fi
CXXFLAGS="$CFLAGS"
DASH="/"

View File

@ -2561,10 +2561,15 @@ case "$target" in
else
C_OPT="/O2" # optimize for speed, no fastcall
fi
if test "$bx_plugins" = 1; then
CFLAGS="/nologo /MD /W3 /EHs-c- /DNDEBUG /DWIN32 /D_WINDOWS /D_CRT_SECURE_NO_WARNINGS $C_OPT"
if test "$bx_debugger" = 1; then
C_OPT="$C_OPT /EHsc"
else
CFLAGS="/nologo /MT /W3 /EHs-c- /DNDEBUG /DWIN32 /D_WINDOWS /D_CRT_SECURE_NO_WARNINGS $C_OPT"
C_OPT="$C_OPT /EHs-c-"
fi
if test "$bx_plugins" = 1; then
CFLAGS="/nologo /MD /W3 /DNDEBUG /DWIN32 /D_WINDOWS /D_CRT_SECURE_NO_WARNINGS $C_OPT"
else
CFLAGS="/nologo /MT /W3 /DNDEBUG /DWIN32 /D_WINDOWS /D_CRT_SECURE_NO_WARNINGS $C_OPT"
fi
CXXFLAGS="$CFLAGS"
DASH="/"

View File

@ -2,7 +2,7 @@
// $Id$
/////////////////////////////////////////////////////////////////////////
//
// Copyright (C) 2001-2013 The Bochs Project
// Copyright (C) 2001-2014 The Bochs Project
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
@ -96,6 +96,8 @@ extern "C" {
#define getch _getch
#define strtoll _strtoi64
#define strtoull _strtoui64
#define isatty _isatty
#define fileno _fileno
#endif
#else /* __MINGW32__ defined */