ext/bsdjail.h
author Michael Granger <ged@FaerieMUD.org>
Thu, 16 Oct 2008 02:43:08 +0000
changeset 2 0c24586f579a
child 5 41a1542b3b10
permissions -rw-r--r--
Checkpoint commit.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
     1
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
     2
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
     3
#include <stdlib.h>
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
     4
#include <stdio.h>
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
     5
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
     6
#include <ruby.h>
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
     7
#include <intern.h>				/* For rb_dbl2big() */
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
     8
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
     9
#include <link-grammar/link-includes.h>
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    10
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    11
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    12
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    13
/* Debugging functions/macros */
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    14
#ifdef HAVE_STDARG_PROTOTYPES
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    15
#include <stdarg.h>
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    16
#define va_init_list(a,b) va_start(a,b)
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    17
extern void rbjail_debug(const char *fmt, ...);
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    18
#else
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    19
#include <varargs.h>
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    20
#define va_init_list(a,b) va_start(a)
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    21
extern void rbjail_debug(fmt, va_alist);
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    22
#endif
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    23
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    24
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    25
/* Debugging macro */
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    26
#if DEBUG
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    27
#  define debugMsg(f)	rbjail_debug f
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    28
#else /* ! DEBUG */
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    29
#  define debugMsg(f) 
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    30
#endif /* DEBUG */
0c24586f579a Checkpoint commit.
Michael Granger <ged@FaerieMUD.org>
parents:
diff changeset
    31