v1.1.24 update
[musl-tools.git] / abi_type.sh.cc
blob7e0a253d4c04f54f3cd5b0912656236219ba2eec
2 #define _GNU_SOURCE 1
3 #define _FILE_OFFSET_BITS 64
4 #define SYSLOG_NAMES 1
5 #include <stddef.h>
6 #include <sys/types.h>
8 #include <aio.h>
9 #include <alloca.h>
10 #include <ar.h>
11 #include <arpa/ftp.h>
12 #include <arpa/inet.h>
13 #include <arpa/nameser.h>
14 #include <arpa/telnet.h>
15 #include <arpa/tftp.h>
16 #include <assert.h>
17 #include <byteswap.h>
18 #include <complex.h>
19 #include <cpio.h>
20 #include <crypt.h>
21 #include <ctype.h>
22 #include <dirent.h>
23 #include <dlfcn.h>
24 #include <elf.h>
25 #include <endian.h>
26 #include <err.h>
27 #include <errno.h>
28 #include <fcntl.h>
29 #include <features.h>
30 #include <fenv.h>
31 #include <float.h>
32 #include <fmtmsg.h>
33 #include <fnmatch.h>
34 #include <ftw.h>
35 #include <getopt.h>
36 #include <glob.h>
37 #include <grp.h>
38 #include <iconv.h>
39 #include <ifaddrs.h>
40 #include <inttypes.h>
41 #include <iso646.h>
42 #include <langinfo.h>
43 #include <libgen.h>
44 #include <libintl.h>
45 #include <limits.h>
46 #include <link.h>
47 #include <locale.h>
48 #include <malloc.h>
49 #include <math.h>
50 #include <mntent.h>
51 #include <monetary.h>
52 #include <mqueue.h>
53 #include <net/ethernet.h>
54 #include <net/if.h>
55 #include <net/if_arp.h>
56 #include <net/route.h>
57 #include <netdb.h>
58 #include <netinet/ether.h>
59 #include <netinet/icmp6.h>
60 #include <netinet/if_ether.h>
61 #include <netinet/igmp.h>
62 #include <netinet/in.h>
63 #include <netinet/in_systm.h>
64 #include <netinet/ip.h>
65 #include <netinet/ip6.h>
66 #include <netinet/ip_icmp.h>
67 #include <netinet/tcp.h>
68 #include <netinet/udp.h>
69 #include <netpacket/packet.h>
70 #include <nl_types.h>
71 #include <paths.h>
72 #include <poll.h>
73 #include <pthread.h>
74 #include <pty.h>
75 #include <pwd.h>
76 #include <regex.h>
77 #include <resolv.h>
78 #include <sched.h>
79 #include <scsi/scsi.h>
80 #include <scsi/scsi_ioctl.h>
81 #include <scsi/sg.h>
82 #include <search.h>
83 #include <semaphore.h>
84 #include <setjmp.h>
85 #include <shadow.h>
86 #include <signal.h>
87 #include <spawn.h>
88 #ifndef __GLIBC__
89 #include <stdalign.h>
90 #endif
91 #include <stdarg.h>
92 #include <stdbool.h>
93 #include <stdc-predef.h>
94 #include <stddef.h>
95 #include <stdint.h>
96 #include <stdio.h>
97 #include <stdio_ext.h>
98 #include <stdlib.h>
99 #ifndef __GLIBC__
100 #include <stdnoreturn.h>
101 #endif
102 #include <string.h>
103 #include <strings.h>
104 #include <stropts.h>
105 #include <sys/acct.h>
106 #include <sys/auxv.h>
107 //#include <sys/cachectl.h>
108 #include <sys/dir.h>
109 #include <sys/epoll.h>
110 #include <sys/eventfd.h>
111 #include <sys/fanotify.h>
112 #include <sys/file.h>
113 #include <sys/fsuid.h>
114 #include <sys/inotify.h>
115 //#include <sys/io.h>
116 #include <sys/ioctl.h>
117 #include <sys/ipc.h>
118 #include <sys/klog.h>
119 #include <sys/membarrier.h>
120 #include <sys/mman.h>
121 #include <sys/mount.h>
122 #include <sys/msg.h>
123 #include <sys/mtio.h>
124 #include <sys/param.h>
125 #include <sys/personality.h>
126 #include <sys/prctl.h>
127 #include <sys/procfs.h>
128 #include <sys/ptrace.h>
129 #include <sys/quota.h>
130 #include <sys/random.h>
131 #include <sys/reboot.h>
132 //#include <sys/reg.h>
133 #include <sys/resource.h>
134 #include <sys/select.h>
135 #include <sys/sem.h>
136 #include <sys/sendfile.h>
137 #include <sys/shm.h>
138 #include <sys/signalfd.h>
139 #include <sys/socket.h>
140 #include <sys/stat.h>
141 #include <sys/statfs.h>
142 #include <sys/statvfs.h>
143 #include <sys/swap.h>
144 #include <sys/syscall.h>
145 #include <sys/sysinfo.h>
146 #include <sys/sysmacros.h>
147 #include <sys/time.h>
148 #include <sys/timeb.h>
149 #include <sys/timerfd.h>
150 #include <sys/times.h>
151 #include <sys/timex.h>
152 #include <sys/ttydefaults.h>
153 #include <sys/types.h>
154 #include <sys/uio.h>
155 #include <sys/un.h>
156 #include <sys/user.h>
157 #include <sys/utsname.h>
158 #include <sys/wait.h>
159 #include <sys/xattr.h>
160 #include <sysexits.h>
161 #include <syslog.h>
162 #include <tar.h>
163 #include <termios.h>
164 #include <tgmath.h>
165 #ifndef __GLIBC__
166 #include <threads.h>
167 #endif
168 #include <time.h>
169 #include <uchar.h>
170 #include <ucontext.h>
171 #include <ulimit.h>
172 #include <unistd.h>
173 #include <utime.h>
174 #include <utmp.h>
175 #include <utmpx.h>
176 #include <values.h>
177 #include <wchar.h>
178 #include <wctype.h>
179 #include <wordexp.h>
181 typedef long long long_long;
182 typedef long double long_double;
183 typedef void *object_pointer;
184 typedef void (*function_pointer)();
185 struct size {char c;};
186 struct align {char c;};
187 struct incomplete {char c;};
188 #define T(s,t) void x_##t(s t x, s t* ptr, size(*y)[sizeof(s t)], align(*z)[__alignof__(s t)]){}
189 #define P(s,t) void x_##t(incomplete x, s t* ptr, incomplete y, incomplete z){}
190 #ifdef __GLIBC__
191 #define M(x)
192 #else
193 #define M(x) x
194 #endif
196 T(,ACTION)
197 T(,CODE)
198 P(,DIR)
199 T(,Dl_info)
200 T(,ENTRY)
201 T(,Elf32_Addr)
202 T(,Elf32_Chdr)
203 T(,Elf32_Conflict)
204 T(,Elf32_Dyn)
205 T(,Elf32_Ehdr)
206 T(,Elf32_Half)
207 T(,Elf32_Lib)
208 T(,Elf32_Move)
209 T(,Elf32_Nhdr)
210 T(,Elf32_Off)
211 T(,Elf32_Phdr)
212 T(,Elf32_RegInfo)
213 T(,Elf32_Rel)
214 T(,Elf32_Rela)
215 T(,Elf32_Section)
216 T(,Elf32_Shdr)
217 T(,Elf32_Sword)
218 T(,Elf32_Sxword)
219 T(,Elf32_Sym)
220 T(,Elf32_Syminfo)
221 T(,Elf32_Verdaux)
222 T(,Elf32_Verdef)
223 T(,Elf32_Vernaux)
224 T(,Elf32_Verneed)
225 T(,Elf32_Versym)
226 T(,Elf32_Word)
227 T(,Elf32_Xword)
228 T(,Elf32_auxv_t)
229 T(,Elf32_gptab)
230 T(,Elf64_Addr)
231 T(,Elf64_Chdr)
232 T(,Elf64_Dyn)
233 T(,Elf64_Ehdr)
234 T(,Elf64_Half)
235 T(,Elf64_Lib)
236 T(,Elf64_Move)
237 T(,Elf64_Nhdr)
238 T(,Elf64_Off)
239 T(,Elf64_Phdr)
240 T(,Elf64_Rel)
241 T(,Elf64_Rela)
242 T(,Elf64_Section)
243 T(,Elf64_Shdr)
244 T(,Elf64_Sword)
245 T(,Elf64_Sxword)
246 T(,Elf64_Sym)
247 T(,Elf64_Syminfo)
248 T(,Elf64_Verdaux)
249 T(,Elf64_Verdef)
250 T(,Elf64_Vernaux)
251 T(,Elf64_Verneed)
252 T(,Elf64_Versym)
253 T(,Elf64_Word)
254 T(,Elf64_Xword)
255 T(,Elf64_auxv_t)
256 T(,Elf_MIPS_ABIFlags_v0)
257 T(,Elf_Options)
258 T(,Elf_Options_Hw)
259 T(,Elf_Symndx)
260 P(,FILE)
261 T(,HEADER)
262 T(,Sg_io_hdr)
263 //T(,Sg_io_vec)
264 T(,Sg_req_info)
265 T(,Sg_scsi_id)
266 T(,VISIT)
267 //T(,__isoc_va_list)
268 T(,__jmp_buf)
269 T(,blkcnt_t)
270 T(,blksize_t)
271 T(,bool)
272 T(,caddr_t)
273 T(,cc_t)
274 T(,char)
275 T(,char16_t)
276 T(,char32_t)
277 T(,clock_t)
278 T(,clockid_t)
279 M(T(,cnd_t))
280 T(,comp_t)
281 T(,cookie_close_function_t)
282 T(,cookie_io_functions_t)
283 T(,cookie_read_function_t)
284 T(,cookie_seek_function_t)
285 T(,cookie_write_function_t)
286 T(,cpu_set_t)
287 T(,dev_t)
288 T(,div_t)
289 T(,double)
290 T(,double_t)
291 T(,elf_fpregset_t)
292 T(,elf_greg_t)
293 T(,elf_gregset_t)
294 T(,epoll_data_t)
295 T(,eventfd_t)
296 T(,fd_mask)
297 T(,fd_set)
298 T(,fenv_t)
299 T(,fexcept_t)
300 T(,float)
301 T(,float_t)
302 T(,fpos_t)
303 T(,fpregset_t)
304 T(,freg_t)
305 T(,fsblkcnt_t)
306 T(,fsfilcnt_t)
307 T(,fsid_t)
308 T(,function_pointer)
309 T(,gid_t)
310 T(,glob_t)
311 T(,greg_t)
312 T(,gregset_t)
313 T(,iconv_t)
314 T(,id_t)
315 T(,idtype_t)
316 T(,imaxdiv_t)
317 T(,in_addr_t)
318 T(,in_port_t)
319 T(,ino_t)
320 T(,int)
321 T(,int16_t)
322 T(,int32_t)
323 T(,int64_t)
324 T(,int8_t)
325 T(,int_fast16_t)
326 T(,int_fast32_t)
327 T(,int_fast64_t)
328 T(,int_fast8_t)
329 T(,int_least16_t)
330 T(,int_least32_t)
331 T(,int_least64_t)
332 T(,int_least8_t)
333 T(,intmax_t)
334 T(,intptr_t)
335 T(,jmp_buf)
336 T(,key_t)
337 T(,ldiv_t)
338 T(,lldiv_t)
339 T(,locale_t)
340 T(,long)
341 T(,long_double)
342 T(,long_long)
343 T(,lwpid_t)
344 T(,max_align_t)
345 T(,mbstate_t)
346 T(,mcontext_t)
347 T(,mode_t)
348 T(,mqd_t)
349 T(,msglen_t)
350 T(,msgqnum_t)
351 M(T(,mtx_t))
352 T(,n_long)
353 T(,n_short)
354 T(,n_time)
355 T(,nfds_t)
356 T(,nl_catd)
357 T(,nl_item)
358 T(,nlink_t)
359 T(,ns_cert_types)
360 T(,ns_class)
361 T(,ns_flag)
362 T(,ns_key_types)
363 T(,ns_msg)
364 T(,ns_opcode)
365 T(,ns_rcode)
366 T(,ns_rr)
367 T(,ns_sect)
368 //T(,ns_tcp_tsig_state)
369 //T(,ns_tsig_key)
370 T(,ns_type)
371 T(,ns_update_operation)
372 T(,object_pointer)
373 T(,off_t)
374 M(T(,once_flag))
375 T(,pid_t)
376 T(,posix_spawn_file_actions_t)
377 T(,posix_spawnattr_t)
378 T(,prfpregset_t)
379 T(,prgregset_t)
380 T(,prpsinfo_t)
381 T(,prstatus_t)
382 T(,psaddr_t)
383 T(,pthread_attr_t)
384 T(,pthread_barrier_t)
385 T(,pthread_barrierattr_t)
386 T(,pthread_cond_t)
387 T(,pthread_condattr_t)
388 T(,pthread_key_t)
389 T(,pthread_mutex_t)
390 T(,pthread_mutexattr_t)
391 T(,pthread_once_t)
392 T(,pthread_rwlock_t)
393 T(,pthread_rwlockattr_t)
394 T(,pthread_spinlock_t)
395 T(,pthread_t)
396 T(,ptrdiff_t)
397 T(,quad_t)
398 T(,regex_t)
399 T(,register_t)
400 T(,regmatch_t)
401 T(,regoff_t)
402 T(,res_state)
403 T(,rlim_t)
404 T(,sa_family_t)
405 T(,sem_t)
406 T(,sg_io_hdr_t)
407 T(,sg_iovec_t)
408 T(,sg_req_info_t)
409 T(,shmatt_t)
410 T(,short)
411 T(,sig_atomic_t)
412 T(,sig_t)
413 T(,sighandler_t)
414 T(,siginfo_t)
415 T(,sigjmp_buf)
416 T(,sigset_t)
417 T(,size_t)
418 T(,socklen_t)
419 T(,speed_t)
420 T(,ssize_t)
421 T(,stack_t)
422 T(struct,FTW)
423 T(struct,_IO_FILE)
424 T(struct,_IO_cookie_io_functions_t)
425 //T(struct,__fsid_t)
426 T(struct,__jmp_buf_tag)
427 //T(struct,__locale_struct)
428 //T(struct,__mbstate_t)
429 T(struct,__ns_msg)
430 T(struct,__ns_rr)
431 //T(struct,__ptcb)
432 T(struct,__ptrace_peeksiginfo_args)
433 T(struct,__ptrace_seccomp_metadata)
434 T(struct,__res_state)
435 //T(struct,__sigset_t)
436 //T(struct,__ucontext)
437 T(struct,_ns_flagdata)
438 T(struct,acct)
439 T(struct,acct_v3)
440 T(struct,addrinfo)
441 T(struct,aiocb)
442 T(struct,ar_hdr)
443 T(struct,arpd_request)
444 T(struct,arphdr)
445 T(struct,arpreq)
446 T(struct,arpreq_old)
447 T(struct,bandinfo)
448 T(struct,ccs_modesel_head)
449 T(struct,cmsghdr)
450 //T(struct,cpu_set_t)
451 T(struct,crypt_data)
452 T(struct,dirent)
453 T(struct,dl_phdr_info)
454 T(struct,dqblk)
455 T(struct,dqinfo)
456 T(struct,elf_prpsinfo)
457 T(struct,elf_prstatus)
458 T(struct,elf_siginfo)
459 T(struct,entry)
460 T(struct,epoll_event)
461 T(struct,ether_addr)
462 T(struct,ether_arp)
463 T(struct,ether_header)
464 T(struct,ethhdr)
465 T(struct,f_owner_ex)
466 T(struct,fanotify_event_info_fid)
467 T(struct,fanotify_event_info_header)
468 T(struct,fanotify_event_metadata)
469 T(struct,fanotify_response)
470 T(struct,file_handle)
471 T(struct,flock)
472 T(struct,group)
473 T(struct,group_filter)
474 T(struct,group_req)
475 T(struct,group_source_req)
476 T(struct,hostent)
477 T(struct,hsearch_data)
478 T(struct,icmp)
479 T(struct,icmp6_filter)
480 T(struct,icmp6_hdr)
481 T(struct,icmp6_router_renum)
482 T(struct,icmp_ra_addr)
483 T(struct,icmphdr)
484 T(struct,if_nameindex)
485 T(struct,ifaddr)
486 T(struct,ifaddrs)
487 T(struct,ifconf)
488 T(struct,ifmap)
489 T(struct,ifreq)
490 T(struct,igmp)
491 //T(struct,ih_idseq)
492 //T(struct,ih_pmtu)
493 //T(struct,ih_rtradv)
494 T(struct,in6_addr)
495 T(struct,in6_pktinfo)
496 T(struct,in6_rtmsg)
497 T(struct,in_addr)
498 T(struct,in_pktinfo)
499 T(struct,inotify_event)
500 T(struct,iovec)
501 T(struct,ip)
502 T(struct,ip6_dest)
503 T(struct,ip6_ext)
504 T(struct,ip6_frag)
505 T(struct,ip6_hbh)
506 T(struct,ip6_hdr)
507 //T(struct,ip6_hdrctl)
508 T(struct,ip6_mtuinfo)
509 T(struct,ip6_opt)
510 T(struct,ip6_opt_jumbo)
511 T(struct,ip6_opt_nsap)
512 T(struct,ip6_opt_router)
513 T(struct,ip6_opt_tunnel)
514 T(struct,ip6_rthdr)
515 T(struct,ip6_rthdr0)
516 T(struct,ip_mreq)
517 T(struct,ip_mreq_source)
518 T(struct,ip_mreqn)
519 T(struct,ip_msfilter)
520 T(struct,ip_opts)
521 T(struct,ip_timestamp)
522 T(struct,ipc_perm)
523 T(struct,iphdr)
524 T(struct,ipv6_mreq)
525 T(struct,itimerspec)
526 T(struct,itimerval)
527 T(struct,lastlog)
528 T(struct,lconv)
529 T(struct,linger)
530 T(struct,link_map)
531 T(struct,mld_hdr)
532 T(struct,mmsghdr)
533 T(struct,mntent)
534 T(struct,mq_attr)
535 T(struct,msgbuf)
536 T(struct,msghdr)
537 T(struct,msginfo)
538 T(struct,msqid_ds)
539 T(struct,mt_tape_info)
540 T(struct,mtconfiginfo)
541 T(struct,mtget)
542 T(struct,mtop)
543 T(struct,mtpos)
544 T(struct,nd_neighbor_advert)
545 T(struct,nd_neighbor_solicit)
546 T(struct,nd_opt_adv_interval)
547 T(struct,nd_opt_hdr)
548 T(struct,nd_opt_home_agent_info)
549 T(struct,nd_opt_mtu)
550 T(struct,nd_opt_prefix_info)
551 T(struct,nd_opt_rd_hdr)
552 T(struct,nd_redirect)
553 T(struct,nd_router_advert)
554 T(struct,nd_router_solicit)
555 T(struct,netent)
556 T(struct,ns_tcp_tsig_state)
557 T(struct,ns_tsig_key)
558 T(struct,ntptimeval)
559 T(struct,option)
560 T(struct,packet_mreq)
561 T(struct,passwd)
562 T(struct,pollfd)
563 T(struct,prctl_mm_map)
564 T(struct,protoent)
565 T(struct,qelem)
566 T(struct,r_debug)
567 T(struct,re_pattern_buffer)
568 T(struct,res_sym)
569 T(struct,rlimit)
570 T(struct,rr_pco_match)
571 T(struct,rr_pco_use)
572 T(struct,rr_result)
573 T(struct,rtentry)
574 T(struct,rusage)
575 T(struct,sched_param)
576 T(struct,sembuf)
577 T(struct,semid_ds)
578 T(struct,seminfo)
579 T(struct,servent)
580 T(struct,sg_header)
581 T(struct,sg_io_hdr)
582 T(struct,sg_iovec)
583 T(struct,sg_req_info)
584 T(struct,sg_scsi_id)
585 T(struct,shm_info)
586 T(struct,shmid_ds)
587 T(struct,shminfo)
588 T(struct,sigaction)
589 T(struct,sigaltstack)
590 T(struct,sigcontext)
591 T(struct,sigevent)
592 T(struct,signalfd_siginfo)
593 T(struct,sockaddr)
594 T(struct,sockaddr_in)
595 T(struct,sockaddr_in6)
596 T(struct,sockaddr_ll)
597 T(struct,sockaddr_storage)
598 T(struct,sockaddr_un)
599 T(struct,spwd)
600 T(struct,stat)
601 T(struct,statfs)
602 T(struct,statvfs)
603 T(struct,str_list)
604 T(struct,str_mlist)
605 T(struct,strbuf)
606 T(struct,strfdinsert)
607 T(struct,strioctl)
608 T(struct,strpeek)
609 T(struct,strrecvfd)
610 T(struct,sysinfo)
611 T(struct,tcp_diag_md5sig)
612 T(struct,tcp_info)
613 T(struct,tcp_md5sig)
614 T(struct,tcp_repair_window)
615 T(struct,tcp_zerocopy_receive)
616 T(struct,tcphdr)
617 T(struct,termios)
618 T(struct,tftphdr)
619 T(struct,timeb)
620 T(struct,timespec)
621 T(struct,timestamp)
622 T(struct,timeval)
623 T(struct,timex)
624 T(struct,timezone)
625 T(struct,tm)
626 T(struct,tms)
627 T(struct,ucred)
628 T(struct,udphdr)
629 T(struct,user)
630 T(struct,user_fpu_struct)
631 T(struct,utimbuf)
632 T(struct,utmpx)
633 T(struct,utsname)
634 T(struct,winsize)
635 T(,suseconds_t)
636 T(,tcflag_t)
637 //T(,tcp_seq)
638 M(T(,thrd_start_t))
639 M(T(,thrd_t))
640 T(,time_t)
641 T(,timer_t)
642 M(T(,tss_dtor_t))
643 M(T(,tss_t))
644 T(,u_char)
645 T(,u_int)
646 T(,u_int16_t)
647 T(,u_int32_t)
648 T(,u_int64_t)
649 T(,u_int8_t)
650 T(,u_long)
651 T(,u_quad_t)
652 T(,u_short)
653 T(,ucontext_t)
654 T(,uid_t)
655 T(,uint)
656 T(,uint16_t)
657 T(,uint32_t)
658 T(,uint64_t)
659 T(,uint8_t)
660 T(,uint_fast16_t)
661 T(,uint_fast32_t)
662 T(,uint_fast64_t)
663 T(,uint_fast8_t)
664 T(,uint_least16_t)
665 T(,uint_least32_t)
666 T(,uint_least64_t)
667 T(,uint_least8_t)
668 T(,uintmax_t)
669 T(,uintptr_t)
670 T(,ulong)
671 //T(union,_G_fpos64_t)
672 T(union,epoll_data)
673 T(union,sigval)
674 T(,useconds_t)
675 T(,ushort)
676 T(,va_list)
677 T(,wchar_t)
678 T(,wctrans_t)
679 T(,wctype_t)
680 T(,wint_t)
681 T(,wordexp_t)