62{
64
67
68#ifdef PSINGULAR
69 global_argv0 = argv[0];
70#endif
73 #ifdef HAVE_NTL
74 #if NTL_MAJOR_VERSION>=10
75 #ifdef NTL_THREAD_BOOST
77 #endif
78 #endif
79 #endif
80
81
82 int optc, option_index;
83 const char* errormsg;
86 != EOF)
87 {
88 if (optc == '?' || optc == 0)
89 {
90 fprintf(stderr,
"Use '%s --help' for a complete list of options\n",
feArgv0);
91 exit(1);
92 }
93
96
98
103 else
105
106 if (errormsg)
107 {
109 fprintf(stderr, "Error: Option '--%s' %s\n",
111 else
112 fprintf(stderr, "Error: Option '--%s=%s' %s\n",
114 fprintf(stderr,
"Use '%s --help' for a complete list of options\n",
feArgv0);
115 exit(1);
116 }
117 if (optc == 'h') exit(0);
118 switch(option_index)
119 {
120 case FE_OPT_DUMP_VERSIONTUPLE:
121 exit(0);
122 break;
123 default: ;
124 }
125 }
126
127
128
130 {
131 (printf)(
132" SINGULAR /"
133#ifndef MAKE_DISTRIBUTION
134" Development"
135#endif
136"\n"
137" A Computer Algebra System for Polynomial Computations / version %s\n"
138" 0<\n"
139" by: W. Decker, G.-M. Greuel, G. Pfister, H. Schoenemann \\ %s\n"
140"FB Mathematik der Universitaet, D-67653 Kaiserslautern \\\n"
141, VERSION, VERSION_DATE);
143 " shell invocation and links are disallowed");
144 }
145 else
146 {
148 dup2(1,2);
149
150
151
152 }
153
154#ifdef SINGULAR_PYOBJECT_SETUP_H
156#endif
157#ifdef SI_COUNTEDREF_AUTOLOAD
159#endif
161
162
163
164
165
167
168
169
171 {
175 {
177 {
178 Warn(
"Can not open %s", argv[
i]);
179 }
180 else
181 {
184 }
186 }
187 }
188 else
189 {
191 }
192
193
196
197
198
200 {
205
207 {
210 fclose(rc);
212 }
213 }
214
215
217 {
219 char *linkname=(
char*)
feOptValue(FE_OPT_LINK);
220 if((linkname!=
NULL)&&(strcmp(linkname,
"ssi")==0))
221 {
223
224
225 }
226 else
227 {
228 Print(
"** missing arguments: -b requires --link/--MPhost/--MPport\n");
229 return 1;
230 }
231 }
235 return 0;
236}
static const int SW_USE_NTL_SORT
set to 1 to sort factors in a factorization
VAR jmp_buf si_start_jmpbuf
VAR BOOLEAN singular_in_batchmode
void init_signals()
init signal handlers and error handling for libraries: NTL, factory
FILE * feFopen(const char *path, const char *mode, char *where, short useWerror, short path_only)
#define LONG_OPTION_RETURN
const char SHORT_OPTS_STRING[]
feOptIndex feGetOptIndex(const char *name)
const char * feSetOptValue(feOptIndex opt, char *optarg)
static void * feOptValue(feOptIndex opt)
EXTERN_VAR struct fe_option feOptSpec[]
int fe_getopt_long(int argc, char *const *argv, const char *options, const struct fe_option *long_options, int *opt_index)
#define optional_argument
char * fe_fgets_dummy(const char *, char *, int)
char *(* fe_fgets_stdin)(const char *pr, char *s, int size)
void newBuffer(char *s, feBufferTypes t, procinfo *pi, int lineno)
BOOLEAN newFile(char *fname)
Voice * feInitStdin(Voice *pp)
#define omInitGetBackTrace()
void pyobject_setup()
initialize blackbox support for pyobject; functionilty os autoloaded on demand
int status int void * buf
int ssiBatch(const char *host, const char *port)
char name(const Variable &v)
#define omInitRet_2_Info(argv0)