cctools
Main Page
Related Pages
Namespaces
Data Structures
Files
File List
Globals
dttools
src
debug.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2003-2004 Douglas Thain and the University of Wisconsin
3
Copyright (C) 2005- The University of Notre Dame
4
This software is distributed under the GNU General Public License.
5
See the file COPYING for details.
6
*/
7
8
#ifndef DEBUG_H
9
#define DEBUG_H
10
35
#include <stdio.h>
36
#include <unistd.h>
37
#include <sys/types.h>
38
39
#include "int_sizes.h"
40
41
#define D_SYSCALL 0x000000001
42
#define D_CHANNEL 0x000000002
43
#define D_PROCESS 0x000000004
44
#define D_NOTICE 0x000000008
45
#define D_RESOLVE 0x000000010
46
#define D_LIBCALL 0x000000020
47
#define D_LOCAL 0x000000040
48
#define D_DNS 0x000000080
49
#define D_TCP 0x000000100
50
#define D_AUTH 0x000000200
51
#define D_IRODS 0x000000400
52
#define D_CVMFS 0x000000800
53
#define D_HTTP 0x000001000
54
#define D_FTP 0x000002000
55
#define D_NEST 0x000004000
56
#define D_GROW 0x000008000
57
#define D_CHIRP 0x000010000
58
#define D_DCAP 0x000020000
59
#define D_RFIO 0x000040000
60
#define D_GLITE 0x000080000
61
#define D_MULTI 0x000100000
62
#define D_PSTREE 0x000200000
63
#define D_ALLOC 0x000400000
64
#define D_LFC 0x000800000
65
#define D_GFAL 0x001000000
66
#define D_SUMMARY 0x002000000
67
#define D_DEBUG 0x004000000
68
#define D_LOGIN 0x008000000
69
#define D_CACHE 0x010000000
70
#define D_POLL 0x020000000
71
#define D_HDFS 0x040000000
72
#define D_WQ 0x080000000
73
#define D_BXGRID 0x100000000LL
74
#define D_USER 0x200000000LL
75
#define D_XROOTD 0x400000000LL
76
#define D_MPI 0x800000000LL
77
#define D_BATCH 0x1000000000LL
80
#define D_REMOTE (D_HTTP|D_FTP|D_NEST|D_CHIRP|D_DCAP|D_RFIO|D_LFC|D_GFAL|D_MULTI|D_GROW|D_IRODS|D_HDFS|D_BXGRID|D_XROOTD|D_CVMFS)
81
83
#define D_ALL ~(0LL)
84
85
/*
86
It turns out that many libraries and tools make use of
87
symbols like "debug" and "fatal". This causes strange
88
failures when we link against such codes. Rather than change
89
all of our code, we simply insert these defines to
90
transparently modify the linker namespace we are using.
91
*/
92
93
#define debug cctools_debug
94
#define fatal cctools_fatal
95
#define warn cctools_warn
96
#define debug_config cctools_debug_config
97
#define debug_config_file cctools_debug_config_file
98
#define debug_config_file_size cctools_debug_config_file_size
99
#define debug_config_fatal cctools_debug_config_fatal
100
#define debug_config_getpid cctools_debug_config_getpid
101
#define debug_flags_set cctools_debug_flags_set
102
#define debug_flags_print cctools_debug_flags_print
103
#define debug_flags_clear cctools_debug_flags_clear
104
#define debug_flags_restore cctools_debug_flags_restore
105
#define debug_set_flag_name cctools_debug_set_flag_name
106
113
void
debug
(INT64_T flags,
const
char
*fmt, ...);
114
121
void
warn
(INT64_T flags,
const
char
*fmt, ...);
122
128
void
fatal
(
const
char
*fmt, ...);
129
135
void
debug_config
(
const
char
*name);
136
143
void
debug_config_file
(
const
char
*file);
144
152
void
debug_config_file_size
(
size_t
size);
153
154
void
debug_config_fatal(
void
(*callback) (
void
));
155
void
debug_config_getpid(pid_t(*getpidfunc) (
void
));
156
165
int
debug_flags_set
(
const
char
*flagname);
166
173
void
debug_flags_print
(FILE * stream);
174
180
INT64_T
debug_flags_clear
(
void
);
181
188
void
debug_set_flag_name
(INT64_T flag,
const
char
*name);
189
193
void
debug_flags_restore
(INT64_T flags);
194
195
#endif
Generated on Sat Jun 30 2012 09:55:32 for cctools by
1.8.1.1