Initial revision
[imager.git] / log.h
CommitLineData
02d1d628
AMH
1#ifndef _LOG_H_
2#define _LOG_H_
3
4#include <stdio.h>
5#include <stdarg.h>
6#include <time.h>
7/*
8 input: name of file to log too
9 input: onoff, 0 means no logging
10 global: creates a global variable FILE* lg_file
11*/
12
13void m_lhead ( const char *file, int line );
14void init_log( const char *name, int onoff );
15void m_loog(int level,const char *msg, ... );
16void m_fatal ( int exitcode,const char *fmt, ... );
17
18
19#ifdef IMAGER_LOG
20#define mm_log(x) { m_lhead(__FILE__,__LINE__); m_loog x; }
21#else
22#define mm_log(x)
23#endif
24
25
26#endif /* _LOG_H_ */