Patrick Welche <prlw1@cam.ac.uk>
[netbsd-mini2440.git] / external / bsd / ntp / dist / sntp / libopts / proto.h
blob4a200bd60f3a775423c9175ac6e96a4b7447d5e6
1 /* $NetBSD$ */
3 /* -*- buffer-read-only: t -*- vi: set ro:
5 * Prototypes for autoopts
6 * Generated Sun Nov 8 08:41:10 PST 2009
7 */
8 #ifndef AUTOOPTS_PROTO_H_GUARD
9 #define AUTOOPTS_PROTO_H_GUARD 1
11 #ifndef LOCAL
12 # define LOCAL extern
13 # define REDEF_LOCAL 1
14 #else
15 # undef REDEF_LOCAL
16 #endif
18 * Extracted from autoopts.c
20 LOCAL void *
21 ao_malloc( size_t sz );
23 LOCAL void *
24 ao_realloc( void *p, size_t sz );
26 LOCAL void
27 ao_free( void *p );
29 LOCAL char *
30 ao_strdup( char const *str );
32 LOCAL tSuccess
33 handleOption( tOptions* pOpts, tOptState* pOptState );
35 LOCAL tSuccess
36 longOptionFind( tOptions* pOpts, char* pzOptName, tOptState* pOptState );
38 LOCAL tSuccess
39 shortOptionFind( tOptions* pOpts, uint_t optValue, tOptState* pOptState );
41 LOCAL tSuccess
42 doImmediateOpts( tOptions* pOpts );
44 LOCAL tSuccess
45 doRegularOpts( tOptions* pOpts );
48 * Extracted from configfile.c
50 LOCAL void
51 internalFileLoad( tOptions* pOpts );
53 LOCAL char*
54 parseAttributes(
55 tOptions* pOpts,
56 char* pzText,
57 tOptionLoadMode* pMode,
58 tOptionValue* pType );
60 LOCAL tSuccess
61 validateOptionsStruct( tOptions* pOpts, char const* pzProgram );
64 * Extracted from environment.c
66 LOCAL void
67 doPrognameEnv( tOptions* pOpts, teEnvPresetType type );
69 LOCAL void
70 doEnvPresets( tOptions* pOpts, teEnvPresetType type );
73 * Extracted from load.c
75 LOCAL void
76 mungeString( char* pzTxt, tOptionLoadMode mode );
78 LOCAL void
79 loadOptionLine(
80 tOptions* pOpts,
81 tOptState* pOS,
82 char* pzLine,
83 tDirection direction,
84 tOptionLoadMode load_mode );
87 * Extracted from nested.c
89 LOCAL tOptionValue*
90 optionLoadNested(char const* pzTxt, char const* pzName, size_t nameLen);
92 LOCAL int
93 get_special_char(char const ** ppz, int * ct);
95 LOCAL void
96 emit_special_char(FILE * fp, int ch);
99 * Extracted from sort.c
101 LOCAL void
102 optionSort( tOptions* pOpts );
105 * Extracted from stack.c
107 LOCAL void
108 addArgListEntry( void** ppAL, void* entry );
110 #ifdef REDEF_LOCAL
111 # undef LOCAL
112 # define LOCAL
113 #endif
114 #endif /* AUTOOPTS_PROTO_H_GUARD */