diff options
author | John Wiegley <johnw@newartisans.com> | 2004-08-21 05:45:33 -0400 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2004-08-21 05:45:33 -0400 |
commit | 47cb7891c8012af2e6c03619f6b5ecaa32794126 (patch) | |
tree | ac8b1d4cd06d29af291ce3337c3f01401829af50 | |
parent | 86ac953379adc270ff1c9f5bc45256d29f0c41cd (diff) | |
download | fork-ledger-47cb7891c8012af2e6c03619f6b5ecaa32794126.tar.gz fork-ledger-47cb7891c8012af2e6c03619f6b5ecaa32794126.tar.bz2 fork-ledger-47cb7891c8012af2e6c03619f6b5ecaa32794126.zip |
changed RELEASE_LEVEL to DEBUG_LEVEL
-rw-r--r-- | Makefile | 8 | ||||
-rw-r--r-- | binary.cc | 4 | ||||
-rw-r--r-- | debug.h | 24 | ||||
-rw-r--r-- | ledger.h | 6 |
4 files changed, 21 insertions, 21 deletions
@@ -22,9 +22,9 @@ OBJS = $(patsubst %.cc,%.o,$(CODE)) CXX = g++ CFLAGS = -Wall -ansi -pedantic -#DFLAGS = -O3 -fomit-frame-pointer -DRELEASE_LEVEL=0 -DFLAGS = -g -DRELEASE_LEVEL=4 -#DFLAGS = -g -DRELEASE_LEVEL=2 -pg +#DFLAGS = -O3 -fomit-frame-pointer -DDEBUG_LEVEL=0 +DFLAGS = -g -DDEBUG_LEVEL=4 +#DFLAGS = -g -DDEBUG_LEVEL=2 -pg INCS = -I/sw/include \ -I/usr/include/gcc/darwin/3.3/c++ \ @@ -84,7 +84,7 @@ include make.deps install: make clean - make DFLAGS="-O3 -fomit-frame-pointer -DRELEASE_LEVEL=0" + make DFLAGS="-O3 -fomit-frame-pointer -DDEBUG_LEVEL=0" cp ledger $(HOME)/bin strip $(HOME)/bin/ledger @@ -26,7 +26,7 @@ static std::deque<commodity_t *> commodities; static commodity_t::ident_t c_ident; std::deque<amount_t::bigint_t *> bigints; -#if RELEASE_LEVEL >= ALPHA +#if DEBUG_LEVEL >= ALPHA #define read_binary_guard(in, id) { \ unsigned short guard; \ in.read((char *)&guard, sizeof(guard)); \ @@ -267,7 +267,7 @@ unsigned int binary_parser_t::parse(std::istream& in, journal, master); } -#if RELEASE_LEVEL >= ALPHA +#if DEBUG_LEVEL >= ALPHA #define write_binary_guard(in, id) { \ unsigned short guard = id; \ out.write((char *)&guard, sizeof(guard)); \ @@ -7,20 +7,20 @@ #define RELEASE 1 #define NO_SEATBELT 0 -#ifndef RELEASE_LEVEL -#define RELEASE_LEVEL RELEASE +#ifndef DEBUG_LEVEL +#define DEBUG_LEVEL RELEASE #endif -#if RELEASE_LEVEL >= ALPHA +#if DEBUG_LEVEL >= ALPHA #include <cstdlib> // for `getenv' #include <cstring> // for `strcmp' #endif -#if RELEASE_LEVEL >= BETA +#if DEBUG_LEVEL >= BETA #include <cassert> #endif -#if RELEASE_LEVEL >= RELEASE +#if DEBUG_LEVEL >= RELEASE #include <iostream> #endif @@ -57,7 +57,7 @@ namespace ledger { throw exc(s.str().c_str()); \ } -#if RELEASE_LEVEL >= ALPHA +#if DEBUG_LEVEL >= ALPHA #include <pcre.h> #include <cstring> @@ -91,13 +91,13 @@ bool _debug_active(const char * const cls); #define CONFIRM(x) assert(x) -#if RELEASE_LEVEL == DEVELOPER +#if DEBUG_LEVEL == DEVELOPER #define VALIDATE(x) assert(x) #else #define VALIDATE(x) #endif -#else // RELEASE_LEVEL +#else // DEBUG_LEVEL #define DEBUG_CLASS(cls) #define DEBUG(cls) 0 @@ -107,24 +107,24 @@ bool _debug_active(const char * const cls); #define VALIDATE(x) -#if RELEASE_LEVEL == NO_SEATBELT +#if DEBUG_LEVEL == NO_SEATBELT #undef assert #define assert(x) #define CONFIRM(x) -#elif RELEASE_LEVEL >= RELEASE +#elif DEBUG_LEVEL >= RELEASE extern std::ostream * warning_stream; #define CONFIRM(x) -#elif RELEASE_LEVEL >= BETA +#elif DEBUG_LEVEL >= BETA #define CONFIRM(x) assert(x) #endif -#endif // RELEASE_LEVEL +#endif // DEBUG_LEVEL } // namespace ledger @@ -16,10 +16,10 @@ #include <ctime> #include <iostream> -#ifdef RELEASE_LEVEL -#if RELEASE_LEVEL >= 2 +#ifdef DEBUG_LEVEL +#if DEBUG_LEVEL >= 2 #include "debug.h" -#elif RELEASE_LEVEL == 0 +#elif DEBUG_LEVEL == 0 #define NO_CLEANUP 1 #endif #endif |