source: git/Singular/mod2.h.in @ f413ec5

spielwiese
Last change on this file since f413ec5 was f413ec5, checked in by Hans Schönemann <hannes@…>, 24 years ago
* hannes: dynamic loading of readline (Makefile.in cntrlc.cc configure configure.in feResource.cc febase.cc febase.h febase.inc feread.cc misc.cc mod2.h.in) git-svn-id: file:///usr/local/Singular/svn/trunk@3549 2c84dea3-7e68-4137-9b89-c4e89433aadc
  • Property mode set to 100644
File size: 13.7 KB
Line 
1/*******************************************************************
2 *  Computer Algebra System SINGULAR
3 *
4 *  mod2.h: Main configuration file for Singular
5 *          DO NOT EDIT!
6 *
7 *  Version: $Id: mod2.h.in,v 1.66 1999-08-25 16:02:48 Singular Exp $
8 *******************************************************************/
9#ifndef MOD2_H
10#define MOD2_H
11
12/*******************************************************************
13 * Defines which are set by configure
14 ******************************************************************/
15/* Define to use dynamic linking */
16#undef HAVE_DL
17/* Define to use readline lib for fancy display */
18#undef HAVE_READLINE
19/* Define to use built-in command line parser */
20#undef HAVE_FEREAD
21/* Define if you want to use dld's */
22#undef HAVE_DLD
23/* Define to have dbm links */
24#undef HAVE_DBM
25/* Define to have smallgmp */
26#undef HAVE_SMALLGMP
27/* Define to have MP links */
28#undef HAVE_MPSR
29/* Define to have factory functionality added */
30#undef HAVE_FACTORY
31/* Define to have libfac functionality added */
32#undef HAVE_LIBFAC_P
33/* Define if you have stdc headers */
34#undef STDC_HEADERS
35/* Define if you have asm/sigcontext.h */
36#undef HAVE_ASM_SIGCONTEXT_H
37/* Define if you have sys/file.h */
38#undef HAVE_SYS_FILE_H
39/* Define if you have sys/stat.h */
40#undef HAVE_SYS_STAT_H
41/* Define if you have sys/param.h */
42#undef HAVE_SYS_PARAM_H
43/* Define if you have sys/file.h */
44#undef HAVE_SYS_TYPES_H
45/* Define if you have sys/ioctl.h */
46#undef HAVE_SYS_IOCTL_H
47/* Define if you have sys/time.h */
48#undef HAVE_SYS_TIME_H
49/* Define if you have sys/times.h */
50#undef HAVE_SYS_TIMES_H
51/* Define if you have readline/history.h */
52#undef HAVE_READLINE_HISTORY_H
53/* Define if readline/readline.h is ok */
54#undef READLINE_READLINE_H_OK
55/* Define if time.h and sys/time.h can be included at the same time */
56#undef TIME_WITH_SYS_TIME
57/* Define if you have alloca.h */
58#undef HAVE_ALLOCA_H
59/* Define if you have pwd.h */
60#undef HAVE_PWD_H
61/* Define if you have unistd.h */
62#undef HAVE_UNISTD_H
63/* define if you have malloc.h n */
64#undef HAVE_MALLOC_H
65/* Define if you have alloca */
66#undef HAVE_ALLOCA
67/* Define if you have getpagesize */
68#undef GETPAGESIZE
69/* Define if you have vprintf */
70#undef HAVE_VPRINTF
71/* Define if you have gettimeofday */
72#undef HAVE_GETTIMEOFDAY
73/* Define if you have atexit */
74#undef HAVE_ATEXIT
75/* Define if you have bcopy, bzero and bcmp
76   Linux needs that define! */
77#undef HAVE_BCOPY
78/* Define if sprintf does not return number of printed chars */
79#undef BSD_SPRINTF
80/* define if you have explicit C++ constructors */
81#undef HAVE_EXPLICIT_CONSTR
82/* Define if you have the getcwd function.  */
83#undef HAVE_GETCWD
84/* Define if you have the getwd function.  */
85#undef HAVE_GETWD
86/* Define if you have snprintf */
87#undef HAVE_VSNPRINTF
88/* Define if you have sbrk */
89#undef HAVE_SBRK
90/* Define if you have readlink */
91#undef HAVE_READLINK
92/* Define if you have usleep */
93#undef HAVE_USLEEP
94/* Define if you have sleep */
95#undef HAVE_SLEEP
96/* Define if you have setenv */
97#undef HAVE_SETENV
98/* Define sizeof(char) */
99#define SIZEOF_CHAR 1
100/* Define sizeof(short) */
101#define SIZEOF_SHORT 2
102/* Define sizeof(int) */
103#define SIZEOF_INT 4
104/* Define sizeof(long) */
105#define SIZEOF_LONG 4
106/* Define sizeof(void*) */
107#define SIZEOF_VOIDP 4
108/* Define sizeof(double) */
109#define SIZEOF_DOUBLE 8
110/* Define if your integer format is big endian */
111#undef WORDS_BIGENDIAN
112/* Define the type of the exponents to be used in monomials */
113#define EXPONENT_TYPE short
114/* Define the size of exponent */
115#define SIZEOF_EXPONENT SIZEOF_SHORT
116/* Define major version of Singular -- should be set in ../configure.in!!!*/
117#define SINGULAR_MAJOR_VERSION 0
118/* Define minor version of Singular -- should be set in ../configure.in!!! */
119#define SINGULAR_MINOR_VERSION 0
120/* Define sub version of Singular -- should be set in ../configure.in!!! */
121#define SINGULAR_SUB_VERSION 0
122/* Define version as a string */
123#define S_VERSION1 ""
124/* Define version date as a string */
125#define S_VERSION2 ""
126/* Define uname identifier as a string */
127#define S_UNAME ""
128/* Absolute pathname of root directory of Singular source */
129#define S_ROOT_DIR ""
130/* Define if our gmalloc is to be used */
131#undef HAVE_GMALLOC
132/* Define pagesize of your system */
133#define SIZE_OF_SYSTEM_PAGE 4096
134/* size of page as we can use it */
135#define SIZE_OF_PAGE SIZE_OF_SYSTEM_PAGE
136/* valloc routine which returns chunk of SIZE_OF_PAGE */
137#define PALLOC malloc
138#define PFREE  free
139/* define if result of PALLOC is aligned on SIZE_OF_SYSTEM_PAGE */
140#undef HAVE_PAGE_ALIGNMENT
141/* define if you have the MTRACK utilities (only on linux/elf) */
142#undef HAVE_MTRACK
143
144/*******************************************************************
145 * Defines which are not set by configure
146 ******************************************************************/
147/* define to use the dynamic linking of readline in non-distributions builds */
148/* #undef USE_DYN_RL */
149
150/* Default value for timer resolution in ticks per second */
151/* set to 10 for resolution of tenth of a second, etc */
152#define TIMER_RESOLUTION 1
153
154/* Undefine to disable the quote/eval of expressions */
155#define SIQ 1
156
157/* Define to enable TCL interface */
158#undef HAVE_TCL
159/* Define to enable working in Weyl algebras */
160#undef DRING
161/* Define to enable working in exterior algebras */
162#undef SRING
163
164/* Undefine to disable Gerhard's and Wilfried's fast and dirty std computations */
165#define FAST_AND_DIRTY
166#ifdef __MWERKS__
167/* includes for Metrowerks */
168#include "mod2.mwerks.h"
169#else
170/* works around a quirk in the generation of parser tables */
171#define INIT_BUG
172#endif
173
174/* linear algebra extensions from pcv.h/pcv.cc */
175#define HAVE_PCV 1
176
177/* Define to use old mechanismen for saving currRing with procedures
178 * Does not work with HAVE_NAMESPACES enabled
179 */
180#undef USE_IILOCALRING
181
182/* Define to use new namespaces techniks */
183#undef HAVE_NAMESPACES
184
185/* Define to enable dynamic module code */
186#undef HAVE_DYNAMIC_LOADING
187
188/* Define to use scanner when loading libraries */
189#define HAVE_LIBPARSER
190
191/*#define PROFILING*/
192#ifdef PROFILING
193#define PROFILER ,0,0
194#else
195#define PROFILER
196#endif
197
198/* Define to use gmp for rational arithmetic */
199#define HAVE_GMP
200
201/*******************************************************************
202 * Evaluate the set defines
203 ******************************************************************/
204/* dynamic readline or readline ? */
205#ifdef HAVE_DL
206  #if defined(MAKE_DISTRIBUTION) || defined(USE_DYN_RL)
207    #define HAVE_DYN_RL
208  #endif
209#endif
210
211/* FGLM needs factory */
212#ifdef HAVE_FACTORY
213#define HAVE_FGLM
214#endif
215
216/* Define if you want fglm for homogeneous case */
217#ifdef HAVE_FGLM
218#undef HAVE_FGLM_HOME
219#endif
220
221/* Spectrum needs GMP */
222#ifdef HAVE_GMP
223/* #define HAVE_SPECTRUM */
224#endif
225
226/* Undefine to disable real time measurments  */
227#ifdef HAVE_GETTIMEOFDAY
228#if ! defined(__MWERKS__) && ! defined(MSDOS)
229#define HAVE_RTIMER
230#else
231#undef HAVE_RTIMER
232#endif
233#endif
234
235#if SIZEOF_VOIDP == 8
236#define ALIGN_8
237#endif
238
239#define SINGULAR_VERSION (SINGULAR_MAJOR_VERSION*1000 + SINGULAR_MINOR_VERSION*100 + SINGULAR_SUB_VERSION)
240#ifdef DRING
241#define SDRING
242#endif
243
244#ifdef SRING
245#define SDRING
246#endif
247
248#if SIZEOF_EXPONENT == 1
249#define MAX_EXPONENT 0x7f
250#define MAX_COMPONENT 0xff
251#elif SIZEOF_EXPONENT == 2
252#define MAX_EXPONENT 0x7fff
253#define MAX_COMPONENT 0xffff
254#else /* SIZEOF_EXPONENT == 4 */
255#define MAX_EXPONENT 0x7fffffff
256#define MAX_COMPONENT 0xffffffff
257#endif
258
259/*******************************************************************
260 * Miscellanous Defines
261 ******************************************************************/
262/* define MM_COUNT to enable "memory(0)" (resp. memory(1))*/
263#define MM_COUNT 1
264
265
266#ifndef HAVE_LIBPARSER
267#  undef YYLPDEBUG
268#else
269#  define YYLPDEBUG 1
270#endif
271
272#ifndef FALSE
273#define FALSE       0
274#endif
275
276#ifndef TRUE
277#define TRUE        1
278#endif
279
280#ifndef NULL
281#define NULL        (0)
282#endif
283
284#ifndef SEEK_END
285#define SEEK_END 2
286#endif
287
288#ifndef SEEK_SET
289#define SEEK_SET 0
290#endif
291
292#define HALT() m2_end(2)
293
294#define memcpy4 memcpy
295
296/* define OLD_RES for res/sres/mres(i,j,k) */
297#undef OLD_RES
298
299/* the maximal ascii length of an int number + 1 = 11 for 32 bit int */
300#define MAX_INT_LEN 11
301#define MAX_INT_VAL 0x7fffffff
302extern int pShortOut;
303
304#ifdef DO_PROFILE
305/* define to enable explicit profiling of some crucial inline
306 * routines and defines  */
307#undef DO_DEEP_PROFILE
308#endif
309
310#define buildin_rand 1
311
312/* define to enable assume */
313#ifndef HAVE_ASSUME
314#undef HAVE_ASSUME
315#endif
316
317/*******************************************************************
318 * DEBUG OPTIONS
319 * -- only significant for for compiling without -DNDEBUG
320 * -- you better know what your are doing, if you touch this
321 ******************************************************************/
322#ifndef NDEBUG
323
324/* undefine to disable assume -- should normally be defined for NDEBUG */
325#define HAVE_ASSUME
326
327
328/* undefine to disable assume -- should normally be defined for NDEBUG */
329#define HAVE_ASSUME
330
331/* undef MDEBUG to disable memory checks
332 *
333 * define MDEBUG to
334 * 0 to enable basic memory checks (at least on each alloc/free)
335 * 1 for addtl. containment checks in free/alloc list for each memory check
336 * 2 for addtl. checks of entire free/alloc list at each memory check
337 * 3 for addtl. checks of all heaps at each memory check
338 * NOTE: For MDEBUG > 1, it gets very slow
339 * You can control MDEBUG at run-time by setting the value of the
340 * variable mm_MDEBUG (defined in mmcheck.c) to the appropriate value.
341 */
342#define MDEBUG 0
343
344/* undef HEAP_DEBUG to disable heap checks
345 *
346 * define HEAP_DEBUG to
347 * 0 to enable basic heap addr checks (at least on each alloc/free)
348 * 1 for addtl. containment checks in free/alloc list of heap
349 * 2 for addtl. check of entire  heap at each heap addr check
350 * NOTE: For HEAP_DEBUG > 1 on, it gets very slow
351 * You can control HEAP_DEBUG at run-time by setting the value of the
352 * variable mm_HEAP_DEBUG (defined in mmheap.c) to the appropriate value.
353 */
354#define HEAP_DEBUG 0
355
356/* define PAGE_DEBUG for page accesses -- never re-uses freed pages */
357#ifndef PAGE_DEBUG
358#undef PAGE_DEBUG
359#endif
360
361
362/* define PDEBUG checking polys, undefine otherwise */
363/* define PDEBUG 1 for additionally checking access to polys  -- vewry slow !*/
364#define PDEBUG 1
365/* define KDEBUG checking during standard base computation */
366#define KDEBUG
367/* define LDEBUG checking numbers, undefine otherwise */
368#define LDEBUG
369/* define RDEBUG checking rings (together with TRACE=9) */
370#define RDEBUG
371/* define TEST for non time critical tests, undefine otherwise */
372#define TEST
373/* define MLIST for printing block of used memory on exit */
374#define MLIST 1
375
376#ifdef HAVE_MTRACK
377/* define MTRACK for allowing to keep track of Alloc/Free with a backtrace */
378/* works only under linux/elf */
379#define MTRACK
380/* the maximal level of stacks to remembre in debug (MTRACK) mode */
381#define BT_MAXSTACK 10
382#endif
383
384/* #define PAGE_TEST */
385
386/* define YYDEBUG 1 for debugging bison texts, 0 otherwise */
387#define YYDEBUG 1
388
389/* Undefine to disable debugging of MP stuff */
390#ifdef HAVE_MPSR
391#define MPSR_DEBUG
392#endif
393
394/* MLIST requires MDEBUG */
395#ifdef MLIST
396#ifndef MDEBUG
397#define MDEBUG 0
398#endif
399#endif
400
401/* MTRACK requires MDEBUG and MLIST*/
402#ifdef MTRACK
403#ifndef MDEBUG
404#define MDEBUG 1
405#endif
406#ifndef MLIST
407#define MLIST
408#endif
409#endif
410
411/* PDEBUG requires MDEBUG */
412#ifdef PDEBUG
413#ifndef MDEBUG
414#define MDEBUG 0
415#endif
416#endif
417
418#ifdef TEST
419#ifndef buildin_rand
420#define buildin_rand 1
421#endif
422#endif
423
424#ifdef MTRACK
425#define BT_MAXSTACK 10
426#endif /* MTRACK */
427
428/* define SPECTRUM_DEBUG and SPECTRUM_PRINT for debugging the spectrum code */
429/* define SPECTRUM_IOSTREAM to use C++ iostream for error messages          */
430
431/* #define SPECTRUM_DEBUG */
432/* #define SPECTRUM_PRINT */
433#undef  SPECTRUM_IOSTREAM
434
435#ifdef  SPECTRUM_DEBUG
436#define MULTICNT_DEBUG
437#define GMPRAT_DEBUG
438#define KMATRIX_DEBUG
439#define SPLIST_DEBUG
440#define NPOLYGON_DEBUG
441#define SEMIC_DEBUG
442#endif
443
444#ifdef  SPECTRUM_PRINT
445#define MULTICNT_PRINT
446#define GMPRAT_PRINT
447#define KMATRIX_PRINT
448#define SPLIST_PRINT
449#define NPOLYGON_PRINT
450#define SEMIC_PRINT
451#endif
452
453#ifdef  SPECTRUM_IOSTREAM
454#define MULTICNT_IOSTREAM
455#define GMPRAT_IOSTREAM
456#define KMATRIX_IOSTREAM
457#define SPLIST_IOSTREAM
458#define NPOLYGON_IOSTREAM
459#define SEMIC_IOSTREAM
460#endif
461
462
463#else /* not NDEBUG **************************************************** */
464
465/* define YYDEBUG 1 for debugging bison texts, 0 otherwise */
466#define YYDEBUG 0
467
468#endif /* not NDEBUG */
469
470#ifdef HAVE_DYNAMIC_LOADING
471#   define HAVE_NAMESPACES 1
472#endif /* HAVE_DYNAMIC_LOADING */
473#ifdef HAVE_NAMESPACES
474#  undef USE_IILOCALRING
475#endif
476
477/*******************************************************************
478 *
479 * assume(x) -- a handy macro for assumptions
480 *
481 ******************************************************************/
482
483#ifndef HAVE_ASSUME
484#define assume(x) ((void*) 0)
485#define r_assume(x) ((void*) 0)
486#else /* ! HAVE_ASSUME */
487
488#ifdef __cplusplus
489extern "C" {
490#endif
491/* Set a breakpoint on this function */
492extern void assume_violation(char* file, int line);
493#ifdef __cplusplus
494}
495#endif
496
497
498#define assume(x)   _assume(x, __FILE__, __LINE__)
499#define r_assume(x) _r_assume(x, __FILE__, __LINE__)
500
501#define _assume(x, f, l)                        \
502do                                              \
503{                                               \
504  if (! (x))                                    \
505  {                                             \
506    assume_violation(f, l);                     \
507  }                                             \
508}                                               \
509while (0)
510
511#define _r_assume(x, f, l)                      \
512do                                              \
513{                                               \
514  if (! (x))                                    \
515  {                                             \
516    assume_violation(f, l);                     \
517    return 0;                                   \
518  }                                             \
519}                                               \
520while (0)
521#endif /* HAVE_ASSUME */
522
523#endif /* MOD2_H  */
Note: See TracBrowser for help on using the repository browser.