File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / mpd / src / defs.h
Revision 1.1.1.3 (vendor branch): download - view: text, annotated - select for diffs - revision graph
Tue Nov 1 09:56:12 2016 UTC (7 years, 8 months ago) by misho
Branches: mpd, MAIN
CVS tags: v5_9p16, v5_9, v5_8p7, v5_8p1_cross, v5_8p1, v5_8, HEAD
mpd 5.8

    1: 
    2: /*
    3:  * defs.h
    4:  *
    5:  * Written by Archie Cobbs <archie@freebsd.org>
    6:  * Copyright (c) 1995-1999 Whistle Communications, Inc. All rights reserved.
    7:  * See ``COPYRIGHT.whistle''
    8:  */
    9: 
   10: #ifndef _DEFS_H_
   11: #define _DEFS_H_
   12: 
   13: #include <sys/param.h>
   14: #include <sys/types.h>
   15: #include <sysexits.h>
   16: #include "config.h"
   17: 
   18: /*
   19:  * DEFINITIONS
   20:  */
   21: 
   22:   /* Compile time configuring. */
   23: #ifndef HAVE_NG_CAR
   24:   #undef USE_NG_CAR
   25: #endif
   26: #if !defined(HAVE_NG_DEFLATE) || !defined(USE_NG_DEFLATE) || !defined(CCP_DEFLATE)
   27:   #undef CCP_DEFLATE
   28:   #undef USE_NG_DEFLATE
   29: #endif
   30: #ifndef HAVE_NG_IPACCT
   31:   #undef USE_NG_IPACCT
   32: #endif
   33: #if !defined(HAVE_NG_MPPC) || !defined(USE_NG_MPPC) || !defined(CCP_MPPC)
   34:   #undef CCP_MPPC
   35:   #undef USE_NG_MPPC
   36: #endif
   37: #ifndef HAVE_NG_NAT
   38:   #undef USE_NG_NAT
   39: #endif
   40: #ifndef HAVE_NG_NETFLOW
   41:   #undef USE_NG_NETFLOW
   42: #endif
   43: #if !defined(HAVE_NG_PRED1) || !defined(CCP_PRED1)
   44:   #undef USE_NG_PRED1
   45: #endif
   46: #ifndef HAVE_NG_TCPMSS
   47:   #undef USE_NG_TCPMSS
   48: #endif
   49: #ifndef HAVE_NG_VJC
   50:   #undef USE_NG_VJC
   51: #endif
   52: #ifndef HAVE_NG_BPF
   53:   #undef USE_NG_BPF
   54: #endif
   55: #ifndef HAVE_IPFW
   56:   #undef USE_IPFW
   57: #endif
   58: #ifndef HAVE_RAD_BIND
   59:   #undef HAVE_RAD_BIND
   60: #endif
   61: #ifndef	HAVE_NTOA_R
   62:   #undef HAVE_NTOA_R
   63: #endif
   64: 
   65:   /* Boolean */
   66: #ifndef TRUE
   67:   #define TRUE 			1
   68: #endif
   69: #ifndef FALSE
   70:   #define FALSE 		0
   71: #endif
   72: 
   73: #ifndef MPD_VENDOR
   74:   #define MPD_VENDOR		"FreeBSD MPD"
   75: #endif
   76: 
   77:   /* Exit codes */
   78:   #define EX_NORMAL		EX_OK
   79:   #define EX_ERRDEAD		EX_SOFTWARE
   80:   #define EX_TERMINATE		99	/* pseudo-code */
   81: 
   82:   /* Pathnames */
   83:   #define CONF_FILE 		"mpd.conf"
   84:   #define SECRET_FILE		"mpd.secret"
   85:   #define SCRIPT_FILE		"mpd.script"
   86: 
   87: #ifndef PATH_CONF_DIR
   88:   #define PATH_CONF_DIR		"/etc/ppp"
   89: #endif
   90: 
   91:   #define LG_FILE		"/var/log/mpd"
   92:   #define PID_FILE		"/var/run/mpd.pid"
   93: 
   94:   #define PATH_ARP		"/usr/sbin/arp"
   95: #ifdef USE_IPFW
   96:   #define PATH_IPFW		"/sbin/ipfw"
   97: #endif
   98:   #define PATH_NETSTAT		"/usr/bin/netstat"
   99: 
  100:   #define AUTH_MAX_AUTHNAME	64
  101:   #define AUTH_MAX_PASSWORD	64
  102:   #define AUTH_MAX_SESSIONID	32
  103: 
  104:   #define LINK_MAX_NAME		16
  105: 
  106:   #define DEFAULT_CONSOLE_PORT	5005
  107:   #define DEFAULT_CONSOLE_IP	"127.0.0.1"
  108: 
  109:   #define DEFAULT_WEB_PORT	5006
  110:   #define DEFAULT_WEB_IP	"127.0.0.1"
  111: 
  112:   #define DEFAULT_RADSRV_PORT	3799
  113:   #define DEFAULT_RADSRV_IP	"0.0.0.0"
  114: 
  115:   /* Characters, leave for interface number. For example: ppp9999 */
  116:   #define IFNUMLEN		(sizeof("9999") - 1)
  117: 
  118:   /* Forward decl's */
  119:   struct linkst;
  120:   typedef struct linkst *Link;
  121:   struct bundle;
  122:   typedef struct bundle *Bund;
  123:   struct rep;
  124:   typedef struct rep *Rep;
  125: 
  126:   struct context;
  127:   typedef struct context *Context;
  128: 
  129: #endif
  130: 

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>