home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD2.mdf / c / library / os2 / remind / src / config.h < prev    next >
Encoding:
C/C++ Source or Header  |  1993-10-31  |  12.3 KB  |  246 lines

  1. /***************************************************************/
  2. /*                                                             */
  3. /*  CONFIG.H                                                   */
  4. /*                                                             */
  5. /*  Contains various configuration parameters for Remind.      */
  6. /*  You may have to edit this file to tweak parameters or take */
  7. /*  care of certain system dependencies.                       */
  8. /*                                                             */
  9. /*  This file is part of REMIND.                               */
  10. /*  Copyright (C) 1992, 1993 by David F. Skoll.                */
  11. /*                                                             */
  12. /***************************************************************/
  13.  
  14. /*---------------------------------------------------------------------*/
  15. /* LAT_DEG, LAT_MIN and LAT_SEC: Latitude of your location             */
  16. /* LON_DEG, LON_MIN and LON_SEC: Longitude of your location            */
  17. /* LOCATION: A string identifying your location.                       */
  18. /* For latitude, north is positive, south is negative.                 */
  19. /* For longitude, west is positive, east is negative.                  */
  20. /* NOTE:  For negative numbers, all three of DEG, MIN, SEC should be   */
  21. /*        negative.  To indicate -20deg22'33" use                      */
  22. /*        DEG=-20, MIN=-22 and SEC=-33.                                */
  23. /* The default values are initially set to Ottawa, Ontario, Canada.    */
  24. /*---------------------------------------------------------------------*/
  25. #define LAT_DEG 45
  26. #define LAT_MIN 24
  27. #define LAT_SEC  0
  28. #define LON_DEG 75
  29. #define LON_MIN 39
  30. #define LON_SEC  0
  31. #define LOCATION "Ottawa"
  32.  
  33. /*---------------------------------------------------------------------*/
  34. /* HAVE_MKTIME: Define this if your C library includes the mktime()    */
  35. /*              function.  Otherwise, will attempt to use the Unix     */
  36. /*              style time manipulations.                              */
  37. /*---------------------------------------------------------------------*/
  38. #define HAVE_MKTIME 1
  39.  
  40. /*---------------------------------------------------------------------*/
  41. /* NEED_TIMEGM: If your C library does not have mktime() and it ALSO   */
  42. /*              does not have timelocal() or timegm(), uncomment the   */
  43. /*              next line.  If HAVE_MKTIME is defined, NEED_TIMEGM is  */
  44. /*              ignored.  Very few systems should require NEED_TIMEGM. */
  45. /*---------------------------------------------------------------------*/
  46. /* #define NEED_TIMEGM 1 */
  47.  
  48. /*---------------------------------------------------------------------*/
  49. /* DEFAULT_PAGE:  The default page size to use for Rem2PS.             */
  50. /* The Letter version is appropriate for North America; the A4 version */
  51. /* is appropriate for Europe.                                          */
  52. /*---------------------------------------------------------------------*/
  53. #define DEFAULT_PAGE {"Letter", 612, 792}
  54. /* #define DEFAULT_PAGE {"A4", 595, 842} */
  55.   
  56. /*---------------------------------------------------------------------*/
  57. /* DATESEP:  The default date separator.  North American usage is '/'; */
  58. /* others may prefer '-'.                                              */
  59. /*---------------------------------------------------------------------*/
  60. #define DATESEP '/'
  61. /* #define DATESEP '-' */
  62.  
  63. /*---------------------------------------------------------------------*/
  64. /* TIMESEP:  The default time separator.  North American usage is ':'; */
  65. /* others may prefer '.'.                                              */
  66. /*---------------------------------------------------------------------*/
  67. #define TIMESEP ':'
  68. /* #define TIMESEP '.' */
  69.  
  70. /*---------------------------------------------------------------------*/
  71. /* ISOLATIN1: uncomment the following line if your system uses the     */
  72. /* ISO 8859-1 character set instead of ASCII.                          */
  73. /*---------------------------------------------------------------------*/
  74. /* #define ISOLATIN1 1 */
  75.  
  76. /*---------------------------------------------------------------------*/
  77. /* IBMEXTENDED: uncomment the following line if you want to use the    */
  78. /* IBM extended character set.  NOT ALL LANGUAGE MODULES SUPPORT THIS. */
  79. /* Note that at most one of ISOLATIN1 or IBMEXTENDED should be         */
  80. /* defined; if both are defined, the results are unspecified.          */
  81. /*---------------------------------------------------------------------*/
  82. /* #define IBMEXTENDED 1 */
  83.  
  84. /*---------------------------------------------------------------------*/
  85. /* WANT_U_OPTION: Comment out the next define to permanently disable   */
  86. /* the -u option.  If you do this, however, remind-all.[c]sh will not  */
  87. /* work.                                                               */
  88. /*---------------------------------------------------------------------*/
  89. #define WANT_U_OPTION 1
  90.  
  91. /*---------------------------------------------------------------------*/
  92. /* STRSTR:  If your system does not have the "strstr" function,        */
  93. /* uncomment the following line.                                       */
  94. /*---------------------------------------------------------------------*/
  95. /* #define NO_STRSTR 1 */
  96.  
  97. /*---------------------------------------------------------------------*/
  98. /* STDLIB:  If you don't have the <stdlib.h> header file, comment the  */
  99. /* following line.                                                     */
  100. /*---------------------------------------------------------------------*/
  101. #define HAVE_STDLIB_H 1
  102.  
  103. /*---------------------------------------------------------------------*/
  104. /* MALLOC:  If you do not have the <malloc.h> header file,             */
  105. /* comment out the next 3 lines.                                       */
  106. /*---------------------------------------------------------------------*/
  107. #ifdef UNIX
  108. #define HAVE_MALLOC_H 1
  109. #endif
  110.  
  111. /*---------------------------------------------------------------------*/
  112. /* BASE: The base year for date calculation.  NOTE!  January 1 of the  */
  113. /*       base year MUST be a Monday, else Remind will not work!        */
  114. /*       IMPORTANT NOTE:  The Hebrew date routines depend on BASE      */
  115. /*       being set to 1990.  If you change it, you'll have to add the  */
  116. /*       number of days between 1 Jan <NEWBASE> and 1 Jan 1990 to the  */
  117. /*       manifest constant CORRECTION in hbcal.c.  Also, the year      */
  118. /*       folding mechanism in main.c depends on BASE<2001.             */
  119. /*---------------------------------------------------------------------*/
  120. #define BASE 1990
  121.  
  122. /*---------------------------------------------------------------------*/
  123. /* YR_RANGE: The range of years allowed.  Computers with 16-bit        */
  124. /*           integers can handle about 89 years worth of reminders; if */
  125. /*           you use 32-bit integers, you can handle over 5 867 000    */
  126. /*           years.  Note that YR_RANGE is set to 88 rather than 89    */
  127. /*           because we can range up to the last day of the 88th year. */
  128. /*---------------------------------------------------------------------*/
  129. #define YR_RANGE 88
  130.  
  131. /*---------------------------------------------------------------------*/
  132. /* VAR_NAME_LEN: The maximum length of variable names.  Don't make it  */
  133. /*               any less than 12.                                     */
  134. /*---------------------------------------------------------------------*/
  135. #define VAR_NAME_LEN 12
  136.  
  137. /*---------------------------------------------------------------------*/
  138. /* MAX_PRT_LEN: The maximum number of characters to print when         */
  139. /* displaying a string value for debugging purposes.                   */
  140. /*---------------------------------------------------------------------*/
  141. #define MAX_PRT_LEN 40
  142.  
  143. /*---------------------------------------------------------------------*/
  144. /* LINELEN: The maximum length of an input line                        */
  145. /*---------------------------------------------------------------------*/
  146. #define LINELEN 512
  147.  
  148. /*---------------------------------------------------------------------*/
  149. /* OP_STACK_SIZE: The size of the operator stack for expr. parsing     */
  150. /*---------------------------------------------------------------------*/
  151. #define OP_STACK_SIZE 30
  152.  
  153. /*---------------------------------------------------------------------*/
  154. /* VAL_STACK_SIZE: The size of the operand stack for expr. parsing     */
  155. /*---------------------------------------------------------------------*/
  156. #define VAL_STACK_SIZE 30
  157.  
  158. /*---------------------------------------------------------------------*/
  159. /* INCLUDE_NEST: How many nested INCLUDES do we handle?                */
  160. /*---------------------------------------------------------------------*/
  161. #define INCLUDE_NEST 8
  162.  
  163. /*---------------------------------------------------------------------*/
  164. /* IF_NEST: How many nested IFs do we handle?  Maximum is the number   */
  165. /* of bits in an int, divided by two.  Beware!                         */
  166. /*---------------------------------------------------------------------*/
  167. #define IF_NEST (4*sizeof(unsigned int))
  168.  
  169. /*---------------------------------------------------------------------*/
  170. /* Do we handle queued reminders?                                      */
  171. /*---------------------------------------------------------------------*/
  172. #if defined(UNIX) || defined(__OS2__)
  173. #define HAVE_QUEUED 1
  174. #endif
  175.  
  176. /*---------------------------------------------------------------------*/
  177. /* Does our C compiler have prototypes?  Override this test if you     */
  178. /* are using a non-ANSI compiler that nevertheless has prototypes.     */
  179. /*---------------------------------------------------------------------*/
  180. #if defined(__STDC__) || defined(__TURBOC__) || defined(__BORLANDC__)
  181. #define HAVE_PROTOS 1
  182. #endif
  183.  
  184. /*---------------------------------------------------------------------*/
  185. /* Do we use the <stdarg.h> scheme for functions with variable number  */
  186. /* of parameters?  If not, the <varargs.h> scheme is assumed.          */
  187. /*---------------------------------------------------------------------*/
  188. #if defined(__STDC__) || defined(__TURBOC__) || defined(__BORLANDC__)
  189. #define HAVE_STDARG 1
  190. #endif
  191.  
  192. /*---------------------------------------------------------------------*/
  193. /* Do we have the <unistd.h> header?  If not, use sys/files.h          */
  194. /*---------------------------------------------------------------------*/
  195. #ifdef UNIX
  196. #define HAVE_UNISTD 1
  197. #endif
  198.  
  199. /*---------------------------------------------------------------------*/
  200. /* How many attempts to resolve a weird date spec?                     */
  201. /*---------------------------------------------------------------------*/
  202. #define TRIG_ATTEMPTS 25
  203.  
  204. /*---------------------------------------------------------------------*/
  205. /* How many global omits of the form YYYY MM DD do we handle?          */
  206. /*---------------------------------------------------------------------*/
  207. #define MAX_FULL_OMITS 75
  208.  
  209. /*---------------------------------------------------------------------*/
  210. /* How many global omits of the form MM DD do we handle?               */
  211. /*---------------------------------------------------------------------*/
  212. #define MAX_PARTIAL_OMITS 75
  213.  
  214. /*---------------------------------------------------------------------*/
  215. /* The size of statically-allocated buffers for tokens.                */
  216. /*---------------------------------------------------------------------*/
  217. #define TOKSIZE 128
  218.  
  219. /*---------------------------------------------------------------------*/
  220. /* The size of the buffer for the shell() function.                    */
  221. /*---------------------------------------------------------------------*/
  222. #define SHELLSIZE 512
  223.  
  224. /*---------------------------------------------------------------------*/
  225. /* A newline - some systems need "\n\r"                                */
  226. /*---------------------------------------------------------------------*/
  227. #define NL "\n"
  228.  
  229. /*---------------------------------------------------------------------*/
  230. /* Minimum number of linefeeds in each calendar "box"                  */
  231. /*---------------------------------------------------------------------*/
  232. #define CAL_LINES 5
  233.  
  234. /*---------------------------------------------------------------------*/
  235. /* Don't change the next definitions                                   */
  236. /*---------------------------------------------------------------------*/
  237. #define PUBLIC
  238. #define PRIVATE static
  239.  
  240. #ifdef UNIX
  241. #define _POSIX_SOURCE
  242. #endif
  243.  
  244. #define PSBEGIN "# rem2ps begin"
  245. #define PSEND   "# rem2ps end"
  246.