home *** CD-ROM | disk | FTP | other *** search
/ GEMini Atari / GEMini_Atari_CD-ROM_Walnut_Creek_December_1993.iso / files / gnu / g__lib / libconfi.h < prev    next >
Encoding:
C/C++ Source or Header  |  1993-07-23  |  2.9 KB  |  119 lines

  1. // This may look like C code, but it is really -*- C++ -*-
  2. /* 
  3. Copyright (C) 1988 Free Software Foundation
  4.     written by Doug Lea (dl@rocky.oswego.edu)
  5.  
  6. This file is part of GNU CC.
  7.  
  8. GNU CC is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY.  No author or distributor
  10. accepts responsibility to anyone for the consequences of using it
  11. or for whether it serves any particular purpose or works at all,
  12. unless he says so in writing.  Refer to the GNU CC General Public
  13. License for full details.
  14.  
  15. Everyone is granted permission to copy, modify and redistribute
  16. GNU CC, but only under the conditions described in the
  17. GNU CC General Public License.   A copy of this license is
  18. supposed to have been given to you along with GNU CC so you
  19. can know your rights and responsibilities.  It should be in a
  20. file named COPYING.  Among other things, the copyright notice
  21. and this notice must be preserved on all copies.  
  22. */
  23.  
  24.  
  25. /*
  26. This file contains machine and operating-system dependent constants
  27. used by libg++
  28. */
  29.  
  30.  
  31. #ifndef _libconfig_h
  32.  
  33. #define _libconfig_h 1
  34.  
  35. #include <values.h>
  36.  
  37. /* 
  38.    define USG for a SystemV-oriented system
  39. */
  40.  
  41. //#define USG
  42.  
  43.  
  44.  
  45. /*
  46.    HAVE_VPRINTF should be set if vprintf is in libc.a
  47.    HAVE_SETVBUF should be set if setvbuf is in libc.a
  48.    HAVE_SETLINEBUF should be set if setlinebuf in libc.a
  49.  
  50.    The following are correct for vax BSD4.3 and sun. Others not yet known
  51. */
  52.  
  53. #if defined(vax)
  54. //#define HAVE_VPRINTF
  55. //#define  HAVE_SETVBUF  
  56. #define HAVE_SETLINEBUF
  57.  
  58. #elif defined(sun)
  59. #define  HAVE_VPRINTF
  60. #define  HAVE_SETVBUF  
  61. #define  HAVE_SETLINEBUF
  62.  
  63. #elif defined(sequent)
  64. //#define  HAVE_VPRINTF
  65. //#define  HAVE_SETVBUF  
  66. #define  HAVE_SETLINEBUF
  67.  
  68. #elif defined(i386)
  69. #define  HAVE_VPRINTF
  70. #define  HAVE_SETVBUF  
  71. //#define  HAVE_SETLINEBUF
  72. #define  USG
  73.  
  74. #elif defined(atarist)
  75. #define HAVE_VPRINTF
  76.  
  77. #endif
  78.  
  79. /*
  80.    SYSV bcopy, etc.
  81. */
  82.  
  83. #ifdef USG
  84. #define bzero(src, len)       memset((src), 0, (len))
  85. #define bcopy(src, dest, len) memcopy((dest), (src), (len))
  86. #define bcmp(s1,s2,n)         memcmp((s1),(s2),(n))
  87. #endif
  88.  
  89.  
  90. /* 
  91.   Define SHOULD_FREE_TO_REALLOC
  92.   if realloc(p, l) only works (or just works best) if the pointer p
  93.   is first passed through free(p).
  94.   
  95.   This should be set for vax 4.3BSD and probably for most other systems
  96. */
  97.  
  98. #define SHOULD_FREE_TO_REALLOC 1
  99.  
  100.  
  101.  
  102.  
  103. /*
  104.  Sizes of shifts for multiple-precision arithmetic.
  105.  These should not be changed unless Integer representation
  106.  as unsigned shorts is changed in the implementation files.
  107. */
  108.  
  109. #define I_SHIFT         SHORTBITS
  110. #define I_RADIX         ((unsigned long)(1L << I_SHIFT))
  111. #define I_MAXNUM        ((unsigned long)((I_RADIX - 1)))
  112. #define I_MINNUM        ((unsigned long)(I_RADIX >> 1))
  113. #define I_POSITIVE      1
  114. #define I_NEGATIVE      0
  115. #define SHORT_PER_LONG  ((LONGBITS + SHORTBITS - 1) / SHORTBITS)
  116. #define CHAR_PER_LONG   ((LONGBITS + CHARBITS - 1) / CHARBITS)
  117.  
  118. #endif
  119.