My Project
Loading...
Searching...
No Matches
feOptTab.h
Go to the documentation of this file.
1#ifndef FE_OPT_TAB_H
2#define FE_OPT_TAB_H
3
4#define LONG_OPTION_RETURN 13
5
6// Define here which cmd-line options are recognized
7#ifndef FE_OPT_STRUCTURE
9#else
10VAR struct fe_option feOptSpec[] =
11{
12//
13// Has to be of the form
14// {name, has_arg, val,
15// arg_name, help, type, value, set}
16// where:
17//
18// name is the name of the long option.
19//
20// has_arg
21// is: no_argument (or 0) if the option does not take
22// an argument, required_argument (or 1) if the option
23// requires an argument, or optional_argument (or 2)
24// if the option takes an optional argument.
25//
26// val is the value to return, or to load into the
27// variable pointed to by flag.
28// NEEDS TO BE LONG_OPTION_RETURN, for long option
29// short option char, for short option
30//
31// arg_name if set, uses this value as name for argument in
32// display of help
33//
34// help one-line description of option
35//
36// type one of feOptUntyped (value is never set),
37// feOptBool, feOptInt, feOptString
38//
39// value (default) value of option
40//
41// set only relevant for feOptString:
42// 1: if value different from default value
43// 0: otherwise
44//
45// The order in which options are specified is the order in which
46// their help is printed on -h
47//
48// Options whose hel starts with an "//" are considered undocumented,
49// i.e., their help is not printed on -h
50//
51#if defined(ESINGULAR) || defined(TSINGULAR)
52#ifdef ESINGULAR
53// options only relevant for ESINGULAR
55 "EMACS", "Use EMACS as emacs program to run Singular", feOptString, 0, 0},
56
58 "DIR", "Use DIR as directory to look for emacs lisp files", feOptString, 0, 0},
59
61 "FILE", "Load FILE on emacs start-up, instead of default", feOptString, 0, 0},
62#else
64 "XTERM", "Use XTERM as terminal program to run Singular", feOptString, 0, 0},
65#endif
66
68 "PROG", "Start PROG as Singular program within emacs", feOptString, 0, 0},
69
71 0, "Do not start program. Print call to stdout", feOptBool, 0, 0},
72#endif
73
74 {"batch", no_argument, 'b',
75 0, "Run in batch mode (requires --link/--MPhost/--MPport)", feOptBool, 0, 0},
76
77 {"execute", required_argument, 'c',
78 "STRING", "Execute STRING on start-up", feOptString, 0, 0},
79
80 {"sdb", no_argument, 'd',
81 0, "Enable source code debugger (experimental)", feOptBool, 0, 0},
82
83 {"echo", optional_argument, 'e',
84 "VAL", "Set value of variable `echo' to (integer) VAL", feOptInt, 0, 0},
85
86 {"help", no_argument, 'h',
87 0, "Print help message and exit", feOptUntyped, 0, 0},
88
89 {"profile", no_argument, 'p',
90 0, "Collect profiling data in smon.out", feOptBool, 0, 0},
91 {"quiet", no_argument, 'q',
92 0, "Do not print start-up banner and lib load messages", feOptBool, 0, 0},
93 {"sort", no_argument, 's',
94 0, "// Sort NTL results", feOptBool, 0, 0},
95
96 {"random", required_argument, 'r',
97 "SEED", "Seed random generator with (integer) SEED", feOptInt, 0, 0},
98
99 {"no-tty", no_argument, 't',
100 0, "Do not redefine the terminal characteristics", feOptBool, 0, 0},
101
102 {"user-option", required_argument, 'u',
103 "STRING", "Return STRING on `system(\"--user-option\")'", feOptString, 0, 0},
104
105 {"version", no_argument, 'v',
106 0, "Print extended version and configuration info", feOptUntyped, 0, 0},
107
108
109 {"allow-net", no_argument, LONG_OPTION_RETURN,
110 0, "Allow one to fetch (html) help pages from the net", feOptBool, 0, 0},
111
113 "BROWSER", "Display help in BROWSER (see help.cnf)", feOptString, 0, 0},
114
116 "CHAR", "Automatic answer for CTRL-C prompt", feOptString, 0, 0},
117#ifndef ESINGULAR
119 0, "Set defaults for running within emacs", feOptBool, 0, 0},
120#endif
122 "LOGFILE", "Log all input to LOGFILE.*", feOptString, 0, 0},
123
124 {"no-stdlib", no_argument, LONG_OPTION_RETURN,
125 0, "Do not load `standard.lib' on start-up", feOptBool, 0, 0},
126
128 0, "Do not execute `.singularrc' file(s) on start-up", feOptBool, 0, 0},
129
130 {"no-warn", no_argument, LONG_OPTION_RETURN,
131 0, "Do not display warning messages", feOptBool, 0, 0},
132
134 0, "Suppress all output", feOptBool, 0, 0},
135
136 {"no-shell", no_argument, LONG_OPTION_RETURN,
137 0, "Restricted mode: prohibit shell escape commands and links", feOptBool, 0, 0},
138
140 "SECS", "Do not display times smaller than SECS (in seconds)", feOptString, (void*) "0.5", 0},
141
143 "#CPUs", "maximal number of CPUs to use", feOptInt, (void*)2, 0},
144
146 "#threads", "maximal number of CPUs to use for threads", feOptInt, (void*)2, 0},
147
148 {"flint-threads", required_argument, LONG_OPTION_RETURN,
149 "#flintthreads", "maximal number of threads to use in flint library", feOptInt, (void*)1, 0},
150
152 "PORT", "Use PORT number for connections", feOptString, 0, 0},
153
155 "HOST", "Use HOST for connections", feOptString, 0, 0},
156
158 "LINK", "Use LINK for connections", feOptString, 0, 0},
159
160 {"ticks-per-sec", required_argument, LONG_OPTION_RETURN,
161 "TICKS", "Sets unit of timer to TICKS per second", feOptInt, (void*)1, 0},
162
163 {"dump-versiontuple", no_argument, LONG_OPTION_RETURN,
164 0, "Display the version-tuple and exit", feOptUntyped, 0, 0},
165
166// terminator -- do NOT remove
167 { 0, 0, 0, 0, 0, feOptInt, 0, 0}
168};
169
170#endif
171#endif
EXTERN_VAR struct fe_option feOptSpec[]
Definition: feOptTab.h:8
#define LONG_OPTION_RETURN
Definition: feOptTab.h:4
@ feOptInt
Definition: fegetopt.h:77
@ feOptUntyped
Definition: fegetopt.h:77
@ feOptBool
Definition: fegetopt.h:77
@ feOptString
Definition: fegetopt.h:77
#define no_argument
Definition: fegetopt.h:99
#define required_argument
Definition: fegetopt.h:100
#define optional_argument
Definition: fegetopt.h:101
#define EXTERN_VAR
Definition: globaldefs.h:6
#define VAR
Definition: globaldefs.h:5