summaryrefslogtreecommitdiff
path: root/include/libelfu/debug.h
blob: b9f9161f7ac30f9f813e6c21d10b2012e1f4e1dd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#ifndef __LIBELFU_DEBUG_H_
#define __LIBELFU_DEBUG_H_

#include <stdio.h>


#define ELFU_DEBUG(...) do { fprintf(stdout, __VA_ARGS__); } while(0)

#define ELFU_INFO(...) do { fprintf(stdout, __VA_ARGS__); } while(0)

#define ELFU_WARN(...) do { fprintf(stderr, __VA_ARGS__); } while(0)

#define ELFU_WARNELF(function_name) ELFU_WARN(function_name "() failed: %s\n", elf_errmsg(-1))

#endif