]> diplodocus.org Git - nmh/blob - h/nmh.h
h/mf.h: Remove many unused macros; some UUCP related.
[nmh] / h / nmh.h
1
2 /*
3 * nmh.h -- system configuration header file
4 */
5
6 #ifdef HAVE_CONFIG_H
7 #include <config.h>
8 #endif
9
10 #include <unistd.h>
11 #include <stdio.h>
12 #include <ctype.h>
13 #ifndef NDEBUG
14 /* See etc/gen-ctype-checked.c. */
15 # include <sbr/ctype-checked.h>
16 #endif
17 #include <assert.h>
18
19 #ifdef HAVE_STDBOOL_H
20 # include <stdbool.h>
21 #else
22 # define bool int
23 # define true 1
24 # define false 0
25 #endif
26
27 #include <sys/stat.h>
28 #include <sys/wait.h>
29
30 # include <dirent.h>
31
32 #include <stdlib.h>
33 #include <stdarg.h>
34 #include <string.h>
35
36 #ifdef HAVE_SYS_PARAM_H
37 # include <sys/param.h>
38 #endif
39
40 #include <locale.h>
41 #include <limits.h>
42 #include <errno.h>
43
44 /*
45 * we should be getting this value from pathconf(_PC_PATH_MAX)
46 */
47 #ifndef PATH_MAX
48 # ifdef MAXPATHLEN
49 # define PATH_MAX MAXPATHLEN
50 # else
51 /* so we will just pick something */
52 # define PATH_MAX 1024
53 # endif
54 #endif
55
56 /*
57 * we should get this value from sysconf(_SC_NGROUPS_MAX)
58 */
59 #ifndef NGROUPS_MAX
60 # ifdef NGROUPS
61 # define NGROUPS_MAX NGROUPS
62 # else
63 # define NGROUPS_MAX 16
64 # endif
65 #endif
66
67 /*
68 * we should be getting this value from sysconf(_SC_OPEN_MAX)
69 */
70 #ifndef OPEN_MAX
71 # ifdef NOFILE
72 # define OPEN_MAX NOFILE
73 # else
74 /* so we will just pick something */
75 # define OPEN_MAX 64
76 # endif
77 #endif
78
79 #ifndef HAVE_GETLINE
80 ssize_t getline(char **lineptr, size_t *n, FILE *stream);
81 #endif
82
83 /*
84 * Defaults for programs if they aren't configured in a user's profile
85 */
86
87 #define DEFAULT_PAGER "more"
88 #define DEFAULT_EDITOR "vi"