remove stdout/stderr calls
[compress.git] / debug.h
CommitLineData
c9987f3b
LM
1#ifndef __DEBUG_H__
2#define __DEBUG_H__
3
4/* constants */
5
6#define COMPRESS 1
7#define DECOMPRESS 2
8
9#define NB_CHARS 256
c9987f3b
LM
10
11#define DEBUG 4
12#define INFO 3
13#define WARNING 2
14#define ERROR 1
15
16/* macros */
17
18#define CEIL(x, y) (((x) + (y) - 1) / (y))
19#define MIN(x, y) (((x) < (y)) ? (x) : (y))
20#define MAX(x, y) (((x) > (y)) ? (x) : (y))
21#define VERBOSE(level, statement...) do { if (level <= verbose) { statement; } } while(0)
c9987f3b
LM
22
23/* gobal variables */
24
25extern int verbose;
26
27#endif /* __DEBUG_H__ */
28
5f83300c 29/* vim: set ts=4 sw=4 et */