1 /************************************************************************/ 2 /* */ 3 /* Debugging and diagnostic macros. */ 4 /* */ 5 /* The mechanism is activated when the macro APP_DEBUG is defined. */ 6 /* */ 7 /************************************************************************/ 8 9 # ifndef APP_DEBUG_H 10 # define APP_DEBUG_H 11 12 # ifdef APP_DEB 13 # undef APP_DEB 14 # endif 15 16 # ifdef __cplusplus 17 extern "C" 18 { 19 # endif 20 21 #ifdef __GNUC__ 22 extern int appDebug( const char * format, ... ) 23 __attribute__ (( format ( printf, 1, 2 ) )); 24 #else 25 extern int appDebug( const char * format, ... ); 26 #endif 27 28 extern const int appDebugZero; 29 extern int appDebugSetFile( const char * filename, 30 const char * mode ); 31 32 # ifdef APP_DEBUG 33 # include <ctype.h> 34 # define APP_DEB(x) (x) 35 # else 36 # define APP_DEB(x) 37 # endif 38 39 # define DEB0(sa) ((sa)?"\"":""), ((sa)?(sa):"0x0"), ((sa)?"\"":"") 40 # define DEBS(sa) (((sa)+appDebugZero)?"\"":""), (((sa)+appDebugZero)?(sa):"0x0"), (((sa)+appDebugZero)?"\"":"") 41 # define DEBX(lo) ((unsigned long)(lo)) 42 # define DEBP(pt) ((void *)(pt)) 43 # define DEBO(lo) ((unsigned long)(lo)) 44 # define DEBL(lo) ((long)(lo)) 45 # define DEBD(do) ((double)(do)) 46 # define DEBC(ch) (ch)&0xff,isprint((ch))?'=':' ',isprint((ch))?(ch):' ' 47 48 # define DFMS " %s=%s%s%s" 49 # define DFMX " %s=0x%lx" 50 # define DFMP " %s=%p" 51 # define DFMO " %s=0%lo" 52 # define DFML " %s=%ld" 53 # define DFMD " %s=%g" 54 # define DFMC " %s=0x%02x%c%c" 55 56 # define SDEB(s1) APP_DEB(appDebug( "%s(%3d)" \ 57 DFMS \ 58 "\n", __FILE__, __LINE__, \ 59 #s1, DEBS(s1) )) 60 61 # define LDEB(l1) APP_DEB(appDebug( "%s(%3d)" \ 62 DFML \ 63 "\n", __FILE__, __LINE__, \ 64 #l1, DEBL(l1) )) 65 66 # define ODEB(l1) APP_DEB(appDebug( "%s(%3d)" \ 67 DFMO \ 68 "\n", __FILE__, __LINE__, \ 69 #l1, DEBO(l1) )) 70 71 # define XDEB(l1) APP_DEB(appDebug( "%s(%3d)" \ 72 DFMX \ 73 "\n", __FILE__, __LINE__, \ 74 #l1, DEBL(l1) )) 75 # define PDEB(p1) APP_DEB(appDebug( "%s(%3d)" \ 76 DFMP \ 77 "\n", __FILE__, __LINE__, \ 78 #p1, DEBP(p1) )) 79 80 # define FDEB(d1) APP_DEB(appDebug( "%s(%3d)" \ 81 DFMD \ 82 "\n", __FILE__, __LINE__, \ 83 #d1, DEBD(d1) )) 84 85 # define CDEB(c1) APP_DEB(appDebug( "%s(%3d)" \ 86 DFMC \ 87 "\n", __FILE__, __LINE__, \ 88 #c1, DEBC(c1) )) 89 90 # define CLDEB(c1,l2) APP_DEB(appDebug( "%s(%3d)" \ 91 DFMC \ 92 DFML \ 93 "\n", __FILE__, __LINE__, \ 94 #c1, DEBC(c1), \ 95 #l2, DEBL(l2) )) 96 97 # define CSDEB(c1,s2) APP_DEB(appDebug( "%s(%3d)" \ 98 DFMC \ 99 DFMS \ 100 "\n", __FILE__, __LINE__, \ 101 #c1, DEBC(c1), \ 102 #s2, DEBS(s2) )) 103 104 # define CLSDEB(c1,l2,s3) APP_DEB(appDebug( "%s(%3d)" \ 105 DFMC \ 106 DFML \ 107 DFMS \ 108 "\n", __FILE__, __LINE__, \ 109 #c1, DEBC(c1), \ 110 #l2, DEBL(l2), \ 111 #s3, DEBS(s3) )) 112 113 # define CLLDEB(c1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 114 DFMC \ 115 DFML \ 116 DFML \ 117 "\n", __FILE__, __LINE__, \ 118 #c1, DEBC(c1), \ 119 #l2, DEBL(l2), \ 120 #l3, DEBL(l3) )) 121 122 # define CLLLDEB(c1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 123 DFMC \ 124 DFML \ 125 DFML \ 126 DFML \ 127 "\n", __FILE__, __LINE__, \ 128 #c1, DEBC(c1), \ 129 #l2, DEBL(l2), \ 130 #l3, DEBL(l3), \ 131 #l4, DEBL(l4) )) 132 133 # define CCDEB(c1,c2) APP_DEB(appDebug( "%s(%3d)" \ 134 DFMC \ 135 DFMC \ 136 "\n", __FILE__, __LINE__, \ 137 #c1, DEBC(c1), \ 138 #c2, DEBC(c2) )) 139 140 # define LCCDEB(l1,c2,c3) APP_DEB(appDebug( "%s(%3d)" \ 141 DFML \ 142 DFMC \ 143 DFMC \ 144 "\n", __FILE__, __LINE__, \ 145 #l1, DEBL(l1), \ 146 #c2, DEBC(c2), \ 147 #c3, DEBC(c3) )) 148 149 # define LCXDEB(l1,c2,l3) APP_DEB(appDebug( "%s(%3d)" \ 150 DFML \ 151 DFMC \ 152 DFMX \ 153 "\n", __FILE__, __LINE__, \ 154 #l1, DEBL(l1), \ 155 #c2, DEBC(c2), \ 156 #l3, DEBX(l3) )) 157 158 # define CXLDEB(c1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 159 DFMC \ 160 DFMX \ 161 DFML \ 162 "\n", __FILE__, __LINE__, \ 163 #c1, DEBC(c1), \ 164 #l2, DEBX(l2), \ 165 #l3, DEBL(l3) )) 166 167 # define LCLDEB(l1,c2,l3) APP_DEB(appDebug( "%s(%3d)" \ 168 DFML \ 169 DFMC \ 170 DFML \ 171 "\n", __FILE__, __LINE__, \ 172 #l1, DEBL(l1), \ 173 #c2, DEBC(c2), \ 174 #l3, DEBL(l3) )) 175 176 # define LCSDEB(l1,c2,s3) APP_DEB(appDebug( "%s(%3d)" \ 177 DFML \ 178 DFMC \ 179 DFMS \ 180 "\n", __FILE__, __LINE__, \ 181 #l1, DEBL(l1), \ 182 #c2, DEBC(c2), \ 183 #s3, DEBS(s3) )) 184 185 # define LLCDEB(l1,l2,c3) APP_DEB(appDebug( "%s(%3d)" \ 186 DFML \ 187 DFML \ 188 DFMC \ 189 "\n", __FILE__, __LINE__, \ 190 #l1, DEBL(l1), \ 191 #l2, DEBL(l2), \ 192 #c3, DEBC(c3) )) 193 194 # define SSDEB(s1,s2) APP_DEB(appDebug( "%s(%3d)" \ 195 DFMS \ 196 DFMS \ 197 "\n", __FILE__, __LINE__, \ 198 #s1, DEBS(s1), \ 199 #s2, DEBS(s2) )) 200 201 # define SCDEB(s1,c2) APP_DEB(appDebug( "%s(%3d)" \ 202 DFMS \ 203 DFMC \ 204 "\n", __FILE__, __LINE__, \ 205 #s1, DEBS(s1), \ 206 #c2, DEBC(c2) )) 207 208 # define LLDEB(l1,l2) APP_DEB(appDebug( "%s(%3d)" \ 209 DFML \ 210 DFML \ 211 "\n", __FILE__, __LINE__, \ 212 #l1, DEBL(l1), \ 213 #l2, DEBL(l2) )) 214 215 # define FLDEB(d1,l2) APP_DEB(appDebug( "%s(%3d)" \ 216 DFMD \ 217 DFML \ 218 "\n", __FILE__, __LINE__, \ 219 #d1, DEBD(d1), \ 220 #l2, DEBL(l2) )) 221 222 # define XXDEB(l1,l2) APP_DEB(appDebug( "%s(%3d)" \ 223 DFMX \ 224 DFMX \ 225 "\n", __FILE__, __LINE__, \ 226 #l1, DEBL(l1), \ 227 #l2, DEBL(l2) )) 228 229 # define PPDEB(p1,p2) APP_DEB(appDebug( "%s(%3d)" \ 230 DFMP \ 231 DFMP \ 232 "\n", __FILE__, __LINE__, \ 233 #p1, DEBP(p1), \ 234 #p2, DEBP(p2) )) 235 236 # define XLDEB(l1,l2) APP_DEB(appDebug( "%s(%3d)" \ 237 DFMX \ 238 DFML \ 239 "\n", __FILE__, __LINE__, \ 240 #l1, DEBL(l1), \ 241 #l2, DEBL(l2) )) 242 243 # define LXDEB(l1,l2) APP_DEB(appDebug( "%s(%3d)" \ 244 DFML \ 245 DFMX \ 246 "\n", __FILE__, __LINE__, \ 247 #l1, DEBL(l1), \ 248 #l2, DEBL(l2) )) 249 # define LPDEB(l1,p2) APP_DEB(appDebug( "%s(%3d)" \ 250 DFML \ 251 DFMP \ 252 "\n", __FILE__, __LINE__, \ 253 #l1, DEBL(l1), \ 254 #p2, DEBP(p2) )) 255 256 # define SLDEB(s1,l2) APP_DEB(appDebug( "%s(%3d)" \ 257 DFMS \ 258 DFML \ 259 "\n", __FILE__, __LINE__, \ 260 #s1, DEBS(s1), \ 261 #l2, DEBL(l2) )) 262 263 # define SFDEB(s1,d2) APP_DEB(appDebug( "%s(%3d)" \ 264 DFMS \ 265 DFMD \ 266 "\n", __FILE__, __LINE__, \ 267 #s1, DEBS(s1), \ 268 #d2, DEBD(d2) )) 269 270 # define LSDEB(l1,s2) APP_DEB(appDebug( "%s(%3d)" \ 271 DFML \ 272 DFMS \ 273 "\n", __FILE__, __LINE__, \ 274 #l1, DEBL(l1), \ 275 #s2, DEBS(s2) )) 276 277 # define FSDEB(d1,s2) APP_DEB(appDebug( "%s(%3d)" \ 278 DFMD \ 279 DFMS \ 280 "\n", __FILE__, __LINE__, \ 281 #d1, DEBD(d1), \ 282 #s2, DEBS(s2) )) 283 284 # define SXDEB(s1,l2) APP_DEB(appDebug( "%s(%3d)" \ 285 DFMS \ 286 DFMX \ 287 "\n", __FILE__, __LINE__, \ 288 #s1, DEBS(s1), \ 289 #l2, DEBL(l2) )) 290 # define SPDEB(s1,p2) APP_DEB(appDebug( "%s(%3d)" \ 291 DFMS \ 292 DFMP \ 293 "\n", __FILE__, __LINE__, \ 294 #s1, DEBS(s1), \ 295 #p2, DEBP(p2) )) 296 297 # define SXSDEB(s1,l2,s3) APP_DEB(appDebug( "%s(%3d)" \ 298 DFMS \ 299 DFMX \ 300 DFMS \ 301 "\n", __FILE__, __LINE__, \ 302 #s1, DEBS(s1), \ 303 #l2, DEBX(l2), \ 304 #s3, DEBS(s3) )) 305 306 # define SLSDEB(s1,l2,s3) APP_DEB(appDebug( "%s(%3d)" \ 307 DFMS \ 308 DFML \ 309 DFMS \ 310 "\n", __FILE__, __LINE__, \ 311 #s1, DEBS(s1), \ 312 #l2, DEBL(l2), \ 313 #s3, DEBS(s3) )) 314 315 # define SLSSDEB(s1,l2,s3,s4) APP_DEB(appDebug( "%s(%3d)" \ 316 DFMS \ 317 DFML \ 318 DFMS \ 319 DFMS \ 320 "\n", __FILE__, __LINE__, \ 321 #s1, DEBS(s1), \ 322 #l2, DEBL(l2), \ 323 #s3, DEBS(s3), \ 324 #s4, DEBS(s4) )) 325 326 # define LLSSDEB(l1,l2,s3,s4) APP_DEB(appDebug( "%s(%3d)" \ 327 DFML \ 328 DFML \ 329 DFMS \ 330 DFMS \ 331 "\n", __FILE__, __LINE__, \ 332 #l1, DEBL(l1), \ 333 #l2, DEBL(l2), \ 334 #s3, DEBS(s3), \ 335 #s4, DEBS(s4) )) 336 337 # define XSDEB(l1,s2) APP_DEB(appDebug( "%s(%3d)" \ 338 DFMX \ 339 DFMS \ 340 "\n", __FILE__, __LINE__, \ 341 #l1, DEBL(l1), \ 342 #s2, DEBS(s2) )) 343 344 # define LFDEB(l1,d2) APP_DEB(appDebug( "%s(%3d)" \ 345 DFML \ 346 DFMD \ 347 "\n", __FILE__, __LINE__, \ 348 #l1, DEBL(l1), \ 349 #d2, DEBD(d2) )) 350 351 # define LFLDEB(l1,d2,l3) APP_DEB(appDebug( "%s(%3d)" \ 352 DFML \ 353 DFMD \ 354 DFML \ 355 "\n", __FILE__, __LINE__, \ 356 #l1, DEBL(l1), \ 357 #d2, DEBD(d2), \ 358 #l3, DEBL(l3) )) 359 360 # define LFCDEB(l1,d2,c3) APP_DEB(appDebug( "%s(%3d)" \ 361 DFML \ 362 DFMD \ 363 DFMC \ 364 "\n", __FILE__, __LINE__, \ 365 #l1, DEBL(l1), \ 366 #d2, DEBD(d2), \ 367 #c3, DEBC(c3) )) 368 369 # define FFDEB(d1,d2) APP_DEB(appDebug( "%s(%3d)" \ 370 DFMD \ 371 DFMD \ 372 "\n", __FILE__, __LINE__, \ 373 #d1, DEBD(d1), \ 374 #d2, DEBD(d2) )) 375 376 # define FFLDEB(d1,d2,l3) APP_DEB(appDebug( "%s(%3d)" \ 377 DFMD \ 378 DFMD \ 379 DFML \ 380 "\n", __FILE__, __LINE__, \ 381 #d1, DEBD(d1), \ 382 #d2, DEBD(d2), \ 383 #l3, DEBL(l3) )) 384 385 # define LCDEB(l1,c2) APP_DEB(appDebug( "%s(%3d)" \ 386 DFML \ 387 DFMC \ 388 "\n", __FILE__, __LINE__, \ 389 #l1, DEBL(l1), \ 390 #c2, DEBC(c2) )) 391 392 # define SLLDEB(s1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 393 DFMS \ 394 DFML \ 395 DFML \ 396 "\n", __FILE__, __LINE__, \ 397 #s1, DEBS(s1), \ 398 #l2, DEBL(l2), \ 399 #l3, DEBL(l3) )) 400 401 # define SXLDEB(s1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 402 DFMS \ 403 DFMX \ 404 DFML \ 405 "\n", __FILE__, __LINE__, \ 406 #s1, DEBS(s1), \ 407 #l2, DEBX(l2), \ 408 #l3, DEBL(l3) )) 409 410 # define SLXDEB(s1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 411 DFMS \ 412 DFML \ 413 DFMX \ 414 "\n", __FILE__, __LINE__, \ 415 #s1, DEBS(s1), \ 416 #l2, DEBL(l2), \ 417 #l3, DEBX(l3) )) 418 419 # define SXXDEB(s1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 420 DFMS \ 421 DFMX \ 422 DFMX \ 423 "\n", __FILE__, __LINE__, \ 424 #s1, DEBS(s1), \ 425 #l2, DEBX(l2), \ 426 #l3, DEBX(l3) )) 427 428 # define SFLDEB(s1,d2,l3) APP_DEB(appDebug( "%s(%3d)" \ 429 DFMS \ 430 DFMD \ 431 DFML \ 432 "\n", __FILE__, __LINE__, \ 433 #s1, DEBS(s1), \ 434 #d2, DEBD(d2), \ 435 #l3, DEBL(l3) )) 436 437 # define SLFFDEB(s1,l2,d3,d4) APP_DEB(appDebug( "%s(%3d)" \ 438 DFMS \ 439 DFML \ 440 DFMD \ 441 DFMD \ 442 "\n", __FILE__, __LINE__, \ 443 #s1, DEBS(s1), \ 444 #l2, DEBL(l2), \ 445 #d3, DEBD(d3), \ 446 #d4, DEBD(d4) )) 447 448 # define SLFDEB(s1,l2,d3) APP_DEB(appDebug( "%s(%3d)" \ 449 DFMS \ 450 DFML \ 451 DFMD \ 452 "\n", __FILE__, __LINE__, \ 453 #s1, DEBS(s1), \ 454 #l2, DEBL(l2), \ 455 #d3, DEBD(d3) )) 456 457 # define SFFDEB(s1,d2,d3) APP_DEB(appDebug( "%s(%3d)" \ 458 DFMS \ 459 DFMD \ 460 DFMD \ 461 "\n", __FILE__, __LINE__, \ 462 #s1, DEBS(s1), \ 463 #d2, DEBD(d2), \ 464 #d3, DEBD(d3) )) 465 466 # define SFFFDEB(s1,d2,d3,d4) APP_DEB(appDebug( "%s(%3d)" \ 467 DFMS \ 468 DFMD \ 469 DFMD \ 470 DFMD \ 471 "\n", __FILE__, __LINE__, \ 472 #s1, DEBS(s1), \ 473 #d2, DEBD(d2), \ 474 #d3, DEBD(d3), \ 475 #d4, DEBD(d4) )) 476 477 # define LSLDEB(l1,s2,l3) APP_DEB(appDebug( "%s(%3d)" \ 478 DFML \ 479 DFMS \ 480 DFML \ 481 "\n", __FILE__, __LINE__, \ 482 #l1, DEBL(l1), \ 483 #s2, DEBS(s2), \ 484 #l3, DEBL(l3) )) 485 486 # define LSCDEB(l1,s2,c3) APP_DEB(appDebug( "%s(%3d)" \ 487 DFML \ 488 DFMS \ 489 DFMC \ 490 "\n", __FILE__, __LINE__, \ 491 #l1, DEBL(l1), \ 492 #s2, DEBS(s2), \ 493 #c3, DEBC(c3) )) 494 495 # define XSLDEB(l1,s2,l3) APP_DEB(appDebug( "%s(%3d)" \ 496 DFMX \ 497 DFMS \ 498 DFML \ 499 "\n", __FILE__, __LINE__, \ 500 #l1, DEBX(l1), \ 501 #s2, DEBS(s2), \ 502 #l3, DEBL(l3) )) 503 504 # define LSXDEB(l1,s2,l3) APP_DEB(appDebug( "%s(%3d)" \ 505 DFML \ 506 DFMS \ 507 DFMX \ 508 "\n", __FILE__, __LINE__, \ 509 #l1, DEBL(l1), \ 510 #s2, DEBS(s2), \ 511 #l3, DEBX(l3) )) 512 513 # define LSFDEB(l1,s2,d3) APP_DEB(appDebug( "%s(%3d)" \ 514 DFML \ 515 DFMS \ 516 DFMD \ 517 "\n", __FILE__, __LINE__, \ 518 #l1, DEBL(l1), \ 519 #s2, DEBS(s2), \ 520 #d3, DEBD(d3) )) 521 522 # define LSLLDEB(l1,s2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 523 DFML \ 524 DFMS \ 525 DFML \ 526 DFML \ 527 "\n", __FILE__, __LINE__, \ 528 #l1, DEBL(l1), \ 529 #s2, DEBS(s2), \ 530 #l3, DEBL(l3), \ 531 #l4, DEBL(l4) )) 532 533 # define LSFFDEB(l1,s2,d3,d4) APP_DEB(appDebug( "%s(%3d)" \ 534 DFML \ 535 DFMS \ 536 DFMD \ 537 DFMD \ 538 "\n", __FILE__, __LINE__, \ 539 #l1, DEBL(l1), \ 540 #s2, DEBS(s2), \ 541 #d3, DEBD(d3), \ 542 #d4, DEBD(d4) )) 543 544 # define SLLLDEB(s1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 545 DFMS \ 546 DFML \ 547 DFML \ 548 DFML \ 549 "\n", __FILE__, __LINE__, \ 550 #s1, DEBS(s1), \ 551 #l2, DEBL(l2), \ 552 #l3, DEBL(l3), \ 553 #l4, DEBL(l4) )) 554 555 # define SLXXDEB(s1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 556 DFMS \ 557 DFML \ 558 DFMX \ 559 DFMX \ 560 "\n", __FILE__, __LINE__, \ 561 #s1, DEBS(s1), \ 562 #l2, DEBL(l2), \ 563 #l3, DEBX(l3), \ 564 #l4, DEBX(l4) )) 565 566 # define SXLLDEB(s1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 567 DFMS \ 568 DFMX \ 569 DFML \ 570 DFML \ 571 "\n", __FILE__, __LINE__, \ 572 #s1, DEBS(s1), \ 573 #l2, DEBX(l2), \ 574 #l3, DEBL(l3), \ 575 #l4, DEBL(l4) )) 576 577 # define SLLLLDEB(s1,l2,l3,l4,l5) APP_DEB(appDebug( "%s(%3d)" \ 578 DFMS \ 579 DFML \ 580 DFML \ 581 DFML \ 582 DFML \ 583 "\n", __FILE__, __LINE__, \ 584 #s1, DEBS(s1), \ 585 #l2, DEBL(l2), \ 586 #l3, DEBL(l3), \ 587 #l4, DEBL(l4), \ 588 #l5, DEBL(l5) )) 589 590 # define SLLLLLDEB(s1,l2,l3,l4,l5,l6) APP_DEB(appDebug( "%s(%3d)" \ 591 DFMS \ 592 DFML \ 593 DFML \ 594 DFML \ 595 DFML \ 596 DFML \ 597 "\n", __FILE__, __LINE__, \ 598 #s1, DEBS(s1), \ 599 #l2, DEBL(l2), \ 600 #l3, DEBL(l3), \ 601 #l4, DEBL(l4), \ 602 #l5, DEBL(l5), \ 603 #l6, DEBL(l6) )) 604 605 # define SLLLXDEB(s1,l2,l3,l4,l5) APP_DEB(appDebug( "%s(%3d)" \ 606 DFMS \ 607 DFML \ 608 DFML \ 609 DFML \ 610 DFMX \ 611 "\n", __FILE__, __LINE__, \ 612 #s1, DEBS(s1), \ 613 #l2, DEBL(l2), \ 614 #l3, DEBL(l3), \ 615 #l4, DEBL(l4), \ 616 #l5, DEBX(l5) )) 617 618 # define SLLXDEB(s1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 619 DFMS \ 620 DFML \ 621 DFML \ 622 DFMX \ 623 "\n", __FILE__, __LINE__, \ 624 #s1, DEBS(s1), \ 625 #l2, DEBL(l2), \ 626 #l3, DEBL(l3), \ 627 #l4, DEBX(l4) )) 628 629 # define LLLSDEB(l1,l2,l3,s4) APP_DEB(appDebug( "%s(%3d)" \ 630 DFML \ 631 DFML \ 632 DFML \ 633 DFMS \ 634 "\n", __FILE__, __LINE__, \ 635 #l1, DEBL(l1), \ 636 #l2, DEBL(l2), \ 637 #l3, DEBL(l3), \ 638 #s4, DEBS(s4) )) 639 640 # define LLFFDEB(l1,l2,d3,d4) APP_DEB(appDebug( "%s(%3d)" \ 641 DFML \ 642 DFML \ 643 DFMD \ 644 DFMD \ 645 "\n", __FILE__, __LINE__, \ 646 #l1, DEBL(l1), \ 647 #l2, DEBL(l2), \ 648 #d3, DEBD(d3), \ 649 #d4, DEBD(d4) )) 650 651 # define SLLSDEB(s1,l2,l3,s4) APP_DEB(appDebug( "%s(%3d)" \ 652 DFMS \ 653 DFML \ 654 DFML \ 655 DFMS \ 656 "\n", __FILE__, __LINE__, \ 657 #s1, DEBS(s1), \ 658 #l2, DEBL(l2), \ 659 #l3, DEBL(l3), \ 660 #s4, DEBS(s4) )) 661 662 # define LLLDEB(l1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 663 DFML \ 664 DFML \ 665 DFML \ 666 "\n", __FILE__, __LINE__, \ 667 #l1, DEBL(l1), \ 668 #l2, DEBL(l2), \ 669 #l3, DEBL(l3) )) 670 671 # define LXLDEB(l1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 672 DFML \ 673 DFMX \ 674 DFML \ 675 "\n", __FILE__, __LINE__, \ 676 #l1, DEBL(l1), \ 677 #l2, DEBX(l2), \ 678 #l3, DEBL(l3) )) 679 680 # define XXXDEB(l1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 681 DFMX \ 682 DFMX \ 683 DFMX \ 684 "\n", __FILE__, __LINE__, \ 685 #l1, DEBX(l1), \ 686 #l2, DEBX(l2), \ 687 #l3, DEBX(l3) )) 688 689 # define LXXXDEB(l1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 690 DFML \ 691 DFMX \ 692 DFMX \ 693 DFMX \ 694 "\n", __FILE__, __LINE__, \ 695 #l1, DEBL(l1), \ 696 #l2, DEBX(l2), \ 697 #l3, DEBX(l3), \ 698 #l4, DEBX(l4) )) 699 700 # define XLLDEB(l1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 701 DFMX \ 702 DFML \ 703 DFML \ 704 "\n", __FILE__, __LINE__, \ 705 #l1, DEBX(l1), \ 706 #l2, DEBL(l2), \ 707 #l3, DEBL(l3) )) 708 # define PLLDEB(p1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 709 DFMP \ 710 DFML \ 711 DFML \ 712 "\n", __FILE__, __LINE__, \ 713 #p1, DEBP(p1), \ 714 #l2, DEBL(l2), \ 715 #l3, DEBL(l3) )) 716 717 # define XLXDEB(l1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 718 DFMX \ 719 DFML \ 720 DFMX \ 721 "\n", __FILE__, __LINE__, \ 722 #l1, DEBX(l1), \ 723 #l2, DEBL(l2), \ 724 #l3, DEBX(l3) )) 725 726 # define LLLLDEB(l1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 727 DFML \ 728 DFML \ 729 DFML \ 730 DFML \ 731 "\n", __FILE__, __LINE__, \ 732 #l1, DEBL(l1), \ 733 #l2, DEBL(l2), \ 734 #l3, DEBL(l3), \ 735 #l4, DEBL(l4) )) 736 737 # define LXXLDEB(l1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 738 DFML \ 739 DFMX \ 740 DFMX \ 741 DFML \ 742 "\n", __FILE__, __LINE__, \ 743 #l1, DEBL(l1), \ 744 #l2, DEBX(l2), \ 745 #l3, DEBX(l3), \ 746 #l4, DEBL(l4) )) 747 748 # define LLLXDEB(l1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 749 DFML \ 750 DFML \ 751 DFML \ 752 DFMX \ 753 "\n", __FILE__, __LINE__, \ 754 #l1, DEBL(l1), \ 755 #l2, DEBL(l2), \ 756 #l3, DEBL(l3), \ 757 #l4, DEBX(l4) )) 758 759 # define LLLLXDEB(l1,l2,l3,l4,l5) APP_DEB(appDebug( "%s(%3d)" \ 760 DFML \ 761 DFML \ 762 DFML \ 763 DFML \ 764 DFMX \ 765 "\n", __FILE__, __LINE__, \ 766 #l1, DEBL(l1), \ 767 #l2, DEBL(l2), \ 768 #l3, DEBL(l3), \ 769 #l4, DEBL(l4), \ 770 #l5, DEBX(l5) )) 771 772 # define XXLLDEB(l1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 773 DFMX \ 774 DFMX \ 775 DFML \ 776 DFML \ 777 "\n", __FILE__, __LINE__, \ 778 #l1, DEBX(l1), \ 779 #l2, DEBX(l2), \ 780 #l3, DEBL(l3), \ 781 #l4, DEBL(l4) )) 782 783 # define LLXXDEB(l1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 784 DFML \ 785 DFML \ 786 DFMX \ 787 DFMX \ 788 "\n", __FILE__, __LINE__, \ 789 #l1, DEBL(l1), \ 790 #l2, DEBL(l2), \ 791 #l3, DEBX(l3), \ 792 #l4, DEBX(l4) )) 793 794 # define FFLLDEB(d1,d2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 795 DFMD \ 796 DFMD \ 797 DFML \ 798 DFML \ 799 "\n", __FILE__, __LINE__, \ 800 #d1, DEBD(d1), \ 801 #d2, DEBD(d2), \ 802 #l3, DEBL(l3), \ 803 #l4, DEBL(l4) )) 804 805 # define XXXXDEB(l1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 806 DFMX \ 807 DFMX \ 808 DFMX \ 809 DFMX \ 810 "\n", __FILE__, __LINE__, \ 811 #l1, DEBX(l1), \ 812 #l2, DEBX(l2), \ 813 #l3, DEBX(l3), \ 814 #l4, DEBX(l4) )) 815 816 # define XXXLDEB(l1,l2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 817 DFMX \ 818 DFMX \ 819 DFMX \ 820 DFML \ 821 "\n", __FILE__, __LINE__, \ 822 #l1, DEBX(l1), \ 823 #l2, DEBX(l2), \ 824 #l3, DEBX(l3), \ 825 #l4, DEBL(l4) )) 826 827 # define LLLLLDEB(l1,l2,l3,l4,l5) APP_DEB(appDebug( "%s(%3d)" \ 828 DFML \ 829 DFML \ 830 DFML \ 831 DFML \ 832 DFML \ 833 "\n", __FILE__, __LINE__, \ 834 #l1, DEBL(l1), \ 835 #l2, DEBL(l2), \ 836 #l3, DEBL(l3), \ 837 #l4, DEBL(l4), \ 838 #l5, DEBL(l5) )) 839 840 # define XXXLLDEB(l1,l2,l3,l4,l5) APP_DEB(appDebug( "%s(%3d)" \ 841 DFMX \ 842 DFMX \ 843 DFMX \ 844 DFML \ 845 DFML \ 846 "\n", __FILE__, __LINE__, \ 847 #l1, DEBX(l1), \ 848 #l2, DEBX(l2), \ 849 #l3, DEBX(l3), \ 850 #l4, DEBL(l4), \ 851 #l5, DEBL(l5) )) 852 853 # define LLLLLLDEB(l1,l2,l3,l4,l5,l6) APP_DEB(appDebug( "%s(%3d)" \ 854 DFML \ 855 DFML \ 856 DFML \ 857 DFML \ 858 DFML \ 859 DFML \ 860 "\n", __FILE__, __LINE__, \ 861 #l1, DEBL(l1), \ 862 #l2, DEBL(l2), \ 863 #l3, DEBL(l3), \ 864 #l4, DEBL(l4), \ 865 #l5, DEBL(l5), \ 866 #l6, DEBL(l6) )) 867 868 # define LLLFDEB(l1,l2,l3,d4) APP_DEB(appDebug( "%s(%3d)" \ 869 DFML \ 870 DFML \ 871 DFML \ 872 DFMD \ 873 "\n", __FILE__, __LINE__, \ 874 #l1, DEBL(l1), \ 875 #l2, DEBL(l2), \ 876 #l3, DEBL(l3), \ 877 #d4, DEBD(d4) )) 878 879 # define LXXDEB(l1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 880 DFML \ 881 DFMX \ 882 DFMX \ 883 "\n", __FILE__, __LINE__, \ 884 #l1, DEBL(l1), \ 885 #l2, DEBX(l2), \ 886 #l3, DEBX(l3) )) 887 888 # define XXLDEB(l1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 889 DFMX \ 890 DFMX \ 891 DFML \ 892 "\n", __FILE__, __LINE__, \ 893 #l1, DEBX(l1), \ 894 #l2, DEBX(l2), \ 895 #l3, DEBL(l3) )) 896 897 # define LLXDEB(l1,l2,l3) APP_DEB(appDebug( "%s(%3d)" \ 898 DFML \ 899 DFML \ 900 DFMX \ 901 "\n", __FILE__, __LINE__, \ 902 #l1, DEBL(l1), \ 903 #l2, DEBL(l2), \ 904 #l3, DEBX(l3) )) 905 906 # define LLPDEB(l1,l2,p3) APP_DEB(appDebug( "%s(%3d)" \ 907 DFML \ 908 DFML \ 909 DFMP \ 910 "\n", __FILE__, __LINE__, \ 911 #l1, DEBL(l1), \ 912 #l2, DEBL(l2), \ 913 #p3, DEBP(p3) )) 914 915 # define LFFDEB(l1,d2,d3) APP_DEB(appDebug( "%s(%3d)" \ 916 DFML \ 917 DFMD \ 918 DFMD \ 919 "\n", __FILE__, __LINE__, \ 920 #l1, DEBL(l1), \ 921 #d2, DEBD(d2), \ 922 #d3, DEBD(d3) )) 923 924 # define LFLLDEB(l1,d2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 925 DFML \ 926 DFMD \ 927 DFML \ 928 DFML \ 929 "\n", __FILE__, __LINE__, \ 930 #l1, DEBL(l1), \ 931 #d2, DEBD(d2), \ 932 #l3, DEBL(l3), \ 933 #l4, DEBL(l4) )) 934 935 # define LLFFFDEB(l1,l2,d3,d4,d5) APP_DEB(appDebug( "%s(%3d)" \ 936 DFML \ 937 DFML \ 938 DFMD \ 939 DFMD \ 940 DFMD \ 941 "\n", __FILE__, __LINE__, \ 942 #l1, DEBL(l1), \ 943 #l2, DEBL(l2), \ 944 #d3, DEBD(d3), \ 945 #d4, DEBD(d4), \ 946 #d5, DEBD(d5) )) 947 948 # define LFFFDEB(l1,d2,d3,d4) APP_DEB(appDebug( "%s(%3d)" \ 949 DFML \ 950 DFMD \ 951 DFMD \ 952 DFMD \ 953 "\n", __FILE__, __LINE__, \ 954 #l1, DEBL(l1), \ 955 #d2, DEBD(d2), \ 956 #d3, DEBD(d3), \ 957 #d4, DEBD(d4) )) 958 959 # define LFFFFDEB(l1,d2,d3,d4,d5) APP_DEB(appDebug( "%s(%3d)" \ 960 DFML \ 961 DFMD \ 962 DFMD \ 963 DFMD \ 964 DFMD \ 965 "\n", __FILE__, __LINE__, \ 966 #l1, DEBL(l1), \ 967 #d2, DEBD(d2), \ 968 #d3, DEBD(d3), \ 969 #d4, DEBD(d4), \ 970 #d5, DEBD(d5) )) 971 972 # define LLFDEB(l1,l2,d3) APP_DEB(appDebug( "%s(%3d)" \ 973 DFML \ 974 DFML \ 975 DFMD \ 976 "\n", __FILE__, __LINE__, \ 977 #l1, DEBL(l1), \ 978 #l2, DEBL(l2), \ 979 #d3, DEBD(d3) )) 980 981 # define LLSDEB(l1,l2,s3) APP_DEB(appDebug( "%s(%3d)" \ 982 DFML \ 983 DFML \ 984 DFMS \ 985 "\n", __FILE__, __LINE__, \ 986 #l1, DEBL(l1), \ 987 #l2, DEBL(l2), \ 988 #s3, DEBS(s3) )) 989 990 # define XLSDEB(l1,l2,s3) APP_DEB(appDebug( "%s(%3d)" \ 991 DFMX \ 992 DFML \ 993 DFMS \ 994 "\n", __FILE__, __LINE__, \ 995 #l1, DEBX(l1), \ 996 #l2, DEBL(l2), \ 997 #s3, DEBS(s3) )) 998 999 # define LXSDEB(l1,l2,s3) APP_DEB(appDebug( "%s(%3d)" \ 1000 DFML \ 1001 DFMX \ 1002 DFMS \ 1003 "\n", __FILE__, __LINE__, \ 1004 #l1, DEBL(l1), \ 1005 #l2, DEBX(l2), \ 1006 #s3, DEBS(s3) )) 1007 1008 # define SSXDEB(s1,s2,l3) APP_DEB(appDebug( "%s(%3d)" \ 1009 DFMS \ 1010 DFMS \ 1011 DFMX \ 1012 "\n", __FILE__, __LINE__, \ 1013 #s1, DEBS(s1), \ 1014 #s2, DEBS(s2), \ 1015 #l3, DEBX(l3) )) 1016 # define SSPDEB(s1,s2,p3) APP_DEB(appDebug( "%s(%3d)" \ 1017 DFMS \ 1018 DFMS \ 1019 DFMP \ 1020 "\n", __FILE__, __LINE__, \ 1021 #s1, DEBS(s1), \ 1022 #s2, DEBS(s2), \ 1023 #p3, DEBP(p3) )) 1024 1025 # define SSLDEB(s1,s2,l3) APP_DEB(appDebug( "%s(%3d)" \ 1026 DFMS \ 1027 DFMS \ 1028 DFML \ 1029 "\n", __FILE__, __LINE__, \ 1030 #s1, DEBS(s1), \ 1031 #s2, DEBS(s2), \ 1032 #l3, DEBL(l3) )) 1033 1034 # define SSLSDEB(s1,s2,l3,s4) APP_DEB(appDebug( "%s(%3d)" \ 1035 DFMS \ 1036 DFMS \ 1037 DFML \ 1038 DFMS \ 1039 "\n", __FILE__, __LINE__, \ 1040 #s1, DEBS(s1), \ 1041 #s2, DEBS(s2), \ 1042 #l3, DEBL(l3), \ 1043 #s4, DEBS(s4) )) 1044 1045 # define SSFDEB(s1,s2,d3) APP_DEB(appDebug( "%s(%3d)" \ 1046 DFMS \ 1047 DFMS \ 1048 DFMD \ 1049 "\n", __FILE__, __LINE__, \ 1050 #s1, DEBS(s1), \ 1051 #s2, DEBS(s2), \ 1052 #d3, DEBD(d3) )) 1053 1054 # define SSSLDEB(s1,s2,s3,l4) APP_DEB(appDebug( "%s(%3d)" \ 1055 DFMS \ 1056 DFMS \ 1057 DFMS \ 1058 DFML \ 1059 "\n", __FILE__, __LINE__, \ 1060 #s1, DEBS(s1), \ 1061 #s2, DEBS(s2), \ 1062 #s3, DEBS(s3), \ 1063 #l4, DEBL(l4) )) 1064 1065 # define SSSFDEB(s1,s2,s3,d4) APP_DEB(appDebug( "%s(%3d)" \ 1066 DFMS \ 1067 DFMS \ 1068 DFMS \ 1069 DFMD \ 1070 "\n", __FILE__, __LINE__, \ 1071 #s1, DEBS(s1), \ 1072 #s2, DEBS(s2), \ 1073 #s3, DEBS(s3), \ 1074 #d4, DEBD(d4) )) 1075 1076 # define SSSSDEB(s1,s2,s3,s4) APP_DEB(appDebug( "%s(%3d)" \ 1077 DFMS \ 1078 DFMS \ 1079 DFMS \ 1080 DFMS \ 1081 "\n", __FILE__, __LINE__, \ 1082 #s1, DEBS(s1), \ 1083 #s2, DEBS(s2), \ 1084 #s3, DEBS(s3), \ 1085 #s4, DEBS(s4) )) 1086 1087 # define SSLLDEB(s1,s2,l3,l4) APP_DEB(appDebug( "%s(%3d)" \ 1088 DFMS \ 1089 DFMS \ 1090 DFML \ 1091 DFML \ 1092 "\n", __FILE__, __LINE__, \ 1093 #s1, DEBS(s1), \ 1094 #s2, DEBS(s2), \ 1095 #l3, DEBL(l3), \ 1096 #l4, DEBL(l4) )) 1097 1098 # define SSLFDEB(s1,s2,l3,d4) APP_DEB(appDebug( "%s(%3d)" \ 1099 DFMS \ 1100 DFMS \ 1101 DFML \ 1102 DFMD \ 1103 "\n", __FILE__, __LINE__, \ 1104 #s1, DEBS(s1), \ 1105 #s2, DEBS(s2), \ 1106 #l3, DEBL(l3), \ 1107 #d4, DEBD(d4) )) 1108 1109 # define LLSLDEB(l1,l2,s3,l4) APP_DEB(appDebug( "%s(%3d)" \ 1110 DFML \ 1111 DFML \ 1112 DFMS \ 1113 DFML \ 1114 "\n", __FILE__, __LINE__, \ 1115 #l1, DEBS(l1), \ 1116 #l2, DEBS(l2), \ 1117 #s3, DEBL(s3), \ 1118 #l4, DEBL(l4) )) 1119 1120 # define SSSDEB(s1,s2,s3) APP_DEB(appDebug( "%s(%3d)" \ 1121 DFMS \ 1122 DFMS \ 1123 DFMS \ 1124 "\n", __FILE__, __LINE__, \ 1125 #s1, DEBS(s1), \ 1126 #s2, DEBS(s2), \ 1127 #s3, DEBS(s3) )) 1128 1129 # define LSSSDEB(l1,s2,s3,s4) APP_DEB(appDebug( "%s(%3d)" \ 1130 DFML \ 1131 DFMS \ 1132 DFMS \ 1133 DFMS \ 1134 "\n", __FILE__, __LINE__, \ 1135 #l1, DEBL(l1), \ 1136 #s2, DEBS(s2), \ 1137 #s3, DEBS(s3), \ 1138 #s4, DEBS(s4) )) 1139 1140 # define LSSLDEB(l1,s2,s3,l4) APP_DEB(appDebug( "%s(%3d)" \ 1141 DFML \ 1142 DFMS \ 1143 DFMS \ 1144 DFML \ 1145 "\n", __FILE__, __LINE__, \ 1146 #l1, DEBL(l1), \ 1147 #s2, DEBS(s2), \ 1148 #s3, DEBS(s3), \ 1149 #l4, DEBL(l4) )) 1150 1151 # define LSSLLDEB(l1,s2,s3,l4,l5) APP_DEB(appDebug( "%s(%3d)" \ 1152 DFML \ 1153 DFMS \ 1154 DFMS \ 1155 DFML \ 1156 DFML \ 1157 "\n", __FILE__, __LINE__, \ 1158 #l1, DEBL(l1), \ 1159 #s2, DEBS(s2), \ 1160 #s3, DEBS(s3), \ 1161 #l4, DEBL(l4), \ 1162 #l5, DEBL(l5) )) 1163 1164 # define LSSDEB(l1,s2,s3) APP_DEB(appDebug( "%s(%3d)" \ 1165 DFML \ 1166 DFMS \ 1167 DFMS \ 1168 "\n", __FILE__, __LINE__, \ 1169 #l1, DEBL(l1), \ 1170 #s2, DEBS(s2), \ 1171 #s3, DEBS(s3) )) 1172 1173 # define XSSDEB(l1,s2,s3) APP_DEB(appDebug( "%s(%3d)" \ 1174 DFMX \ 1175 DFMS \ 1176 DFMS \ 1177 "\n", __FILE__, __LINE__, \ 1178 #l1, DEBX(l1), \ 1179 #s2, DEBS(s2), \ 1180 #s3, DEBS(s3) )) 1181 1182 # define FFFDEB(d1,d2,d3) APP_DEB(appDebug( "%s(%3d)" \ 1183 DFMD \ 1184 DFMD \ 1185 DFMD \ 1186 "\n", __FILE__, __LINE__, \ 1187 #d1, DEBD(d1), \ 1188 #d2, DEBD(d2), \ 1189 #d3, DEBD(d3) )) 1190 1191 # define FFFFDEB(d1,d2,d3,d4) APP_DEB(appDebug( "%s(%3d)" \ 1192 DFMD \ 1193 DFMD \ 1194 DFMD \ 1195 DFMD \ 1196 "\n", __FILE__, __LINE__, \ 1197 #d1, DEBD(d1), \ 1198 #d2, DEBD(d2), \ 1199 #d3, DEBD(d3), \ 1200 #d4, DEBD(d4) )) 1201 1202 # ifdef __cplusplus 1203 } 1204 # endif 1205 1206 # endif /* APP_DEBUG_H */ 1207