diff options
author | Xin Ouyang <Xin.Ouyang@windriver.com> | 2013-03-28 17:09:49 +0800 |
---|---|---|
committer | Xin Ouyang <Xin.Ouyang@windriver.com> | 2013-04-01 11:06:39 +0800 |
commit | 9468ed53d978f0d304fd789c90f265ac567f98a3 (patch) | |
tree | 7d0f3c04df5bcd0f99ebf6c5acdd1201546acdb8 | |
parent | 0dfeb9260d318ac9a49b0b3c1fe9694541508228 (diff) | |
download | meta-selinux-9468ed53d978f0d304fd789c90f265ac567f98a3.tar.gz |
audit: use generated headers for cross compiling
Default audit Makefile will generate native executables in lib/ and
auparse/, which are named as gen_*_h and run on the hosts to create
*_tables.h/*tabs.h header files for the targets.
This is inappropriate for our cross compiling because they need
linux-libc-headers from the host.
Even worse, on some old hosts, build will fail because some .h files
in the old linux-libc-headers (<= 2.6.29) has incomplete DEFINE lists
for the audit system.
So add *tables.h/*tabs.h header files which are generated from
linux-libc-headers-3.4, and do not generate and run those native
executables.
Signed-off-by: Xin Ouyang <Xin.Ouyang@windriver.com>
3 files changed, 2442 insertions, 334 deletions
diff --git a/recipes-security/audit/audit-2.2.1/2.2.1-audit-for-cross-compiling.patch b/recipes-security/audit/audit-2.2.1/2.2.1-audit-for-cross-compiling.patch deleted file mode 100644 index e2eea95..0000000 --- a/recipes-security/audit/audit-2.2.1/2.2.1-audit-for-cross-compiling.patch +++ /dev/null | |||
@@ -1,311 +0,0 @@ | |||
1 | Fix audit for cross compiling | ||
2 | |||
3 | Add support for CC_FOR_BUILD to the gen_captabs_h.... | ||
4 | |||
5 | Signed-off-by: Amy Fong <amy.fong@windriver.com> | ||
6 | --- | ||
7 | auparse/Makefile.am | 44 ++++++++++++++++++++++++++++++++++++++++++++ | ||
8 | configure.ac | 9 +++++++++ | ||
9 | lib/Makefile.am | 32 ++++++++++++++++++++++++++++++++ | ||
10 | 3 files changed, 85 insertions(+) | ||
11 | |||
12 | --- a/auparse/Makefile.am | ||
13 | +++ b/auparse/Makefile.am | ||
14 | @@ -58,114 +58,158 @@ | ||
15 | |||
16 | gen_captabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h captab.h | ||
17 | gen_captabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="captab.h"' | ||
18 | +gen_captabs_h: $(gen_captabs_h_SOURCES) | ||
19 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_captabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
20 | captabs.h: gen_captabs_h Makefile | ||
21 | ./gen_captabs_h --i2s cap > $@ | ||
22 | |||
23 | gen_clock_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h clocktab.h | ||
24 | gen_clock_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="clocktab.h"' | ||
25 | +gen_clock_h: $(gen_clock_h_SOURCES) | ||
26 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_clock_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
27 | clocktabs.h: gen_clock_h Makefile | ||
28 | ./gen_clock_h --i2s clock > $@ | ||
29 | |||
30 | gen_clone_flagtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h \ | ||
31 | clone-flagtab.h | ||
32 | gen_clone_flagtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="clone-flagtab.h"' | ||
33 | +gen_clone-flagtabs_h: $(gen_clone_flagtabs_h_SOURCES) | ||
34 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_clone_flagtabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
35 | clone-flagtabs.h: gen_clone-flagtabs_h Makefile | ||
36 | ./gen_clone-flagtabs_h --i2s-transtab clone_flag > $@ | ||
37 | |||
38 | gen_epoll_ctls_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h epoll_ctl.h | ||
39 | gen_epoll_ctls_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="epoll_ctl.h"' | ||
40 | +gen_epoll_ctls_h: $(gen_epoll_ctls_h_SOURCES) | ||
41 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_epoll_ctls_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
42 | epoll_ctls.h: gen_epoll_ctls_h Makefile | ||
43 | ./gen_epoll_ctls_h --i2s epoll_ctl > $@ | ||
44 | |||
45 | gen_famtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h famtab.h | ||
46 | gen_famtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="famtab.h"' | ||
47 | +gen_famtabs_h: $(gen_famtabs_h_SOURCES) | ||
48 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_famtabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
49 | famtabs.h: gen_famtabs_h Makefile | ||
50 | ./gen_famtabs_h --i2s fam > $@ | ||
51 | |||
52 | gen_flagtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h flagtab.h | ||
53 | # ../auparse/ is used to avoid using ../lib/flagtab.h | ||
54 | gen_flagtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="../auparse/flagtab.h"' | ||
55 | +gen_flagtabs_h: $(gen_flagtabs_h_SOURCES) | ||
56 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_flagtabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
57 | flagtabs.h: gen_flagtabs_h Makefile | ||
58 | ./gen_flagtabs_h --i2s-transtab flag > $@ | ||
59 | |||
60 | gen_fcntl_cmdtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h \ | ||
61 | fcntl-cmdtab.h | ||
62 | gen_fcntl_cmdtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="fcntl-cmdtab.h"' | ||
63 | +gen_fcntl-cmdtabs_h: $(gen_fcntl_cmdtabs_h_SOURCES) | ||
64 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_fcntl_cmdtabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
65 | fcntl-cmdtabs.h: gen_fcntl-cmdtabs_h Makefile | ||
66 | ./gen_fcntl-cmdtabs_h --i2s fcntl > $@ | ||
67 | |||
68 | gen_icmptypetabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h icmptypetab.h | ||
69 | gen_icmptypetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="icmptypetab.h"' | ||
70 | +gen_icmptypetabs_h: $(gen_icmptypetabs_h_SOURCES) | ||
71 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_icmptypetabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
72 | icmptypetabs.h: gen_icmptypetabs_h Makefile | ||
73 | ./gen_icmptypetabs_h --i2s icmptype > $@ | ||
74 | |||
75 | gen_ipctabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h ipctab.h | ||
76 | gen_ipctabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="ipctab.h"' | ||
77 | +gen_ipctabs_h: $(gen_ipctabs_h_SOURCES) | ||
78 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_ipctabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
79 | ipctabs.h: gen_ipctabs_h Makefile | ||
80 | ./gen_ipctabs_h --i2s ipc > $@ | ||
81 | |||
82 | gen_mmaptabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h mmaptab.h | ||
83 | gen_mmaptabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="mmaptab.h"' | ||
84 | +gen_mmaptabs_h: $(gen_mmaptabs_h_SOURCES) | ||
85 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_mmaptabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
86 | mmaptabs.h: gen_mmaptabs_h Makefile | ||
87 | ./gen_mmaptabs_h --i2s-transtab mmap > $@ | ||
88 | |||
89 | gen_mounttabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h mounttab.h | ||
90 | gen_mounttabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="mounttab.h"' | ||
91 | +gen_mounttabs_h: $(gen_mounttabs_h_SOURCES) | ||
92 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_mounttabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
93 | mounttabs.h: gen_mounttabs_h Makefile | ||
94 | ./gen_mounttabs_h --i2s-transtab mount > $@ | ||
95 | |||
96 | gen_nfprototabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h nfprototab.h | ||
97 | gen_nfprototabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="nfprototab.h"' | ||
98 | +gen_nfprototabs_h: $(gen_nfprototabs_h_SOURCES) | ||
99 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_nfprototabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
100 | nfprototabs.h: gen_nfprototabs_h Makefile | ||
101 | ./gen_nfprototabs_h --i2s nfproto > $@ | ||
102 | |||
103 | gen_open_flagtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h \ | ||
104 | open-flagtab.h | ||
105 | gen_open_flagtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="open-flagtab.h"' | ||
106 | +gen_open-flagtabs_h: $(gen_open_flagtabs_h_SOURCES) | ||
107 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_open_flagtabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
108 | open-flagtabs.h: gen_open-flagtabs_h Makefile | ||
109 | ./gen_open-flagtabs_h --i2s-transtab open_flag > $@ | ||
110 | |||
111 | gen_persontabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h persontab.h | ||
112 | gen_persontabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="persontab.h"' | ||
113 | +gen_persontabs_h: $(gen_persontabs_h_SOURCES) | ||
114 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_persontabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
115 | persontabs.h: gen_persontabs_h Makefile | ||
116 | ./gen_persontabs_h --i2s person > $@ | ||
117 | |||
118 | gen_ptracetabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h ptracetab.h | ||
119 | gen_ptracetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="ptracetab.h"' | ||
120 | +gen_ptracetabs_h: $(gen_ptracetabs_h_SOURCES) | ||
121 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_ptracetabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
122 | ptracetabs.h: gen_ptracetabs_h Makefile | ||
123 | ./gen_ptracetabs_h --i2s ptrace > $@ | ||
124 | |||
125 | gen_prottabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h prottab.h | ||
126 | gen_prottabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="prottab.h"' | ||
127 | +gen_prottabs_h: $(gen_prottabs_h_SOURCES) | ||
128 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_prottabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
129 | prottabs.h: gen_prottabs_h Makefile | ||
130 | ./gen_prottabs_h --i2s-transtab prot > $@ | ||
131 | |||
132 | gen_recvtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h recvtab.h | ||
133 | gen_recvtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="recvtab.h"' | ||
134 | +gen_recvtabs_h: $(gen_recvtabs_h_SOURCES) | ||
135 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_recvtabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
136 | recvtabs.h: gen_recvtabs_h Makefile | ||
137 | ./gen_recvtabs_h --i2s-transtab recv > $@ | ||
138 | |||
139 | gen_rlimit_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h rlimittab.h | ||
140 | gen_rlimit_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="rlimittab.h"' | ||
141 | +gen_rlimit_h: $(gen_rlimit_h_SOURCES) | ||
142 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_rlimit_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
143 | rlimittabs.h: gen_rlimit_h Makefile | ||
144 | ./gen_rlimit_h --i2s rlimit > $@ | ||
145 | |||
146 | gen_signals_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h signaltab.h | ||
147 | gen_signals_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="signaltab.h"' | ||
148 | +gen_signals_h: $(gen_signals_h_SOURCES) | ||
149 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_signals_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
150 | signaltabs.h: gen_signals_h Makefile | ||
151 | ./gen_signals_h --i2s signal > $@ | ||
152 | |||
153 | gen_socktabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h socktab.h | ||
154 | gen_socktabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="socktab.h"' | ||
155 | +gen_socktabs_h: $(gen_socktabs_h_SOURCES) | ||
156 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_socktabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
157 | socktabs.h: gen_socktabs_h Makefile | ||
158 | ./gen_socktabs_h --i2s sock > $@ | ||
159 | |||
160 | gen_socktypetabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h socktypetab.h | ||
161 | gen_socktypetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="socktypetab.h"' | ||
162 | +gen_socktypetabs_h: $(gen_socktypetabs_h_SOURCES) | ||
163 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_socktypetabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
164 | socktypetabs.h: gen_socktypetabs_h Makefile | ||
165 | ./gen_socktypetabs_h --i2s sock_type > $@ | ||
166 | |||
167 | gen_typetabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h typetab.h | ||
168 | gen_typetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="typetab.h"' | ||
169 | +gen_typetabs_h: $(gen_typetabs_h_SOURCES) | ||
170 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../lib $(gen_typetabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
171 | typetabs.h: gen_typetabs_h Makefile | ||
172 | ./gen_typetabs_h --s2i type > $@ | ||
173 | --- a/configure.ac | ||
174 | +++ b/configure.ac | ||
175 | @@ -104,6 +104,15 @@ | ||
176 | fi | ||
177 | AM_CONDITIONAL(HAVE_PYTHON, test ${python_found} = "yes") | ||
178 | |||
179 | +if test -z "$CC_FOR_BUILD"; then | ||
180 | + if test "x$cross_compiling" = "xno"; then | ||
181 | + CC_FOR_BUILD='$(CC)' | ||
182 | + else | ||
183 | + CC_FOR_BUILD=gcc | ||
184 | + fi | ||
185 | +fi | ||
186 | +AC_SUBST(CC_FOR_BUILD) | ||
187 | + | ||
188 | #gssapi | ||
189 | AC_ARG_ENABLE(gssapi_krb5, | ||
190 | [AS_HELP_STRING([--enable-gssapi-krb5],[Enable GSSAPI Kerberos 5 support @<:@default=no@:>@])], | ||
191 | --- a/lib/Makefile.am | ||
192 | +++ b/lib/Makefile.am | ||
193 | @@ -60,12 +60,16 @@ | ||
194 | endif | ||
195 | gen_actiontabs_h_SOURCES = gen_tables.c gen_tables.h actiontab.h | ||
196 | gen_actiontabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="actiontab.h"' | ||
197 | +gen_actiontabs_h: $(gen_actiontabs_h_SOURCES) | ||
198 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_actiontabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
199 | actiontabs.h: gen_actiontabs_h Makefile | ||
200 | ./gen_actiontabs_h --lowercase --i2s --s2i action > $@ | ||
201 | |||
202 | if USE_ALPHA | ||
203 | gen_alpha_tables_h_SOURCES = gen_tables.c gen_tables.h alpha_table.h | ||
204 | gen_alpha_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="alpha_table.h"' | ||
205 | +gen_alpha_tables_h: $(gen_alpha_tables_h_SOURCES) | ||
206 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_alpha_tables_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
207 | alpha_tables.h: gen_alpha_tables_h Makefile | ||
208 | ./gen_alpha_tables_h --lowercase --i2s --s2i alpha_syscall > $@ | ||
209 | endif | ||
210 | @@ -73,73 +77,101 @@ | ||
211 | if USE_ARMEB | ||
212 | gen_armeb_tables_h_SOURCES = gen_tables.c gen_tables.h armeb_table.h | ||
213 | gen_armeb_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="armeb_table.h"' | ||
214 | +gen_armeb_tables_h: $(gen_armeb_tables_h_SOURCES) | ||
215 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_armeb_tables_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
216 | armeb_tables.h: gen_armeb_tables_h Makefile | ||
217 | ./gen_armeb_tables_h --lowercase --i2s --s2i armeb_syscall > $@ | ||
218 | endif | ||
219 | |||
220 | gen_errtabs_h_SOURCES = gen_tables.c gen_tables.h errtab.h | ||
221 | gen_errtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="errtab.h"' | ||
222 | +gen_errtabs_h: $(gen_errtabs_h_SOURCES) | ||
223 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_errtabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
224 | errtabs.h: gen_errtabs_h Makefile | ||
225 | ./gen_errtabs_h --duplicate-ints --uppercase --i2s --s2i err > $@ | ||
226 | |||
227 | gen_fieldtabs_h_SOURCES = gen_tables.c gen_tables.h fieldtab.h | ||
228 | gen_fieldtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="fieldtab.h"' | ||
229 | +gen_fieldtabs_h: $(gen_fieldtabs_h_SOURCES) | ||
230 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_fieldtabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
231 | fieldtabs.h: gen_fieldtabs_h Makefile | ||
232 | ./gen_fieldtabs_h --duplicate-ints --lowercase --i2s --s2i field > $@ | ||
233 | |||
234 | gen_flagtabs_h_SOURCES = gen_tables.c gen_tables.h flagtab.h | ||
235 | gen_flagtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="flagtab.h"' | ||
236 | +gen_flagtabs_h: $(gen_flagtabs_h_SOURCES) | ||
237 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_flagtabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
238 | flagtabs.h: gen_flagtabs_h Makefile | ||
239 | ./gen_flagtabs_h --lowercase --i2s --s2i flag > $@ | ||
240 | |||
241 | gen_ftypetabs_h_SOURCES = gen_tables.c gen_tables.h ftypetab.h | ||
242 | gen_ftypetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="ftypetab.h"' | ||
243 | +gen_ftypetabs_h: $(gen_ftypetabs_h_SOURCES) | ||
244 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_ftypetabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
245 | ftypetabs.h: gen_ftypetabs_h Makefile | ||
246 | ./gen_ftypetabs_h --lowercase --i2s --s2i ftype > $@ | ||
247 | |||
248 | gen_i386_tables_h_SOURCES = gen_tables.c gen_tables.h i386_table.h | ||
249 | gen_i386_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="i386_table.h"' | ||
250 | +gen_i386_tables_h: $(gen_i386_tables_h_SOURCES) | ||
251 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_i386_tables_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
252 | i386_tables.h: gen_i386_tables_h Makefile | ||
253 | ./gen_i386_tables_h --duplicate-ints --lowercase --i2s --s2i \ | ||
254 | i386_syscall > $@ | ||
255 | |||
256 | gen_ia64_tables_h_SOURCES = gen_tables.c gen_tables.h ia64_table.h | ||
257 | gen_ia64_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="ia64_table.h"' | ||
258 | +gen_ia64_tables_h: $(gen_ia64_tables_h_SOURCES) | ||
259 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_ia64_tables_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
260 | ia64_tables.h: gen_ia64_tables_h Makefile | ||
261 | ./gen_ia64_tables_h --lowercase --i2s --s2i ia64_syscall > $@ | ||
262 | |||
263 | gen_machinetabs_h_SOURCES = gen_tables.c gen_tables.h machinetab.h | ||
264 | gen_machinetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="machinetab.h"' | ||
265 | +gen_machinetabs_h: $(gen_machinetabs_h_SOURCES) | ||
266 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_machinetabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
267 | machinetabs.h: gen_machinetabs_h Makefile | ||
268 | ./gen_machinetabs_h --duplicate-ints --lowercase --i2s --s2i machine \ | ||
269 | > $@ | ||
270 | |||
271 | gen_msg_typetabs_h_SOURCES = gen_tables.c gen_tables.h msg_typetab.h | ||
272 | gen_msg_typetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="msg_typetab.h"' | ||
273 | +gen_msg_typetabs_h: $(gen_msg_typetabs_h_SOURCES) | ||
274 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_msg_typetabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
275 | msg_typetabs.h: gen_msg_typetabs_h Makefile | ||
276 | ./gen_msg_typetabs_h --uppercase --i2s --s2i msg_type > $@ | ||
277 | |||
278 | gen_optabs_h_SOURCES = gen_tables.c gen_tables.h optab.h | ||
279 | gen_optabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="optab.h"' | ||
280 | +gen_optabs_h: $(gen_optabs_h_SOURCES) | ||
281 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_optabs_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
282 | optabs.h: gen_optabs_h Makefile | ||
283 | ./gen_optabs_h --i2s op > $@ | ||
284 | |||
285 | gen_ppc_tables_h_SOURCES = gen_tables.c gen_tables.h ppc_table.h | ||
286 | gen_ppc_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="ppc_table.h"' | ||
287 | +gen_ppc_tables_h: $(gen_ppc_tables_h_SOURCES) | ||
288 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_ppc_tables_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
289 | ppc_tables.h: gen_ppc_tables_h Makefile | ||
290 | ./gen_ppc_tables_h --lowercase --i2s --s2i ppc_syscall > $@ | ||
291 | |||
292 | gen_s390_tables_h_SOURCES = gen_tables.c gen_tables.h s390_table.h | ||
293 | gen_s390_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="s390_table.h"' | ||
294 | +gen_s390_tables_h: $(gen_s390_tables_h_SOURCES) | ||
295 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_s390_tables_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
296 | s390_tables.h: gen_s390_tables_h Makefile | ||
297 | ./gen_s390_tables_h --lowercase --i2s --s2i s390_syscall > $@ | ||
298 | |||
299 | gen_s390x_tables_h_SOURCES = gen_tables.c gen_tables.h s390x_table.h | ||
300 | gen_s390x_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="s390x_table.h"' | ||
301 | +gen_s390x_tables_h: $(gen_s390x_tables_h_SOURCES) | ||
302 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_s390x_tables_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
303 | s390x_tables.h: gen_s390x_tables_h Makefile | ||
304 | ./gen_s390x_tables_h --lowercase --i2s --s2i s390x_syscall > $@ | ||
305 | |||
306 | gen_x86_64_tables_h_SOURCES = gen_tables.c gen_tables.h x86_64_table.h | ||
307 | gen_x86_64_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="x86_64_table.h"' | ||
308 | +gen_x86_64_tables_h: $(gen_x86_64_tables_h_SOURCES) | ||
309 | + $(CC_FOR_BUILD) -DHAVE_CONFIG_H -I. -I.. -I../auparse $(gen_x86_64_tables_h_CFLAGS) $(LDFLAGS) -o $@ $< | ||
310 | x86_64_tables.h: gen_x86_64_tables_h Makefile | ||
311 | ./gen_x86_64_tables_h --lowercase --i2s --s2i x86_64_syscall > $@ | ||
diff --git a/recipes-security/audit/audit-2.2.1/audit-cross-compiling.patch b/recipes-security/audit/audit-2.2.1/audit-cross-compiling.patch new file mode 100644 index 0000000..3f1ad71 --- /dev/null +++ b/recipes-security/audit/audit-2.2.1/audit-cross-compiling.patch | |||
@@ -0,0 +1,2439 @@ | |||
1 | Subject: [PATCH] audit: use generated headers for cross compiling | ||
2 | |||
3 | Default audit Makefile will generate native executables in lib/ and | ||
4 | auparse/, which are named as gen_*_h and run on the hosts to create | ||
5 | *_tables.h/*tabs.h header files for the targets. | ||
6 | |||
7 | This is inappropriate for our cross compiling because they need | ||
8 | linux-libc-headers from the host. | ||
9 | |||
10 | Even worse, on some old hosts, build will fail because some .h files | ||
11 | in the old linux-libc-headers (<= 2.6.29) has incomplete DEFINE lists | ||
12 | for the audit system. | ||
13 | |||
14 | So add *tables.h/*tabs.h header files which are generated from | ||
15 | linux-libc-headers-3.4, and do not generate and run those native | ||
16 | executables. | ||
17 | |||
18 | Upstream-Status: Inappropriate [cross compile] | ||
19 | |||
20 | Signed-off-by: Xin Ouyang <Xin.Ouyang@windriver.com> | ||
21 | --- | ||
22 | auparse/Makefile.am | 122 ----------------------------- | ||
23 | auparse/captabs.h | 14 ++++ | ||
24 | auparse/clocktabs.h | 8 ++ | ||
25 | auparse/clone-flagtabs.h | 10 +++ | ||
26 | auparse/epoll_ctls.h | 8 ++ | ||
27 | auparse/famtabs.h | 14 ++++ | ||
28 | auparse/fcntl-cmdtabs.h | 17 ++++ | ||
29 | auparse/flagtabs.h | 6 ++ | ||
30 | auparse/icmptypetabs.h | 10 +++ | ||
31 | auparse/ipctabs.h | 11 +++ | ||
32 | auparse/mmaptabs.h | 8 ++ | ||
33 | auparse/mounttabs.h | 10 +++ | ||
34 | auparse/nfprototabs.h | 9 +++ | ||
35 | auparse/open-flagtabs.h | 8 ++ | ||
36 | auparse/persontabs.h | 17 ++++ | ||
37 | auparse/prottabs.h | 6 ++ | ||
38 | auparse/ptracetabs.h | 17 ++++ | ||
39 | auparse/recvtabs.h | 8 ++ | ||
40 | auparse/rlimittabs.h | 10 +++ | ||
41 | auparse/signaltabs.h | 14 ++++ | ||
42 | auparse/socktabs.h | 10 +++ | ||
43 | auparse/socktypetabs.h | 8 ++ | ||
44 | auparse/typetabs.h | 29 +++++++ | ||
45 | lib/Makefile.am | 96 ----------------------- | ||
46 | lib/actiontabs.h | 26 +++++++ | ||
47 | lib/alpha_tables.h | 196 +++++++++++++++++++++++++++++++++++++++++++++++ | ||
48 | lib/armeb_tables.h | 165 +++++++++++++++++++++++++++++++++++++++ | ||
49 | lib/errtabs.h | 78 +++++++++++++++++++ | ||
50 | lib/fieldtabs.h | 49 ++++++++++++ | ||
51 | lib/flagtabs.h | 26 +++++++ | ||
52 | lib/ftypetabs.h | 29 +++++++ | ||
53 | lib/i386_tables.h | 162 +++++++++++++++++++++++++++++++++++++++ | ||
54 | lib/ia64_tables.h | 147 +++++++++++++++++++++++++++++++++++ | ||
55 | lib/machinetabs.h | 26 +++++++ | ||
56 | lib/msg_typetabs.h | 99 ++++++++++++++++++++++++ | ||
57 | lib/optabs.h | 11 +++ | ||
58 | lib/ppc_tables.h | 163 +++++++++++++++++++++++++++++++++++++++ | ||
59 | lib/s390_tables.h | 153 ++++++++++++++++++++++++++++++++++++ | ||
60 | lib/s390x_tables.h | 141 ++++++++++++++++++++++++++++++++++ | ||
61 | lib/x86_64_tables.h | 150 ++++++++++++++++++++++++++++++++++++ | ||
62 | 40 files changed, 1873 insertions(+), 218 deletions(-) | ||
63 | create mode 100644 auparse/captabs.h | ||
64 | create mode 100644 auparse/clocktabs.h | ||
65 | create mode 100644 auparse/clone-flagtabs.h | ||
66 | create mode 100644 auparse/epoll_ctls.h | ||
67 | create mode 100644 auparse/famtabs.h | ||
68 | create mode 100644 auparse/fcntl-cmdtabs.h | ||
69 | create mode 100644 auparse/flagtabs.h | ||
70 | create mode 100644 auparse/icmptypetabs.h | ||
71 | create mode 100644 auparse/ipctabs.h | ||
72 | create mode 100644 auparse/mmaptabs.h | ||
73 | create mode 100644 auparse/mounttabs.h | ||
74 | create mode 100644 auparse/nfprototabs.h | ||
75 | create mode 100644 auparse/open-flagtabs.h | ||
76 | create mode 100644 auparse/persontabs.h | ||
77 | create mode 100644 auparse/prottabs.h | ||
78 | create mode 100644 auparse/ptracetabs.h | ||
79 | create mode 100644 auparse/recvtabs.h | ||
80 | create mode 100644 auparse/rlimittabs.h | ||
81 | create mode 100644 auparse/signaltabs.h | ||
82 | create mode 100644 auparse/socktabs.h | ||
83 | create mode 100644 auparse/socktypetabs.h | ||
84 | create mode 100644 auparse/typetabs.h | ||
85 | create mode 100644 lib/actiontabs.h | ||
86 | create mode 100644 lib/alpha_tables.h | ||
87 | create mode 100644 lib/armeb_tables.h | ||
88 | create mode 100644 lib/errtabs.h | ||
89 | create mode 100644 lib/fieldtabs.h | ||
90 | create mode 100644 lib/flagtabs.h | ||
91 | create mode 100644 lib/ftypetabs.h | ||
92 | create mode 100644 lib/i386_tables.h | ||
93 | create mode 100644 lib/ia64_tables.h | ||
94 | create mode 100644 lib/machinetabs.h | ||
95 | create mode 100644 lib/msg_typetabs.h | ||
96 | create mode 100644 lib/optabs.h | ||
97 | create mode 100644 lib/ppc_tables.h | ||
98 | create mode 100644 lib/s390_tables.h | ||
99 | create mode 100644 lib/s390x_tables.h | ||
100 | create mode 100644 lib/x86_64_tables.h | ||
101 | |||
102 | diff --git a/auparse/Makefile.am b/auparse/Makefile.am | ||
103 | index 2f7306f..9524342 100644 | ||
104 | --- a/auparse/Makefile.am | ||
105 | +++ b/auparse/Makefile.am | ||
106 | @@ -47,125 +47,3 @@ BUILT_SOURCES = captabs.h clocktabs.h clone-flagtabs.h epoll_ctls.h famtabs.h \ | ||
107 | mmaptabs.h mounttabs.h nfprototabs.h open-flagtabs.h \ | ||
108 | persontabs.h prottabs.h ptracetabs.h rlimittabs.h recvtabs.h \ | ||
109 | signaltabs.h socktabs.h socktypetabs.h typetabs.h | ||
110 | -noinst_PROGRAMS = gen_captabs_h gen_clock_h gen_clone-flagtabs_h \ | ||
111 | - gen_epoll_ctls_h gen_famtabs_h \ | ||
112 | - gen_fcntl-cmdtabs_h gen_flagtabs_h \ | ||
113 | - gen_icmptypetabs_h gen_ipctabs_h gen_nfprototabs_h \ | ||
114 | - gen_mmaptabs_h gen_mounttabs_h \ | ||
115 | - gen_open-flagtabs_h gen_persontabs_h gen_prottabs_h \ | ||
116 | - gen_recvtabs_h gen_rlimit_h gen_ptracetabs_h \ | ||
117 | - gen_signals_h gen_socktabs_h gen_socktypetabs_h gen_typetabs_h | ||
118 | - | ||
119 | -gen_captabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h captab.h | ||
120 | -gen_captabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="captab.h"' | ||
121 | -captabs.h: gen_captabs_h Makefile | ||
122 | - ./gen_captabs_h --i2s cap > $@ | ||
123 | - | ||
124 | -gen_clock_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h clocktab.h | ||
125 | -gen_clock_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="clocktab.h"' | ||
126 | -clocktabs.h: gen_clock_h Makefile | ||
127 | - ./gen_clock_h --i2s clock > $@ | ||
128 | - | ||
129 | -gen_clone_flagtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h \ | ||
130 | - clone-flagtab.h | ||
131 | -gen_clone_flagtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="clone-flagtab.h"' | ||
132 | -clone-flagtabs.h: gen_clone-flagtabs_h Makefile | ||
133 | - ./gen_clone-flagtabs_h --i2s-transtab clone_flag > $@ | ||
134 | - | ||
135 | -gen_epoll_ctls_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h epoll_ctl.h | ||
136 | -gen_epoll_ctls_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="epoll_ctl.h"' | ||
137 | -epoll_ctls.h: gen_epoll_ctls_h Makefile | ||
138 | - ./gen_epoll_ctls_h --i2s epoll_ctl > $@ | ||
139 | - | ||
140 | -gen_famtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h famtab.h | ||
141 | -gen_famtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="famtab.h"' | ||
142 | -famtabs.h: gen_famtabs_h Makefile | ||
143 | - ./gen_famtabs_h --i2s fam > $@ | ||
144 | - | ||
145 | -gen_flagtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h flagtab.h | ||
146 | -# ../auparse/ is used to avoid using ../lib/flagtab.h | ||
147 | -gen_flagtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="../auparse/flagtab.h"' | ||
148 | -flagtabs.h: gen_flagtabs_h Makefile | ||
149 | - ./gen_flagtabs_h --i2s-transtab flag > $@ | ||
150 | - | ||
151 | -gen_fcntl_cmdtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h \ | ||
152 | - fcntl-cmdtab.h | ||
153 | -gen_fcntl_cmdtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="fcntl-cmdtab.h"' | ||
154 | -fcntl-cmdtabs.h: gen_fcntl-cmdtabs_h Makefile | ||
155 | - ./gen_fcntl-cmdtabs_h --i2s fcntl > $@ | ||
156 | - | ||
157 | -gen_icmptypetabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h icmptypetab.h | ||
158 | -gen_icmptypetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="icmptypetab.h"' | ||
159 | -icmptypetabs.h: gen_icmptypetabs_h Makefile | ||
160 | - ./gen_icmptypetabs_h --i2s icmptype > $@ | ||
161 | - | ||
162 | -gen_ipctabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h ipctab.h | ||
163 | -gen_ipctabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="ipctab.h"' | ||
164 | -ipctabs.h: gen_ipctabs_h Makefile | ||
165 | - ./gen_ipctabs_h --i2s ipc > $@ | ||
166 | - | ||
167 | -gen_mmaptabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h mmaptab.h | ||
168 | -gen_mmaptabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="mmaptab.h"' | ||
169 | -mmaptabs.h: gen_mmaptabs_h Makefile | ||
170 | - ./gen_mmaptabs_h --i2s-transtab mmap > $@ | ||
171 | - | ||
172 | -gen_mounttabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h mounttab.h | ||
173 | -gen_mounttabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="mounttab.h"' | ||
174 | -mounttabs.h: gen_mounttabs_h Makefile | ||
175 | - ./gen_mounttabs_h --i2s-transtab mount > $@ | ||
176 | - | ||
177 | -gen_nfprototabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h nfprototab.h | ||
178 | -gen_nfprototabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="nfprototab.h"' | ||
179 | -nfprototabs.h: gen_nfprototabs_h Makefile | ||
180 | - ./gen_nfprototabs_h --i2s nfproto > $@ | ||
181 | - | ||
182 | -gen_open_flagtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h \ | ||
183 | - open-flagtab.h | ||
184 | -gen_open_flagtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="open-flagtab.h"' | ||
185 | -open-flagtabs.h: gen_open-flagtabs_h Makefile | ||
186 | - ./gen_open-flagtabs_h --i2s-transtab open_flag > $@ | ||
187 | - | ||
188 | -gen_persontabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h persontab.h | ||
189 | -gen_persontabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="persontab.h"' | ||
190 | -persontabs.h: gen_persontabs_h Makefile | ||
191 | - ./gen_persontabs_h --i2s person > $@ | ||
192 | - | ||
193 | -gen_ptracetabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h ptracetab.h | ||
194 | -gen_ptracetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="ptracetab.h"' | ||
195 | -ptracetabs.h: gen_ptracetabs_h Makefile | ||
196 | - ./gen_ptracetabs_h --i2s ptrace > $@ | ||
197 | - | ||
198 | -gen_prottabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h prottab.h | ||
199 | -gen_prottabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="prottab.h"' | ||
200 | -prottabs.h: gen_prottabs_h Makefile | ||
201 | - ./gen_prottabs_h --i2s-transtab prot > $@ | ||
202 | - | ||
203 | -gen_recvtabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h recvtab.h | ||
204 | -gen_recvtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="recvtab.h"' | ||
205 | -recvtabs.h: gen_recvtabs_h Makefile | ||
206 | - ./gen_recvtabs_h --i2s-transtab recv > $@ | ||
207 | - | ||
208 | -gen_rlimit_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h rlimittab.h | ||
209 | -gen_rlimit_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="rlimittab.h"' | ||
210 | -rlimittabs.h: gen_rlimit_h Makefile | ||
211 | - ./gen_rlimit_h --i2s rlimit > $@ | ||
212 | - | ||
213 | -gen_signals_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h signaltab.h | ||
214 | -gen_signals_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="signaltab.h"' | ||
215 | -signaltabs.h: gen_signals_h Makefile | ||
216 | - ./gen_signals_h --i2s signal > $@ | ||
217 | - | ||
218 | -gen_socktabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h socktab.h | ||
219 | -gen_socktabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="socktab.h"' | ||
220 | -socktabs.h: gen_socktabs_h Makefile | ||
221 | - ./gen_socktabs_h --i2s sock > $@ | ||
222 | - | ||
223 | -gen_socktypetabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h socktypetab.h | ||
224 | -gen_socktypetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="socktypetab.h"' | ||
225 | -socktypetabs.h: gen_socktypetabs_h Makefile | ||
226 | - ./gen_socktypetabs_h --i2s sock_type > $@ | ||
227 | - | ||
228 | -gen_typetabs_h_SOURCES = ../lib/gen_tables.c ../lib/gen_tables.h typetab.h | ||
229 | -gen_typetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="typetab.h"' | ||
230 | -typetabs.h: gen_typetabs_h Makefile | ||
231 | - ./gen_typetabs_h --s2i type > $@ | ||
232 | diff --git a/auparse/captabs.h b/auparse/captabs.h | ||
233 | new file mode 100644 | ||
234 | index 0000000..6b13a64 | ||
235 | --- /dev/null | ||
236 | +++ b/auparse/captabs.h | ||
237 | @@ -0,0 +1,14 @@ | ||
238 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
239 | +static const char cap_strings[] = "audit_control\0audit_write\0chown\0dac_override\0dac_read_search\0fowner\0fsetid\0ipc_lock\0ipc_owner\0kill\0" | ||
240 | + "lease\0linux_immutable\0mac_admin\0mac_override\0mknod\0net_admin\0net_bind_service\0net_broadcast\0net_raw\0setfcap\0" | ||
241 | + "setgid\0setpcap\0setuid\0sys_admin\0sys_boot\0sys_chroot\0sys_module\0sys_nice\0sys_pacct\0sys_ptrace\0" | ||
242 | + "sys_rawio\0sys_resource\0sys_time\0sys_tty_config\0syslog\0wake_alarm"; | ||
243 | +static const unsigned cap_i2s_direct[] = { | ||
244 | + 26,32,45,61,68,94,207,222,214,105, | ||
245 | + 160,177,150,191,75,84,259,300,248,289, | ||
246 | + 279,229,239,270,310,323,332,144,99,14, | ||
247 | + 0,199,131,121,347,354, | ||
248 | +}; | ||
249 | +static const char *cap_i2s(int v) { | ||
250 | + return i2s_direct__(cap_strings, cap_i2s_direct, 0, 35, v); | ||
251 | +} | ||
252 | diff --git a/auparse/clocktabs.h b/auparse/clocktabs.h | ||
253 | new file mode 100644 | ||
254 | index 0000000..03f9f09 | ||
255 | --- /dev/null | ||
256 | +++ b/auparse/clocktabs.h | ||
257 | @@ -0,0 +1,8 @@ | ||
258 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
259 | +static const char clock_strings[] = "CLOCK_BOOTTIME\0CLOCK_BOOTTIME_ALARM\0CLOCK_MONOTONIC\0CLOCK_MONOTONIC_COARSE\0CLOCK_MONOTONIC_RAW\0CLOCK_PROCESS_CPUTIME_ID\0CLOCK_REALTIME\0CLOCK_REALTIME_ALARM\0CLOCK_REALTIME_COARSE\0CLOCK_THREAD_CPUTIME_ID"; | ||
260 | +static const unsigned clock_i2s_direct[] = { | ||
261 | + 120,36,95,178,75,156,52,0,135,15, | ||
262 | +}; | ||
263 | +static const char *clock_i2s(int v) { | ||
264 | + return i2s_direct__(clock_strings, clock_i2s_direct, 0, 9, v); | ||
265 | +} | ||
266 | diff --git a/auparse/clone-flagtabs.h b/auparse/clone-flagtabs.h | ||
267 | new file mode 100644 | ||
268 | index 0000000..b8f815d | ||
269 | --- /dev/null | ||
270 | +++ b/auparse/clone-flagtabs.h | ||
271 | @@ -0,0 +1,10 @@ | ||
272 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
273 | +static const char clone_flag_strings[] = "CLONE_CHILD_CLEARTID\0CLONE_CHILD_SETTID\0CLONE_DETACHED\0CLONE_FILES\0CLONE_FS\0CLONE_IO\0CLONE_NEWIPC\0CLONE_NEWNET\0CLONE_NEWNS\0CLONE_NEWPID\0" | ||
274 | + "CLONE_NEWUSER\0CLONE_NEWUTS\0CLONE_PARENT\0CLONE_PARENT_SETTID\0CLONE_PTRACE\0CLONE_SETTLS\0CLONE_SIGHAND\0CLONE_STOPPED\0CLONE_SYSVSEM\0CLONE_THREAD\0" | ||
275 | + "CLONE_UNTRACED\0CLONE_VFORK\0CLONE_VM"; | ||
276 | +static const struct transtab clone_flag_table[] = { | ||
277 | + {256,304},{512,67},{1024,55},{2048,222},{8192,196},{16384,292},{32768,163},{65536,264},{131072,111},{262144,250}, | ||
278 | + {524288,209},{1048576,176},{2097152,0},{4194304,40},{8388608,277},{16777216,21},{33554432,236},{67108864,150},{134217728,85},{268435456,136}, | ||
279 | + {536870912,123},{1073741824,98},{-2147483648,76}, | ||
280 | +}; | ||
281 | +#define CLONE_FLAG_NUM_ENTRIES (sizeof(clone_flag_table) / sizeof(*clone_flag_table)) | ||
282 | diff --git a/auparse/epoll_ctls.h b/auparse/epoll_ctls.h | ||
283 | new file mode 100644 | ||
284 | index 0000000..2787c18 | ||
285 | --- /dev/null | ||
286 | +++ b/auparse/epoll_ctls.h | ||
287 | @@ -0,0 +1,8 @@ | ||
288 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
289 | +static const char epoll_ctl_strings[] = "EPOLL_CTL_ADD\0EPOLL_CTL_DEL\0EPOLL_CTL_MOD"; | ||
290 | +static const unsigned epoll_ctl_i2s_direct[] = { | ||
291 | + 0,14,28, | ||
292 | +}; | ||
293 | +static const char *epoll_ctl_i2s(int v) { | ||
294 | + return i2s_direct__(epoll_ctl_strings, epoll_ctl_i2s_direct, 1, 3, v); | ||
295 | +} | ||
296 | diff --git a/auparse/famtabs.h b/auparse/famtabs.h | ||
297 | new file mode 100644 | ||
298 | index 0000000..4c88ee5 | ||
299 | --- /dev/null | ||
300 | +++ b/auparse/famtabs.h | ||
301 | @@ -0,0 +1,14 @@ | ||
302 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
303 | +static const char fam_strings[] = "alg\0appletalk\0ash\0atmpvc\0atmsvc\0ax25\0bluetooth\0bridge\0caif\0can\0" | ||
304 | + "decnet\0econet\0ieee802154\0inet\0inet6\0ipx\0irda\0isdn\0iucv\0key\0" | ||
305 | + "llc\0local\0netbeui\0netlink\0netrom\0nfc\0packet\0phonet\0pppox\0rds\0" | ||
306 | + "rose\0rxrpc\0security\0sna\0tipc\0wanpipe\0x25"; | ||
307 | +static const unsigned fam_i2s_direct[] = { | ||
308 | + 126,88,32,99,4,148,47,18,220,93, | ||
309 | + 183,63,132,194,118,140,159,14,70,25, | ||
310 | + 179,203,103,173,212,122,-1u,-1u,59,207, | ||
311 | + 37,113,188,108,166,77,54,0,155, | ||
312 | +}; | ||
313 | +static const char *fam_i2s(int v) { | ||
314 | + return i2s_direct__(fam_strings, fam_i2s_direct, 1, 39, v); | ||
315 | +} | ||
316 | diff --git a/auparse/fcntl-cmdtabs.h b/auparse/fcntl-cmdtabs.h | ||
317 | new file mode 100644 | ||
318 | index 0000000..5082755 | ||
319 | --- /dev/null | ||
320 | +++ b/auparse/fcntl-cmdtabs.h | ||
321 | @@ -0,0 +1,17 @@ | ||
322 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
323 | +static const char fcntl_strings[] = "F_CANCELLK\0F_DUPFD\0F_DUPFD_CLOEXEC\0F_GETFD\0F_GETFL\0F_GETLEASE\0F_GETLK\0F_GETLK64\0F_GETOWN\0F_GETOWN_EX\0" | ||
324 | + "F_GETPIPE_SZ\0F_GETSIG\0F_NOTIFY\0F_SETFD\0F_SETFL\0F_SETLEASE\0F_SETLK\0F_SETLK64\0F_SETLKW\0F_SETLKW64\0" | ||
325 | + "F_SETOWN\0F_SETOWN_EX\0F_SETPIPE_SZ\0F_SETSIG"; | ||
326 | +static const int fcntl_i2s_i[] = { | ||
327 | + 0,1,2,3,4,5,6,7,8,9, | ||
328 | + 10,11,12,13,14,15,16,1024,1025,1026, | ||
329 | + 1029,1030,1031,1032, | ||
330 | +}; | ||
331 | +static const unsigned fcntl_i2s_s[] = { | ||
332 | + 11,35,132,43,140,62,159,177,197,80, | ||
333 | + 231,114,70,167,186,206,89,148,51,123, | ||
334 | + 0,19,218,101, | ||
335 | +}; | ||
336 | +static const char *fcntl_i2s(int v) { | ||
337 | + return i2s_bsearch__(fcntl_strings, fcntl_i2s_i, fcntl_i2s_s, 24, v); | ||
338 | +} | ||
339 | diff --git a/auparse/flagtabs.h b/auparse/flagtabs.h | ||
340 | new file mode 100644 | ||
341 | index 0000000..5f57e14 | ||
342 | --- /dev/null | ||
343 | +++ b/auparse/flagtabs.h | ||
344 | @@ -0,0 +1,6 @@ | ||
345 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
346 | +static const char flag_strings[] = "access\0atomic\0continue\0create\0directory\0follow\0noalt\0open\0parent"; | ||
347 | +static const struct transtab flag_table[] = { | ||
348 | + {1,40},{2,30},{4,14},{16,58},{32,47},{64,7},{256,53},{512,23},{1024,0}, | ||
349 | +}; | ||
350 | +#define FLAG_NUM_ENTRIES (sizeof(flag_table) / sizeof(*flag_table)) | ||
351 | diff --git a/auparse/icmptypetabs.h b/auparse/icmptypetabs.h | ||
352 | new file mode 100644 | ||
353 | index 0000000..49b44bf | ||
354 | --- /dev/null | ||
355 | +++ b/auparse/icmptypetabs.h | ||
356 | @@ -0,0 +1,10 @@ | ||
357 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
358 | +static const char icmptype_strings[] = "address-mask-reply\0address-mask-request\0destination-unreachable\0echo\0echo-reply\0info-reply\0info-request\0parameter-problem\0redirect\0source-quench\0" | ||
359 | + "time-exceeded\0timestamp-reply\0timestamp-request"; | ||
360 | +static const unsigned icmptype_i2s_direct[] = { | ||
361 | + 69,-1u,-1u,40,131,122,-1u,-1u,64,-1u, | ||
362 | + -1u,145,104,175,159,91,80,19,0, | ||
363 | +}; | ||
364 | +static const char *icmptype_i2s(int v) { | ||
365 | + return i2s_direct__(icmptype_strings, icmptype_i2s_direct, 0, 18, v); | ||
366 | +} | ||
367 | diff --git a/auparse/ipctabs.h b/auparse/ipctabs.h | ||
368 | new file mode 100644 | ||
369 | index 0000000..4bf3bcd | ||
370 | --- /dev/null | ||
371 | +++ b/auparse/ipctabs.h | ||
372 | @@ -0,0 +1,11 @@ | ||
373 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
374 | +static const char ipc_strings[] = "msgctl\0msgget\0msgrcv\0msgsnd\0semctl\0semget\0semop\0semtimedop\0shmat\0shmctl\0" | ||
375 | + "shmdt\0shmget"; | ||
376 | +static const unsigned ipc_i2s_direct[] = { | ||
377 | + 42,35,28,48,-1u,-1u,-1u,-1u,-1u,-1u, | ||
378 | + 21,14,7,0,-1u,-1u,-1u,-1u,-1u,-1u, | ||
379 | + 59,72,78,65, | ||
380 | +}; | ||
381 | +static const char *ipc_i2s(int v) { | ||
382 | + return i2s_direct__(ipc_strings, ipc_i2s_direct, 1, 24, v); | ||
383 | +} | ||
384 | diff --git a/auparse/mmaptabs.h b/auparse/mmaptabs.h | ||
385 | new file mode 100644 | ||
386 | index 0000000..386833c | ||
387 | --- /dev/null | ||
388 | +++ b/auparse/mmaptabs.h | ||
389 | @@ -0,0 +1,8 @@ | ||
390 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
391 | +static const char mmap_strings[] = "MAP_32BIT\0MAP_ANONYMOUS\0MAP_DENYWRITE\0MAP_EXECUTABLE\0MAP_FIXED\0MAP_GROWSDOWN\0MAP_HUGETLB\0MAP_LOCKED\0MAP_NONBLOCK\0MAP_NORESERVE\0" | ||
392 | + "MAP_POPULATE\0MAP_PRIVATE\0MAP_SHARED\0MAP_STACK"; | ||
393 | +static const struct transtab mmap_table[] = { | ||
394 | + {1,152},{2,140},{16,53},{32,10},{64,0},{256,63},{2048,24},{4096,38},{8192,89},{16384,113}, | ||
395 | + {32768,127},{65536,100},{131072,163},{262144,77}, | ||
396 | +}; | ||
397 | +#define MMAP_NUM_ENTRIES (sizeof(mmap_table) / sizeof(*mmap_table)) | ||
398 | diff --git a/auparse/mounttabs.h b/auparse/mounttabs.h | ||
399 | new file mode 100644 | ||
400 | index 0000000..018a6b0 | ||
401 | --- /dev/null | ||
402 | +++ b/auparse/mounttabs.h | ||
403 | @@ -0,0 +1,10 @@ | ||
404 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
405 | +static const char mount_strings[] = "MS_ACTIVE\0MS_BIND\0MS_BORN\0MS_DIRSYNC\0MS_I_VERSION\0MS_KERNMOUNT\0MS_MANDLOCK\0MS_MOVE\0MS_NOATIME\0MS_NODEV\0" | ||
406 | + "MS_NODIRATIME\0MS_NOEXEC\0MS_NOSEC\0MS_NOSUID\0MS_NOUSER\0MS_POSIXACL\0MS_PRIVATE\0MS_RDONLY\0MS_REC\0MS_RELATIME\0" | ||
407 | + "MS_REMOUNT\0MS_SHARED\0MS_SILENT\0MS_SLAVE\0MS_STRICTATIME\0MS_SYNCHRONOUS\0MS_UNBINDABLE"; | ||
408 | +static const struct transtab mount_table[] = { | ||
409 | + {1,179},{2,136},{4,94},{8,117},{16,263},{32,208},{64,63},{128,26},{1024,83},{2048,103}, | ||
410 | + {4096,10},{8192,75},{16384,189},{32768,229},{65536,156},{131072,278},{262144,168},{524288,239},{1048576,219},{2097152,196}, | ||
411 | + {4194304,50},{8388608,37},{16777216,248},{268435456,127},{536870912,18},{1073741824,0},{-2147483648,146}, | ||
412 | +}; | ||
413 | +#define MOUNT_NUM_ENTRIES (sizeof(mount_table) / sizeof(*mount_table)) | ||
414 | diff --git a/auparse/nfprototabs.h b/auparse/nfprototabs.h | ||
415 | new file mode 100644 | ||
416 | index 0000000..9bb2723 | ||
417 | --- /dev/null | ||
418 | +++ b/auparse/nfprototabs.h | ||
419 | @@ -0,0 +1,9 @@ | ||
420 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
421 | +static const char nfproto_strings[] = "arp\0bridge\0decnet\0ipv4\0ipv6\0unspecified"; | ||
422 | +static const unsigned nfproto_i2s_direct[] = { | ||
423 | + 28,-1u,18,0,-1u,-1u,-1u,4,-1u,-1u, | ||
424 | + 23,-1u,11, | ||
425 | +}; | ||
426 | +static const char *nfproto_i2s(int v) { | ||
427 | + return i2s_direct__(nfproto_strings, nfproto_i2s_direct, 0, 12, v); | ||
428 | +} | ||
429 | diff --git a/auparse/open-flagtabs.h b/auparse/open-flagtabs.h | ||
430 | new file mode 100644 | ||
431 | index 0000000..0988baf | ||
432 | --- /dev/null | ||
433 | +++ b/auparse/open-flagtabs.h | ||
434 | @@ -0,0 +1,8 @@ | ||
435 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
436 | +static const char open_flag_strings[] = "O_APPEND\0O_ASYNC\0O_CLOEXEC\0O_CREAT\0O_DIRECT\0O_DIRECTORY\0O_EXCL\0O_NOATIME\0O_NOCTTY\0O_NOFOLLOW\0" | ||
437 | + "O_NONBLOCK\0O_RDWR\0O_SYNC\0O_TRUNC\0O_WRONLY"; | ||
438 | +static const struct transtab open_flag_table[] = { | ||
439 | + {1,126},{2,104},{64,27},{128,56},{256,73},{512,118},{1024,0},{2048,93},{4096,111},{8192,9}, | ||
440 | + {16384,35},{65536,44},{131072,82},{262144,63},{524288,17}, | ||
441 | +}; | ||
442 | +#define OPEN_FLAG_NUM_ENTRIES (sizeof(open_flag_table) / sizeof(*open_flag_table)) | ||
443 | diff --git a/auparse/persontabs.h b/auparse/persontabs.h | ||
444 | new file mode 100644 | ||
445 | index 0000000..d099839 | ||
446 | --- /dev/null | ||
447 | +++ b/auparse/persontabs.h | ||
448 | @@ -0,0 +1,17 @@ | ||
449 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
450 | +static const char person_strings[] = "PER_BSD\0PER_HPUX\0PER_IRIX32\0PER_IRIX64\0PER_IRIXN32\0PER_ISCR4\0PER_LINUX\0PER_LINUX32\0PER_LINUX32_3GB\0PER_LINUX_32BIT\0" | ||
451 | + "PER_OSF4\0PER_OSR5\0PER_RISCOS\0PER_SCOSVR3\0PER_SOLARIS\0PER_SUNOS\0PER_SVR3\0PER_SVR4\0PER_UW7\0PER_WYSEV386\0" | ||
452 | + "PER_XENIX"; | ||
453 | +static const int person_i2s_i[] = { | ||
454 | + 0,6,8,12,15,16,8388608,67108869,67108870,67108873, | ||
455 | + 67108874,67108875,67108877,68157441,68157454,83886082,83886084,83886087,100663299,117440515, | ||
456 | + 134217736, | ||
457 | +}; | ||
458 | +static const unsigned person_i2s_s[] = { | ||
459 | + 61,0,71,133,115,8,99,51,168,17, | ||
460 | + 39,28,156,187,196,178,204,217,124,144, | ||
461 | + 83, | ||
462 | +}; | ||
463 | +static const char *person_i2s(int v) { | ||
464 | + return i2s_bsearch__(person_strings, person_i2s_i, person_i2s_s, 21, v); | ||
465 | +} | ||
466 | diff --git a/auparse/prottabs.h b/auparse/prottabs.h | ||
467 | new file mode 100644 | ||
468 | index 0000000..1727f43 | ||
469 | --- /dev/null | ||
470 | +++ b/auparse/prottabs.h | ||
471 | @@ -0,0 +1,6 @@ | ||
472 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
473 | +static const char prot_strings[] = "PROT_EXEC\0PROT_READ\0PROT_SEM\0PROT_WRITE"; | ||
474 | +static const struct transtab prot_table[] = { | ||
475 | + {1,10},{2,29},{4,0},{8,20}, | ||
476 | +}; | ||
477 | +#define PROT_NUM_ENTRIES (sizeof(prot_table) / sizeof(*prot_table)) | ||
478 | diff --git a/auparse/ptracetabs.h b/auparse/ptracetabs.h | ||
479 | new file mode 100644 | ||
480 | index 0000000..6bbfc9b | ||
481 | --- /dev/null | ||
482 | +++ b/auparse/ptracetabs.h | ||
483 | @@ -0,0 +1,17 @@ | ||
484 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
485 | +static const char ptrace_strings[] = "PTRACE_ATTACH\0PTRACE_CONT\0PTRACE_DETACH\0PTRACE_GETEVENTMSG\0PTRACE_GETFPREGS\0PTRACE_GETFPXREGS\0PTRACE_GETREGS\0PTRACE_GETREGSET\0PTRACE_GETSIGINFO\0PTRACE_INTERRUPT\0" | ||
486 | + "PTRACE_KILL\0PTRACE_LISTEN\0PTRACE_PEEKDATA\0PTRACE_PEEKTEXT\0PTRACE_PEEKUSER\0PTRACE_POKEDATA\0PTRACE_POKETEXT\0PTRACE_POKEUSER\0PTRACE_SEIZE\0PTRACE_SETFPREGS\0" | ||
487 | + "PTRACE_SETFPXREGS\0PTRACE_SETOPTIONS\0PTRACE_SETREGS\0PTRACE_SETREGSET\0PTRACE_SETSIGINFO\0PTRACE_SINGLESTEP\0PTRACE_SYSCALL\0PTRACE_TRACEME"; | ||
488 | +static const int ptrace_i2s_i[] = { | ||
489 | + 0,1,2,3,4,5,6,7,8,9, | ||
490 | + 12,13,14,15,16,17,18,19,24,16896, | ||
491 | + 16897,16898,16899,16900,16901,16902,16903,16904, | ||
492 | +}; | ||
493 | +static const unsigned ptrace_i2s_s[] = { | ||
494 | + 432,203,187,219,251,235,267,14,161,399, | ||
495 | + 94,349,59,296,0,26,76,313,417,331, | ||
496 | + 40,126,381,109,364,283,144,173, | ||
497 | +}; | ||
498 | +static const char *ptrace_i2s(int v) { | ||
499 | + return i2s_bsearch__(ptrace_strings, ptrace_i2s_i, ptrace_i2s_s, 28, v); | ||
500 | +} | ||
501 | diff --git a/auparse/recvtabs.h b/auparse/recvtabs.h | ||
502 | new file mode 100644 | ||
503 | index 0000000..59578eb | ||
504 | --- /dev/null | ||
505 | +++ b/auparse/recvtabs.h | ||
506 | @@ -0,0 +1,8 @@ | ||
507 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
508 | +static const char recv_strings[] = "MSG_CMSG_CLOEXEC\0MSG_CONFIRM\0MSG_CTRUNC\0MSG_DONTROUTE\0MSG_DONTWAIT\0MSG_EOR\0MSG_ERRQUEUE\0MSG_FIN\0MSG_MORE\0MSG_NOSIGNAL\0" | ||
509 | + "MSG_OOB\0MSG_PEEK\0MSG_PROXY\0MSG_RST\0MSG_SYN\0MSG_TRUNC\0MSG_WAITALL\0MSG_WAITFORONE"; | ||
510 | +static const struct transtab recv_table[] = { | ||
511 | + {1,118},{2,126},{4,40},{8,29},{16,135},{32,161},{64,54},{128,67},{256,171},{512,88}, | ||
512 | + {1024,153},{2048,17},{4096,145},{8192,75},{16384,105},{32768,96},{65536,183},{1073741824,0}, | ||
513 | +}; | ||
514 | +#define RECV_NUM_ENTRIES (sizeof(recv_table) / sizeof(*recv_table)) | ||
515 | diff --git a/auparse/rlimittabs.h b/auparse/rlimittabs.h | ||
516 | new file mode 100644 | ||
517 | index 0000000..364ad69 | ||
518 | --- /dev/null | ||
519 | +++ b/auparse/rlimittabs.h | ||
520 | @@ -0,0 +1,10 @@ | ||
521 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
522 | +static const char rlimit_strings[] = "RLIMIT_AS\0RLIMIT_CORE\0RLIMIT_CPU\0RLIMIT_DATA\0RLIMIT_FSIZE\0RLIMIT_LOCKS\0RLIMIT_MEMLOCK\0RLIMIT_MSGQUEUE\0RLIMIT_NICE\0RLIMIT_NOFILE\0" | ||
523 | + "RLIMIT_NPROC\0RLIMIT_RSS\0RLIMIT_RTPRIO\0RLIMIT_RTTIME\0RLIMIT_SIGPENDING\0RLIMIT_STACK"; | ||
524 | +static const unsigned rlimit_i2s_direct[] = { | ||
525 | + 22,45,33,198,10,141,128,114,71,0, | ||
526 | + 58,180,86,102,152,166, | ||
527 | +}; | ||
528 | +static const char *rlimit_i2s(int v) { | ||
529 | + return i2s_direct__(rlimit_strings, rlimit_i2s_direct, 0, 15, v); | ||
530 | +} | ||
531 | diff --git a/auparse/signaltabs.h b/auparse/signaltabs.h | ||
532 | new file mode 100644 | ||
533 | index 0000000..974621f | ||
534 | --- /dev/null | ||
535 | +++ b/auparse/signaltabs.h | ||
536 | @@ -0,0 +1,14 @@ | ||
537 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
538 | +static const char signal_strings[] = "0\0IGPWR\0SIGABRT\0SIGALRM\0SIGBUS\0SIGCHLD\0SIGCONT\0SIGFPE\0SIGHUP\0SIGILL\0" | ||
539 | + "SIGINT\0SIGIO\0SIGKILL\0SIGPIPE\0SIGPROF\0SIGQUIT\0SIGSEGV\0SIGSTKFLT\0SIGSTOP\0SIGSYS\0" | ||
540 | + "SIGTERM\0SIGTRAP\0SIGTSTP\0SIGTTIN\0SIGTTOU\0SIGURG\0SIGUSR1\0SIGUSR2\0SIGVTALRM\0SIGWINCH\0" | ||
541 | + "SIGXCPU\0SIGXFSZ"; | ||
542 | +static const unsigned signal_i2s_direct[] = { | ||
543 | + 0,54,68,105,61,154,8,24,47,81, | ||
544 | + 193,113,201,89,16,146,121,31,39,131, | ||
545 | + 162,170,178,186,228,236,209,97,219,75, | ||
546 | + 2,139, | ||
547 | +}; | ||
548 | +static const char *signal_i2s(int v) { | ||
549 | + return i2s_direct__(signal_strings, signal_i2s_direct, 0, 31, v); | ||
550 | +} | ||
551 | diff --git a/auparse/socktabs.h b/auparse/socktabs.h | ||
552 | new file mode 100644 | ||
553 | index 0000000..66a8235 | ||
554 | --- /dev/null | ||
555 | +++ b/auparse/socktabs.h | ||
556 | @@ -0,0 +1,10 @@ | ||
557 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
558 | +static const char sock_strings[] = "accept\0accept4\0bind\0connect\0getpeername\0getsockname\0getsockopt\0listen\0recv\0recvfrom\0" | ||
559 | + "recvmmsg\0recvmsg\0send\0sendmmsg\0sendmsg\0sendto\0setsockopt\0shutdown\0socket\0socketpair"; | ||
560 | +static const unsigned sock_i2s_direct[] = { | ||
561 | + 150,15,20,63,0,40,28,157,101,70, | ||
562 | + 123,75,141,130,52,115,93,7,84,106, | ||
563 | +}; | ||
564 | +static const char *sock_i2s(int v) { | ||
565 | + return i2s_direct__(sock_strings, sock_i2s_direct, 1, 20, v); | ||
566 | +} | ||
567 | diff --git a/auparse/socktypetabs.h b/auparse/socktypetabs.h | ||
568 | new file mode 100644 | ||
569 | index 0000000..05e8d36 | ||
570 | --- /dev/null | ||
571 | +++ b/auparse/socktypetabs.h | ||
572 | @@ -0,0 +1,8 @@ | ||
573 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
574 | +static const char sock_type_strings[] = "SOCK_DCCP\0SOCK_DGRAM\0SOCK_PACKET\0SOCK_RAW\0SOCK_RDM\0SOCK_SEQPACKET\0SOCK_STREAM"; | ||
575 | +static const unsigned sock_type_i2s_direct[] = { | ||
576 | + 66,10,33,42,51,0,-1u,-1u,-1u,21, | ||
577 | +}; | ||
578 | +static const char *sock_type_i2s(int v) { | ||
579 | + return i2s_direct__(sock_type_strings, sock_type_i2s_direct, 1, 10, v); | ||
580 | +} | ||
581 | diff --git a/auparse/typetabs.h b/auparse/typetabs.h | ||
582 | new file mode 100644 | ||
583 | index 0000000..4dc097f | ||
584 | --- /dev/null | ||
585 | +++ b/auparse/typetabs.h | ||
586 | @@ -0,0 +1,29 @@ | ||
587 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
588 | +static const char type_strings[] = "a0\0a1\0a2\0a3\0acct\0addr\0arch\0auid\0cap_fi\0cap_fp\0" | ||
589 | + "cap_pe\0cap_pi\0cap_pp\0capability\0cgroup\0cmd\0comm\0cwd\0data\0device\0" | ||
590 | + "dir\0egid\0euid\0exe\0exit\0family\0file\0flags\0fsgid\0fsuid\0" | ||
591 | + "gid\0icmptype\0id\0igid\0inode_gid\0inode_uid\0iuid\0key\0mode\0name\0" | ||
592 | + "new-disk\0new-fs\0new_gid\0oauid\0obj_gid\0obj_uid\0ogid\0old-disk\0old-fs\0old_prom\0" | ||
593 | + "ouid\0path\0per\0perm\0perm_mask\0prom\0proto\0res\0result\0saddr\0" | ||
594 | + "sauid\0ses\0sgid\0sig\0suid\0syscall\0uid\0vm\0watch"; | ||
595 | +static const unsigned type_s2i_s[] = { | ||
596 | + 0,3,6,9,12,17,22,27,32,39, | ||
597 | + 46,53,60,67,78,85,89,94,98,103, | ||
598 | + 110,114,119,124,128,133,140,145,151,157, | ||
599 | + 163,167,176,179,184,194,204,209,213,218, | ||
600 | + 223,232,239,247,253,261,269,274,283,290, | ||
601 | + 299,304,309,313,318,328,333,339,343,350, | ||
602 | + 356,362,366,371,375,380,388,392,395, | ||
603 | +}; | ||
604 | +static const int type_s2i_i[] = { | ||
605 | + 14,15,16,17,6,26,4,1,22,22, | ||
606 | + 22,22,22,12,6,6,6,6,20,6, | ||
607 | + 6,2,1,6,5,23,6,10,2,1, | ||
608 | + 2,24,1,2,2,1,1,6,8,6, | ||
609 | + 6,6,2,1,2,1,2,6,6,11, | ||
610 | + 1,6,27,7,7,11,25,13,13,9, | ||
611 | + 1,21,2,18,1,3,1,6,6, | ||
612 | +}; | ||
613 | +static int type_s2i(const char *s, int *value) { | ||
614 | + return s2i__(type_strings, type_s2i_s, type_s2i_i, 69, s, value); | ||
615 | +} | ||
616 | diff --git a/lib/Makefile.am b/lib/Makefile.am | ||
617 | index c5952f9..6497e0a 100644 | ||
618 | --- a/lib/Makefile.am | ||
619 | +++ b/lib/Makefile.am | ||
620 | @@ -47,99 +47,3 @@ endif | ||
621 | if USE_ARMEB | ||
622 | BUILT_SOURCES += armeb_tables.h | ||
623 | endif | ||
624 | -noinst_PROGRAMS = gen_actiontabs_h gen_errtabs_h gen_fieldtabs_h \ | ||
625 | - gen_flagtabs_h gen_ftypetabs_h gen_i386_tables_h \ | ||
626 | - gen_ia64_tables_h gen_machinetabs_h gen_msg_typetabs_h \ | ||
627 | - gen_optabs_h gen_ppc_tables_h gen_s390_tables_h \ | ||
628 | - gen_s390x_tables_h gen_x86_64_tables_h | ||
629 | -if USE_ALPHA | ||
630 | -noinst_PROGRAMS += gen_alpha_tables_h | ||
631 | -endif | ||
632 | -if USE_ARMEB | ||
633 | -noinst_PROGRAMS += gen_armeb_tables_h | ||
634 | -endif | ||
635 | -gen_actiontabs_h_SOURCES = gen_tables.c gen_tables.h actiontab.h | ||
636 | -gen_actiontabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="actiontab.h"' | ||
637 | -actiontabs.h: gen_actiontabs_h Makefile | ||
638 | - ./gen_actiontabs_h --lowercase --i2s --s2i action > $@ | ||
639 | - | ||
640 | -if USE_ALPHA | ||
641 | -gen_alpha_tables_h_SOURCES = gen_tables.c gen_tables.h alpha_table.h | ||
642 | -gen_alpha_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="alpha_table.h"' | ||
643 | -alpha_tables.h: gen_alpha_tables_h Makefile | ||
644 | - ./gen_alpha_tables_h --lowercase --i2s --s2i alpha_syscall > $@ | ||
645 | -endif | ||
646 | - | ||
647 | -if USE_ARMEB | ||
648 | -gen_armeb_tables_h_SOURCES = gen_tables.c gen_tables.h armeb_table.h | ||
649 | -gen_armeb_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="armeb_table.h"' | ||
650 | -armeb_tables.h: gen_armeb_tables_h Makefile | ||
651 | - ./gen_armeb_tables_h --lowercase --i2s --s2i armeb_syscall > $@ | ||
652 | -endif | ||
653 | - | ||
654 | -gen_errtabs_h_SOURCES = gen_tables.c gen_tables.h errtab.h | ||
655 | -gen_errtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="errtab.h"' | ||
656 | -errtabs.h: gen_errtabs_h Makefile | ||
657 | - ./gen_errtabs_h --duplicate-ints --uppercase --i2s --s2i err > $@ | ||
658 | - | ||
659 | -gen_fieldtabs_h_SOURCES = gen_tables.c gen_tables.h fieldtab.h | ||
660 | -gen_fieldtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="fieldtab.h"' | ||
661 | -fieldtabs.h: gen_fieldtabs_h Makefile | ||
662 | - ./gen_fieldtabs_h --duplicate-ints --lowercase --i2s --s2i field > $@ | ||
663 | - | ||
664 | -gen_flagtabs_h_SOURCES = gen_tables.c gen_tables.h flagtab.h | ||
665 | -gen_flagtabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="flagtab.h"' | ||
666 | -flagtabs.h: gen_flagtabs_h Makefile | ||
667 | - ./gen_flagtabs_h --lowercase --i2s --s2i flag > $@ | ||
668 | - | ||
669 | -gen_ftypetabs_h_SOURCES = gen_tables.c gen_tables.h ftypetab.h | ||
670 | -gen_ftypetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="ftypetab.h"' | ||
671 | -ftypetabs.h: gen_ftypetabs_h Makefile | ||
672 | - ./gen_ftypetabs_h --lowercase --i2s --s2i ftype > $@ | ||
673 | - | ||
674 | -gen_i386_tables_h_SOURCES = gen_tables.c gen_tables.h i386_table.h | ||
675 | -gen_i386_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="i386_table.h"' | ||
676 | -i386_tables.h: gen_i386_tables_h Makefile | ||
677 | - ./gen_i386_tables_h --duplicate-ints --lowercase --i2s --s2i \ | ||
678 | - i386_syscall > $@ | ||
679 | - | ||
680 | -gen_ia64_tables_h_SOURCES = gen_tables.c gen_tables.h ia64_table.h | ||
681 | -gen_ia64_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="ia64_table.h"' | ||
682 | -ia64_tables.h: gen_ia64_tables_h Makefile | ||
683 | - ./gen_ia64_tables_h --lowercase --i2s --s2i ia64_syscall > $@ | ||
684 | - | ||
685 | -gen_machinetabs_h_SOURCES = gen_tables.c gen_tables.h machinetab.h | ||
686 | -gen_machinetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="machinetab.h"' | ||
687 | -machinetabs.h: gen_machinetabs_h Makefile | ||
688 | - ./gen_machinetabs_h --duplicate-ints --lowercase --i2s --s2i machine \ | ||
689 | - > $@ | ||
690 | - | ||
691 | -gen_msg_typetabs_h_SOURCES = gen_tables.c gen_tables.h msg_typetab.h | ||
692 | -gen_msg_typetabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="msg_typetab.h"' | ||
693 | -msg_typetabs.h: gen_msg_typetabs_h Makefile | ||
694 | - ./gen_msg_typetabs_h --uppercase --i2s --s2i msg_type > $@ | ||
695 | - | ||
696 | -gen_optabs_h_SOURCES = gen_tables.c gen_tables.h optab.h | ||
697 | -gen_optabs_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="optab.h"' | ||
698 | -optabs.h: gen_optabs_h Makefile | ||
699 | - ./gen_optabs_h --i2s op > $@ | ||
700 | - | ||
701 | -gen_ppc_tables_h_SOURCES = gen_tables.c gen_tables.h ppc_table.h | ||
702 | -gen_ppc_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="ppc_table.h"' | ||
703 | -ppc_tables.h: gen_ppc_tables_h Makefile | ||
704 | - ./gen_ppc_tables_h --lowercase --i2s --s2i ppc_syscall > $@ | ||
705 | - | ||
706 | -gen_s390_tables_h_SOURCES = gen_tables.c gen_tables.h s390_table.h | ||
707 | -gen_s390_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="s390_table.h"' | ||
708 | -s390_tables.h: gen_s390_tables_h Makefile | ||
709 | - ./gen_s390_tables_h --lowercase --i2s --s2i s390_syscall > $@ | ||
710 | - | ||
711 | -gen_s390x_tables_h_SOURCES = gen_tables.c gen_tables.h s390x_table.h | ||
712 | -gen_s390x_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="s390x_table.h"' | ||
713 | -s390x_tables.h: gen_s390x_tables_h Makefile | ||
714 | - ./gen_s390x_tables_h --lowercase --i2s --s2i s390x_syscall > $@ | ||
715 | - | ||
716 | -gen_x86_64_tables_h_SOURCES = gen_tables.c gen_tables.h x86_64_table.h | ||
717 | -gen_x86_64_tables_h_CFLAGS = $(AM_CFLAGS) '-DTABLE_H="x86_64_table.h"' | ||
718 | -x86_64_tables.h: gen_x86_64_tables_h Makefile | ||
719 | - ./gen_x86_64_tables_h --lowercase --i2s --s2i x86_64_syscall > $@ | ||
720 | diff --git a/lib/actiontabs.h b/lib/actiontabs.h | ||
721 | new file mode 100644 | ||
722 | index 0000000..a7a9e62 | ||
723 | --- /dev/null | ||
724 | +++ b/lib/actiontabs.h | ||
725 | @@ -0,0 +1,26 @@ | ||
726 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
727 | +static const char action_strings[] = "always\0never\0possible"; | ||
728 | +static const unsigned action_s2i_s[] = { | ||
729 | + 0,7,13, | ||
730 | +}; | ||
731 | +static const int action_s2i_i[] = { | ||
732 | + 2,0,1, | ||
733 | +}; | ||
734 | +static int action_s2i(const char *s, int *value) { | ||
735 | + size_t len, i; | ||
736 | + len = strlen(s); | ||
737 | + { char copy[len + 1]; | ||
738 | + for (i = 0; i < len; i++) { | ||
739 | + char c = s[i]; | ||
740 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
741 | + } | ||
742 | + copy[i] = 0; | ||
743 | + return s2i__(action_strings, action_s2i_s, action_s2i_i, 3, copy, value); | ||
744 | + } | ||
745 | +} | ||
746 | +static const unsigned action_i2s_direct[] = { | ||
747 | + 7,13,0, | ||
748 | +}; | ||
749 | +static const char *action_i2s(int v) { | ||
750 | + return i2s_direct__(action_strings, action_i2s_direct, 0, 2, v); | ||
751 | +} | ||
752 | diff --git a/lib/alpha_tables.h b/lib/alpha_tables.h | ||
753 | new file mode 100644 | ||
754 | index 0000000..da03f34 | ||
755 | --- /dev/null | ||
756 | +++ b/lib/alpha_tables.h | ||
757 | @@ -0,0 +1,196 @@ | ||
758 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
759 | +static const char alpha_syscall_strings[] = "_sysctl\0accept\0accept4\0access\0acct\0add_key\0adjtimex\0afs_syscall\0bdflush\0bind\0" | ||
760 | + "brk\0capget\0capset\0chdir\0chmod\0chown\0chroot\0clock_adjtime\0clone\0close\0" | ||
761 | + "connect\0create_module\0delete_module\0dipc\0dup\0dup2\0dup3\0epoll_create\0epoll_create1\0epoll_ctl\0" | ||
762 | + "epoll_pwait\0epoll_wait\0eventfd\0eventfd2\0exec_with_loader\0execve\0exit\0exit_group\0faccessat\0fadvise64\0" | ||
763 | + "fallocate\0fanotify_init\0fanotify_mark\0fchdir\0fchmod\0fchmodat\0fchown\0fchownat\0fcntl\0fdatasync\0" | ||
764 | + "fgetxattr\0flistxattr\0flock\0fork\0fremovexattr\0fsetxattr\0fstat\0fstat64\0fstatat64\0fstatfs\0" | ||
765 | + "fsync\0ftruncate\0futex\0futimesat\0get_kernel_syms\0get_mempolicy\0get_robust_list\0getcpu\0getcwd\0getdents\0" | ||
766 | + "getdents64\0getdtablesize\0getgroups\0gethostname\0getitimer\0getpagesize\0getpeername\0getpgid\0getpgrp\0getpriority\0" | ||
767 | + "getresgid\0getresuid\0getrlimit\0getrusage\0getsid\0getsockname\0getsockopt\0gettid\0gettimeofday\0getxattr\0" | ||
768 | + "getxgid\0getxpid\0getxuid\0init_module\0inotify_add_watch\0inotify_init\0inotify_init1\0inotify_rm_watch\0io_cancel\0io_destroy\0" | ||
769 | + "io_getevents\0io_setup\0io_submit\0ioctl\0ioprio_get\0ioprio_set\0kexec_load\0keyctl\0kill\0lchown\0" | ||
770 | + "lgetxattr\0link\0linkat\0listen\0listxattr\0llistxattr\0lookup_dcookie\0lremovexattr\0lseek\0lsetxattr\0" | ||
771 | + "lstat\0lstat64\0madvise\0mbind\0migrate_pages\0mincore\0mkdir\0mkdirat\0mknod\0mknodat\0" | ||
772 | + "mlock\0mlockall\0mmap\0mount\0move_pages\0mprotect\0mq_getsetattr\0mq_notify\0mq_open\0mq_timedreceive\0" | ||
773 | + "mq_timedsend\0mq_unlink\0mremap\0msgctl\0msgget\0msgrcv\0msgsnd\0msync\0munlock\0munlockall\0" | ||
774 | + "munmap\0name_to_handle_at\0nanosleep\0nfsservctl\0old_adjtimex\0oldumount\0open\0open_by_handle_at\0openat\0osf_adjtime\0" | ||
775 | + "osf_afs_syscall\0osf_alt_plock\0osf_alt_setsid\0osf_alt_sigpending\0osf_asynch_daemon\0osf_audcntl\0osf_audgen\0osf_chflags\0osf_execve\0osf_exportfs\0" | ||
776 | + "osf_fchflags\0osf_fdatasync\0osf_fpathconf\0osf_fstatfs\0osf_fuser\0osf_getaddressconf\0osf_getdirentries\0osf_getdomainname\0osf_getfh\0osf_getfsstat\0" | ||
777 | + "osf_gethostid\0osf_getitimer\0osf_getlogin\0osf_getmnt\0osf_getrusage\0osf_getsysinfo\0osf_gettimeofday\0osf_kloadcall\0osf_kmodcall\0osf_memcntl\0" | ||
778 | + "osf_mincore\0osf_mount\0osf_mremap\0osf_msfs_syscall\0osf_msleep\0osf_mvalid\0osf_mwakeup\0osf_naccept\0osf_nfssvc\0osf_ngetpeername\0" | ||
779 | + "osf_ngetsockname\0osf_nrecvfrom\0osf_nrecvmsg\0osf_nsendmsg\0osf_ntp_adjtime\0osf_ntp_gettime\0osf_old_creat\0osf_old_fstat\0osf_old_getpgrp\0osf_old_killpg\0" | ||
780 | + "osf_old_lstat\0osf_old_open\0osf_old_sigaction\0osf_old_sigblock\0osf_old_sigreturn\0osf_old_sigsetmask\0osf_old_sigvec\0osf_old_stat\0osf_old_vadvise\0osf_old_vtrace\0" | ||
781 | + "osf_old_wait\0osf_oldquota\0osf_pathconf\0osf_pid_block\0osf_pid_unblock\0osf_plock\0osf_priocntlset\0osf_profil\0osf_proplist_syscall\0osf_reboot\0" | ||
782 | + "osf_revoke\0osf_sbrk\0osf_security\0osf_select\0osf_set_program_attributes\0osf_set_speculative\0osf_sethostid\0osf_setitimer\0osf_setlogin\0osf_setsysinfo\0" | ||
783 | + "osf_settimeofday\0osf_shmat\0osf_signal\0osf_sigprocmask\0osf_sigsendset\0osf_sigstack\0osf_sigwaitprim\0osf_sstk\0osf_statfs\0osf_subsys_info\0" | ||
784 | + "osf_swapctl\0osf_swapon\0osf_syscall\0osf_sysinfo\0osf_table\0osf_uadmin\0osf_usleep_thread\0osf_uswitch\0osf_utc_adjtime\0osf_utc_gettime\0" | ||
785 | + "osf_utimes\0osf_utsname\0osf_wait4\0osf_waitid\0pciconfig_iobase\0pciconfig_read\0pciconfig_write\0perf_event_open\0personality\0pipe\0" | ||
786 | + "pipe2\0pivot_root\0poll\0ppoll\0prctl\0pread\0preadv\0prlimit64\0pselect6\0ptrace\0" | ||
787 | + "pwrite\0pwritev\0query_module\0quotactl\0read\0readahead\0readlink\0readlinkat\0readv\0reboot\0" | ||
788 | + "recv\0recvfrom\0recvmmsg\0recvmsg\0remap_file_pages\0removexattr\0rename\0renameat\0request_key\0restart_syscall\0" | ||
789 | + "rmdir\0rt_sigaction\0rt_sigpending\0rt_sigprocmask\0rt_sigqueueinfo\0rt_sigreturn\0rt_sigsuspend\0rt_sigtimedwait\0rt_tgsigqueueinfo\0sched_get_priority_max\0" | ||
790 | + "sched_get_priority_min\0sched_getaffinity\0sched_getparam\0sched_getscheduler\0sched_rr_get_interval\0sched_setaffinity\0sched_setparam\0sched_setscheduler\0sched_yield\0select\0" | ||
791 | + "semctl\0semget\0semop\0send\0sendfile\0sendmmsg\0sendmsg\0sendto\0set_mempolicy\0set_robust_list\0" | ||
792 | + "set_tid_address\0setdomainname\0setfsgid\0setfsuid\0setgid\0setgroups\0sethae\0sethostname\0setitimer\0setns\0" | ||
793 | + "setpgid\0setpgrp\0setpriority\0setregid\0setresgid\0setresuid\0setreuid\0setrlimit\0setsid\0setsockopt\0" | ||
794 | + "settimeofday\0setuid\0setxattr\0shmctl\0shmdt\0shmget\0shutdown\0sigaction\0sigaltstack\0signalfd\0" | ||
795 | + "signalfd4\0sigpending\0sigreturn\0sigsuspend\0socket\0socketpair\0splice\0stat\0stat64\0statfs\0" | ||
796 | + "swapoff\0swapon\0symlink\0symlinkat\0sync\0sync_file_range\0syncfs\0sysfs\0sysinfo\0syslog\0" | ||
797 | + "tee\0tgkill\0timerfd\0timerfd_create\0timerfd_gettime\0timerfd_settime\0times\0tkill\0truncate\0tuxcall\0" | ||
798 | + "umask\0umount\0uname\0unlink\0unlinkat\0unshare\0uselib\0ustat\0utimensat\0utimes\0" | ||
799 | + "vfork\0vhangup\0vmsplice\0vserver\0wait4\0waitid\0write\0writev"; | ||
800 | +static const unsigned alpha_syscall_s2i_s[] = { | ||
801 | + 0,8,15,23,30,35,43,52,64,72, | ||
802 | + 77,81,88,95,101,107,113,120,134,140, | ||
803 | + 146,154,168,182,187,191,196,201,214,228, | ||
804 | + 238,250,261,269,278,295,302,307,318,328, | ||
805 | + 338,348,362,376,383,390,399,406,415,421, | ||
806 | + 431,441,452,458,463,476,486,492,500,510, | ||
807 | + 518,524,534,540,550,566,580,596,603,610, | ||
808 | + 619,630,644,654,666,676,688,700,708,716, | ||
809 | + 728,738,748,758,768,775,787,798,805,818, | ||
810 | + 827,835,843,851,863,881,894,908,925,935, | ||
811 | + 946,959,968,978,984,995,1006,1017,1024,1029, | ||
812 | + 1036,1046,1051,1058,1065,1075,1086,1101,1114,1120, | ||
813 | + 1130,1136,1144,1152,1158,1172,1180,1186,1194,1200, | ||
814 | + 1208,1214,1223,1228,1234,1245,1254,1268,1278,1286, | ||
815 | + 1302,1315,1325,1332,1339,1346,1353,1360,1366,1374, | ||
816 | + 1385,1392,1410,1420,1431,1444,1454,1459,1477,1484, | ||
817 | + 1496,1512,1526,1541,1560,1578,1590,1601,1613,1624, | ||
818 | + 1637,1650,1664,1678,1690,1700,1719,1737,1755,1765, | ||
819 | + 1779,1793,1807,1820,1831,1845,1860,1877,1891,1904, | ||
820 | + 1916,1928,1938,1949,1966,1977,1988,2000,2012,2023, | ||
821 | + 2040,2057,2071,2084,2097,2113,2129,2143,2157,2173, | ||
822 | + 2188,2202,2215,2233,2250,2268,2287,2302,2315,2331, | ||
823 | + 2346,2359,2372,2385,2399,2415,2425,2441,2452,2473, | ||
824 | + 2484,2495,2504,2517,2528,2555,2575,2589,2603,2616, | ||
825 | + 2631,2648,2658,2669,2685,2700,2713,2729,2738,2749, | ||
826 | + 2765,2777,2788,2800,2812,2822,2833,2851,2863,2879, | ||
827 | + 2895,2906,2918,2928,2939,2956,2971,2987,3003,3015, | ||
828 | + 3020,3026,3037,3042,3048,3054,3060,3067,3077,3086, | ||
829 | + 3093,3100,3108,3121,3130,3135,3145,3154,3165,3171, | ||
830 | + 3178,3183,3192,3201,3209,3226,3238,3245,3254,3266, | ||
831 | + 3282,3288,3301,3315,3330,3346,3359,3373,3389,3407, | ||
832 | + 3430,3453,3471,3486,3505,3527,3545,3560,3579,3591, | ||
833 | + 3598,3605,3612,3618,3623,3632,3641,3649,3656,3670, | ||
834 | + 3686,3702,3716,3725,3734,3741,3751,3758,3770,3780, | ||
835 | + 3786,3794,3802,3814,3823,3833,3843,3852,3862,3869, | ||
836 | + 3880,3893,3900,3909,3916,3922,3929,3938,3948,3960, | ||
837 | + 3969,3979,3990,4000,4011,4018,4029,4036,4041,4048, | ||
838 | + 4055,4063,4070,4078,4088,4093,4109,4116,4122,4130, | ||
839 | + 4137,4141,4148,4156,4171,4187,4203,4209,4215,4224, | ||
840 | + 4232,4238,4245,4251,4258,4267,4275,4282,4288,4298, | ||
841 | + 4305,4311,4319,4328,4336,4342,4349,4355, | ||
842 | +}; | ||
843 | +static const int alpha_syscall_s2i_i[] = { | ||
844 | + 319,99,502,33,51,439,366,338,300,104, | ||
845 | + 17,368,369,12,15,16,61,499,312,6, | ||
846 | + 98,306,308,373,41,90,487,407,486,408, | ||
847 | + 474,409,478,485,25,59,1,405,462,413, | ||
848 | + 480,494,495,13,124,461,123,453,92,447, | ||
849 | + 387,390,131,2,393,384,91,427,455,329, | ||
850 | + 95,130,394,454,309,430,467,473,367,305, | ||
851 | + 377,89,79,87,361,64,141,233,63,100, | ||
852 | + 372,344,144,364,234,150,118,378,359,385, | ||
853 | + 47,20,24,307,445,444,489,446,402,399, | ||
854 | + 400,398,401,54,443,442,448,441,37,208, | ||
855 | + 386,9,458,106,388,389,406,392,19,383, | ||
856 | + 68,426,75,429,449,375,136,451,14,452, | ||
857 | + 314,316,71,302,472,74,437,436,432,435, | ||
858 | + 434,433,341,200,201,202,203,217,315,317, | ||
859 | + 73,497,340,342,303,321,45,498,450,140, | ||
860 | + 258,181,188,187,163,252,253,34,11,169, | ||
861 | + 35,261,248,161,243,214,159,165,164,18, | ||
862 | + 142,86,49,184,117,256,116,223,77,260, | ||
863 | + 78,21,65,240,215,213,216,30,158,31, | ||
864 | + 32,29,27,28,245,246,8,62,81,146, | ||
865 | + 40,5,46,109,139,110,108,38,72,115, | ||
866 | + 84,149,247,153,154,107,237,44,244,55, | ||
867 | + 56,69,222,93,43,239,143,83,50,257, | ||
868 | + 122,209,218,48,238,112,157,70,160,255, | ||
869 | + 259,199,0,241,85,242,251,250,220,219, | ||
870 | + 138,207,7,236,376,345,346,493,324,42, | ||
871 | + 488,374,94,464,348,349,490,496,463,26, | ||
872 | + 350,491,347,148,3,379,58,460,120,311, | ||
873 | + 102,125,479,113,410,391,128,457,440,412, | ||
874 | + 137,352,354,353,356,351,357,355,492,335, | ||
875 | + 336,396,331,333,337,395,330,332,334,358, | ||
876 | + 204,205,206,101,370,503,114,133,431,466, | ||
877 | + 411,166,326,325,132,80,301,88,362,501, | ||
878 | + 39,82,96,127,371,343,126,145,147,105, | ||
879 | + 360,23,382,210,211,212,134,156,235,476, | ||
880 | + 484,52,103,111,97,135,468,67,425,328, | ||
881 | + 304,322,57,459,36,469,500,254,318,310, | ||
882 | + 470,424,477,481,483,482,323,381,129,397, | ||
883 | + 60,22,339,10,456,465,313,327,475,363, | ||
884 | + 66,76,471,428,365,438,4,121, | ||
885 | +}; | ||
886 | +static int alpha_syscall_s2i(const char *s, int *value) { | ||
887 | + size_t len, i; | ||
888 | + len = strlen(s); | ||
889 | + { char copy[len + 1]; | ||
890 | + for (i = 0; i < len; i++) { | ||
891 | + char c = s[i]; | ||
892 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
893 | + } | ||
894 | + copy[i] = 0; | ||
895 | + return s2i__(alpha_syscall_strings, alpha_syscall_s2i_s, alpha_syscall_s2i_i, 408, copy, value); | ||
896 | + } | ||
897 | +} | ||
898 | +static const unsigned alpha_syscall_i2s_direct[] = { | ||
899 | + 2788,302,458,3130,4349,2202,140,2918,2129,1046, | ||
900 | + 4251,1613,95,376,1194,101,107,77,1765,1114, | ||
901 | + 835,1928,4238,3893,843,278,3086,2071,2084,2057, | ||
902 | + 2000,2023,2040,23,1601,1637,4088,1024,2302,3786, | ||
903 | + 2188,187,3015,2528,2441,1454,2215,827,2669,1807, | ||
904 | + 2603,30,3979,-1u,978,2473,2484,4070,3145,295, | ||
905 | + 4232,113,2143,708,676,1938,4305,4036,1130,2495, | ||
906 | + 2729,1223,2315,1385,1245,1144,4311,1891,1916,644, | ||
907 | + 3741,2157,3794,2589,2346,2812,1793,654,3758,630, | ||
908 | + 191,486,415,2517,3037,518,3802,4011,146,8, | ||
909 | + 716,3618,3178,3990,72,3869,1058,2415,2287,2233, | ||
910 | + 2268,4000,2700,3201,3641,2331,1860,1831,787,-1u, | ||
911 | + 3165,4355,2631,399,383,3183,3843,3814,3238,4215, | ||
912 | + 524,452,3734,3649,3929,4018,1180,3282,2895,2250, | ||
913 | + 1484,688,1779,2575,748,3852,2173,3862,3121,2359, | ||
914 | + 775,-1u,-1u,2385,2399,-1u,3938,2713,2012,1719, | ||
915 | + 2738,1678,-1u,1560,1755,1737,3702,-1u,-1u,1624, | ||
916 | + -1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u, | ||
917 | + -1u,1512,-1u,-1u,1820,-1u,-1u,1541,1526,-1u, | ||
918 | + -1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u,2777, | ||
919 | + 1332,1339,1346,1353,3598,3605,3612,2906,1029,2648, | ||
920 | + 3909,3916,3922,1977,1700,1966,1988,1360,2658,2879, | ||
921 | + 2863,-1u,2504,1877,-1u,-1u,-1u,-1u,-1u,-1u, | ||
922 | + -1u,-1u,-1u,700,768,3948,2928,2425,2685,2555, | ||
923 | + 1949,2800,2822,1690,2452,2097,2113,2372,1664,-1u, | ||
924 | + 2851,2833,1578,1590,4116,2749,1845,2616,1496,2765, | ||
925 | + 1904,1650,-1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u, | ||
926 | + -1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u, | ||
927 | + -1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u, | ||
928 | + -1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u,-1u, | ||
929 | + 64,3751,1228,1431,4055,610,154,851,168,550, | ||
930 | + 4130,3171,134,4275,1208,1366,1214,1374,4122,0, | ||
931 | + -1u,1444,4063,4203,3003,3725,3716,4282,4048,510, | ||
932 | + 3545,3471,3560,3486,3579,3407,3430,3505,52,4245, | ||
933 | + 1410,1325,1420,3833,738,2956,2971,3108,3048,3054, | ||
934 | + 3093,3346,3288,3315,3301,3373,3330,3359,3591,805, | ||
935 | + 3880,666,3770,4298,758,4336,43,603,81,88, | ||
936 | + 3623,3823,728,182,3026,1172,2939,619,798,3135, | ||
937 | + -1u,4209,3900,1120,476,818,1036,431,1065,1075, | ||
938 | + 441,3226,1101,463,534,3527,3453,4224,959,935, | ||
939 | + 946,968,925,-1u,-1u,307,1086,201,228,250, | ||
940 | + 3209,3686,3266,328,-1u,-1u,-1u,-1u,-1u,-1u, | ||
941 | + -1u,-1u,-1u,-1u,4141,4041,1136,492,4328,1152, | ||
942 | + 566,3656,1278,1315,1302,1286,1268,1254,4342,35, | ||
943 | + 3254,1017,995,984,881,863,908,421,1006,1158, | ||
944 | + 1477,1186,1200,406,540,500,4258,3245,1051,4078, | ||
945 | + 3154,390,318,3077,3042,4267,3670,580,4029,4093, | ||
946 | + 4137,4319,1234,596,238,4288,3960,4148,261,3192, | ||
947 | + 338,4156,4187,4171,3969,269,214,196,3020,894, | ||
948 | + 3060,3100,3389,2987,348,362,3067,1392,1459,120, | ||
949 | + 4109,3780,15,3632, | ||
950 | +}; | ||
951 | +static const char *alpha_syscall_i2s(int v) { | ||
952 | + return i2s_direct__(alpha_syscall_strings, alpha_syscall_i2s_direct, 0, 503, v); | ||
953 | +} | ||
954 | diff --git a/lib/armeb_tables.h b/lib/armeb_tables.h | ||
955 | new file mode 100644 | ||
956 | index 0000000..5afe038 | ||
957 | --- /dev/null | ||
958 | +++ b/lib/armeb_tables.h | ||
959 | @@ -0,0 +1,165 @@ | ||
960 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
961 | +static const char armeb_syscall_strings[] = "accept\0accept4\0access\0acct\0add_key\0adjtimex\0alarm\0bdflush\0bind\0brk\0" | ||
962 | + "capget\0capset\0chdir\0chmod\0chown\0chown32\0chroot\0clock_adjtime\0clock_getres\0clock_gettime\0" | ||
963 | + "clock_nanosleep\0clock_settime\0clone\0close\0connect\0creat\0delete_module\0dup\0dup2\0dup3\0" | ||
964 | + "epoll_create\0epoll_create1\0epoll_ctl\0epoll_wait\0eventfd\0eventfd2\0execve\0exit\0exit_group\0faccessat\0" | ||
965 | + "fadvise64_64\0fallocate\0fanotify_init\0fanotify_mark\0fchdir\0fchmod\0fchmodat\0fchown\0fchown32\0fchownat\0" | ||
966 | + "fcntl\0fcntl64\0fdatasync\0fgetxattr\0flistxattr\0flock\0fork\0fremovexattr\0fsetxattr\0fstat\0" | ||
967 | + "fstat64\0fstatat64\0fstatfs\0fstatfs64\0fsync\0ftruncate\0ftruncate64\0futex\0futimesat\0get_mempolicy\0" | ||
968 | + "get_robust_list\0getcpu\0getcwd\0getdents\0getdents64\0getegid\0getegid32\0geteuid\0geteuid32\0getgid\0" | ||
969 | + "getgid32\0getgroups\0getgroups32\0getitimer\0getpeername\0getpgid\0getpgrp\0getpid\0getppid\0getpriority\0" | ||
970 | + "getresgid\0getresgid32\0getresuid\0getresuid32\0getrlimit\0getrusage\0getsid\0getsockname\0getsockopt\0gettid\0" | ||
971 | + "gettimeofday\0getuid\0getuid32\0getxattr\0init_module\0inotify_add_watch\0inotify_init\0inotify_init1\0inotify_rm_watch\0io_cancel\0" | ||
972 | + "io_destroy\0io_getevents\0io_setup\0io_submit\0ioctl\0ioprio_get\0ioprio_set\0ipc\0kexec_load\0keyctl\0" | ||
973 | + "kill\0lchown\0lchown32\0lgetxattr\0link\0linkat\0listen\0listxattr\0llistxattr\0llseek\0" | ||
974 | + "lookup_dcookie\0lremovexattr\0lseek\0lsetxattr\0lstat\0lstat64\0madvise\0mbind\0mincore\0mkdir\0" | ||
975 | + "mkdirat\0mknod\0mknodat\0mlock\0mlockall\0mmap\0mmap2\0mount\0move_pages\0mprotect\0" | ||
976 | + "mq_getsetattr\0mq_notify\0mq_open\0mq_timedreceive\0mq_timedsend\0mq_unlink\0mremap\0msgctl\0msgget\0msgrcv\0" | ||
977 | + "msgsnd\0msync\0munlock\0munlockall\0munmap\0name_to_handle_at\0nanosleep\0newselect\0nfsservctl\0nice\0" | ||
978 | + "open\0open_by_handle_at\0openat\0pause\0pciconfig_iobase\0pciconfig_read\0pciconfig_write\0perf_event_open\0personality\0pipe\0" | ||
979 | + "pipe2\0pivot_root\0poll\0prctl\0pread64\0preadv\0prlimit64\0process_vm_readv\0process_vm_writev\0ptrace\0" | ||
980 | + "pwrite64\0pwritev\0quotactl\0read\0readahead\0readdir\0readlink\0readlinkat\0readv\0reboot\0" | ||
981 | + "recv\0recvfrom\0recvmmsg\0recvmsg\0remap_file_pages\0removexattr\0rename\0renameat\0request_key\0restart_syscall\0" | ||
982 | + "rmdir\0rt_sigaction\0rt_sigpending\0rt_sigprocmask\0rt_sigqueueinfo\0rt_sigreturn\0rt_sigsuspend\0rt_sigtimedwait\0rt_tgsigqueueinfo\0sched_get_priority_max\0" | ||
983 | + "sched_get_priority_min\0sched_getaffinity\0sched_getparam\0sched_getscheduler\0sched_rr_get_interval\0sched_setaffinity\0sched_setparam\0sched_setscheduler\0sched_yield\0select\0" | ||
984 | + "semctl\0semget\0semop\0semtimedop\0send\0sendfile\0sendfile64\0sendmmsg\0sendmsg\0sendto\0" | ||
985 | + "set_mempolicy\0set_robust_list\0set_tid_address\0setdomainname\0setfsgid\0setfsgid32\0setfsuid\0setfsuid32\0setgid\0setgid32\0" | ||
986 | + "setgroups\0setgroups32\0sethostname\0setitimer\0setns\0setpgid\0setpriority\0setregid\0setregid32\0setresgid\0" | ||
987 | + "setresgid32\0setresuid\0setresuid32\0setreuid\0setreuid32\0setrlimit\0setsid\0setsockopt\0settimeofday\0setuid\0" | ||
988 | + "setuid32\0setxattr\0shmat\0shmctl\0shmdt\0shmget\0shutdown\0sigaction\0sigaltstack\0signalfd\0" | ||
989 | + "signalfd4\0sigpending\0sigprocmask\0sigreturn\0sigsuspend\0socket\0socketcall\0socketpair\0splice\0stat\0" | ||
990 | + "stat64\0statfs\0statfs64\0stime\0swapoff\0swapon\0symlink\0symlinkat\0sync\0sync_file_range\0" | ||
991 | + "syncfs\0syscall\0sysctl\0sysfs\0sysinfo\0syslog\0tee\0tgkill\0time\0timer_create\0" | ||
992 | + "timer_delete\0timer_getoverrun\0timer_gettime\0timer_settime\0timerfd_create\0timerfd_gettime\0timerfd_settime\0times\0tkill\0truncate\0" | ||
993 | + "truncate64\0ugetrlimit\0umask\0umount\0umount2\0uname\0unlink\0unlinkat\0unshare\0uselib\0" | ||
994 | + "ustat\0utime\0utimensat\0utimes\0vfork\0vhangup\0vmsplice\0vserver\0wait4\0waitid\0" | ||
995 | + "write\0writev"; | ||
996 | +static const unsigned armeb_syscall_s2i_s[] = { | ||
997 | + 0,7,15,22,27,35,44,50,58,63, | ||
998 | + 67,74,81,87,93,99,107,114,128,141, | ||
999 | + 155,171,185,191,197,205,211,225,229,234, | ||
1000 | + 239,252,266,276,287,295,304,311,316,327, | ||
1001 | + 337,350,360,374,388,395,402,411,418,427, | ||
1002 | + 436,442,450,460,470,481,487,492,505,515, | ||
1003 | + 521,529,539,547,557,563,573,585,591,601, | ||
1004 | + 615,631,638,645,654,665,673,683,691,701, | ||
1005 | + 708,717,727,739,749,761,769,777,784,792, | ||
1006 | + 804,814,826,836,848,858,868,875,887,898, | ||
1007 | + 905,918,925,934,943,955,973,986,1000,1017, | ||
1008 | + 1027,1038,1051,1060,1070,1076,1087,1098,1102,1113, | ||
1009 | + 1120,1125,1132,1141,1151,1156,1163,1170,1180,1191, | ||
1010 | + 1198,1213,1226,1232,1242,1248,1256,1264,1270,1278, | ||
1011 | + 1284,1292,1298,1306,1312,1321,1326,1332,1338,1349, | ||
1012 | + 1358,1372,1382,1390,1406,1419,1429,1436,1443,1450, | ||
1013 | + 1457,1464,1470,1478,1489,1496,1514,1524,1534,1545, | ||
1014 | + 1550,1555,1573,1580,1586,1603,1618,1634,1650,1662, | ||
1015 | + 1667,1673,1684,1689,1695,1703,1710,1720,1737,1755, | ||
1016 | + 1762,1771,1779,1788,1793,1803,1811,1820,1831,1837, | ||
1017 | + 1844,1849,1858,1867,1875,1892,1904,1911,1920,1932, | ||
1018 | + 1948,1954,1967,1981,1996,2012,2025,2039,2055,2073, | ||
1019 | + 2096,2119,2137,2152,2171,2193,2211,2226,2245,2257, | ||
1020 | + 2264,2271,2278,2284,2295,2300,2309,2320,2329,2337, | ||
1021 | + 2344,2358,2374,2390,2404,2413,2424,2433,2444,2451, | ||
1022 | + 2460,2470,2482,2494,2504,2510,2518,2530,2539,2550, | ||
1023 | + 2560,2572,2582,2594,2603,2614,2624,2631,2642,2655, | ||
1024 | + 2662,2671,2680,2686,2693,2699,2706,2715,2725,2737, | ||
1025 | + 2746,2756,2767,2779,2789,2800,2807,2818,2829,2836, | ||
1026 | + 2841,2848,2855,2864,2870,2878,2885,2893,2903,2908, | ||
1027 | + 2924,2931,2939,2946,2952,2960,2967,2971,2978,2983, | ||
1028 | + 2996,3009,3026,3040,3054,3069,3085,3101,3107,3113, | ||
1029 | + 3122,3133,3144,3150,3157,3165,3171,3178,3187,3195, | ||
1030 | + 3202,3208,3214,3224,3231,3237,3245,3254,3262,3268, | ||
1031 | + 3275,3281, | ||
1032 | +}; | ||
1033 | +static const int armeb_syscall_s2i_i[] = { | ||
1034 | + 285,366,33,51,309,124,27,134,282,45, | ||
1035 | + 184,185,12,15,182,212,61,372,264,263, | ||
1036 | + 265,262,120,6,283,8,129,41,63,358, | ||
1037 | + 250,357,251,252,351,356,11,1,248,334, | ||
1038 | + 270,352,367,368,133,94,333,95,207,325, | ||
1039 | + 55,221,148,231,234,143,2,237,228,108, | ||
1040 | + 197,327,100,267,118,93,194,240,326,320, | ||
1041 | + 339,345,183,141,217,50,202,49,201,47, | ||
1042 | + 200,80,205,105,287,132,65,20,64,96, | ||
1043 | + 171,211,165,209,76,77,147,286,295,224, | ||
1044 | + 78,24,199,229,128,317,316,360,318,247, | ||
1045 | + 244,245,243,246,54,315,314,117,347,311, | ||
1046 | + 37,16,198,230,9,330,284,232,233,140, | ||
1047 | + 249,236,19,227,107,196,220,319,219,39, | ||
1048 | + 323,14,324,150,152,90,192,21,344,125, | ||
1049 | + 279,278,274,277,276,275,163,304,303,302, | ||
1050 | + 301,144,151,153,91,370,162,142,169,34, | ||
1051 | + 5,371,322,29,271,272,273,364,136,42, | ||
1052 | + 359,218,168,172,180,361,369,376,377,26, | ||
1053 | + 181,362,131,3,225,89,85,332,145,88, | ||
1054 | + 291,292,365,297,253,235,38,329,310,0, | ||
1055 | + 40,174,176,175,178,173,179,177,363,159, | ||
1056 | + 160,242,155,157,161,241,154,156,158,82, | ||
1057 | + 300,299,298,312,289,187,239,374,296,290, | ||
1058 | + 321,338,256,121,139,216,138,215,46,214, | ||
1059 | + 81,206,74,104,375,57,97,71,204,170, | ||
1060 | + 210,164,208,70,203,75,66,294,79,23, | ||
1061 | + 213,226,305,308,306,307,293,67,186,349, | ||
1062 | + 355,73,126,119,72,281,102,288,340,106, | ||
1063 | + 195,99,266,25,115,87,83,331,36,341, | ||
1064 | + 373,113,149,135,116,103,342,268,13,257, | ||
1065 | + 261,260,259,258,350,354,353,43,238,92, | ||
1066 | + 193,191,60,22,52,122,10,328,337,86, | ||
1067 | + 62,30,348,269,190,111,343,313,114,280, | ||
1068 | + 4,146, | ||
1069 | +}; | ||
1070 | +static int armeb_syscall_s2i(const char *s, int *value) { | ||
1071 | + size_t len, i; | ||
1072 | + len = strlen(s); | ||
1073 | + { char copy[len + 1]; | ||
1074 | + for (i = 0; i < len; i++) { | ||
1075 | + char c = s[i]; | ||
1076 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
1077 | + } | ||
1078 | + copy[i] = 0; | ||
1079 | + return s2i__(armeb_syscall_strings, armeb_syscall_s2i_s, armeb_syscall_s2i_i, 342, copy, value); | ||
1080 | + } | ||
1081 | +} | ||
1082 | +static const unsigned armeb_syscall_i2s_direct[] = { | ||
1083 | + 1932,311,487,1788,3275,1550,191,-1u,205,1151, | ||
1084 | + 3171,304,81,2978,1292,87,1125,-1u,-1u,1226, | ||
1085 | + 777,1332,3150,2655,918,2864,1755,44,-1u,1580, | ||
1086 | + 3208,-1u,-1u,15,1545,-1u,2903,1120,1904,1278, | ||
1087 | + 1948,225,1662,3101,-1u,63,2444,701,-1u,683, | ||
1088 | + 665,22,3157,-1u,1070,436,-1u,2510,-1u,-1u, | ||
1089 | + 3144,107,3202,229,784,769,2624,2715,-1u,-1u, | ||
1090 | + 2594,2530,2789,2756,2482,2614,848,858,905,2642, | ||
1091 | + 717,2460,2257,2885,-1u,1811,3195,2878,1837,1803, | ||
1092 | + 1321,1489,3113,563,395,411,792,2518,-1u,2848, | ||
1093 | + 539,-1u,2807,2960,2494,739,2836,1242,515,-1u, | ||
1094 | + -1u,3237,-1u,2931,3262,2870,2952,1098,557,2779, | ||
1095 | + 185,2390,3165,-1u,35,1349,2767,-1u,943,211, | ||
1096 | + -1u,1779,761,388,50,2946,1650,-1u,2424,2404, | ||
1097 | + 1191,645,1524,481,1464,1831,3281,868,450,2939, | ||
1098 | + 1306,1470,1312,1478,2211,2137,2226,2152,2245,2073, | ||
1099 | + 2096,2171,1514,1429,2572,826,-1u,-1u,1684,1534, | ||
1100 | + 2550,804,1689,2012,1954,1981,1967,2039,1996,2025, | ||
1101 | + 1695,1762,93,638,67,74,2725,2300,-1u,-1u, | ||
1102 | + 3231,3133,1326,3122,573,2841,1248,521,1132,925, | ||
1103 | + 708,691,673,2603,2539,727,2470,418,2582,836, | ||
1104 | + 2560,814,99,2662,2451,2433,2413,654,1673,1270, | ||
1105 | + 1256,442,-1u,-1u,898,1793,2671,1232,505,934, | ||
1106 | + 1141,460,1170,1180,470,1892,1213,492,3107,2309, | ||
1107 | + 585,2193,2119,1051,1027,1038,1060,1017,316,1198, | ||
1108 | + 239,266,276,1875,-1u,-1u,2374,2983,3040,3026, | ||
1109 | + 3009,2996,171,141,128,155,2855,547,2971,3224, | ||
1110 | + 337,1586,1603,1618,1382,1419,1406,1390,1372,1358, | ||
1111 | + 3268,2800,58,197,1163,0,875,749,2818,2295, | ||
1112 | + 2337,1844,1849,2706,2631,887,2329,1867,2278,2271, | ||
1113 | + 2264,1457,1450,1443,1436,2680,2693,2699,2686,27, | ||
1114 | + 1920,1113,2284,3254,1087,1076,973,955,1000,1264, | ||
1115 | + 601,2344,1573,1284,1298,427,591,529,3178,1911, | ||
1116 | + 1156,2893,1820,402,327,-1u,-1u,3187,2358,615, | ||
1117 | + 2829,2908,2967,3245,1338,631,-1u,1102,3214,2737, | ||
1118 | + 3054,287,350,3085,3069,2746,295,252,234,1667, | ||
1119 | + 986,1703,1771,2055,1634,1858,7,360,374,1710, | ||
1120 | + 1496,1555,114,2924,2320,2504,1720,1737, | ||
1121 | +}; | ||
1122 | +static const char *armeb_syscall_i2s(int v) { | ||
1123 | + return i2s_direct__(armeb_syscall_strings, armeb_syscall_i2s_direct, 0, 377, v); | ||
1124 | +} | ||
1125 | diff --git a/lib/errtabs.h b/lib/errtabs.h | ||
1126 | new file mode 100644 | ||
1127 | index 0000000..53deac2 | ||
1128 | --- /dev/null | ||
1129 | +++ b/lib/errtabs.h | ||
1130 | @@ -0,0 +1,78 @@ | ||
1131 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
1132 | +static const char err_strings[] = "E2BIG\0EACCES\0EADDRINUSE\0EADDRNOTAVAIL\0EADV\0EAFNOSUPPORT\0EAGAIN\0EALREADY\0EBADE\0EBADF\0" | ||
1133 | + "EBADFD\0EBADMSG\0EBADR\0EBADRQC\0EBADSLT\0EBFONT\0EBUSY\0ECANCELED\0ECHILD\0ECHRNG\0" | ||
1134 | + "ECOMM\0ECONNABORTED\0ECONNREFUSED\0ECONNRESET\0EDEADLK\0EDEADLOCK\0EDESTADDRREQ\0EDOM\0EDOTDOT\0EDQUOT\0" | ||
1135 | + "EEXIST\0EFAULT\0EFBIG\0EHOSTDOWN\0EHOSTUNREACH\0EIDRM\0EILSEQ\0EINPROGRESS\0EINTR\0EINVAL\0" | ||
1136 | + "EIO\0EISCONN\0EISDIR\0EISNAM\0EKEYEXPIRED\0EKEYREJECTED\0EKEYREVOKED\0EL2HLT\0EL2NSYNC\0EL3HLT\0" | ||
1137 | + "EL3RST\0ELIBACC\0ELIBBAD\0ELIBEXEC\0ELIBMAX\0ELIBSCN\0ELNRNG\0ELOOP\0EMEDIUMTYPE\0EMFILE\0" | ||
1138 | + "EMLINK\0EMSGSIZE\0EMULTIHOP\0ENAMETOOLONG\0ENAVAIL\0ENETDOWN\0ENETRESET\0ENETUNREACH\0ENFILE\0ENOANO\0" | ||
1139 | + "ENOBUFS\0ENOCSI\0ENODATA\0ENODEV\0ENOENT\0ENOEXEC\0ENOKEY\0ENOLCK\0ENOLINK\0ENOMEDIUM\0" | ||
1140 | + "ENOMEM\0ENOMSG\0ENONET\0ENOPKG\0ENOPROTOOPT\0ENOSPC\0ENOSR\0ENOSTR\0ENOSYS\0ENOTBLK\0" | ||
1141 | + "ENOTCONN\0ENOTDIR\0ENOTEMPTY\0ENOTNAM\0ENOTRECOVERABLE\0ENOTSOCK\0ENOTTY\0ENOTUNIQ\0ENXIO\0EOPNOTSUPP\0" | ||
1142 | + "EOVERFLOW\0EOWNERDEAD\0EPERM\0EPFNOSUPPORT\0EPIPE\0EPROTO\0EPROTONOSUPPORT\0EPROTOTYPE\0ERANGE\0EREMCHG\0" | ||
1143 | + "EREMOTE\0EREMOTEIO\0ERESTART\0EROFS\0ESHUTDOWN\0ESOCKTNOSUPPORT\0ESPIPE\0ESRCH\0ESRMNT\0ESTALE\0" | ||
1144 | + "ESTRPIPE\0ETIME\0ETIMEDOUT\0ETOOMANYREFS\0ETXTBSY\0EUCLEAN\0EUNATCH\0EUSERS\0EWOULDBLOCK\0EXDEV\0" | ||
1145 | + "EXFULL"; | ||
1146 | +static const unsigned err_s2i_s[] = { | ||
1147 | + 0,6,13,24,38,43,56,63,72,78, | ||
1148 | + 84,91,99,105,113,121,128,134,144,151, | ||
1149 | + 158,164,177,190,201,209,219,232,237,245, | ||
1150 | + 252,259,266,272,282,295,301,308,320,326, | ||
1151 | + 333,337,345,352,359,371,384,396,403,412, | ||
1152 | + 419,426,434,442,451,459,467,474,480,492, | ||
1153 | + 499,506,515,525,538,546,555,565,577,584, | ||
1154 | + 591,599,606,614,621,628,636,643,650,658, | ||
1155 | + 668,675,682,689,696,708,715,721,728,735, | ||
1156 | + 743,752,760,770,778,794,803,810,819,825, | ||
1157 | + 836,846,857,863,876,882,889,905,916,923, | ||
1158 | + 931,939,949,958,964,974,990,997,1003,1010, | ||
1159 | + 1017,1026,1032,1042,1055,1063,1071,1079,1086,1098, | ||
1160 | + 1104, | ||
1161 | +}; | ||
1162 | +static const int err_s2i_i[] = { | ||
1163 | + 7,13,98,99,68,97,11,114,52,9, | ||
1164 | + 77,74,53,56,57,59,16,125,10,44, | ||
1165 | + 70,103,111,104,35,35,89,33,73,122, | ||
1166 | + 17,14,27,112,113,43,84,115,4,22, | ||
1167 | + 5,106,21,120,127,129,128,51,45,46, | ||
1168 | + 47,79,80,83,82,81,48,40,124,24, | ||
1169 | + 31,90,72,36,119,100,102,101,23,55, | ||
1170 | + 105,50,61,19,2,8,126,37,67,123, | ||
1171 | + 12,42,64,65,92,28,63,60,38,15, | ||
1172 | + 107,20,39,118,131,88,25,76,6,95, | ||
1173 | + 75,130,1,96,32,71,93,91,34,78, | ||
1174 | + 66,121,85,30,108,94,29,3,69,116, | ||
1175 | + 86,62,110,109,26,117,49,87,11,18, | ||
1176 | + 54, | ||
1177 | +}; | ||
1178 | +static int err_s2i(const char *s, int *value) { | ||
1179 | + size_t len, i; | ||
1180 | + len = strlen(s); | ||
1181 | + { char copy[len + 1]; | ||
1182 | + for (i = 0; i < len; i++) { | ||
1183 | + char c = s[i]; | ||
1184 | + copy[i] = GT_ISLOWER(c) ? c - 'a' + 'A' : c; | ||
1185 | + } | ||
1186 | + copy[i] = 0; | ||
1187 | + return s2i__(err_strings, err_s2i_s, err_s2i_i, 131, copy, value); | ||
1188 | + } | ||
1189 | +} | ||
1190 | +static const unsigned err_i2s_direct[] = { | ||
1191 | + 857,621,997,320,333,819,0,628,78,144, | ||
1192 | + 56,668,6,259,735,128,252,1098,614,752, | ||
1193 | + 345,326,577,492,803,1055,266,708,990,958, | ||
1194 | + 499,876,232,916,201,525,643,728,760,474, | ||
1195 | + -1u,675,295,151,403,412,419,467,1071,599, | ||
1196 | + 396,72,99,1104,584,105,113,-1u,121,721, | ||
1197 | + 606,1026,715,682,689,931,650,38,1003,158, | ||
1198 | + 882,515,237,91,836,810,84,923,426,434, | ||
1199 | + 459,451,442,301,949,1017,1079,794,219,506, | ||
1200 | + 905,696,889,974,825,863,43,13,24,546, | ||
1201 | + 565,555,164,190,591,337,743,964,1042,1032, | ||
1202 | + 177,272,282,63,308,1010,1063,770,538,352, | ||
1203 | + 939,245,658,480,134,636,359,384,371,846, | ||
1204 | + 778, | ||
1205 | +}; | ||
1206 | +static const char *err_i2s(int v) { | ||
1207 | + return i2s_direct__(err_strings, err_i2s_direct, 1, 131, v); | ||
1208 | +} | ||
1209 | diff --git a/lib/fieldtabs.h b/lib/fieldtabs.h | ||
1210 | new file mode 100644 | ||
1211 | index 0000000..fb50e08 | ||
1212 | --- /dev/null | ||
1213 | +++ b/lib/fieldtabs.h | ||
1214 | @@ -0,0 +1,49 @@ | ||
1215 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
1216 | +static const char field_strings[] = "a0\0a1\0a2\0a3\0arch\0auid\0devmajor\0devminor\0dir\0egid\0" | ||
1217 | + "euid\0exit\0field_compare\0filetype\0fsgid\0fsuid\0gid\0inode\0key\0loginuid\0" | ||
1218 | + "msgtype\0obj_gid\0obj_lev_high\0obj_lev_low\0obj_role\0obj_type\0obj_uid\0obj_user\0path\0perm\0" | ||
1219 | + "pers\0pid\0ppid\0sgid\0subj_clr\0subj_role\0subj_sen\0subj_type\0subj_user\0success\0" | ||
1220 | + "suid\0uid"; | ||
1221 | +static const unsigned field_s2i_s[] = { | ||
1222 | + 0,3,6,9,12,17,22,31,40,44, | ||
1223 | + 49,54,59,73,82,88,94,98,104,108, | ||
1224 | + 117,125,133,146,158,167,176,184,193,198, | ||
1225 | + 203,208,212,217,222,231,241,250,260,270, | ||
1226 | + 278,283, | ||
1227 | +}; | ||
1228 | +static const int field_s2i_i[] = { | ||
1229 | + 200,201,202,203,11,9,100,101,107,6, | ||
1230 | + 2,103,111,108,8,4,5,102,210,9, | ||
1231 | + 12,110,23,22,20,21,109,19,105,106, | ||
1232 | + 10,0,18,7,17,14,16,15,13,104, | ||
1233 | + 3,1, | ||
1234 | +}; | ||
1235 | +static int field_s2i(const char *s, int *value) { | ||
1236 | + size_t len, i; | ||
1237 | + len = strlen(s); | ||
1238 | + { char copy[len + 1]; | ||
1239 | + for (i = 0; i < len; i++) { | ||
1240 | + char c = s[i]; | ||
1241 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
1242 | + } | ||
1243 | + copy[i] = 0; | ||
1244 | + return s2i__(field_strings, field_s2i_s, field_s2i_i, 42, copy, value); | ||
1245 | + } | ||
1246 | +} | ||
1247 | +static const int field_i2s_i[] = { | ||
1248 | + 0,1,2,3,4,5,6,7,8,9, | ||
1249 | + 10,11,12,13,14,15,16,17,18,19, | ||
1250 | + 20,21,22,23,100,101,102,103,104,105, | ||
1251 | + 106,107,108,109,110,111,200,201,202,203, | ||
1252 | + 210, | ||
1253 | +}; | ||
1254 | +static const unsigned field_i2s_s[] = { | ||
1255 | + 208,283,49,278,88,94,44,217,82,17, | ||
1256 | + 203,12,117,260,231,250,241,222,212,184, | ||
1257 | + 158,167,146,133,22,31,98,54,270,193, | ||
1258 | + 198,40,73,176,125,59,0,3,6,9, | ||
1259 | + 104, | ||
1260 | +}; | ||
1261 | +static const char *field_i2s(int v) { | ||
1262 | + return i2s_bsearch__(field_strings, field_i2s_i, field_i2s_s, 41, v); | ||
1263 | +} | ||
1264 | diff --git a/lib/flagtabs.h b/lib/flagtabs.h | ||
1265 | new file mode 100644 | ||
1266 | index 0000000..e191db3 | ||
1267 | --- /dev/null | ||
1268 | +++ b/lib/flagtabs.h | ||
1269 | @@ -0,0 +1,26 @@ | ||
1270 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
1271 | +static const char flag_strings[] = "entry\0exclude\0exit\0task\0user"; | ||
1272 | +static const unsigned flag_s2i_s[] = { | ||
1273 | + 0,6,14,19,24, | ||
1274 | +}; | ||
1275 | +static const int flag_s2i_i[] = { | ||
1276 | + 2,5,4,1,0, | ||
1277 | +}; | ||
1278 | +static int flag_s2i(const char *s, int *value) { | ||
1279 | + size_t len, i; | ||
1280 | + len = strlen(s); | ||
1281 | + { char copy[len + 1]; | ||
1282 | + for (i = 0; i < len; i++) { | ||
1283 | + char c = s[i]; | ||
1284 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
1285 | + } | ||
1286 | + copy[i] = 0; | ||
1287 | + return s2i__(flag_strings, flag_s2i_s, flag_s2i_i, 5, copy, value); | ||
1288 | + } | ||
1289 | +} | ||
1290 | +static const unsigned flag_i2s_direct[] = { | ||
1291 | + 24,19,0,-1u,14,6, | ||
1292 | +}; | ||
1293 | +static const char *flag_i2s(int v) { | ||
1294 | + return i2s_direct__(flag_strings, flag_i2s_direct, 0, 5, v); | ||
1295 | +} | ||
1296 | diff --git a/lib/ftypetabs.h b/lib/ftypetabs.h | ||
1297 | new file mode 100644 | ||
1298 | index 0000000..04aaa46 | ||
1299 | --- /dev/null | ||
1300 | +++ b/lib/ftypetabs.h | ||
1301 | @@ -0,0 +1,29 @@ | ||
1302 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
1303 | +static const char ftype_strings[] = "block\0character\0dir\0fifo\0file\0link\0socket"; | ||
1304 | +static const unsigned ftype_s2i_s[] = { | ||
1305 | + 0,6,16,20,25,30,35, | ||
1306 | +}; | ||
1307 | +static const int ftype_s2i_i[] = { | ||
1308 | + 24576,8192,16384,4096,32768,40960,49152, | ||
1309 | +}; | ||
1310 | +static int ftype_s2i(const char *s, int *value) { | ||
1311 | + size_t len, i; | ||
1312 | + len = strlen(s); | ||
1313 | + { char copy[len + 1]; | ||
1314 | + for (i = 0; i < len; i++) { | ||
1315 | + char c = s[i]; | ||
1316 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
1317 | + } | ||
1318 | + copy[i] = 0; | ||
1319 | + return s2i__(ftype_strings, ftype_s2i_s, ftype_s2i_i, 7, copy, value); | ||
1320 | + } | ||
1321 | +} | ||
1322 | +static const int ftype_i2s_i[] = { | ||
1323 | + 4096,8192,16384,24576,32768,40960,49152, | ||
1324 | +}; | ||
1325 | +static const unsigned ftype_i2s_s[] = { | ||
1326 | + 20,6,16,0,25,30,35, | ||
1327 | +}; | ||
1328 | +static const char *ftype_i2s(int v) { | ||
1329 | + return i2s_bsearch__(ftype_strings, ftype_i2s_i, ftype_i2s_s, 7, v); | ||
1330 | +} | ||
1331 | diff --git a/lib/i386_tables.h b/lib/i386_tables.h | ||
1332 | new file mode 100644 | ||
1333 | index 0000000..59d458c | ||
1334 | --- /dev/null | ||
1335 | +++ b/lib/i386_tables.h | ||
1336 | @@ -0,0 +1,162 @@ | ||
1337 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
1338 | +static const char i386_syscall_strings[] = "_llseek\0_newselect\0_sysctl\0access\0acct\0add_key\0adjtimex\0afs_syscall\0alarm\0bdflush\0" | ||
1339 | + "break\0brk\0capget\0capset\0chdir\0chmod\0chown\0chown32\0chroot\0clock_adjtime\0" | ||
1340 | + "clock_getres\0clock_gettime\0clock_nanosleep\0clock_settime\0clone\0close\0creat\0create_module\0delete_module\0dup\0" | ||
1341 | + "dup2\0dup3\0epoll_create\0epoll_create1\0epoll_ctl\0epoll_pwait\0epoll_wait\0eventfd\0eventfd2\0execve\0" | ||
1342 | + "exit\0exit_group\0faccessat\0fadvise64\0fadvise64_64\0fallocate\0fanotify_init\0fanotify_mark\0fchdir\0fchmod\0" | ||
1343 | + "fchmodat\0fchown\0fchown32\0fchownat\0fcntl\0fcntl64\0fdatasync\0fgetxattr\0flistxattr\0flock\0" | ||
1344 | + "fork\0fremovexattr\0fsetxattr\0fstat\0fstat64\0fstatat64\0fstatfs\0fstatfs64\0fsync\0ftime\0" | ||
1345 | + "ftruncate\0ftruncate64\0futex\0futimesat\0get_kernel_syms\0get_mempolicy\0get_robust_list\0get_thread_area\0getcpu\0getcwd\0" | ||
1346 | + "getdents\0getdents64\0getegid\0getegid32\0geteuid\0geteuid32\0getgid\0getgid32\0getgroups\0getgroups32\0" | ||
1347 | + "getitimer\0getpgid\0getpgrp\0getpid\0getpmsg\0getppid\0getpriority\0getresgid\0getresgid32\0getresuid\0" | ||
1348 | + "getresuid32\0getrlimit\0getrusage\0getsid\0gettid\0gettimeofday\0getuid\0getuid32\0getxattr\0gtty\0" | ||
1349 | + "idle\0init_module\0inotify_add_watch\0inotify_init\0inotify_init1\0inotify_rm_watch\0io_cancel\0io_destroy\0io_getevents\0io_setup\0" | ||
1350 | + "io_submit\0ioctl\0ioperm\0iopl\0ioprio_get\0ioprio_set\0ipc\0keyctl\0kill\0lchown\0" | ||
1351 | + "lchown32\0lgetxattr\0link\0linkat\0listxattr\0llistxattr\0lock\0lookup_dcookie\0lremovexattr\0lseek\0" | ||
1352 | + "lsetxattr\0lstat\0lstat64\0madvise\0madvise1\0mbind\0migrate_pages\0mincore\0mkdir\0mkdirat\0" | ||
1353 | + "mknod\0mknodat\0mlock\0mlockall\0mmap\0mmap2\0modify_ldt\0mount\0move_pages\0mprotect\0" | ||
1354 | + "mpx\0mq_getsetattr\0mq_notify\0mq_open\0mq_timedreceive\0mq_timedsend\0mq_unlink\0mremap\0msync\0munlock\0" | ||
1355 | + "munlockall\0munmap\0name_to_handle_at\0nanosleep\0nfsservctl\0nice\0oldfstat\0oldlstat\0oldolduname\0oldstat\0" | ||
1356 | + "olduname\0open\0open_by_handle_at\0openat\0pause\0perf_event_open\0personality\0pipe\0pipe2\0pivot_root\0" | ||
1357 | + "poll\0ppoll\0prctl\0pread64\0preadv\0prlimit64\0process_vm_readv\0process_vm_writev\0prof\0profil\0" | ||
1358 | + "pselect6\0ptrace\0putpmsg\0pwrite64\0pwritev\0query_module\0quotactl\0read\0readahead\0readdir\0" | ||
1359 | + "readlink\0readlinkat\0readv\0reboot\0recvmmsg\0remap_file_pages\0removexattr\0rename\0renameat\0request_key\0" | ||
1360 | + "restart_syscall\0rmdir\0rt_sigaction\0rt_sigpending\0rt_sigprocmask\0rt_sigqueueinfo\0rt_sigreturn\0rt_sigsuspend\0rt_sigtimedwait\0rt_tgsigqueueinfo\0" | ||
1361 | + "sched_get_priority_max\0sched_get_priority_min\0sched_getaffinity\0sched_getparam\0sched_getscheduler\0sched_rr_get_interval\0sched_setaffinity\0sched_setparam\0sched_setscheduler\0sched_yield\0" | ||
1362 | + "select\0sendfile\0sendfile64\0sendmmsg\0set_mempolicy\0set_robust_list\0set_thread_area\0set_tid_address\0setdomainname\0setfsgid\0" | ||
1363 | + "setfsgid32\0setfsuid\0setfsuid32\0setgid\0setgid32\0setgroups\0setgroups32\0sethostname\0setitimer\0setns\0" | ||
1364 | + "setpgid\0setpriority\0setregid\0setregid32\0setresgid\0setresgid32\0setresuid\0setresuid32\0setreuid\0setreuid32\0" | ||
1365 | + "setrlimit\0setsid\0settimeofday\0setuid\0setuid32\0setxattr\0sgetmask\0sigaction\0sigaltstack\0signal\0" | ||
1366 | + "signalfd\0signalfd4\0sigpending\0sigprocmask\0sigreturn\0sigsuspend\0socketcall\0splice\0ssetmask\0stat\0" | ||
1367 | + "stat64\0statfs\0statfs64\0stime\0stty\0swapoff\0swapon\0symlink\0symlinkat\0sync\0" | ||
1368 | + "sync_file_range\0syncfs\0sys_kexec_load\0sysfs\0sysinfo\0syslog\0tee\0tgkill\0time\0timer_create\0" | ||
1369 | + "timer_delete\0timer_getoverrun\0timer_gettime\0timer_settime\0timerfd\0timerfd_gettime\0timerfd_settime\0times\0tkill\0truncate\0" | ||
1370 | + "truncate64\0ugetrlimit\0ulimit\0umask\0umount\0umount2\0uname\0unlink\0unlinkat\0unshare\0" | ||
1371 | + "uselib\0ustat\0utime\0utimensat\0utimes\0vfork\0vhangup\0vm86\0vm86old\0vmsplice\0" | ||
1372 | + "vserver\0wait4\0waitid\0waitpid\0write\0writev"; | ||
1373 | +static const unsigned i386_syscall_s2i_s[] = { | ||
1374 | + 0,8,19,27,34,39,47,56,68,74, | ||
1375 | + 82,88,92,99,106,112,118,124,132,139, | ||
1376 | + 153,166,180,196,210,216,222,228,242,256, | ||
1377 | + 260,265,270,283,297,307,319,330,338,347, | ||
1378 | + 354,359,370,380,390,403,413,427,441,448, | ||
1379 | + 455,464,471,480,489,495,503,513,523,534, | ||
1380 | + 540,545,558,568,574,582,592,600,610,616, | ||
1381 | + 622,632,644,650,660,676,690,706,722,729, | ||
1382 | + 736,745,756,764,774,782,792,799,808,818, | ||
1383 | + 830,840,848,856,863,871,879,891,901,913, | ||
1384 | + 923,935,945,955,962,969,982,989,998,1007, | ||
1385 | + 1012,1017,1029,1047,1060,1074,1091,1101,1112,1125, | ||
1386 | + 1134,1144,1150,1157,1162,1173,1184,1188,1195,1200, | ||
1387 | + 1207,1216,1226,1231,1238,1248,1259,1264,1279,1292, | ||
1388 | + 1298,1308,1314,1322,1330,1339,1345,1359,1367,1373, | ||
1389 | + 1381,1387,1395,1401,1410,1415,1421,1432,1438,1449, | ||
1390 | + 1458,1462,1476,1486,1494,1510,1523,1533,1540,1546, | ||
1391 | + 1554,1565,1572,1590,1600,1611,1616,1625,1634,1646, | ||
1392 | + 1654,1663,1668,1686,1693,1699,1715,1727,1732,1738, | ||
1393 | + 1749,1754,1760,1766,1774,1781,1791,1808,1826,1831, | ||
1394 | + 1838,1847,1854,1862,1871,1879,1892,1901,1906,1916, | ||
1395 | + 1924,1933,1944,1950,1957,1966,1983,1995,2002,2011, | ||
1396 | + 2023,2039,2045,2058,2072,2087,2103,2116,2130,2146, | ||
1397 | + 2164,2187,2210,2228,2243,2262,2284,2302,2317,2336, | ||
1398 | + 2348,2355,2364,2375,2384,2398,2414,2430,2446,2460, | ||
1399 | + 2469,2480,2489,2500,2507,2516,2526,2538,2550,2560, | ||
1400 | + 2566,2574,2586,2595,2606,2616,2628,2638,2650,2659, | ||
1401 | + 2670,2680,2687,2700,2707,2716,2725,2734,2744,2756, | ||
1402 | + 2763,2772,2782,2793,2805,2815,2826,2837,2844,2853, | ||
1403 | + 2858,2865,2872,2881,2887,2892,2900,2907,2915,2925, | ||
1404 | + 2930,2946,2953,2968,2974,2982,2989,2993,3000,3005, | ||
1405 | + 3018,3031,3048,3062,3076,3084,3100,3116,3122,3128, | ||
1406 | + 3137,3148,3159,3166,3172,3179,3187,3193,3200,3209, | ||
1407 | + 3217,3224,3230,3236,3246,3253,3259,3267,3272,3280, | ||
1408 | + 3289,3297,3303,3310,3318,3324, | ||
1409 | +}; | ||
1410 | +static const int i386_syscall_s2i_i[] = { | ||
1411 | + 140,142,149,33,51,286,124,137,27,134, | ||
1412 | + 17,45,184,185,12,15,182,212,61,343, | ||
1413 | + 266,265,267,264,120,6,8,127,129,41, | ||
1414 | + 63,330,254,329,255,319,256,323,328,11, | ||
1415 | + 1,252,307,250,272,324,338,339,133,94, | ||
1416 | + 306,95,207,298,55,221,148,231,234,143, | ||
1417 | + 2,237,228,108,197,300,100,269,118,35, | ||
1418 | + 93,194,240,299,130,275,312,244,318,183, | ||
1419 | + 141,220,50,202,49,201,47,200,80,205, | ||
1420 | + 105,132,65,20,188,64,96,171,211,165, | ||
1421 | + 209,76,77,147,224,78,24,199,229,32, | ||
1422 | + 112,128,292,291,332,293,249,246,247,245, | ||
1423 | + 248,54,101,110,290,289,117,288,37,16, | ||
1424 | + 198,230,9,303,232,233,53,253,236,19, | ||
1425 | + 227,107,196,219,219,274,294,218,39,296, | ||
1426 | + 14,297,150,152,90,192,123,21,317,125, | ||
1427 | + 56,282,281,277,280,279,278,163,144,151, | ||
1428 | + 153,91,341,162,169,34,28,84,59,18, | ||
1429 | + 109,5,342,295,29,336,136,42,331,217, | ||
1430 | + 168,309,172,180,333,340,347,348,44,98, | ||
1431 | + 308,26,189,181,334,167,131,3,225,89, | ||
1432 | + 85,305,145,88,337,257,235,38,302,287, | ||
1433 | + 0,40,174,176,175,178,173,179,177,335, | ||
1434 | + 159,160,242,155,157,161,241,154,156,158, | ||
1435 | + 82,187,239,345,276,311,243,258,121,139, | ||
1436 | + 216,138,215,46,214,81,206,74,104,346, | ||
1437 | + 57,97,71,204,170,210,164,208,70,203, | ||
1438 | + 75,66,79,23,213,226,68,67,186,48, | ||
1439 | + 321,327,73,126,119,72,102,313,69,106, | ||
1440 | + 195,99,268,25,31,115,87,83,304,36, | ||
1441 | + 314,344,283,135,116,103,315,270,13,259, | ||
1442 | + 263,262,261,260,322,326,325,43,238,92, | ||
1443 | + 193,191,58,60,22,52,122,10,301,310, | ||
1444 | + 86,62,30,320,271,190,111,166,113,316, | ||
1445 | + 273,114,284,7,4,146, | ||
1446 | +}; | ||
1447 | +static int i386_syscall_s2i(const char *s, int *value) { | ||
1448 | + size_t len, i; | ||
1449 | + len = strlen(s); | ||
1450 | + { char copy[len + 1]; | ||
1451 | + for (i = 0; i < len; i++) { | ||
1452 | + char c = s[i]; | ||
1453 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
1454 | + } | ||
1455 | + copy[i] = 0; | ||
1456 | + return s2i__(i386_syscall_strings, i386_syscall_s2i_s, i386_syscall_s2i_i, 346, copy, value); | ||
1457 | + } | ||
1458 | +} | ||
1459 | +static const unsigned i386_syscall_i2s_direct[] = { | ||
1460 | + 2023,354,540,1901,3318,1663,216,3310,222,1226, | ||
1461 | + 3193,347,106,3000,1381,112,1200,82,1646,1292, | ||
1462 | + 856,1432,3172,2700,982,2881,1847,68,1616,1693, | ||
1463 | + 3230,2887,1007,27,1611,616,2925,1195,1995,1367, | ||
1464 | + 2039,256,1727,3116,1826,88,2500,792,2756,774, | ||
1465 | + 756,34,3179,1259,1144,489,1458,2566,3159,1634, | ||
1466 | + 3166,132,3224,260,871,848,2680,2734,2725,2844, | ||
1467 | + 2650,2586,2815,2782,2538,2670,935,945,969,2687, | ||
1468 | + 808,2516,2348,2907,1625,1924,3217,2900,1950,1916, | ||
1469 | + 1410,1565,3128,622,448,464,879,2574,1831,2865, | ||
1470 | + 592,1150,2826,2982,2550,830,2853,1308,568,1654, | ||
1471 | + 1157,3259,1012,3272,3297,2892,2974,1184,610,2805, | ||
1472 | + 210,2446,3187,1421,47,1449,2793,228,1017,242, | ||
1473 | + 660,1892,840,441,74,2968,1715,56,2480,2460, | ||
1474 | + 0,736,8,534,1540,1944,3324,955,503,19, | ||
1475 | + 1395,1546,1401,1554,2302,2228,2317,2243,2336,2164, | ||
1476 | + 2187,2262,1590,1533,2628,913,3267,1879,1749,1600, | ||
1477 | + 2606,891,1760,2103,2045,2072,2058,2130,2087,2116, | ||
1478 | + 1766,1862,118,729,92,99,2744,2355,863,1854, | ||
1479 | + 3253,3148,1415,3137,632,2858,1314,574,1207,989, | ||
1480 | + 799,782,764,2659,2595,818,2526,471,2638,923, | ||
1481 | + 2616,901,124,2707,2507,2489,2469,1738,1359,1322, | ||
1482 | + 745,495,-1u,-1u,962,1906,2716,1298,558,998, | ||
1483 | + 1216,513,1238,1248,523,1983,1279,545,3122,2364, | ||
1484 | + 644,2284,2210,2414,706,1125,1101,1112,1134,1091, | ||
1485 | + 380,-1u,359,1264,270,297,319,1966,2430,3005, | ||
1486 | + 3062,3048,3031,3018,196,166,153,180,2872,600, | ||
1487 | + 2993,3246,390,3289,1339,676,2384,1486,1523,1510, | ||
1488 | + 1494,1476,1462,2953,3303,-1u,39,2011,1188,1173, | ||
1489 | + 1162,1047,1029,1074,1345,1686,1373,1387,480,650, | ||
1490 | + 582,3200,2002,1231,2915,1933,455,370,1838,1754, | ||
1491 | + 3209,2398,690,2837,2930,2989,3280,1438,722,307, | ||
1492 | + 3236,2763,3076,330,403,3100,3084,2772,338,283, | ||
1493 | + 265,1732,1060,1774,1871,2146,1699,1957,413,427, | ||
1494 | + 1781,1572,1668,139,2946,2375,2560,1791,1808, | ||
1495 | +}; | ||
1496 | +static const char *i386_syscall_i2s(int v) { | ||
1497 | + return i2s_direct__(i386_syscall_strings, i386_syscall_i2s_direct, 0, 348, v); | ||
1498 | +} | ||
1499 | diff --git a/lib/ia64_tables.h b/lib/ia64_tables.h | ||
1500 | new file mode 100644 | ||
1501 | index 0000000..504a90f | ||
1502 | --- /dev/null | ||
1503 | +++ b/lib/ia64_tables.h | ||
1504 | @@ -0,0 +1,147 @@ | ||
1505 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
1506 | +static const char ia64_syscall_strings[] = "_sysctl\0accept\0accept4\0access\0acct\0add_key\0adjtimex\0afs_syscall\0bdflush\0bind\0" | ||
1507 | + "brk\0capget\0capset\0chdir\0chmod\0chown\0chroot\0clock_adjtime\0clock_getres\0clock_gettime\0" | ||
1508 | + "clock_nanosleep\0clock_settime\0clone\0clone2\0close\0connect\0creat\0delete_module\0dup\0dup2\0" | ||
1509 | + "dup3\0epoll_create\0epoll_create1\0epoll_ctl\0epoll_pwait\0epoll_wait\0eventfd\0eventfd2\0execve\0exit\0" | ||
1510 | + "exit_group\0faccessat\0fadvise64\0fallocate\0fanotify_init\0fanotify_mark\0fchdir\0fchmod\0fchmodat\0fchown\0" | ||
1511 | + "fchownat\0fcntl\0fdatasync\0fgetxattr\0flistxattr\0flock\0fremovexattr\0fsetxattr\0fstat\0fstatfs\0" | ||
1512 | + "fstatfs64\0fsync\0ftruncate\0futex\0futimesat\0get_mempolicy\0get_robust_list\0getcpu\0getcwd\0getdents\0" | ||
1513 | + "getdents64\0getegid\0geteuid\0getgid\0getgroups\0getitimer\0getpeername\0getpgid\0getpid\0getpmsg\0" | ||
1514 | + "getppid\0getpriority\0getresgid\0getresuid\0getrlimit\0getrusage\0getsid\0getsockname\0getsockopt\0gettid\0" | ||
1515 | + "gettimeofday\0getuid\0getunwind\0getxattr\0init_module\0inotify_add_watch\0inotify_init\0inotify_init1\0inotify_rm_watch\0io_cancel\0" | ||
1516 | + "io_destroy\0io_getevents\0io_setup\0io_submit\0ioctl\0ioprio_get\0ioprio_set\0kexec_load\0keyctl\0kill\0" | ||
1517 | + "lchown\0lgetxattr\0link\0linkat\0listen\0listxattr\0llistxattr\0lookup_dcookie\0lremovexattr\0lseek\0" | ||
1518 | + "lsetxattr\0lstat\0madvise\0mbind\0migrate_pages\0mincore\0mkdir\0mkdirat\0mknod\0mknodat\0" | ||
1519 | + "mlock\0mlockall\0mmap\0mmap2\0mount\0mprotect\0mq_getsetattr\0mq_notify\0mq_open\0mq_timedreceive\0" | ||
1520 | + "mq_timedsend\0mq_unlink\0mremap\0msgctl\0msgget\0msgrcv\0msgsnd\0msync\0munlock\0munlockall\0" | ||
1521 | + "munmap\0name_to_handle_at\0nanosleep\0newfstatat\0nfsservctl\0ni_syscall\0open\0open_by_handle_at\0openat\0pciconfig_read\0" | ||
1522 | + "pciconfig_write\0perfmonctl\0personality\0pipe\0pipe2\0pivot_root\0poll\0ppoll\0prctl\0pread64\0" | ||
1523 | + "preadv\0prlimit64\0process_vm_readv\0process_vm_writev\0pselect\0ptrace\0putpmsg\0pwrite64\0pwritev\0quotactl\0" | ||
1524 | + "read\0readahead\0readlink\0readlinkat\0readv\0reboot\0recv\0recvfrom\0recvmmsg\0recvmsg\0" | ||
1525 | + "remap_file_pages\0removexattr\0rename\0renameat\0request_key\0restart_syscall\0rmdir\0rt_sigaction\0rt_sigpending\0rt_sigprocmask\0" | ||
1526 | + "rt_sigqueueinfo\0rt_sigreturn\0rt_sigsuspend\0rt_sigtimedwait\0rt_tgsigqueueinfo\0sched_get_priority_max\0sched_get_priority_min\0sched_getaffinity\0sched_getparam\0sched_getscheduler\0" | ||
1527 | + "sched_rr_get_interval\0sched_setaffinity\0sched_setparam\0sched_setscheduler\0sched_yield\0select\0semctl\0semget\0semop\0semtimedop\0" | ||
1528 | + "send\0sendfile\0sendmmsg\0sendmsg\0sendto\0set_mempolicy\0set_robust_list\0set_tid_address\0set_zone_reclaim\0setdomainname\0" | ||
1529 | + "setfsgid\0setfsuid\0setgid\0setgroups\0sethostname\0setitimer\0setns\0setpgid\0setpriority\0setregid\0" | ||
1530 | + "setresgid\0setresuid\0setreuid\0setrlimit\0setsid\0setsockopt\0settimeofday\0setuid\0setxattr\0shmat\0" | ||
1531 | + "shmctl\0shmdt\0shmget\0shutdown\0sigaltstack\0signalfd\0signalfd4\0socket\0socketpair\0splice\0" | ||
1532 | + "stat\0statfs\0statfs64\0swapoff\0swapon\0symlink\0symlinkat\0sync\0sync_file_range\0syncfs\0" | ||
1533 | + "sysfs\0sysinfo\0syslog\0tee\0tgkill\0timer_create\0timer_delete\0timer_getoverrun\0timer_gettime\0timer_settime\0" | ||
1534 | + "timerfd\0timerfd_create\0timerfd_gettime\0timerfd_settime\0times\0tkill\0truncate\0tux\0umask\0umount\0" | ||
1535 | + "uname\0unlink\0unlinkat\0unshare\0uselib\0ustat\0utimensat\0utimes\0vhangup\0vmsplice\0" | ||
1536 | + "vserver\0wait4\0waitid\0write\0writev"; | ||
1537 | +static const unsigned ia64_syscall_s2i_s[] = { | ||
1538 | + 0,8,15,23,30,35,43,52,64,72, | ||
1539 | + 77,81,88,95,101,107,113,120,134,147, | ||
1540 | + 161,177,191,197,204,210,218,224,238,242, | ||
1541 | + 247,252,265,279,289,301,312,320,329,336, | ||
1542 | + 341,352,362,372,382,396,410,417,424,433, | ||
1543 | + 440,449,455,465,475,486,492,505,515,521, | ||
1544 | + 529,539,545,555,561,571,585,601,608,615, | ||
1545 | + 624,635,643,651,658,668,678,690,698,705, | ||
1546 | + 713,721,733,743,753,763,773,780,792,803, | ||
1547 | + 810,823,830,840,849,861,879,892,906,923, | ||
1548 | + 933,944,957,966,976,982,993,1004,1015,1022, | ||
1549 | + 1027,1034,1044,1049,1056,1063,1073,1084,1099,1112, | ||
1550 | + 1118,1128,1134,1142,1148,1162,1170,1176,1184,1190, | ||
1551 | + 1198,1204,1213,1218,1224,1230,1239,1253,1263,1271, | ||
1552 | + 1287,1300,1310,1317,1324,1331,1338,1345,1351,1359, | ||
1553 | + 1370,1377,1395,1405,1416,1427,1438,1443,1461,1468, | ||
1554 | + 1483,1499,1510,1522,1527,1533,1544,1549,1555,1561, | ||
1555 | + 1569,1576,1586,1603,1621,1629,1636,1644,1653,1661, | ||
1556 | + 1670,1675,1685,1694,1705,1711,1718,1723,1732,1741, | ||
1557 | + 1749,1766,1778,1785,1794,1806,1822,1828,1841,1855, | ||
1558 | + 1870,1886,1899,1913,1929,1947,1970,1993,2011,2026, | ||
1559 | + 2045,2067,2085,2100,2119,2131,2138,2145,2152,2158, | ||
1560 | + 2169,2174,2183,2192,2200,2207,2221,2237,2253,2270, | ||
1561 | + 2284,2293,2302,2309,2319,2331,2341,2347,2355,2367, | ||
1562 | + 2376,2386,2396,2405,2415,2422,2433,2446,2453,2462, | ||
1563 | + 2468,2475,2481,2488,2497,2509,2518,2528,2535,2546, | ||
1564 | + 2553,2558,2565,2574,2582,2589,2597,2607,2612,2628, | ||
1565 | + 2635,2641,2649,2656,2660,2667,2680,2693,2710,2724, | ||
1566 | + 2738,2746,2761,2777,2793,2799,2805,2814,2818,2824, | ||
1567 | + 2831,2837,2844,2853,2861,2868,2874,2884,2891,2899, | ||
1568 | + 2908,2916,2922,2929,2935, | ||
1569 | +}; | ||
1570 | +static const int ia64_syscall_s2i_i[] = { | ||
1571 | + 1150,1194,1334,1049,1064,1271,1131,1141,1138,1191, | ||
1572 | + 1060,1185,1186,1034,1038,1039,1068,1328,1255,1254, | ||
1573 | + 1256,1253,1128,1213,1029,1192,1030,1134,1057,1070, | ||
1574 | + 1316,1243,1315,1244,1305,1245,1309,1314,1033,1025, | ||
1575 | + 1236,1293,1234,1303,1323,1324,1035,1099,1292,1100, | ||
1576 | + 1284,1066,1052,1222,1225,1145,1228,1219,1212,1104, | ||
1577 | + 1257,1051,1098,1230,1285,1260,1299,1304,1184,1144, | ||
1578 | + 1214,1063,1047,1062,1077,1119,1196,1079,1041,1188, | ||
1579 | + 1042,1101,1075,1073,1085,1086,1082,1195,1204,1105, | ||
1580 | + 1087,1046,1215,1220,1133,1278,1277,1318,1279,1242, | ||
1581 | + 1239,1240,1238,1241,1065,1275,1274,1268,1273,1053, | ||
1582 | + 1124,1221,1031,1289,1193,1223,1224,1237,1227,1040, | ||
1583 | + 1218,1211,1209,1259,1280,1208,1055,1282,1037,1283, | ||
1584 | + 1153,1154,1151,1172,1043,1155,1267,1266,1262,1265, | ||
1585 | + 1264,1263,1156,1112,1109,1111,1110,1157,1158,1159, | ||
1586 | + 1152,1326,1168,1286,1169,1024,1028,1327,1281,1173, | ||
1587 | + 1174,1175,1140,1058,1317,1207,1090,1295,1170,1148, | ||
1588 | + 1319,1325,1332,1333,1294,1048,1189,1149,1320,1137, | ||
1589 | + 1026,1216,1092,1291,1146,1096,1200,1201,1322,1206, | ||
1590 | + 1125,1226,1054,1288,1272,1246,1056,1177,1178,1179, | ||
1591 | + 1180,1181,1182,1183,1321,1165,1166,1232,1160,1162, | ||
1592 | + 1167,1231,1161,1163,1164,1089,1108,1106,1107,1247, | ||
1593 | + 1198,1187,1331,1205,1199,1261,1298,1233,1276,1129, | ||
1594 | + 1143,1142,1061,1078,1083,1118,1330,1080,1102,1072, | ||
1595 | + 1076,1074,1071,1084,1081,1203,1088,1045,1217,1114, | ||
1596 | + 1116,1115,1113,1202,1176,1307,1313,1190,1197,1297, | ||
1597 | + 1210,1103,1258,1095,1094,1091,1290,1050,1300,1329, | ||
1598 | + 1139,1127,1117,1301,1235,1248,1252,1251,1250,1249, | ||
1599 | + 1308,1310,1312,1311,1059,1229,1097,1120,1067,1044, | ||
1600 | + 1130,1032,1287,1296,1093,1069,1306,1036,1123,1302, | ||
1601 | + 1269,1126,1270,1027,1147, | ||
1602 | +}; | ||
1603 | +static int ia64_syscall_s2i(const char *s, int *value) { | ||
1604 | + size_t len, i; | ||
1605 | + len = strlen(s); | ||
1606 | + { char copy[len + 1]; | ||
1607 | + for (i = 0; i < len; i++) { | ||
1608 | + char c = s[i]; | ||
1609 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
1610 | + } | ||
1611 | + copy[i] = 0; | ||
1612 | + return s2i__(ia64_syscall_strings, ia64_syscall_s2i_s, ia64_syscall_s2i_i, 305, copy, value); | ||
1613 | + } | ||
1614 | +} | ||
1615 | +static const unsigned ia64_syscall_i2s_direct[] = { | ||
1616 | + 1427,336,1670,2929,1438,204,218,1044,2837,329, | ||
1617 | + 95,410,2884,1184,101,107,1112,698,713,1224, | ||
1618 | + 2824,2446,823,643,1629,23,2607,539,455,1022, | ||
1619 | + 1778,1170,1822,238,1522,2793,77,2302,651,635, | ||
1620 | + 30,976,449,2818,113,2868,242,2396,2367,743, | ||
1621 | + 2386,733,2376,658,2309,690,2347,2415,773,2319, | ||
1622 | + 2405,753,763,810,2433,2131,1544,2589,1685,2861, | ||
1623 | + 2582,2574,1711,2805,545,417,433,721,2355,2558, | ||
1624 | + 521,803,2145,2152,2138,1324,1338,1331,1317,2481, | ||
1625 | + 2462,2475,2468,2649,2331,668,2814,-1u,-1u,2891, | ||
1626 | + 1027,1749,2916,2641,191,2270,2831,43,-1u,849, | ||
1627 | + 224,-1u,-1u,1661,64,2635,1510,52,2293,2284, | ||
1628 | + 615,486,1705,2935,1561,1644,0,1213,1370,1198, | ||
1629 | + 1204,1230,1310,1345,1351,1359,2011,2085,2026,2100, | ||
1630 | + 2119,1947,1970,2045,1395,1416,1555,-1u,1218,1468, | ||
1631 | + 1483,1499,2497,1828,1841,1855,1870,1886,1899,1913, | ||
1632 | + 608,81,88,2174,705,1636,2528,72,210,1056, | ||
1633 | + 8,780,678,2535,2169,2200,1718,1723,2488,2422, | ||
1634 | + 792,2192,1741,1533,1162,1134,2553,1128,515,197, | ||
1635 | + 624,830,1675,2453,1118,505,840,1034,465,1063, | ||
1636 | + 1073,475,1766,1099,492,2799,555,2067,1993,2237, | ||
1637 | + 362,2660,341,1084,957,933,944,966,923,252, | ||
1638 | + 279,301,1806,2158,2667,2724,2710,2693,2680,177, | ||
1639 | + 147,134,161,529,2565,1142,571,2207,1263,1300, | ||
1640 | + 1287,1271,1253,1239,1004,2908,2922,35,1794,1015, | ||
1641 | + 993,982,2253,879,861,906,1148,1461,1176,1190, | ||
1642 | + 440,561,1405,2844,1785,1049,2597,1694,424,352, | ||
1643 | + 1621,1549,2853,2546,2221,585,2612,2656,2899,372, | ||
1644 | + 601,289,2874,2509,2738,312,2746,2777,2761,2518, | ||
1645 | + 320,265,247,1527,892,1569,1653,1929,1732,382, | ||
1646 | + 396,1576,1377,1443,120,2628,2341,2183,1586,1603, | ||
1647 | + 15, | ||
1648 | +}; | ||
1649 | +static const char *ia64_syscall_i2s(int v) { | ||
1650 | + return i2s_direct__(ia64_syscall_strings, ia64_syscall_i2s_direct, 1024, 1334, v); | ||
1651 | +} | ||
1652 | diff --git a/lib/machinetabs.h b/lib/machinetabs.h | ||
1653 | new file mode 100644 | ||
1654 | index 0000000..ec2d033 | ||
1655 | --- /dev/null | ||
1656 | +++ b/lib/machinetabs.h | ||
1657 | @@ -0,0 +1,26 @@ | ||
1658 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
1659 | +static const char machine_strings[] = "i386\0i486\0i586\0i686\0ia64\0ppc\0ppc64\0s390\0s390x\0x86_64"; | ||
1660 | +static const unsigned machine_s2i_s[] = { | ||
1661 | + 0,5,10,15,20,25,29,35,40,46, | ||
1662 | +}; | ||
1663 | +static const int machine_s2i_i[] = { | ||
1664 | + 0,0,0,0,2,4,3,6,5,1, | ||
1665 | +}; | ||
1666 | +static int machine_s2i(const char *s, int *value) { | ||
1667 | + size_t len, i; | ||
1668 | + len = strlen(s); | ||
1669 | + { char copy[len + 1]; | ||
1670 | + for (i = 0; i < len; i++) { | ||
1671 | + char c = s[i]; | ||
1672 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
1673 | + } | ||
1674 | + copy[i] = 0; | ||
1675 | + return s2i__(machine_strings, machine_s2i_s, machine_s2i_i, 10, copy, value); | ||
1676 | + } | ||
1677 | +} | ||
1678 | +static const unsigned machine_i2s_direct[] = { | ||
1679 | + 0,46,20,29,25,40,35, | ||
1680 | +}; | ||
1681 | +static const char *machine_i2s(int v) { | ||
1682 | + return i2s_direct__(machine_strings, machine_i2s_direct, 0, 6, v); | ||
1683 | +} | ||
1684 | diff --git a/lib/msg_typetabs.h b/lib/msg_typetabs.h | ||
1685 | new file mode 100644 | ||
1686 | index 0000000..d3f9b4d | ||
1687 | --- /dev/null | ||
1688 | +++ b/lib/msg_typetabs.h | ||
1689 | @@ -0,0 +1,99 @@ | ||
1690 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
1691 | +static const char msg_type_strings[] = "ADD_GROUP\0ADD_USER\0ANOM_ABEND\0ANOM_ACCESS_FS\0ANOM_ADD_ACCT\0ANOM_AMTU_FAIL\0ANOM_CRYPTO_FAIL\0ANOM_DEL_ACCT\0ANOM_EXEC\0ANOM_LOGIN_ACCT\0" | ||
1692 | + "ANOM_LOGIN_FAILURES\0ANOM_LOGIN_LOCATION\0ANOM_LOGIN_SESSIONS\0ANOM_LOGIN_TIME\0ANOM_MAX_DAC\0ANOM_MAX_MAC\0ANOM_MK_EXEC\0ANOM_MOD_ACCT\0ANOM_PROMISCUOUS\0ANOM_RBAC_FAIL\0" | ||
1693 | + "ANOM_RBAC_INTEGRITY_FAIL\0ANOM_ROOT_TRANS\0AVC\0AVC_PATH\0BPRM_FCAPS\0CAPSET\0CHGRP_ID\0CHUSER_ID\0CONFIG_CHANGE\0CRED_ACQ\0" | ||
1694 | + "CRED_DISP\0CRED_REFR\0CRYPTO_FAILURE_USER\0CRYPTO_KEY_USER\0CRYPTO_LOGIN\0CRYPTO_LOGOUT\0CRYPTO_PARAM_CHANGE_USER\0CRYPTO_REPLAY_USER\0CRYPTO_SESSION\0CRYPTO_TEST_USER\0" | ||
1695 | + "CWD\0DAC_CHECK\0DAEMON_ABORT\0DAEMON_ACCEPT\0DAEMON_CLOSE\0DAEMON_CONFIG\0DAEMON_END\0DAEMON_RESUME\0DAEMON_ROTATE\0DAEMON_START\0" | ||
1696 | + "DEL_GROUP\0DEL_USER\0DEV_ALLOC\0DEV_DEALLOC\0EOE\0EXECVE\0FD_PAIR\0FS_RELABEL\0GRP_AUTH\0INTEGRITY_DATA\0" | ||
1697 | + "INTEGRITY_HASH\0INTEGRITY_METADATA\0INTEGRITY_PCR\0INTEGRITY_RULE\0INTEGRITY_STATUS\0IPC\0IPC_SET_PERM\0KERNEL\0KERNEL_OTHER\0LABEL_LEVEL_CHANGE\0" | ||
1698 | + "LABEL_OVERRIDE\0LIST_RULES\0LOGIN\0MAC_CIPSOV4_ADD\0MAC_CIPSOV4_DEL\0MAC_CONFIG_CHANGE\0MAC_IPSEC_ADDSA\0MAC_IPSEC_ADDSPD\0MAC_IPSEC_DELSA\0MAC_IPSEC_DELSPD\0" | ||
1699 | + "MAC_IPSEC_EVENT\0MAC_MAP_ADD\0MAC_MAP_DEL\0MAC_POLICY_LOAD\0MAC_STATUS\0MAC_UNLBL_ALLOW\0MAC_UNLBL_STCADD\0MAC_UNLBL_STCDEL\0MMAP\0MQ_GETSETATTR\0" | ||
1700 | + "MQ_NOTIFY\0MQ_OPEN\0MQ_SENDRECV\0NETFILTER_CFG\0NETFILTER_PKT\0OBJ_PID\0PATH\0RESP_ACCT_LOCK\0RESP_ACCT_LOCK_TIMED\0RESP_ACCT_REMOTE\0" | ||
1701 | + "RESP_ACCT_UNLOCK_TIMED\0RESP_ALERT\0RESP_ANOMALY\0RESP_EXEC\0RESP_HALT\0RESP_KILL_PROC\0RESP_SEBOOL\0RESP_SINGLE\0RESP_TERM_ACCESS\0RESP_TERM_LOCK\0" | ||
1702 | + "ROLE_ASSIGN\0ROLE_MODIFY\0ROLE_REMOVE\0SELINUX_ERR\0SERVICE_START\0SERVICE_STOP\0SOCKADDR\0SOCKETCALL\0SYSCALL\0SYSTEM_BOOT\0" | ||
1703 | + "SYSTEM_RUNLEVEL\0SYSTEM_SHUTDOWN\0TEST\0TRUSTED_APP\0TTY\0TTY_GET\0TTY_SET\0USER\0USER_ACCT\0USER_AUTH\0" | ||
1704 | + "USER_AVC\0USER_CHAUTHTOK\0USER_CMD\0USER_END\0USER_ERR\0USER_LABELED_EXPORT\0USER_LOGIN\0USER_LOGOUT\0USER_MAC_POLICY_LOAD\0USER_MGMT\0" | ||
1705 | + "USER_ROLE_CHANGE\0USER_SELINUX_ERR\0USER_START\0USER_TTY\0USER_UNLABELED_EXPORT\0USYS_CONFIG\0VIRT_CONTROL\0VIRT_MACHINE_ID\0VIRT_RESOURCE"; | ||
1706 | +static const unsigned msg_type_s2i_s[] = { | ||
1707 | + 0,10,19,30,45,59,74,91,105,115, | ||
1708 | + 131,151,171,191,207,220,233,246,260,277, | ||
1709 | + 292,317,333,337,346,357,364,373,383,397, | ||
1710 | + 406,416,426,446,462,475,489,514,533,548, | ||
1711 | + 565,569,579,592,606,619,633,644,658,672, | ||
1712 | + 685,695,704,714,726,730,737,745,756,765, | ||
1713 | + 780,795,814,828,843,860,864,877,884,897, | ||
1714 | + 916,931,942,948,964,980,998,1014,1031,1047, | ||
1715 | + 1064,1080,1092,1104,1120,1131,1147,1164,1181,1186, | ||
1716 | + 1200,1210,1218,1230,1244,1258,1266,1271,1286,1307, | ||
1717 | + 1324,1347,1358,1371,1381,1391,1406,1418,1430,1447, | ||
1718 | + 1462,1474,1486,1498,1510,1524,1537,1546,1557,1565, | ||
1719 | + 1577,1593,1609,1614,1626,1630,1638,1646,1651,1661, | ||
1720 | + 1671,1680,1695,1704,1713,1722,1742,1753,1765,1786, | ||
1721 | + 1796,1813,1830,1841,1850,1872,1884,1897,1913, | ||
1722 | +}; | ||
1723 | +static const int msg_type_s2i_i[] = { | ||
1724 | + 1116,1114,1701,2111,2114,2107,2110,2115,2112,2103, | ||
1725 | + 2100,2104,2102,2101,2105,2106,2113,2116,1700,2108, | ||
1726 | + 2109,2117,1400,1402,1321,1322,1119,1125,1305,1103, | ||
1727 | + 1104,1110,2405,2404,2402,2403,2401,2406,2407,2400, | ||
1728 | + 1307,1118,1202,1207,1208,1203,1201,1206,1205,1200, | ||
1729 | + 1117,1115,2307,2308,1320,1309,1317,2309,1126,1800, | ||
1730 | + 1803,1801,1804,1805,1802,1303,1311,2000,1316,2304, | ||
1731 | + 2303,1013,1006,1407,1408,1405,1411,1413,1412,1414, | ||
1732 | + 1415,1409,1410,1403,1404,1406,1416,1417,1323,1315, | ||
1733 | + 1314,1312,1313,1325,1324,1318,1302,2207,2205,2204, | ||
1734 | + 2206,2201,2200,2210,2212,2202,2209,2211,2203,2208, | ||
1735 | + 2301,2311,2302,1401,1130,1131,1306,1304,1300,1127, | ||
1736 | + 1129,1128,1120,1121,1319,1016,1017,1005,1101,1100, | ||
1737 | + 1107,1108,1123,1106,1109,2305,1112,1113,2310,1102, | ||
1738 | + 2300,1122,1105,1124,2306,1111,2500,2502,2501, | ||
1739 | +}; | ||
1740 | +static int msg_type_s2i(const char *s, int *value) { | ||
1741 | + size_t len, i; | ||
1742 | + len = strlen(s); | ||
1743 | + { char copy[len + 1]; | ||
1744 | + for (i = 0; i < len; i++) { | ||
1745 | + char c = s[i]; | ||
1746 | + copy[i] = GT_ISLOWER(c) ? c - 'a' + 'A' : c; | ||
1747 | + } | ||
1748 | + copy[i] = 0; | ||
1749 | + return s2i__(msg_type_strings, msg_type_s2i_s, msg_type_s2i_i, 149, copy, value); | ||
1750 | + } | ||
1751 | +} | ||
1752 | +static const int msg_type_i2s_i[] = { | ||
1753 | + 1005,1006,1013,1016,1017,1100,1101,1102,1103,1104, | ||
1754 | + 1105,1106,1107,1108,1109,1110,1111,1112,1113,1114, | ||
1755 | + 1115,1116,1117,1118,1119,1120,1121,1122,1123,1124, | ||
1756 | + 1125,1126,1127,1128,1129,1130,1131,1200,1201,1202, | ||
1757 | + 1203,1205,1206,1207,1208,1300,1302,1303,1304,1305, | ||
1758 | + 1306,1307,1309,1311,1312,1313,1314,1315,1316,1317, | ||
1759 | + 1318,1319,1320,1321,1322,1323,1324,1325,1400,1401, | ||
1760 | + 1402,1403,1404,1405,1406,1407,1408,1409,1410,1411, | ||
1761 | + 1412,1413,1414,1415,1416,1417,1700,1701,1800,1801, | ||
1762 | + 1802,1803,1804,1805,2000,2100,2101,2102,2103,2104, | ||
1763 | + 2105,2106,2107,2108,2109,2110,2111,2112,2113,2114, | ||
1764 | + 2115,2116,2117,2200,2201,2202,2203,2204,2205,2206, | ||
1765 | + 2207,2208,2209,2210,2211,2212,2300,2301,2302,2303, | ||
1766 | + 2304,2305,2306,2307,2308,2309,2310,2311,2400,2401, | ||
1767 | + 2402,2403,2404,2405,2406,2407,2500,2501,2502, | ||
1768 | +}; | ||
1769 | +static const unsigned msg_type_i2s_s[] = { | ||
1770 | + 1646,942,931,1630,1638,1661,1651,1786,397,406, | ||
1771 | + 1830,1704,1671,1680,1713,416,1872,1742,1753,10, | ||
1772 | + 695,0,685,569,364,1609,1614,1813,1695,1841, | ||
1773 | + 373,756,1565,1593,1577,1510,1524,672,633,579, | ||
1774 | + 619,658,644,592,606,1557,1266,860,1546,383, | ||
1775 | + 1537,565,730,864,1210,1218,1200,1186,884,737, | ||
1776 | + 1258,1626,726,346,357,1181,1244,1230,333,1498, | ||
1777 | + 337,1104,1120,980,1131,948,964,1080,1092,998, | ||
1778 | + 1031,1014,1047,1064,1147,1164,260,19,765,795, | ||
1779 | + 843,780,814,828,877,131,191,171,115,151, | ||
1780 | + 207,220,59,277,292,74,30,105,233,45, | ||
1781 | + 91,246,317,1358,1347,1391,1430,1307,1286,1324, | ||
1782 | + 1271,1447,1406,1371,1418,1381,1796,1462,1486,916, | ||
1783 | + 897,1722,1850,704,714,745,1765,1474,548,489, | ||
1784 | + 462,475,446,426,514,533,1884,1913,1897, | ||
1785 | +}; | ||
1786 | +static const char *msg_type_i2s(int v) { | ||
1787 | + return i2s_bsearch__(msg_type_strings, msg_type_i2s_i, msg_type_i2s_s, 149, v); | ||
1788 | +} | ||
1789 | diff --git a/lib/optabs.h b/lib/optabs.h | ||
1790 | new file mode 100644 | ||
1791 | index 0000000..d79b665 | ||
1792 | --- /dev/null | ||
1793 | +++ b/lib/optabs.h | ||
1794 | @@ -0,0 +1,11 @@ | ||
1795 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
1796 | +static const char op_strings[] = "!=\0&\0&=\0<\0<=\0=\0>\0>="; | ||
1797 | +static const int op_i2s_i[] = { | ||
1798 | + 134217728,268435456,536870912,805306368,1073741824,1207959552,1342177280,1610612736, | ||
1799 | +}; | ||
1800 | +static const unsigned op_i2s_s[] = { | ||
1801 | + 3,8,15,0,13,5,10,17, | ||
1802 | +}; | ||
1803 | +static const char *op_i2s(int v) { | ||
1804 | + return i2s_bsearch__(op_strings, op_i2s_i, op_i2s_s, 8, v); | ||
1805 | +} | ||
1806 | diff --git a/lib/ppc_tables.h b/lib/ppc_tables.h | ||
1807 | new file mode 100644 | ||
1808 | index 0000000..f6346a8 | ||
1809 | --- /dev/null | ||
1810 | +++ b/lib/ppc_tables.h | ||
1811 | @@ -0,0 +1,163 @@ | ||
1812 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
1813 | +static const char ppc_syscall_strings[] = "_llseek\0_newselect\0_sysctl\0accept\0accept4\0access\0acct\0add_key\0adjtimex\0afs_syscall\0" | ||
1814 | + "alarm\0bdflush\0bind\0break\0brk\0capget\0capset\0chdir\0chmod\0chown\0" | ||
1815 | + "chroot\0clock_adjtime\0clock_getres\0clock_gettime\0clock_nanosleep\0clock_settime\0clone\0close\0connect\0creat\0" | ||
1816 | + "create_module\0delete_module\0dup\0dup2\0dup3\0epoll_create\0epoll_create1\0epoll_ctl\0epoll_pwait\0epoll_wait\0" | ||
1817 | + "eventfd\0eventfd2\0execve\0exit\0exit_group\0faccessat\0fadvise64\0fadvise64_64\0fallocate\0fanotify_init\0" | ||
1818 | + "fanotify_mark\0fchdir\0fchmod\0fchmodat\0fchown\0fchownat\0fcntl\0fcntl64\0fdatasync\0fgetxattr\0" | ||
1819 | + "flistxattr\0flock\0fork\0fremovexattr\0fsetxattr\0fstat\0fstat64\0fstatat\0fstatfs\0fstatfs64\0" | ||
1820 | + "fsync\0ftime\0ftruncate\0ftruncate64\0futex\0futimesat\0get_kernel_syms\0get_robust_list\0getcpu\0getcwd\0" | ||
1821 | + "getdents\0getdents64\0getegid\0geteuid\0getgid\0getgroups\0getitimer\0getpeername\0getpgid\0getpgrp\0" | ||
1822 | + "getpid\0getpmsg\0getppid\0getpriority\0getresgid\0getresuid\0getrlimit\0getrusage\0getsid\0getsockname\0" | ||
1823 | + "getsockopt\0gettid\0gettimeofday\0getuid\0getxattr\0gtty\0idle\0init_module\0inotify_add_watch\0inotify_init\0" | ||
1824 | + "inotify_init1\0inotify_rm_watch\0io_cancel\0io_destroy\0io_getevents\0io_setup\0io_submit\0ioctl\0ioperm\0iopl\0" | ||
1825 | + "ioprio_get\0ioprio_set\0ipc\0kexec_load\0keyctl\0kill\0lchown\0lgetxattr\0link\0linkat\0" | ||
1826 | + "listen\0listxattr\0llistxattr\0lock\0lookup_dcookie\0lremovexattr\0lseek\0lsetxattr\0lstat\0lstat64\0" | ||
1827 | + "madvise\0mincore\0mkdir\0mkdirat\0mknod\0mknodat\0mlock\0mlockall\0mmap\0mmap2\0" | ||
1828 | + "modify_ldt\0mount\0move_pages\0mprotect\0mpx\0mq_getsetattr\0mq_notify\0mq_open\0mq_timedreceive\0mq_timedsend\0" | ||
1829 | + "mq_unlink\0mremap\0msync\0multiplexer\0munlock\0munlockall\0munmap\0name_to_handle_at\0nanosleep\0nfsservctl\0" | ||
1830 | + "nice\0oldfstat\0oldlstat\0oldolduname\0oldstat\0olduname\0open\0open_by_handle_at\0openat\0pause\0" | ||
1831 | + "pciconfig_iobase\0pciconfig_read\0pciconfig_write\0perf_counter_open\0personality\0pipe\0pipe2\0pivot_root\0poll\0ppoll\0" | ||
1832 | + "prctl\0pread\0preadv\0prlimit64\0process_vm_readv\0process_vm_writev\0prof\0profil\0pselect6\0ptrace\0" | ||
1833 | + "putpmsg\0pwrite\0pwritev\0query_module\0quotactl\0read\0readahead\0readdir\0readlink\0readlinkat\0" | ||
1834 | + "readv\0reboot\0recv\0recvfrom\0recvmmsg\0recvmsg\0remap_file_pages\0removexattr\0rename\0renameat\0" | ||
1835 | + "request_key\0rmdir\0rt_sigaction\0rt_sigpending\0rt_sigprocmask\0rt_sigqueueinfo\0rt_sigreturn\0rt_sigsuspend\0rt_sigtimedwait\0rt_tgsigqueueinfo\0" | ||
1836 | + "rtas\0sched_get_priority_max\0sched_get_priority_min\0sched_getaffinity\0sched_getparam\0sched_getscheduler\0sched_rr_get_interval\0sched_setaffinity\0sched_setparam\0sched_setscheduler\0" | ||
1837 | + "sched_yield\0select\0send\0sendfile\0sendfile64\0sendmmsg\0sendmsg\0sendto\0set_robust_list\0set_tid_address\0" | ||
1838 | + "setdomainname\0setfsgid\0setfsuid\0setgid\0setgroups\0sethostname\0setitimer\0setns\0setpgid\0setpriority\0" | ||
1839 | + "setregid\0setresgid\0setresuid\0setreuid\0setrlimit\0setsid\0setsockopt\0settimeofday\0setuid\0setxattr\0" | ||
1840 | + "sgetmask\0shutdown\0sigaction\0sigaltstack\0signal\0signalfd\0signalfd4\0sigpending\0sigprocmask\0sigreturn\0" | ||
1841 | + "sigsuspend\0socket\0socketcall\0socketpair\0splice\0spu_create\0spu_run\0ssetmask\0stat\0stat64\0" | ||
1842 | + "statfs\0statfs64\0stime\0stty\0subpage_prot\0swapcontext\0swapoff\0swapon\0symlink\0symlinkat\0" | ||
1843 | + "sync\0sync_file_range2\0syncfs\0sysfs\0sysinfo\0syslog\0tee\0tgkill\0time\0timer_create\0" | ||
1844 | + "timer_delete\0timer_getoverrun\0timer_gettime\0timer_settime\0timerfd\0timerfd_gettime\0timerfd_settime\0times\0tkill\0truncate\0" | ||
1845 | + "truncate64\0tuxcall\0ugetrlimit\0ulimit\0umask\0umount\0umount2\0uname\0unlink\0unlinkat\0" | ||
1846 | + "unshare\0uselib\0ustat\0utime\0utimensat\0utimes\0vfork\0vhangup\0vm86\0vmsplice\0" | ||
1847 | + "wait4\0waitid\0waitpid\0write\0writev"; | ||
1848 | +static const unsigned ppc_syscall_s2i_s[] = { | ||
1849 | + 0,8,19,27,34,42,49,54,62,71, | ||
1850 | + 83,89,97,102,108,112,119,126,132,138, | ||
1851 | + 144,151,165,178,192,208,222,228,234,242, | ||
1852 | + 248,262,276,280,285,290,303,317,327,339, | ||
1853 | + 350,358,367,374,379,390,400,410,423,433, | ||
1854 | + 447,461,468,475,484,491,500,506,514,524, | ||
1855 | + 534,545,551,556,569,579,585,593,601,609, | ||
1856 | + 619,625,631,641,653,659,669,685,701,708, | ||
1857 | + 715,724,735,743,751,758,768,778,790,798, | ||
1858 | + 806,813,821,829,841,851,861,871,881,888, | ||
1859 | + 900,911,918,931,938,947,952,957,969,987, | ||
1860 | + 1000,1014,1031,1041,1052,1065,1074,1084,1090,1097, | ||
1861 | + 1102,1113,1124,1128,1139,1146,1151,1158,1168,1173, | ||
1862 | + 1180,1187,1197,1208,1213,1228,1241,1247,1257,1263, | ||
1863 | + 1271,1279,1287,1293,1301,1307,1315,1321,1330,1335, | ||
1864 | + 1341,1352,1358,1369,1378,1382,1396,1406,1414,1430, | ||
1865 | + 1443,1453,1460,1466,1478,1486,1497,1504,1522,1532, | ||
1866 | + 1543,1548,1557,1566,1578,1586,1595,1600,1618,1625, | ||
1867 | + 1631,1648,1663,1679,1697,1709,1714,1720,1731,1736, | ||
1868 | + 1742,1748,1754,1761,1771,1788,1806,1811,1818,1827, | ||
1869 | + 1834,1842,1849,1857,1870,1879,1884,1894,1902,1911, | ||
1870 | + 1922,1928,1935,1940,1949,1958,1966,1983,1995,2002, | ||
1871 | + 2011,2023,2029,2042,2056,2071,2087,2100,2114,2130, | ||
1872 | + 2148,2153,2176,2199,2217,2232,2251,2273,2291,2306, | ||
1873 | + 2325,2337,2344,2349,2358,2369,2378,2386,2393,2409, | ||
1874 | + 2425,2439,2448,2457,2464,2474,2486,2496,2502,2510, | ||
1875 | + 2522,2531,2541,2551,2560,2570,2577,2588,2601,2608, | ||
1876 | + 2617,2626,2635,2645,2657,2664,2673,2683,2694,2706, | ||
1877 | + 2716,2727,2734,2745,2756,2763,2774,2782,2791,2796, | ||
1878 | + 2803,2810,2819,2825,2830,2843,2855,2863,2870,2878, | ||
1879 | + 2888,2893,2910,2917,2923,2931,2938,2942,2949,2954, | ||
1880 | + 2967,2980,2997,3011,3025,3033,3049,3065,3071,3077, | ||
1881 | + 3086,3097,3105,3116,3123,3129,3136,3144,3150,3157, | ||
1882 | + 3166,3174,3181,3187,3193,3203,3210,3216,3224,3229, | ||
1883 | + 3238,3244,3251,3259,3265, | ||
1884 | +}; | ||
1885 | +static const int ppc_syscall_s2i_i[] = { | ||
1886 | + 140,142,149,330,344,33,51,269,124,137, | ||
1887 | + 27,134,327,17,45,183,184,12,15,181, | ||
1888 | + 61,347,247,246,248,245,120,6,328,8, | ||
1889 | + 127,129,41,63,316,236,315,237,303,238, | ||
1890 | + 307,314,11,1,234,298,233,254,309,323, | ||
1891 | + 324,133,94,297,95,289,55,204,148,214, | ||
1892 | + 217,143,2,220,211,108,197,291,100,253, | ||
1893 | + 118,35,93,194,221,290,130,299,302,182, | ||
1894 | + 141,202,50,49,47,80,105,332,132,65, | ||
1895 | + 20,187,64,96,170,165,76,77,147,331, | ||
1896 | + 340,207,78,24,212,32,112,128,276,275, | ||
1897 | + 318,277,231,228,229,227,230,54,101,110, | ||
1898 | + 274,273,117,268,271,37,16,213,9,294, | ||
1899 | + 329,215,216,53,235,219,19,210,107,196, | ||
1900 | + 205,206,39,287,14,288,150,152,90,192, | ||
1901 | + 123,21,301,125,56,267,266,262,265,264, | ||
1902 | + 263,163,144,201,151,153,91,345,162,168, | ||
1903 | + 34,28,84,59,18,109,5,346,286,29, | ||
1904 | + 200,198,199,319,136,42,317,203,167,281, | ||
1905 | + 171,179,320,325,351,352,44,98,280,26, | ||
1906 | + 188,180,321,166,131,3,191,89,85,296, | ||
1907 | + 145,88,336,337,343,342,239,218,38,293, | ||
1908 | + 270,40,173,175,174,177,172,178,176,322, | ||
1909 | + 255,159,160,223,155,157,161,222,154,156, | ||
1910 | + 158,82,334,186,226,349,341,335,300,232, | ||
1911 | + 121,139,138,46,81,74,104,350,57,97, | ||
1912 | + 71,169,164,70,75,66,339,79,23,209, | ||
1913 | + 68,338,67,185,48,305,313,73,126,119, | ||
1914 | + 72,326,102,333,283,279,278,69,106,195, | ||
1915 | + 99,252,25,31,310,249,115,87,83,295, | ||
1916 | + 36,308,348,135,116,103,284,250,13,240, | ||
1917 | + 244,243,242,241,306,312,311,43,208,92, | ||
1918 | + 193,225,190,58,60,22,52,122,10,292, | ||
1919 | + 282,86,62,30,304,251,189,111,113,285, | ||
1920 | + 114,272,7,4,146, | ||
1921 | +}; | ||
1922 | +static int ppc_syscall_s2i(const char *s, int *value) { | ||
1923 | + size_t len, i; | ||
1924 | + len = strlen(s); | ||
1925 | + { char copy[len + 1]; | ||
1926 | + for (i = 0; i < len; i++) { | ||
1927 | + char c = s[i]; | ||
1928 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
1929 | + } | ||
1930 | + copy[i] = 0; | ||
1931 | + return s2i__(ppc_syscall_strings, ppc_syscall_s2i_s, ppc_syscall_s2i_i, 345, copy, value); | ||
1932 | + } | ||
1933 | +} | ||
1934 | +static const unsigned ppc_syscall_i2s_direct[] = { | ||
1935 | + 374,551,1879,3259,1595,228,3251,242,1168,3150, | ||
1936 | + 367,126,2949,1301,132,1151,102,1578,1241,806, | ||
1937 | + 1352,3129,2601,931,2819,1827,83,1548,1625,3187, | ||
1938 | + 2825,947,42,1543,625,2888,1146,1995,1287,2023, | ||
1939 | + 276,1709,3065,1806,108,2457,751,2657,743,735, | ||
1940 | + 49,3136,1208,1084,500,1378,2502,3116,1566,3123, | ||
1941 | + 144,3181,280,821,798,2570,2635,2617,2782,2551, | ||
1942 | + 2522,2716,2683,2474,2560,861,871,918,2588,758, | ||
1943 | + 2464,2337,2870,1557,1902,3174,2863,1928,1894,1330, | ||
1944 | + 1497,3077,631,468,484,829,2510,1811,2803,601, | ||
1945 | + 1090,2734,2931,2486,768,2791,1257,579,1586,1097, | ||
1946 | + 3216,952,3224,3238,2855,2923,1124,619,2706,222, | ||
1947 | + 2425,3144,1341,62,1369,2694,248,957,262,669, | ||
1948 | + 1870,790,461,89,2917,1697,71,2448,2439,0, | ||
1949 | + 715,8,545,1460,1922,3265,881,514,19,1315, | ||
1950 | + 1478,1321,1486,2291,2217,2306,2232,2325,2153,2176, | ||
1951 | + 2251,1522,1453,2541,851,1857,1731,1532,2531,841, | ||
1952 | + 1742,2087,2029,2056,2042,2114,2071,2100,1748,1842, | ||
1953 | + 138,708,112,119,2645,2349,813,1834,3210,3105, | ||
1954 | + 1884,1335,3086,641,2796,1263,585,1648,1663,1631, | ||
1955 | + 1466,724,1720,506,1271,1279,911,3071,2608,1247, | ||
1956 | + 569,938,1158,524,1187,1197,534,1983,1228,556, | ||
1957 | + 653,2273,2199,-1u,3097,2358,1065,1041,1052,1074, | ||
1958 | + 1031,2409,400,379,1213,290,317,339,1966,2954, | ||
1959 | + 3011,2997,2980,2967,208,178,165,192,2843,2942, | ||
1960 | + 3203,2810,609,410,2148,-1u,-1u,-1u,-1u,-1u, | ||
1961 | + -1u,1406,1443,1430,1414,1396,1382,1128,54,2011, | ||
1962 | + 1139,3244,1113,1102,987,969,1014,2774,2763,1818, | ||
1963 | + 1736,3166,2756,2938,3229,1618,1293,1307,491,659, | ||
1964 | + 593,3157,2002,1173,2878,1911,475,390,685,2393, | ||
1965 | + 1358,701,327,3193,2664,3025,350,2893,423,2830, | ||
1966 | + 3049,3033,2673,358,303,285,1714,1000,1679,1754, | ||
1967 | + 1849,2130,433,447,1761,2727,97,234,1180,27, | ||
1968 | + 888,778,2745,2344,2386,1935,1940,2626,2577,900, | ||
1969 | + 2378,1958,1949,34,1504,1600,151,2910,2369,2496, | ||
1970 | + 1771,1788, | ||
1971 | +}; | ||
1972 | +static const char *ppc_syscall_i2s(int v) { | ||
1973 | + return i2s_direct__(ppc_syscall_strings, ppc_syscall_i2s_direct, 1, 352, v); | ||
1974 | +} | ||
1975 | diff --git a/lib/s390_tables.h b/lib/s390_tables.h | ||
1976 | new file mode 100644 | ||
1977 | index 0000000..09ad437 | ||
1978 | --- /dev/null | ||
1979 | +++ b/lib/s390_tables.h | ||
1980 | @@ -0,0 +1,153 @@ | ||
1981 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
1982 | +static const char s390_syscall_strings[] = "_llseek\0_newselect\0_sysctl\0access\0acct\0add_key\0adjtimex\0afs_syscall\0alarm\0bdflush\0" | ||
1983 | + "brk\0capget\0capset\0chdir\0chmod\0chown\0chown32\0chroot\0clock_adjtime\0clock_getres\0" | ||
1984 | + "clock_gettime\0clock_nanosleep\0clock_settime\0clone\0close\0creat\0create_module\0delete_module\0dup\0dup2\0" | ||
1985 | + "dup3\0epoll_create\0epoll_create1\0epoll_ctl\0epoll_pwait\0epoll_wait\0eventfd\0eventfd2\0execve\0exit\0" | ||
1986 | + "exit_group\0faccessat\0fadvise64\0fadvise64_64\0fallocate\0fanotify_init\0fanotify_mark\0fchdir\0fchmod\0fchmodat\0" | ||
1987 | + "fchown\0fchown32\0fchownat\0fcntl\0fcntl64\0fdatasync\0fgetxattr\0flistxattr\0flock\0fork\0" | ||
1988 | + "fremovexattr\0fsetxattr\0fstat\0fstat64\0fstatat\0fstatfs\0fstatfs64\0fsync\0ftruncate\0ftruncate64\0" | ||
1989 | + "futex\0futimesat\0get_kernel_syms\0get_robust_list\0getcpu\0getcwd\0getdents\0getdents64\0getegid\0getegid32\0" | ||
1990 | + "geteuid\0geteuid32\0getgid\0getgid32\0getgroups\0getgroups32\0getitimer\0getpgid\0getpgrp\0getpid\0" | ||
1991 | + "getpmsg\0getppid\0getpriority\0getresgid\0getresgid32\0getresuid\0getresuid32\0getrlimit\0getrusage\0getsid\0" | ||
1992 | + "gettid\0gettimeofday\0getuid\0getuid32\0getxattr\0idle\0init_module\0inotify_add_watch\0inotify_init\0inotify_init1\0" | ||
1993 | + "inotify_rm_watch\0io_cancel\0io_destroy\0io_getevents\0io_setup\0io_submit\0ioctl\0ioperm\0ioprio_get\0ioprio_set\0" | ||
1994 | + "ipc\0kexec_load\0keyctl\0kill\0lchown\0lchown32\0lgetxattr\0link\0linkat\0listxattr\0" | ||
1995 | + "llistxattr\0lremovexattr\0lseek\0lsetxattr\0lstat\0lstat64\0madvise\0mincore\0mkdir\0mkdirat\0" | ||
1996 | + "mknod\0mknodat\0mlock\0mlockall\0mmap\0mmap2\0mount\0mprotect\0mq_getsetattr\0mq_notify\0" | ||
1997 | + "mq_open\0mq_timedreceive\0mq_timedsend\0mq_unlink\0mremap\0msync\0munlock\0munlockall\0munmap\0name_to_handle_at\0" | ||
1998 | + "nanosleep\0nfsservctl\0nice\0open\0open_by_handle_at\0openat\0pause\0perf_event_open\0personality\0pipe\0" | ||
1999 | + "pipe2\0pivot_root\0poll\0ppoll\0prctl\0pread\0preadv\0prlimit64\0process_vm_readv\0process_vm_writev\0" | ||
2000 | + "pselect6\0ptrace\0putpmsg\0pwrite\0pwritev\0query_module\0quotactl\0read\0readahead\0readdir\0" | ||
2001 | + "readlink\0readlinkat\0readv\0reboot\0remap_file_pages\0removexattr\0rename\0renameat\0request_key\0rmdir\0" | ||
2002 | + "rt_sigaction\0rt_sigpending\0rt_sigprocmask\0rt_sigqueueinfo\0rt_sigreturn\0rt_sigsuspend\0rt_sigtimedwait\0rt_tgsigqueueinfo\0sched_get_priority_max\0sched_get_priority_min\0" | ||
2003 | + "sched_getaffinity\0sched_getparam\0sched_getscheduler\0sched_rr_get_interval\0sched_setaffinity\0sched_setparam\0sched_setscheduler\0sched_yield\0sendfile\0sendfile64\0" | ||
2004 | + "set_robust_list\0set_tid_address\0setdomainname\0setfsgid\0setfsgid32\0setfsuid\0setfsuid32\0setgid\0setgid32\0setgroups\0" | ||
2005 | + "setgroups32\0sethostname\0setitimer\0setns\0setpgid\0setpriority\0setregid\0setregid32\0setresgid\0setresgid32\0" | ||
2006 | + "setresuid\0setresuid32\0setreuid\0setreuid32\0setrlimit\0setsid\0settimeofday\0setuid\0setuid32\0setxattr\0" | ||
2007 | + "sigaction\0sigaltstack\0signal\0signalfd\0signalfd4\0sigpending\0sigprocmask\0sigreturn\0sigsuspend\0socketcall\0" | ||
2008 | + "splice\0stat\0stat64\0statfs\0statfs64\0stime\0swapoff\0swapon\0symlink\0symlinkat\0" | ||
2009 | + "sync\0sync_file_range\0syncfs\0sysfs\0sysinfo\0syslog\0tee\0tgkill\0time\0timer_create\0" | ||
2010 | + "timer_delete\0timer_getoverrun\0timer_gettime\0timer_settime\0timerfd\0timerfd_create\0timerfd_gettime\0timerfd_settime\0times\0tkill\0" | ||
2011 | + "truncate\0truncate64\0ugetrlimit\0umask\0umount\0umount2\0uname\0unlink\0unlinkat\0unshare\0" | ||
2012 | + "uselib\0ustat\0utime\0utimensat\0utimes\0vfork\0vhangup\0vmsplice\0wait4\0waitid\0" | ||
2013 | + "write\0writev"; | ||
2014 | +static const unsigned s390_syscall_s2i_s[] = { | ||
2015 | + 0,8,19,27,34,39,47,56,68,74, | ||
2016 | + 82,86,93,100,106,112,118,126,133,147, | ||
2017 | + 160,174,190,204,210,216,222,236,250,254, | ||
2018 | + 259,264,277,291,301,313,324,332,341,348, | ||
2019 | + 353,364,374,384,397,407,421,435,442,449, | ||
2020 | + 458,465,474,483,489,497,507,517,528,534, | ||
2021 | + 539,552,562,568,576,584,592,602,608,618, | ||
2022 | + 630,636,646,662,678,685,692,701,712,720, | ||
2023 | + 730,738,748,755,764,774,786,796,804,812, | ||
2024 | + 819,827,835,847,857,869,879,891,901,911, | ||
2025 | + 918,925,938,945,954,963,968,980,998,1011, | ||
2026 | + 1025,1042,1052,1063,1076,1085,1095,1101,1108,1119, | ||
2027 | + 1130,1134,1145,1152,1157,1164,1173,1183,1188,1195, | ||
2028 | + 1205,1216,1229,1235,1245,1251,1259,1267,1275,1281, | ||
2029 | + 1289,1295,1303,1309,1318,1323,1329,1335,1344,1358, | ||
2030 | + 1368,1376,1392,1405,1415,1422,1428,1436,1447,1454, | ||
2031 | + 1472,1482,1493,1498,1503,1521,1528,1534,1550,1562, | ||
2032 | + 1567,1573,1584,1589,1595,1601,1607,1614,1624,1641, | ||
2033 | + 1659,1668,1675,1683,1690,1698,1711,1720,1725,1735, | ||
2034 | + 1743,1752,1763,1769,1776,1793,1805,1812,1821,1833, | ||
2035 | + 1839,1852,1866,1881,1897,1910,1924,1940,1958,1981, | ||
2036 | + 2004,2022,2037,2056,2078,2096,2111,2130,2142,2151, | ||
2037 | + 2162,2178,2194,2208,2217,2228,2237,2248,2255,2264, | ||
2038 | + 2274,2286,2298,2308,2314,2322,2334,2343,2354,2364, | ||
2039 | + 2376,2386,2398,2407,2418,2428,2435,2448,2455,2464, | ||
2040 | + 2473,2483,2495,2502,2511,2521,2532,2544,2554,2565, | ||
2041 | + 2576,2583,2588,2595,2602,2611,2617,2625,2632,2640, | ||
2042 | + 2650,2655,2671,2678,2684,2692,2699,2703,2710,2715, | ||
2043 | + 2728,2741,2758,2772,2786,2794,2809,2825,2841,2847, | ||
2044 | + 2853,2862,2873,2884,2890,2897,2905,2911,2918,2927, | ||
2045 | + 2935,2942,2948,2954,2964,2971,2977,2985,2994,3000, | ||
2046 | + 3007,3013, | ||
2047 | +}; | ||
2048 | +static const int s390_syscall_s2i_i[] = { | ||
2049 | + 140,142,149,33,51,278,124,137,27,134, | ||
2050 | + 45,184,185,12,15,182,212,61,337,261, | ||
2051 | + 260,262,259,120,6,8,127,129,41,63, | ||
2052 | + 326,249,327,250,312,251,318,323,11,1, | ||
2053 | + 248,300,253,264,314,332,333,133,94,299, | ||
2054 | + 95,207,291,55,221,148,229,232,143,2, | ||
2055 | + 235,226,108,197,293,100,266,118,93,194, | ||
2056 | + 238,292,130,305,311,183,141,220,50,202, | ||
2057 | + 49,201,47,200,80,205,105,132,65,20, | ||
2058 | + 188,64,96,171,211,165,209,76,77,147, | ||
2059 | + 236,78,24,199,227,112,128,285,284,324, | ||
2060 | + 286,247,244,245,243,246,54,101,283,282, | ||
2061 | + 117,277,280,37,16,198,228,9,296,230, | ||
2062 | + 231,234,19,225,107,196,219,218,39,289, | ||
2063 | + 14,290,150,152,90,192,21,125,276,275, | ||
2064 | + 271,274,273,272,163,144,151,153,91,335, | ||
2065 | + 162,169,34,5,336,288,29,331,136,42, | ||
2066 | + 325,217,168,302,172,180,328,334,340,341, | ||
2067 | + 301,26,189,181,329,167,131,3,222,89, | ||
2068 | + 85,298,145,88,267,233,38,295,279,40, | ||
2069 | + 174,176,175,178,173,179,177,330,159,160, | ||
2070 | + 240,155,157,161,239,154,156,158,187,223, | ||
2071 | + 304,252,121,139,216,138,215,46,214,81, | ||
2072 | + 206,74,104,339,57,97,71,204,170,210, | ||
2073 | + 164,208,70,203,75,66,79,23,213,224, | ||
2074 | + 67,186,48,316,322,73,126,119,72,102, | ||
2075 | + 306,106,195,99,265,25,115,87,83,297, | ||
2076 | + 36,307,338,135,116,103,308,241,13,254, | ||
2077 | + 258,257,256,255,317,319,321,320,43,237, | ||
2078 | + 92,193,191,60,22,52,122,10,294,303, | ||
2079 | + 86,62,30,315,313,190,111,309,114,281, | ||
2080 | + 4,146, | ||
2081 | +}; | ||
2082 | +static int s390_syscall_s2i(const char *s, int *value) { | ||
2083 | + size_t len, i; | ||
2084 | + len = strlen(s); | ||
2085 | + { char copy[len + 1]; | ||
2086 | + for (i = 0; i < len; i++) { | ||
2087 | + char c = s[i]; | ||
2088 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
2089 | + } | ||
2090 | + copy[i] = 0; | ||
2091 | + return s2i__(s390_syscall_strings, s390_syscall_s2i_s, s390_syscall_s2i_i, 312, copy, value); | ||
2092 | + } | ||
2093 | +} | ||
2094 | +static const unsigned s390_syscall_i2s_direct[] = { | ||
2095 | + 348,534,1720,3007,1498,210,-1u,216,1183,2911, | ||
2096 | + 341,100,2710,1289,106,1157,-1u,-1u,1229,812, | ||
2097 | + 1329,2890,2448,938,2611,1668,68,-1u,1528,2948, | ||
2098 | + -1u,-1u,27,1493,-1u,2650,1152,1805,1275,1833, | ||
2099 | + 250,1562,2841,-1u,82,2248,748,2495,730,712, | ||
2100 | + 34,2897,-1u,1095,483,-1u,2314,-1u,-1u,2884, | ||
2101 | + 126,2942,254,827,804,2428,2473,-1u,-1u,2398, | ||
2102 | + 2334,2554,2521,2286,2418,891,901,925,2435,764, | ||
2103 | + 2264,-1u,2632,-1u,1743,2935,2625,1769,1735,1318, | ||
2104 | + 1447,2853,608,442,458,835,2322,-1u,2595,584, | ||
2105 | + 1101,2565,2692,2298,786,2583,1245,562,-1u,-1u, | ||
2106 | + 2977,963,-1u,2994,2617,2684,1130,602,2544,204, | ||
2107 | + 2194,2905,-1u,47,1335,2532,222,968,236,646, | ||
2108 | + 1711,796,435,74,2678,1550,56,2228,2208,0, | ||
2109 | + 692,8,528,1422,1763,3013,911,497,19,1303, | ||
2110 | + 1428,1309,1436,2096,2022,2111,2037,2130,1958,1981, | ||
2111 | + 2056,1472,1415,2376,869,-1u,1698,1584,1482,2354, | ||
2112 | + 847,1595,1897,1839,1866,1852,1924,1881,1910,1601, | ||
2113 | + 1683,112,685,86,93,2483,2142,819,1675,2971, | ||
2114 | + 2873,1323,2862,618,2588,1251,568,1164,945,755, | ||
2115 | + 738,720,2407,2343,774,2274,465,2386,879,2364, | ||
2116 | + 857,118,2455,2255,2237,2217,1573,1267,1259,701, | ||
2117 | + 489,1725,2151,2464,1235,552,954,1173,507,1195, | ||
2118 | + 1205,517,1793,1216,539,918,2847,630,2078,2004, | ||
2119 | + 2703,-1u,1076,1052,1063,1085,1042,353,264,291, | ||
2120 | + 313,2178,374,2715,2772,2758,2741,2728,190,160, | ||
2121 | + 147,174,-1u,384,2602,592,1776,-1u,-1u,-1u, | ||
2122 | + 1368,1405,1392,1376,1358,1344,1134,39,1821,1145, | ||
2123 | + 3000,1119,1108,998,980,1025,-1u,1521,1281,1295, | ||
2124 | + 474,636,576,2918,1812,1188,2640,1752,449,364, | ||
2125 | + 1659,1589,2927,2162,662,2576,2655,2699,2985,-1u, | ||
2126 | + 678,301,2964,397,2954,2502,2786,324,2794,2825, | ||
2127 | + 2809,2511,332,1011,1567,259,277,1607,1690,1940, | ||
2128 | + 1534,407,421,1614,1454,1503,133,2671,2308,1624, | ||
2129 | + 1641, | ||
2130 | +}; | ||
2131 | +static const char *s390_syscall_i2s(int v) { | ||
2132 | + return i2s_direct__(s390_syscall_strings, s390_syscall_i2s_direct, 1, 341, v); | ||
2133 | +} | ||
2134 | diff --git a/lib/s390x_tables.h b/lib/s390x_tables.h | ||
2135 | new file mode 100644 | ||
2136 | index 0000000..6e50cb7 | ||
2137 | --- /dev/null | ||
2138 | +++ b/lib/s390x_tables.h | ||
2139 | @@ -0,0 +1,141 @@ | ||
2140 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
2141 | +static const char s390x_syscall_strings[] = "_sysctl\0access\0acct\0add_key\0adjtimex\0afs_syscall\0alarm\0bdflush\0brk\0capget\0" | ||
2142 | + "capset\0chdir\0chmod\0chown\0chroot\0clock_adjtime\0clock_getres\0clock_gettime\0clock_nanosleep\0clock_settime\0" | ||
2143 | + "clone\0close\0creat\0create_module\0delete_module\0dup\0dup2\0dup3\0epoll_create\0epoll_create1\0" | ||
2144 | + "epoll_ctl\0epoll_pwait\0epoll_wait\0eventfd\0eventfd2\0execve\0exit\0exit_group\0faccessat\0fadvise64\0" | ||
2145 | + "fallocate\0fanotify_init\0fanotify_mark\0fchdir\0fchmod\0fchmodat\0fchown\0fchownat\0fcntl\0fdatasync\0" | ||
2146 | + "fgetxattr\0flistxattr\0flock\0fork\0fremovexattr\0fsetxattr\0fstat\0fstatfs\0fstatfs64\0fsync\0" | ||
2147 | + "ftruncate\0futex\0futimesat\0get_kernel_syms\0get_robust_list\0getcpu\0getcwd\0getdents\0getegid\0geteuid\0" | ||
2148 | + "getgid\0getgroups\0getitimer\0getpgid\0getpgrp\0getpid\0getpmsg\0getppid\0getpriority\0getresgid\0" | ||
2149 | + "getresuid\0getrlimit\0getrusage\0getsid\0gettid\0gettimeofday\0getuid\0getxattr\0idle\0init_module\0" | ||
2150 | + "inotify_add_watch\0inotify_init\0inotify_init1\0inotify_rm_watch\0io_cancel\0io_destroy\0io_getevents\0io_setup\0io_submit\0ioctl\0" | ||
2151 | + "ioprio_get\0ioprio_set\0ipc\0kexec_load\0keyctl\0kill\0lchown\0lgetxattr\0link\0linkat\0" | ||
2152 | + "listxattr\0llistxattr\0lremovexattr\0lseek\0lsetxattr\0lstat\0madvise\0mincore\0mkdir\0mkdirat\0" | ||
2153 | + "mknod\0mknodat\0mlock\0mlockall\0mmap\0mount\0mprotect\0mq_getsetattr\0mq_notify\0mq_open\0" | ||
2154 | + "mq_timedreceive\0mq_timedsend\0mq_unlink\0mremap\0msync\0munlock\0munlockall\0munmap\0name_to_handle_at\0nanosleep\0" | ||
2155 | + "newfstatat\0nfsservctl\0nice\0open\0open_by_handle_at\0openat\0pause\0perf_event_open\0personality\0pipe\0" | ||
2156 | + "pipe2\0pivot_root\0poll\0ppoll\0prctl\0pread\0preadv\0prlimit64\0process_vm_readv\0process_vm_writev\0" | ||
2157 | + "pselect6\0ptrace\0putpmsg\0pwrite\0pwritev\0query_module\0quotactl\0read\0readahead\0readdir\0" | ||
2158 | + "readlink\0readlinkat\0readv\0reboot\0remap_file_pages\0removexattr\0rename\0renameat\0request_key\0rmdir\0" | ||
2159 | + "rt_sigaction\0rt_sigpending\0rt_sigprocmask\0rt_sigqueueinfo\0rt_sigreturn\0rt_sigsuspend\0rt_sigtimedwait\0rt_tgsigqueueinfo\0sched_get_priority_max\0sched_get_priority_min\0" | ||
2160 | + "sched_getaffinity\0sched_getparam\0sched_getscheduler\0sched_rr_get_interval\0sched_setaffinity\0sched_setparam\0sched_setscheduler\0sched_yield\0select\0sendfile\0" | ||
2161 | + "set_robust_list\0set_tid_address\0setdomainname\0setfsgid\0setfsuid\0setgid\0setgroups\0sethostname\0setitimer\0setns\0" | ||
2162 | + "setpgid\0setpriority\0setregid\0setresgid\0setresuid\0setreuid\0setrlimit\0setsid\0settimeofday\0setuid\0" | ||
2163 | + "setxattr\0sigaction\0sigaltstack\0signal\0signalfd\0signalfd4\0sigpending\0sigprocmask\0sigreturn\0sigsuspend\0" | ||
2164 | + "socketcall\0splice\0stat\0statfs\0statfs64\0swapoff\0swapon\0symlink\0symlinkat\0sync\0" | ||
2165 | + "sync_file_range\0syncfs\0sysfs\0sysinfo\0syslog\0tee\0tgkill\0timer_create\0timer_delete\0timer_getoverrun\0" | ||
2166 | + "timer_gettime\0timer_settime\0timerfd\0timerfd_create\0timerfd_gettime\0timerfd_settime\0times\0tkill\0truncate\0umask\0" | ||
2167 | + "umount\0umount2\0uname\0unlink\0unlinkat\0unshare\0uselib\0ustat\0utime\0utimensat\0" | ||
2168 | + "utimes\0vfork\0vhangup\0vmsplice\0wait4\0waitid\0write\0writev"; | ||
2169 | +static const unsigned s390x_syscall_s2i_s[] = { | ||
2170 | + 0,8,15,20,28,37,49,55,63,67, | ||
2171 | + 74,81,87,93,99,106,120,133,147,163, | ||
2172 | + 177,183,189,195,209,223,227,232,237,250, | ||
2173 | + 264,274,286,297,305,314,321,326,337,347, | ||
2174 | + 357,367,381,395,402,409,418,425,434,440, | ||
2175 | + 450,460,471,477,482,495,505,511,519,529, | ||
2176 | + 535,545,551,561,577,593,600,607,616,624, | ||
2177 | + 632,639,649,659,667,675,682,690,698,710, | ||
2178 | + 720,730,740,750,757,764,777,784,793,798, | ||
2179 | + 810,828,841,855,872,882,893,906,915,925, | ||
2180 | + 931,942,953,957,968,975,980,987,997,1002, | ||
2181 | + 1009,1019,1030,1043,1049,1059,1065,1073,1081,1087, | ||
2182 | + 1095,1101,1109,1115,1124,1129,1135,1144,1158,1168, | ||
2183 | + 1176,1192,1205,1215,1222,1228,1236,1247,1254,1272, | ||
2184 | + 1282,1293,1304,1309,1314,1332,1339,1345,1361,1373, | ||
2185 | + 1378,1384,1395,1400,1406,1412,1418,1425,1435,1452, | ||
2186 | + 1470,1479,1486,1494,1501,1509,1522,1531,1536,1546, | ||
2187 | + 1554,1563,1574,1580,1587,1604,1616,1623,1632,1644, | ||
2188 | + 1650,1663,1677,1692,1708,1721,1735,1751,1769,1792, | ||
2189 | + 1815,1833,1848,1867,1889,1907,1922,1941,1953,1960, | ||
2190 | + 1969,1985,2001,2015,2024,2033,2040,2050,2062,2072, | ||
2191 | + 2078,2086,2098,2107,2117,2127,2136,2146,2153,2166, | ||
2192 | + 2173,2182,2192,2204,2211,2220,2230,2241,2253,2263, | ||
2193 | + 2274,2285,2292,2297,2304,2313,2321,2328,2336,2346, | ||
2194 | + 2351,2367,2374,2380,2388,2395,2399,2406,2419,2432, | ||
2195 | + 2449,2463,2477,2485,2500,2516,2532,2538,2544,2553, | ||
2196 | + 2559,2566,2574,2580,2587,2596,2604,2611,2617,2623, | ||
2197 | + 2633,2640,2646,2654,2663,2669,2676,2682, | ||
2198 | +}; | ||
2199 | +static const int s390x_syscall_s2i_i[] = { | ||
2200 | + 149,33,51,278,124,137,27,134,45,184, | ||
2201 | + 185,12,15,212,61,337,261,260,262,259, | ||
2202 | + 120,6,8,127,129,41,63,326,249,327, | ||
2203 | + 250,312,251,318,323,11,1,248,300,253, | ||
2204 | + 314,332,333,133,94,299,207,291,55,148, | ||
2205 | + 229,232,143,2,235,226,108,100,266,118, | ||
2206 | + 93,238,292,130,305,311,183,141,202,201, | ||
2207 | + 200,205,105,132,65,20,188,64,96,211, | ||
2208 | + 209,191,77,147,236,78,199,227,112,128, | ||
2209 | + 285,284,324,286,247,244,245,243,246,54, | ||
2210 | + 283,282,117,277,280,37,198,228,9,296, | ||
2211 | + 230,231,234,19,225,107,219,218,39,289, | ||
2212 | + 14,290,150,152,90,21,125,276,275,271, | ||
2213 | + 274,273,272,163,144,151,153,91,335,162, | ||
2214 | + 293,169,34,5,336,288,29,331,136,42, | ||
2215 | + 325,217,168,302,172,180,328,334,340,341, | ||
2216 | + 301,26,189,181,329,167,131,3,222,89, | ||
2217 | + 85,298,145,88,267,233,38,295,279,40, | ||
2218 | + 174,176,175,178,173,179,177,330,159,160, | ||
2219 | + 240,155,157,161,239,154,156,158,142,187, | ||
2220 | + 304,252,121,216,215,214,206,74,104,339, | ||
2221 | + 57,97,204,210,208,203,75,66,79,213, | ||
2222 | + 224,67,186,48,316,322,73,126,119,72, | ||
2223 | + 102,306,106,99,265,115,87,83,297,36, | ||
2224 | + 307,338,135,116,103,308,241,254,258,257, | ||
2225 | + 256,255,317,319,321,320,43,237,92,60, | ||
2226 | + 22,52,122,10,294,303,86,62,30,315, | ||
2227 | + 313,190,111,309,114,281,4,146, | ||
2228 | +}; | ||
2229 | +static int s390x_syscall_s2i(const char *s, int *value) { | ||
2230 | + size_t len, i; | ||
2231 | + len = strlen(s); | ||
2232 | + { char copy[len + 1]; | ||
2233 | + for (i = 0; i < len; i++) { | ||
2234 | + char c = s[i]; | ||
2235 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
2236 | + } | ||
2237 | + copy[i] = 0; | ||
2238 | + return s2i__(s390x_syscall_strings, s390x_syscall_s2i_s, s390x_syscall_s2i_i, 278, copy, value); | ||
2239 | + } | ||
2240 | +} | ||
2241 | +static const unsigned s390x_syscall_i2s_direct[] = { | ||
2242 | + 321,477,1531,2676,1309,183,-1u,189,997,2580, | ||
2243 | + 314,81,-1u,1095,87,-1u,-1u,-1u,1043,675, | ||
2244 | + 1129,2559,-1u,-1u,-1u,1479,49,-1u,1339,2617, | ||
2245 | + -1u,-1u,8,1304,-1u,2346,975,1616,1081,1644, | ||
2246 | + 223,1373,2532,-1u,63,-1u,-1u,2204,-1u,-1u, | ||
2247 | + 15,2566,-1u,925,434,-1u,2078,-1u,-1u,2553, | ||
2248 | + 99,2611,227,690,667,2146,2182,-1u,-1u,-1u, | ||
2249 | + -1u,2263,2230,2050,2136,-1u,740,764,2153,-1u, | ||
2250 | + -1u,-1u,2328,-1u,1554,2604,2321,1580,1546,1124, | ||
2251 | + 1247,2544,535,402,-1u,698,2086,-1u,2297,511, | ||
2252 | + -1u,2274,2388,2062,649,2292,1059,505,-1u,-1u, | ||
2253 | + 2646,793,-1u,2663,2313,2380,953,529,2253,177, | ||
2254 | + 2001,2574,-1u,28,1135,2241,195,798,209,561, | ||
2255 | + 1522,659,395,55,2374,1361,37,-1u,-1u,-1u, | ||
2256 | + 607,1953,471,1222,1574,2682,750,440,0,1109, | ||
2257 | + 1228,1115,1236,1907,1833,1922,1848,1941,1769,1792, | ||
2258 | + 1867,1272,1215,-1u,-1u,-1u,1509,1395,1293,-1u, | ||
2259 | + -1u,1406,1708,1650,1677,1663,1735,1692,1721,1412, | ||
2260 | + 1494,-1u,600,67,74,2192,1960,682,1486,2640, | ||
2261 | + 730,-1u,-1u,-1u,-1u,-1u,-1u,980,777,632, | ||
2262 | + 624,616,2127,2098,639,2040,418,2117,720,2107, | ||
2263 | + 710,93,2166,2033,2024,2015,1384,1073,1065,-1u, | ||
2264 | + -1u,1536,-1u,2173,1049,495,784,987,450,1009, | ||
2265 | + 1019,460,1604,1030,482,757,2538,545,1889,1815, | ||
2266 | + 2399,-1u,906,882,893,915,872,326,237,264, | ||
2267 | + 286,1985,347,2406,2463,2449,2432,2419,163,133, | ||
2268 | + 120,147,-1u,-1u,2304,519,1587,-1u,-1u,-1u, | ||
2269 | + 1168,1205,1192,1176,1158,1144,957,20,1632,968, | ||
2270 | + 2669,942,931,828,810,855,-1u,1332,1087,1101, | ||
2271 | + 425,551,1282,2587,1623,1002,2336,1563,409,337, | ||
2272 | + 1470,1400,2596,1969,577,2285,2351,2395,2654,-1u, | ||
2273 | + 593,274,2633,357,2623,2211,2477,297,2485,2516, | ||
2274 | + 2500,2220,305,841,1378,232,250,1418,1501,1751, | ||
2275 | + 1345,367,381,1425,1254,1314,106,2367,2072,1435, | ||
2276 | + 1452, | ||
2277 | +}; | ||
2278 | +static const char *s390x_syscall_i2s(int v) { | ||
2279 | + return i2s_direct__(s390x_syscall_strings, s390x_syscall_i2s_direct, 1, 341, v); | ||
2280 | +} | ||
2281 | diff --git a/lib/x86_64_tables.h b/lib/x86_64_tables.h | ||
2282 | new file mode 100644 | ||
2283 | index 0000000..15fb26b | ||
2284 | --- /dev/null | ||
2285 | +++ b/lib/x86_64_tables.h | ||
2286 | @@ -0,0 +1,150 @@ | ||
2287 | +/* This is a generated file, see Makefile.am for its inputs. */ | ||
2288 | +static const char x86_64_syscall_strings[] = "_sysctl\0accept\0accept4\0access\0acct\0add_key\0adjtimex\0afs_syscall\0alarm\0arch_prctl\0" | ||
2289 | + "bind\0brk\0capget\0capset\0chdir\0chmod\0chown\0chroot\0clock_adjtime\0clock_getres\0" | ||
2290 | + "clock_gettime\0clock_nanosleep\0clock_settime\0clone\0close\0connect\0creat\0create_module\0delete_module\0dup\0" | ||
2291 | + "dup2\0dup3\0epoll_create\0epoll_create1\0epoll_ctl\0epoll_ctl_old\0epoll_pwait\0epoll_wait\0epoll_wait_old\0eventfd\0" | ||
2292 | + "eventfd2\0execve\0exit\0exit_group\0faccessat\0fadvise64\0fallocate\0fanotify_init\0fanotify_mark\0fchdir\0" | ||
2293 | + "fchmod\0fchmodat\0fchown\0fchownat\0fcntl\0fdatasync\0fgetxattr\0flistxattr\0flock\0fork\0" | ||
2294 | + "fremovexattr\0fsetxattr\0fstat\0fstatfs\0fsync\0ftruncate\0futex\0futimesat\0get_kernel_syms\0get_mempolicy\0" | ||
2295 | + "get_robust_list\0get_thread_area\0getcpu\0getcwd\0getdents\0getdents64\0getegid\0geteuid\0getgid\0getgroups\0" | ||
2296 | + "getitimer\0getpeername\0getpgid\0getpgrp\0getpid\0getpmsg\0getppid\0getpriority\0getresgid\0getresuid\0" | ||
2297 | + "getrlimit\0getrusage\0getsid\0getsockname\0getsockopt\0gettid\0gettimeofday\0getuid\0getxattr\0init_module\0" | ||
2298 | + "inotify_add_watch\0inotify_init\0inotify_init1\0inotify_rm_watch\0io_cancel\0io_destroy\0io_getevents\0io_setup\0io_submit\0ioctl\0" | ||
2299 | + "ioperm\0iopl\0ioprio_get\0ioprio_set\0kexec_load\0keyctl\0kill\0lchown\0lgetxattr\0link\0" | ||
2300 | + "linkat\0listen\0listxattr\0llistxattr\0lookup_dcookie\0lremovexattr\0lseek\0lsetxattr\0lstat\0madvise\0" | ||
2301 | + "mbind\0migrate_pages\0mincore\0mkdir\0mkdirat\0mknod\0mknodat\0mlock\0mlockall\0mmap\0" | ||
2302 | + "modify_ldt\0mount\0move_pages\0mprotect\0mq_getsetattr\0mq_notify\0mq_open\0mq_timedreceive\0mq_timedsend\0mq_unlink\0" | ||
2303 | + "mremap\0msgctl\0msgget\0msgrcv\0msgsnd\0msync\0munlock\0munlockall\0munmap\0name_to_handle_at\0" | ||
2304 | + "nanosleep\0newfstatat\0nfsservctl\0open\0open_by_handle_at\0openat\0pause\0perf_event_open\0personality\0pipe\0" | ||
2305 | + "pipe2\0pivot_root\0poll\0ppoll\0prctl\0pread\0preadv\0prlimit64\0process_vm_readv\0process_vm_writev\0" | ||
2306 | + "pselect6\0ptrace\0putpmsg\0pwrite\0pwritev\0query_module\0quotactl\0read\0readahead\0readlink\0" | ||
2307 | + "readlinkat\0readv\0reboot\0recvfrom\0recvmmsg\0recvmsg\0remap_file_pages\0removexattr\0rename\0renameat\0" | ||
2308 | + "request_key\0restart_syscall\0rmdir\0rt_sigaction\0rt_sigpending\0rt_sigprocmask\0rt_sigqueueinfo\0rt_sigreturn\0rt_sigsuspend\0rt_sigtimedwait\0" | ||
2309 | + "rt_tgsigqueueinfo\0sched_get_priority_max\0sched_get_priority_min\0sched_getaffinity\0sched_getparam\0sched_getscheduler\0sched_rr_get_interval\0sched_setaffinity\0sched_setparam\0sched_setscheduler\0" | ||
2310 | + "sched_yield\0security\0select\0semctl\0semget\0semop\0semtimedop\0sendfile\0sendmmsg\0sendmsg\0" | ||
2311 | + "sendto\0set_mempolicy\0set_robust_list\0set_thread_area\0set_tid_address\0setdomainname\0setfsgid\0setfsuid\0setgid\0setgroups\0" | ||
2312 | + "sethostname\0setitimer\0setns\0setpgid\0setpriority\0setregid\0setresgid\0setresuid\0setreuid\0setrlimit\0" | ||
2313 | + "setsid\0setsockopt\0settimeofday\0setuid\0setxattr\0shmat\0shmctl\0shmdt\0shmget\0shutdown\0" | ||
2314 | + "sigaltstack\0signalfd\0signalfd4\0socket\0socketpair\0splice\0stat\0statfs\0swapoff\0swapon\0" | ||
2315 | + "symlink\0symlinkat\0sync\0sync_file_range\0syncfs\0sysfs\0sysinfo\0syslog\0tee\0tgkill\0" | ||
2316 | + "time\0timer_create\0timer_delete\0timer_getoverrun\0timer_gettime\0timer_settime\0timerfd\0timerfd_gettime\0timerfd_settime\0times\0" | ||
2317 | + "tkill\0truncate\0tuxcall\0umask\0umount2\0uname\0unlink\0unlinkat\0unshare\0uselib\0" | ||
2318 | + "ustat\0utime\0utimensat\0utimes\0vfork\0vhangup\0vmsplice\0vserver\0wait4\0waitid\0" | ||
2319 | + "write\0writev"; | ||
2320 | +static const unsigned x86_64_syscall_s2i_s[] = { | ||
2321 | + 0,8,15,23,30,35,43,52,64,70, | ||
2322 | + 81,86,90,97,104,110,116,122,129,143, | ||
2323 | + 156,170,186,200,206,212,220,226,240,254, | ||
2324 | + 258,263,268,281,295,305,319,331,342,357, | ||
2325 | + 365,374,381,386,397,407,417,427,441,455, | ||
2326 | + 462,469,478,485,494,500,510,520,531,537, | ||
2327 | + 542,555,565,571,579,585,595,601,611,627, | ||
2328 | + 641,657,673,680,687,696,707,715,723,730, | ||
2329 | + 740,750,762,770,778,785,793,801,813,823, | ||
2330 | + 833,843,853,860,872,883,890,903,910,919, | ||
2331 | + 931,949,962,976,993,1003,1014,1027,1036,1046, | ||
2332 | + 1052,1059,1064,1075,1086,1097,1104,1109,1116,1126, | ||
2333 | + 1131,1138,1145,1155,1166,1181,1194,1200,1210,1216, | ||
2334 | + 1224,1230,1244,1252,1258,1266,1272,1280,1286,1295, | ||
2335 | + 1300,1311,1317,1328,1337,1351,1361,1369,1385,1398, | ||
2336 | + 1408,1415,1422,1429,1436,1443,1449,1457,1468,1475, | ||
2337 | + 1493,1503,1514,1525,1530,1548,1555,1561,1577,1589, | ||
2338 | + 1594,1600,1611,1616,1622,1628,1634,1641,1651,1668, | ||
2339 | + 1686,1695,1702,1710,1717,1725,1738,1747,1752,1762, | ||
2340 | + 1771,1782,1788,1795,1804,1813,1821,1838,1850,1857, | ||
2341 | + 1866,1878,1894,1900,1913,1927,1942,1958,1971,1985, | ||
2342 | + 2001,2019,2042,2065,2083,2098,2117,2139,2157,2172, | ||
2343 | + 2191,2203,2212,2219,2226,2233,2239,2250,2259,2268, | ||
2344 | + 2276,2283,2297,2313,2329,2345,2359,2368,2377,2384, | ||
2345 | + 2394,2406,2416,2422,2430,2442,2451,2461,2471,2480, | ||
2346 | + 2490,2497,2508,2521,2528,2537,2543,2550,2556,2563, | ||
2347 | + 2572,2584,2593,2603,2610,2621,2628,2633,2640,2648, | ||
2348 | + 2655,2663,2673,2678,2694,2701,2707,2715,2722,2726, | ||
2349 | + 2733,2738,2751,2764,2781,2795,2809,2817,2833,2849, | ||
2350 | + 2855,2861,2870,2878,2884,2892,2898,2905,2914,2922, | ||
2351 | + 2929,2935,2941,2951,2958,2964,2972,2981,2989,2995, | ||
2352 | + 3002,3008, | ||
2353 | +}; | ||
2354 | +static const int x86_64_syscall_s2i_i[] = { | ||
2355 | + 156,43,288,21,163,248,159,183,37,158, | ||
2356 | + 49,12,125,126,80,90,92,161,305,229, | ||
2357 | + 228,230,227,56,3,42,85,174,176,32, | ||
2358 | + 33,292,213,291,233,214,281,232,215,284, | ||
2359 | + 290,59,60,231,269,221,285,300,301,81, | ||
2360 | + 91,268,93,260,72,75,193,196,73,57, | ||
2361 | + 199,190,5,138,74,77,202,261,177,239, | ||
2362 | + 274,211,309,79,78,217,108,107,104,115, | ||
2363 | + 36,52,121,111,39,181,110,140,120,118, | ||
2364 | + 97,98,124,51,55,186,96,102,191,175, | ||
2365 | + 254,253,294,255,210,207,208,206,209,16, | ||
2366 | + 173,172,252,251,246,250,62,94,192,86, | ||
2367 | + 265,50,194,195,212,198,8,189,6,28, | ||
2368 | + 237,256,27,83,258,133,259,149,151,9, | ||
2369 | + 154,165,279,10,245,244,240,243,242,241, | ||
2370 | + 25,71,68,70,69,26,150,152,11,303, | ||
2371 | + 35,262,180,2,304,257,34,298,135,22, | ||
2372 | + 293,155,7,271,157,17,295,302,310,311, | ||
2373 | + 270,101,182,18,296,178,179,0,187,89, | ||
2374 | + 267,19,169,45,299,47,216,197,82,264, | ||
2375 | + 249,219,84,13,127,14,129,15,130,128, | ||
2376 | + 297,146,147,204,143,145,148,203,142,144, | ||
2377 | + 24,185,23,66,64,65,220,40,307,46, | ||
2378 | + 44,238,273,205,218,171,123,122,106,116, | ||
2379 | + 170,38,308,109,141,114,119,117,113,160, | ||
2380 | + 112,54,164,105,188,30,31,67,29,48, | ||
2381 | + 131,282,289,41,53,275,4,137,168,167, | ||
2382 | + 88,266,162,277,306,139,99,103,276,234, | ||
2383 | + 201,222,226,225,224,223,283,287,286,100, | ||
2384 | + 200,76,184,95,166,63,87,263,272,134, | ||
2385 | + 136,132,280,235,58,153,278,236,61,247, | ||
2386 | + 1,20, | ||
2387 | +}; | ||
2388 | +static int x86_64_syscall_s2i(const char *s, int *value) { | ||
2389 | + size_t len, i; | ||
2390 | + len = strlen(s); | ||
2391 | + { char copy[len + 1]; | ||
2392 | + for (i = 0; i < len; i++) { | ||
2393 | + char c = s[i]; | ||
2394 | + copy[i] = GT_ISUPPER(c) ? c - 'A' + 'a' : c; | ||
2395 | + } | ||
2396 | + copy[i] = 0; | ||
2397 | + return s2i__(x86_64_syscall_strings, x86_64_syscall_s2i_s, x86_64_syscall_s2i_i, 312, copy, value); | ||
2398 | + } | ||
2399 | +} | ||
2400 | +static const unsigned x86_64_syscall_i2s_direct[] = { | ||
2401 | + 1747,3002,1525,206,2628,565,1210,1611,1194,1295, | ||
2402 | + 1328,1468,86,1900,1927,1958,1046,1628,1710,1782, | ||
2403 | + 3008,23,1589,2212,2191,1408,1443,1244,1216,2556, | ||
2404 | + 2537,2543,254,258,1555,1493,740,64,2406,778, | ||
2405 | + 2250,2603,212,8,2276,1795,2268,1813,2563,81, | ||
2406 | + 1138,860,750,2610,2497,872,200,537,2958,374, | ||
2407 | + 381,2989,1104,2892,2226,2233,2219,2550,1422,1436, | ||
2408 | + 1429,1415,494,531,579,500,2861,585,687,680, | ||
2409 | + 104,455,1850,1252,1894,220,1126,2898,2655,1762, | ||
2410 | + 110,462,116,478,1109,2878,890,833,843,2707, | ||
2411 | + 2849,1695,903,2715,723,2521,2377,715,707,2422, | ||
2412 | + 793,770,2490,2471,2442,730,2384,2461,823,2451, | ||
2413 | + 813,762,2368,2359,853,90,97,1913,1985,1942, | ||
2414 | + 1971,2572,2935,1266,2922,1577,2929,2633,571,2701, | ||
2415 | + 801,2430,2157,2083,2172,2098,2019,2042,2117,1280, | ||
2416 | + 1449,1286,1457,2964,1300,1600,0,1622,70,43, | ||
2417 | + 2480,122,2673,30,2508,1311,2884,2648,2640,1788, | ||
2418 | + 2394,2345,1059,1052,226,919,240,611,1725,1738, | ||
2419 | + 1514,785,1702,52,2870,2203,883,1752,2528,1200, | ||
2420 | + 555,910,1116,510,1145,1155,520,1838,1181,542, | ||
2421 | + 2855,2733,595,2139,2065,2313,1027,1003,1014,1036, | ||
2422 | + 993,657,1166,268,305,342,1821,696,2329,1878, | ||
2423 | + 2239,407,2738,2795,2781,2764,2751,186,156,143, | ||
2424 | + 170,386,331,295,2726,2951,2981,1224,2283,627, | ||
2425 | + 1361,1398,1385,1369,1351,1337,1086,2995,35,1866, | ||
2426 | + 1097,1075,1064,949,931,976,1230,1548,1258,1272, | ||
2427 | + 485,601,1503,2905,1857,1131,2663,1771,469,397, | ||
2428 | + 1686,1616,2914,2297,641,2621,2722,2678,2972,1317, | ||
2429 | + 2941,319,2584,2809,357,417,2833,2817,15,2593, | ||
2430 | + 365,281,263,1594,962,1634,1717,2001,1561,1804, | ||
2431 | + 427,441,1641,1475,1530,129,2694,2259,2416,673, | ||
2432 | + 1651,1668, | ||
2433 | +}; | ||
2434 | +static const char *x86_64_syscall_i2s(int v) { | ||
2435 | + return i2s_direct__(x86_64_syscall_strings, x86_64_syscall_i2s_direct, 0, 311, v); | ||
2436 | +} | ||
2437 | -- | ||
2438 | 1.7.11.7 | ||
2439 | |||
diff --git a/recipes-security/audit/audit_2.2.1.bb b/recipes-security/audit/audit_2.2.1.bb index 4d94025..a58b9e1 100644 --- a/recipes-security/audit/audit_2.2.1.bb +++ b/recipes-security/audit/audit_2.2.1.bb | |||
@@ -4,7 +4,7 @@ storing and searching the audit records generated by the audit subsystem \ | |||
4 | in the Linux kernel." | 4 | in the Linux kernel." |
5 | HOMEPAGE = "http://people.redhat.com/sgrubb/audit/" | 5 | HOMEPAGE = "http://people.redhat.com/sgrubb/audit/" |
6 | SECTION = "base" | 6 | SECTION = "base" |
7 | PR = "r5" | 7 | PR = "r6" |
8 | LICENSE = "GPLv2+ & LGPLv2+" | 8 | LICENSE = "GPLv2+ & LGPLv2+" |
9 | LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f" | 9 | LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f" |
10 | 10 | ||
@@ -12,8 +12,9 @@ SRC_URI = "http://people.redhat.com/sgrubb/audit/audit-${PV}.tar.gz \ | |||
12 | file://disable-ldap.patch \ | 12 | file://disable-ldap.patch \ |
13 | file://audit-python.patch" | 13 | file://audit-python.patch" |
14 | 14 | ||
15 | SRC_URI += "file://2.2.1-audit-for-cross-compiling.patch \ | 15 | SRC_URI += "\ |
16 | file://audit-python-configure.patch \ | 16 | file://audit-python-configure.patch \ |
17 | file://audit-cross-compiling.patch \ | ||
17 | file://auditd" | 18 | file://auditd" |
18 | 19 | ||
19 | inherit autotools pythonnative update-rc.d | 20 | inherit autotools pythonnative update-rc.d |
@@ -61,27 +62,6 @@ FILES_${PN}-dbg += "${libdir}/python${PYTHON_BASEVERSION}/*/.debug" | |||
61 | FILES_${PN}-python = "${libdir}/python${PYTHON_BASEVERSION}" | 62 | FILES_${PN}-python = "${libdir}/python${PYTHON_BASEVERSION}" |
62 | FILES_${PN}-dev += "${base_libdir}/*.so ${base_libdir}/*.la" | 63 | FILES_${PN}-dev += "${base_libdir}/*.so ${base_libdir}/*.la" |
63 | 64 | ||
64 | # The executables in lib/, which are named as gen_*_h, will run on the hosts to create | ||
65 | # *_tables.h/*tabs.h header files for the targets. | ||
66 | # In some old hosts, build will fail because some .h files in the old linux-libc-headers (<= 2.6.29) | ||
67 | # has incomplete DEFINE lists for the audit system. | ||
68 | do_compile_prepend() { | ||
69 | mkdir -p ${S}/lib/linux | ||
70 | cp -f ${STAGING_INCDIR}/linux/audit.h ${S}/lib/linux/ | ||
71 | cp -f ${STAGING_INCDIR}/linux/elf-em.h ${S}/lib/linux/ | ||
72 | cp -f ${STAGING_INCDIR}/linux/net.h ${S}/lib/linux/ | ||
73 | mkdir -p ${S}/lib/sys | ||
74 | cp -f ${STAGING_INCDIR}/sys/mount.h ${S}/lib/sys/ | ||
75 | cp -f ${STAGING_INCDIR}/sys/personality.h ${S}/lib/sys/ | ||
76 | mkdir -p ${S}/lib/bits | ||
77 | cp -f ${STAGING_INCDIR}/bits/socket.h ${S}/lib/bits | ||
78 | |||
79 | # eglibc-2.16 splits enum __socket_type from bits/socket.h to bits/socket_type.h, so we | ||
80 | # copy bits/socket_type.h only if it exists. | ||
81 | test -f ${STAGING_INCDIR}/bits/socket_type.h && \ | ||
82 | cp -f ${STAGING_INCDIR}/bits/socket_type.h ${S}/lib/bits | ||
83 | } | ||
84 | |||
85 | do_install_append() { | 65 | do_install_append() { |
86 | rm -f ${D}/${libdir}/python${PYTHON_BASEVERSION}/site-packages/*.a | 66 | rm -f ${D}/${libdir}/python${PYTHON_BASEVERSION}/site-packages/*.a |
87 | rm -f ${D}/${libdir}/python${PYTHON_BASEVERSION}/site-packages/*.la | 67 | rm -f ${D}/${libdir}/python${PYTHON_BASEVERSION}/site-packages/*.la |