3 * Copyright is disclaimed as to the contents of this file.
5 * $FreeBSD: src/usr.bin/getconf/limits.gperf,v 1.1.2.1 2002/10/27 04:18:40 wollman Exp $
6 * $DragonFly: src/usr.bin/getconf/limits.gperf,v 1.3 2003/11/04 20:25:45 dillon Exp $
17 * Override gperf's built-in external scope.
19 static const struct map *in_word_set(const char *str, unsigned int len);
22 struct map { const char *name; gc_intmax_t value; int valid; };
24 _POSIX_CLOCKRES_MIN, _POSIX_CLOCKRES_MIN
25 _POSIX_AIO_LISTIO_MAX, _POSIX_AIO_LISTIO_MAX
26 _POSIX_AIO_MAX, _POSIX_AIO_MAX
27 _POSIX_ARG_MAX, _POSIX_ARG_MAX
28 _POSIX_CHILD_MAX, _POSIX_CHILD_MAX
29 _POSIX_DELAYTIMER_MAX, _POSIX_DELAYTIMER_MAX
30 _POSIX_HOST_NAME_MAX, _POSIX_HOST_NAME_MAX
31 _POSIX_LINK_MAX, _POSIX_LINK_MAX
32 _POSIX_LOGIN_NAME_MAX, _POSIX_LOGIN_NAME_MAX
33 _POSIX_MAX_CANON, _POSIX_MAX_CANON
34 _POSIX_MAX_INPUT, _POSIX_MAX_INPUT
35 _POSIX_MQ_OPEN_MAX, _POSIX_MQ_OPEN_MAX
36 _POSIX_MQ_PRIO_MAX, _POSIX_MQ_PRIO_MAX
37 _POSIX_NAME_MAX, _POSIX_NAME_MAX
38 _POSIX_NGROUPS_MAX, _POSIX_NGROUPS_MAX
39 _POSIX_OPEN_MAX, _POSIX_OPEN_MAX
40 _POSIX_PATH_MAX, _POSIX_PATH_MAX
41 _POSIX_PIPE_BUF, __POSIX_PIPE_BUF
42 _POSIX_RE_DUP_MAX, _POSIX_RE_DUP_MAX
43 _POSIX_RTSIG_MAX, _POSIX_RTSIG_MAX
44 _POSIX_SEM_NSEMS_MAX, _POSIX_SEM_NSEMS_MAX
45 _POSIX_SEM_VALUE_MAX, _POSIX_SEM_VALUE_MAX
46 _POSIX_SIGQUEUE_MAX, _POSIX_SIGQUEUE_MAX
47 _POSIX_SSIZE_MAX, _POSIX_SSIZE_MAX
48 _POSIX_STREAM_MAX, _POSIX_STREAM_MAX
49 _POSIX_SS_REPL_MAX, _POSIX_SS_REPL_MAX
50 _POSIX_SYMLINK_MAX, _POSIX_SYMLINK_MAX
51 _POSIX_SYMLOOP_MAX, _POSIX_SYMLOOP_MAX
52 _POSIX_THREAD_DESTRUCTOR_ITERATIONS, _POSIX_THREAD_DESTRUCTOR_ITERATIONS
53 _POSIX_THREAD_KEYS_MAX, _POSIX_THREAD_KEYS_MAX
54 _POSIX_THREAD_THREADS_MAX, _POSIX_THREAD_THREADS_MAX
55 _POSIX_TIMER_MAX, _POSIX_TIMER_MAX
56 _POSIX_TRACE_EVENT_NAME_MAX, _POSIX_TRACE_EVENT_NAME_MAX
57 _POSIX_TRACE_NAME_MAX, _POSIX_TRACE_NAME_MAX
58 _POSIX_TRACE_SYS_MAX, _POSIX_TRACE_SYS_MAX
59 _POSIX_TRACE_USER_EVENT_MAX, _POSIX_TRACE_USER_EVENT_MAX
60 _POSIX_TTY_NAME_MAX, _POSIX_TTY_NAME_MAX
61 _POSIX_TZNAME_MAX, _POSIX_TZNAME_MAX
62 _POSIX2_BC_BASE_MAX, _POSIX2_BC_BASE_MAX
63 _POSIX2_BC_DIM_MAX, _POSIX2_BC_DIM_MAX
64 _POSIX2_BC_SCALE_MAX, _POSIX2_BC_SCALE_MAX
65 _POSIX2_BC_STRING_MAX, _POSIX2_BC_STRING_MAX
66 _POSIX2_CHARCLASS_NAME_MAX, _POSIX2_CHARCLASS_NAME_MAX
67 _POSIX2_COLL_WEIGHTS_MAX, _POSIX2_COLL_WEIGHTS_MAX
68 _POSIX2_EXPR_NEXT_MAX, _POSIX2_EXPR_NEST_MAX
69 _POSIX2_LINE_MAX, _POSIX2_LINE_MAX
70 _POSIX2_RE_DUP_MAX, _POSIX2_RE_DUP_MAX
71 _XOPEN_IOV_MAX, _XOPEN_IOV_MAX
72 _XOPEN_NAME_MAX, _XOPEN_NAME_MAX
73 _XOPEN_PATH_MAX, _XOPEN_PATH_MAX
84 MB_LEN_MAX, MB_LEN_MAX
92 ULLONG_MAX, ULLONG_MAX
96 CHARCLASS_NAME_MAX, CHARCLASS_NAME_MAX
98 ML_LANGMAX, NL_LANGMAX
102 NL_TEXTMAX, NL_TEXTMAX
106 find_limit(const char *name, gc_intmax_t *value)
108 const struct map *rv;
110 rv = in_word_set(name, strlen(name));