Fixed the debug builds having NDEBUG defined, causing stuff like asserts not working properly

This commit is contained in:
Steve Dudenhoeffer 2008-04-14 19:56:31 +00:00
parent 53ed817183
commit b33d2f559b
3 changed files with 4 additions and 4 deletions

View File

@ -6,7 +6,7 @@ MM_ROOT = ../../metamod/metamod
### EDIT BELOW FOR OTHER PROJECTS ###
OPT_FLAGS = -O2 -fno-strict-aliasing -funroll-loops -s -fomit-frame-pointer -pipe
OPT_FLAGS = -O2 -fno-strict-aliasing -funroll-loops -s -fomit-frame-pointer -pipe -DNDEBUG
DEBUG_FLAGS = -g -ggdb3
CPP = gcc-4.1
NAME = amxmodx
@ -49,7 +49,7 @@ ifeq "$(BINLOG)" "true"
CFLAGS += -DBINLOG_ENABLED
endif
CFLAGS += -DLINUX -DNDEBUG -DAMX_NOPROPLIST -fPIC -Wall -Werror -DHAVE_STDINT_H -static-libgcc -fno-rtti -fno-exceptions
CFLAGS += -DLINUX -DAMX_NOPROPLIST -fPIC -Wall -Werror -DHAVE_STDINT_H -static-libgcc -fno-rtti -fno-exceptions
ifeq "$(AMD64)" "true"
BINARY = $(NAME)_$(BIN_SUFFIX_64)

View File

@ -803,7 +803,7 @@ static void expand(unsigned char *code, long codesize, long memsize)
do {
codesize--;
/* no input byte should be shifted out completely */
assert(shift<8*sizeof(cell));
assert(shift<static_cast<int>(8*sizeof(cell)));
/* we work from the end of a sequence backwards; the final code in
* a sequence may not have the continuation bit set */
assert(shift>0 || (code[(size_t)codesize] & 0x80)==0);

View File

@ -289,7 +289,7 @@ void Debugger::BeginExec()
{
Tracer *pTracer = new Tracer();
m_pCalls.push_back(pTracer);
assert(m_Top == (m_pCalls.size() - 1));
assert(m_Top == static_cast<int>(m_pCalls.size() - 1));
}
m_pCalls[m_Top]->Reset();