OSDN Git Service

Merge remote-tracking branch 'toybox/master' into HEAD
[android-x86/external-toybox.git] / generated / globals.h
1 // toys/android/getprop.c
2
3 struct getprop_data {
4   size_t size;
5   char **nv; // name/value pairs: even=name, odd=value
6   struct selabel_handle *handle;
7 };
8
9 // toys/android/log.c
10
11 struct log_data {
12   char *tag;
13   char *pri;
14 };
15
16 // toys/example/hello.c
17
18 struct hello_data {
19   int unused;
20 };
21
22 // toys/example/skeleton.c
23
24 struct skeleton_data {
25   union {
26     struct {
27       char *b_string;
28       long c_number;
29       struct arg_list *d_list;
30       long e_count;
31       char *also_string;
32       char *blubber_string;
33     } s;
34     struct {
35       long b_number;
36     } a;
37   };
38
39   int more_globals;
40 };
41
42 // toys/lsb/dmesg.c
43
44 struct dmesg_data {
45   long level;
46   long size;
47 };
48
49 // toys/lsb/hostname.c
50
51 struct hostname_data {
52   char *fname;
53 };
54
55 // toys/lsb/killall.c
56
57 struct killall_data {
58   char *sig;
59
60   int signum;
61   pid_t cur_pid;
62   char **names;
63   short *err;
64 };
65
66 // toys/lsb/md5sum.c
67
68 struct md5sum_data {
69   struct arg_list *c;
70
71   int sawline;
72
73   // Crypto variables blanked after summing
74   unsigned state[5];
75   unsigned oldstate[5];
76   uint64_t count;
77   union {
78     char c[64];
79     unsigned i[16];
80   } buffer;
81 };
82
83 // toys/lsb/mknod.c
84
85 struct mknod_data {
86   char *arg_context;
87   char *m;
88 };
89
90 // toys/lsb/mktemp.c
91
92 struct mktemp_data {
93   char *tmpdir;
94 };
95
96 // toys/lsb/mount.c
97
98 struct mount_data {
99   struct arg_list *optlist;
100   char *type;
101   char *bigO;
102
103   unsigned long flags;
104   char *opts;
105   int okuser;
106 };
107
108 // toys/lsb/passwd.c
109
110 struct passwd_data {
111   char *algo;
112 };
113
114 // toys/lsb/pidof.c
115
116 struct pidof_data {
117   char *omit;
118 };
119
120 // toys/lsb/seq.c
121
122 struct seq_data {
123   char *sep;
124   char *fmt;
125 };
126
127 // toys/lsb/su.c
128
129 struct su_data {
130   char *s;
131   char *c;
132 };
133
134 // toys/lsb/umount.c
135
136 struct umount_data {
137   struct arg_list *t;
138
139   char *types;
140 };
141
142 // toys/net/ifconfig.c
143
144 struct ifconfig_data {
145   int sockfd;
146 };
147
148 // toys/net/netcat.c
149
150 struct netcat_data {
151   char *filename;        // -f read from filename instead of network
152   long quit_delay;       // -q Exit after EOF from stdin after # seconds.
153   char *source_address;  // -s Bind to a specific source address.
154   long port;             // -p Bind to a specific source port.
155   long wait;             // -w Wait # seconds for a connection.
156 };
157
158 // toys/net/netstat.c
159
160 struct netstat_data {
161   struct num_cache *inodes;
162   int wpad;
163 };;
164
165 // toys/other/acpi.c
166
167 struct acpi_data {
168   int ac, bat, therm, cool;
169   char *cpath;
170 };
171
172 // toys/other/base64.c
173
174 struct base64_data {
175   long columns;
176
177   unsigned total;
178 };
179
180 // toys/other/blockdev.c
181
182 struct blockdev_data {
183   long bsz;
184 };
185
186 // toys/other/dos2unix.c
187
188 struct dos2unix_data {
189   char *tempfile;
190 };
191
192 // toys/other/fallocate.c
193
194 struct fallocate_data {
195   long size;
196 };
197
198 // toys/other/free.c
199
200 struct free_data {
201   unsigned bits;
202   unsigned long long units;
203   char *buf;
204 };
205
206 // toys/other/hexedit.c
207
208 struct hexedit_data {
209   char *data;
210   long long len, base;
211   int numlen, undo, undolen;
212   unsigned height;
213 };
214
215 // toys/other/hwclock.c
216
217 struct hwclock_data {
218   char *fname;
219
220   int utc;
221 };
222
223 // toys/other/ionice.c
224
225 struct ionice_data {
226   long pid;
227   long level;
228   long class;
229 };
230
231 // toys/other/login.c
232
233 struct login_data {
234   char *hostname;
235   char *username;
236
237   int login_timeout, login_fail_timeout;
238 };
239
240 // toys/other/losetup.c
241
242 struct losetup_data {
243   char *jfile;
244   long offset;
245   long size;
246
247   int openflags;
248   dev_t jdev;
249   ino_t jino;
250 };
251
252 // toys/other/lspci.c
253
254 struct lspci_data {
255   char *ids;
256   long numeric;
257
258   FILE *db;
259 };
260
261 // toys/other/makedevs.c
262
263 struct makedevs_data {
264   char *fname;
265 };
266
267 // toys/other/mix.c
268
269 struct mix_data {
270    long right;
271    long level;
272    char *dev;
273    char *chan;
274 };
275
276 // toys/other/mkpasswd.c
277
278 struct mkpasswd_data {
279   long pfd;
280   char *method;
281   char *salt;
282 };
283
284 // toys/other/mkswap.c
285
286 struct mkswap_data {
287   char *L;
288 };
289
290 // toys/other/modinfo.c
291
292 struct modinfo_data {
293   char *field;
294   char *knam;
295   char *base;
296
297   long mod;
298 };
299
300 // toys/other/nsenter.c
301
302 struct nsenter_data {
303   char *nsnames[6];
304   long targetpid;
305 };
306
307 // toys/other/oneit.c
308
309 struct oneit_data {
310   char *console;
311 };
312
313 // toys/other/setfattr.c
314
315 struct setfattr_data {
316   char *x, *v, *n;
317 };
318
319 // toys/other/shred.c
320
321 struct shred_data {
322   long offset;
323   long iterations;
324   long size;
325
326   int ufd;
327 };
328
329 // toys/other/stat.c
330
331 struct stat_data {
332   char *fmt;
333
334   union {
335     struct stat st;
336     struct statfs sf;
337   } stat;
338   char *file, *pattern;
339   int patlen;
340 };
341
342 // toys/other/swapon.c
343
344 struct swapon_data {
345   long priority;
346 };
347
348 // toys/other/switch_root.c
349
350 struct switch_root_data {
351   char *console;
352
353   dev_t rootdev;
354 };
355
356 // toys/other/timeout.c
357
358 struct timeout_data {
359   char *s_signal;
360   char *k_timeout;
361
362   int nextsig;
363   pid_t pid;
364   struct timeval ktv;
365   struct itimerval itv;
366 };
367
368 // toys/other/truncate.c
369
370 struct truncate_data {
371   char *s;
372
373   long size;
374   int type;
375 };
376
377 // toys/other/xxd.c
378
379 struct xxd_data {
380   long s;
381   long g;
382   long l;
383   long c;
384 };
385
386 // toys/pending/arp.c
387
388 struct arp_data {
389     char *hw_type;
390     char *af_type_A;
391     char *af_type_p;
392     char *interface;
393     
394     int sockfd;
395     char *device;
396 };
397
398 // toys/pending/arping.c
399
400 struct arping_data {
401     long count;
402     unsigned long time_out;
403     char *iface;
404     char *src_ip;
405
406     int sockfd;
407     unsigned long start, end;
408     unsigned sent_at, sent_nr, rcvd_nr, brd_sent, rcvd_req, brd_rcv,
409              unicast_flag;
410 };
411
412 // toys/pending/bootchartd.c
413
414 struct bootchartd_data {
415   char buf[32];
416   long smpl_period_usec;
417   int proc_accounting;
418   int is_login;
419
420   void *head;
421 };
422
423 // toys/pending/brctl.c
424
425 struct brctl_data {
426     int sockfd;
427 };
428
429 // toys/pending/compress.c
430
431 struct compress_data {
432   // Huffman codes: base offset and extra bits tables (length and distance)
433   char lenbits[29], distbits[30];
434   unsigned short lenbase[29], distbase[30];
435   void *fixdisthuff, *fixlithuff;
436
437   // CRC
438   void (*crcfunc)(char *data, int len);
439   unsigned crc;
440
441   // Compressed data buffer
442   char *data;
443   unsigned pos, len;
444   int infd, outfd;
445
446   // Tables only used for deflation
447   unsigned short *hashhead, *hashchain;
448 };
449
450 // toys/pending/crond.c
451
452 struct crond_data {
453   char *crontabs_dir;
454   char *logfile;
455   int loglevel_d;
456   int loglevel;
457
458   time_t crontabs_dir_mtime;
459   uint8_t flagd;
460 };
461
462 // toys/pending/crontab.c
463
464 struct crontab_data {
465   char *user;
466   char *cdir;
467 };
468
469 // toys/pending/dd.c
470
471 struct dd_data {
472   int show_xfer;
473   int show_records;
474   unsigned long long bytes, c_count, in_full, in_part, out_full, out_part;
475   struct timeval start;
476   struct {
477     char *name;
478     int fd;
479     unsigned char *buff, *bp;
480     long sz, count;
481     unsigned long long offset;
482   } in, out;
483 };;
484
485 // toys/pending/dhcp.c
486
487 struct dhcp_data {
488     char *iface;
489     char *pidfile;
490     char *script;
491     long retries;
492     long timeout;
493     long tryagain;
494     struct arg_list *req_opt;
495     char *req_ip;
496     struct arg_list *pkt_opt;
497     char *fdn_name;
498     char *hostname;
499     char *vendor_cls;
500 };
501
502 // toys/pending/dhcp6.c
503
504 struct dhcp6_data {
505   char *interface_name, *pidfile, *script;
506   long retry, timeout, errortimeout;
507   char *req_ip;
508   int length, state, request_length, sock, sock1, status, retval, retries;
509   struct timeval tv;
510   uint8_t transction_id[3];
511   struct sockaddr_in6 input_socket6;
512 };
513
514 // toys/pending/dhcpd.c
515
516 struct dhcpd_data {
517     char *iface;
518     long port;
519 };;
520
521 // toys/pending/diff.c
522
523 struct diff_data {
524   long ct;
525   char *start;
526   struct arg_list *L_list;
527
528   int dir_num, size, is_binary, status, change, len[2];
529   int *offset[2];
530 };
531
532 // toys/pending/dumpleases.c
533
534 struct dumpleases_data {
535     char *file;
536 };
537
538 // toys/pending/expr.c
539
540 struct expr_data {
541   char **tok; // current token, not on the stack since recursive calls mutate it
542
543   char *refree;
544 };
545
546 // toys/pending/fdisk.c
547
548 struct fdisk_data {
549   long sect_sz;
550   long sectors;
551   long heads;
552   long cylinders;
553 };
554
555 // toys/pending/fold.c
556
557 struct fold_data {
558   int width;
559 };
560
561 // toys/pending/fsck.c
562
563 struct fsck_data {
564   int fd_num;
565   char *t_list;
566
567   struct double_list *devices;
568   char *arr_flag;
569   char **arr_type;
570   int negate;
571   int sum_status;
572   int nr_run;
573   int sig_num;
574   long max_nr_run;
575 };
576
577 // toys/pending/ftpget.c
578
579 struct ftpget_data {
580   long port; //  char *port;
581   char *password;
582   char *username;
583
584   FILE *sockfp;
585   int c;
586   int isget;
587   char buf[sizeof(struct sockaddr_storage)];
588 };
589
590 // toys/pending/getfattr.c
591
592 struct getfattr_data {
593   char *n;
594 };
595
596 // toys/pending/getty.c
597
598 struct getty_data {
599   char *issue_str;
600   char *login_str;
601   char *init_str;
602   char *host_str; 
603   long timeout;
604   
605   char *tty_name;  
606   int  speeds[20];
607   int  sc;              
608   struct termios termios;
609   char buff[128];
610 };
611
612 // toys/pending/groupadd.c
613
614 struct groupadd_data {
615   long gid;
616 };
617
618 // toys/pending/host.c
619
620 struct host_data {
621   char *type_str;
622 };
623
624 // toys/pending/iconv.c
625
626 struct iconv_data {
627   char *from;
628   char *to;
629
630   void *ic;
631 };
632
633 // toys/pending/ip.c
634
635 struct ip_data {
636   char stats, singleline, flush, *filter_dev, gbuf[8192];
637   int sockfd, connected, from_ok, route_cmd;
638   int8_t addressfamily, is_addr;
639 };
640
641 // toys/pending/ipcrm.c
642
643 struct ipcrm_data {
644   struct arg_list *qkey;
645   struct arg_list *qid;
646   struct arg_list *skey;
647   struct arg_list *sid;
648   struct arg_list *mkey;
649   struct arg_list *mid;
650 };
651
652 // toys/pending/ipcs.c
653
654 struct ipcs_data {
655   int id;
656 };
657
658 // toys/pending/klogd.c
659
660 struct klogd_data {
661   long level;
662
663   int fd;
664 };
665
666 // toys/pending/last.c
667
668 struct last_data {
669   char *file;
670
671   struct arg_list *list;
672 };
673
674 // toys/pending/logger.c
675
676 struct logger_data {
677   char *priority_arg;
678   char *ident;
679 };
680
681 // toys/pending/lsof.c
682
683 struct lsof_data {
684   struct arg_list *p;
685
686   struct stat *sought_files;
687
688   struct double_list *all_sockets;
689   struct double_list *files;
690   int last_shown_pid;
691   int shown_header;
692 };
693
694 // toys/pending/mke2fs.c
695
696 struct mke2fs_data {
697   // Command line arguments.
698   long blocksize;
699   long bytes_per_inode;
700   long inodes;           // Total inodes in filesystem.
701   long reserved_percent; // Integer precent of space to reserve for root.
702   char *gendir;          // Where to read dirtree from.
703
704   // Internal data.
705   struct dirtree *dt;    // Tree of files to copy into the new filesystem.
706   unsigned treeblocks;   // Blocks used by dt
707   unsigned treeinodes;   // Inodes used by dt
708
709   unsigned blocks;       // Total blocks in the filesystem.
710   unsigned freeblocks;   // Free blocks in the filesystem.
711   unsigned inodespg;     // Inodes per group
712   unsigned groups;       // Total number of block groups.
713   unsigned blockbits;    // Bits per block.  (Also blocks per group.)
714
715   // For gene2fs
716   unsigned nextblock;    // Next data block to allocate
717   unsigned nextgroup;    // Next group we'll be allocating from
718   int fsfd;              // File descriptor of filesystem (to output to).
719
720   struct ext2_superblock sb;
721 };
722
723 // toys/pending/modprobe.c
724
725 struct modprobe_data {
726   struct arg_list *probes;
727   struct arg_list *dbase[256];
728   char *cmdopts;
729   int nudeps;
730   uint8_t symreq;
731   void (*dbg)(char *format, ...);
732 };
733
734 // toys/pending/more.c
735
736 struct more_data {
737   struct termios inf;
738   int cin_fd;
739 };
740
741 // toys/pending/openvt.c
742
743 struct openvt_data {
744   unsigned long vt_num;
745 };
746
747 // toys/pending/ping.c
748
749 struct ping_data {
750   long wait_exit;
751   long wait_resp;
752   char *iface;
753   long size;
754   long count;
755   long ttl;
756
757   int sock;
758 };
759
760 // toys/pending/route.c
761
762 struct route_data {
763   char *family;
764 };
765
766 // toys/pending/sh.c
767
768 struct sh_data {
769   char *command;
770
771   long lineno;
772 };
773
774 // toys/pending/sulogin.c
775
776 struct sulogin_data {
777   long timeout;
778   struct termios crntio;
779 };
780
781 // toys/pending/syslogd.c
782
783 struct syslogd_data {
784   char *socket;
785   char *config_file;
786   char *unix_socket;
787   char *logfile;
788   long interval;
789   long rot_size;
790   long rot_count;
791   char *remote_log;
792   long log_prio;
793
794   struct unsocks *lsocks;  // list of listen sockets
795   struct logfile *lfiles;  // list of write logfiles
796   int sigfd[2];
797 };
798
799 // toys/pending/tar.c
800
801 struct tar_data {
802   char *fname;
803   char *dir;
804   struct arg_list *inc_file;
805   struct arg_list *exc_file;
806   char *tocmd;
807   struct arg_list *exc;
808
809   struct arg_list *inc, *pass;
810   void *inodes, *handle;
811 };
812
813 // toys/pending/tcpsvd.c
814
815 struct tcpsvd_data {
816   char *name;
817   char *user;
818   long bn;
819   char *nmsg;
820   long cn;
821
822   int maxc;
823   int count_all;
824   int udp;
825 };
826
827 // toys/pending/telnet.c
828
829 struct telnet_data {
830   int port;
831   int sfd;
832   char buff[128];
833   int pbuff;
834   char iac[256];
835   int piac;
836   char *ttype;
837   struct termios def_term;
838   struct termios raw_term;
839   uint8_t term_ok;
840   uint8_t term_mode;
841   uint8_t flags;
842   unsigned win_width;
843   unsigned win_height;
844 };
845
846 // toys/pending/telnetd.c
847
848 struct telnetd_data {
849     char *login_path;
850     char *issue_path;
851     int port;
852     char *host_addr;
853     long w_sec;
854
855     int gmax_fd;
856     pid_t fork_pid;
857 };
858
859 // toys/pending/tftp.c
860
861 struct tftp_data {
862   char *local_file;
863   char *remote_file;
864   long block_size;
865
866   struct sockaddr_storage inaddr;
867   int af;
868 };
869
870 // toys/pending/tftpd.c
871
872 struct tftpd_data {
873   char *user;
874
875   long sfd;
876   struct passwd *pw;
877 };
878
879 // toys/pending/tr.c
880
881 struct tr_data {
882   short map[256]; //map of chars
883   int len1, len2;
884 };
885
886 // toys/pending/traceroute.c
887
888 struct traceroute_data {
889   long max_ttl;
890   long port;
891   long ttl_probes;
892   char *src_ip;
893   long tos;
894   long wait_time;
895   struct arg_list *loose_source;
896   long pause_time;
897   long first_ttl;
898   char *iface;
899
900   uint32_t gw_list[9];
901   int recv_sock;
902   int snd_sock;
903   unsigned msg_len;
904   char *packet;
905   uint32_t ident;
906   int istraceroute6;
907 };
908
909 // toys/pending/useradd.c
910
911 struct useradd_data {
912   char *dir;
913   char *gecos;
914   char *shell;
915   char *u_grp;
916   long uid;
917
918   long gid;
919 };
920
921 // toys/pending/vi.c
922
923 struct vi_data {
924   struct linestack *ls;
925   char *statline;
926 };
927
928 // toys/pending/watch.c
929
930 struct watch_data {
931   int interval;
932 };
933
934 // toys/pending/wget.c
935
936 struct wget_data {
937   char *filename;
938 };
939
940 // toys/posix/chgrp.c
941
942 struct chgrp_data {
943   uid_t owner;
944   gid_t group;
945   char *owner_name, *group_name;
946   int symfollow;
947 };
948
949 // toys/posix/chmod.c
950
951 struct chmod_data {
952   char *mode;
953 };
954
955 // toys/posix/cksum.c
956
957 struct cksum_data {
958   unsigned crc_table[256];
959 };
960
961 // toys/posix/cmp.c
962
963 struct cmp_data {
964   int fd;
965   char *name;
966 };
967
968 // toys/posix/cp.c
969
970 struct cp_data {
971   union {
972     struct {
973       // install's options
974       char *group;
975       char *user;
976       char *mode;
977     } i;
978     struct {
979       char *preserve;
980     } c;
981   };
982
983   char *destname;
984   struct stat top;
985   int (*callback)(struct dirtree *try);
986   uid_t uid;
987   gid_t gid;
988   int pflags;
989 };
990
991 // toys/posix/cpio.c
992
993 struct cpio_data {
994   char *archive;
995   char *pass;
996   char *fmt;
997 };
998
999 // toys/posix/cut.c
1000
1001 struct cut_data {
1002   char *delim;
1003   char *flist;
1004   char *clist;
1005   char *blist;
1006
1007   void *slist_head;
1008   unsigned nelem;
1009   void (*do_cut)(int fd);
1010 };
1011
1012 // toys/posix/date.c
1013
1014 struct date_data {
1015   char *file;
1016   char *setfmt;
1017   char *showdate;
1018
1019   char *tz;
1020   unsigned nano;
1021 };
1022
1023 // toys/posix/df.c
1024
1025 struct df_data {
1026   struct arg_list *fstype;
1027
1028   long units;
1029   int column_widths[5];
1030   int header_shown;
1031 };
1032
1033 // toys/posix/du.c
1034
1035 struct du_data {
1036   long maxdepth;
1037
1038   long depth, total;
1039   dev_t st_dev;
1040   void *inodes;
1041 };
1042
1043 // toys/posix/env.c
1044
1045 struct env_data {
1046   struct arg_list *u;
1047 };;
1048
1049 // toys/posix/expand.c
1050
1051 struct expand_data {
1052   struct arg_list *tabs;
1053
1054   unsigned tabcount, *tab;
1055 };
1056
1057 // toys/posix/file.c
1058
1059 struct file_data {
1060   int max_name_len;
1061 };
1062
1063 // toys/posix/find.c
1064
1065 struct find_data {
1066   char **filter;
1067   struct double_list *argdata;
1068   int topdir, xdev, depth;
1069   time_t now;
1070 };
1071
1072 // toys/posix/grep.c
1073
1074 struct grep_data {
1075   long m;
1076   struct arg_list *f;
1077   struct arg_list *e;
1078   long a;
1079   long b;
1080   long c;
1081
1082   char indelim, outdelim;
1083 };
1084
1085 // toys/posix/head.c
1086
1087 struct head_data {
1088   long lines;
1089   int file_no;
1090 };
1091
1092 // toys/posix/id.c
1093
1094 struct id_data {
1095   int is_groups;
1096 };
1097
1098 // toys/posix/kill.c
1099
1100 struct kill_data {
1101   char *signame;
1102   struct arg_list *olist;
1103 };
1104
1105 // toys/posix/ls.c
1106
1107 struct ls_data {
1108   char *color;
1109
1110   struct dirtree *files, *singledir;
1111
1112   unsigned screen_width;
1113   int nl_title;
1114   char *escmore;
1115 };
1116
1117 // toys/posix/mkdir.c
1118
1119 struct mkdir_data {
1120   char *arg_mode;
1121   char *arg_context;
1122 };
1123
1124 // toys/posix/mkfifo.c
1125
1126 struct mkfifo_data {
1127   char *m_string;
1128   char *Z;
1129
1130   mode_t mode;
1131 };
1132
1133 // toys/posix/nice.c
1134
1135 struct nice_data {
1136   long priority;
1137 };
1138
1139 // toys/posix/nl.c
1140
1141 struct nl_data {
1142   long w;
1143   char *s;
1144   char *n;
1145   char *b;
1146   long l;
1147   long v;
1148
1149   // Count of consecutive blank lines for -l has to persist between files
1150   long lcount;
1151 };
1152
1153 // toys/posix/od.c
1154
1155 struct od_data {
1156   struct arg_list *output_base;
1157   char *address_base;
1158   long max_count;
1159   long width;
1160   long jump_bytes;
1161
1162   int address_idx;
1163   unsigned types, leftover, star;
1164   char *buf; // Points to buffers[0] or buffers[1].
1165   char *bufs[2]; // Used to detect duplicate lines.
1166   off_t pos;
1167 };
1168
1169 // toys/posix/paste.c
1170
1171 struct paste_data {
1172   char *delim;
1173 };
1174
1175 // toys/posix/patch.c
1176
1177 struct patch_data {
1178   char *infile;
1179   long prefix;
1180   char *dir;
1181
1182   struct double_list *current_hunk;
1183   long oldline, oldlen, newline, newlen;
1184   long linenum;
1185   int context, state, filein, fileout, filepatch, hunknum;
1186   char *tempname;
1187 };
1188
1189 // toys/posix/ps.c
1190
1191 struct ps_data {
1192   union {
1193     struct {
1194       struct arg_list *G;
1195       struct arg_list *g;
1196       struct arg_list *U;
1197       struct arg_list *u;
1198       struct arg_list *t;
1199       struct arg_list *s;
1200       struct arg_list *p;
1201       struct arg_list *O;
1202       struct arg_list *o;
1203       struct arg_list *P;
1204       struct arg_list *k;
1205     } ps;
1206     struct {
1207       long n;
1208       long d;
1209       long s;
1210       struct arg_list *u;
1211       struct arg_list *p;
1212       struct arg_list *o;
1213       struct arg_list *k;
1214       struct arg_list *O;
1215     } top;
1216     struct {
1217       char *L;
1218       struct arg_list *G;
1219       struct arg_list *g;
1220       struct arg_list *P;
1221       struct arg_list *s;
1222       struct arg_list *t;
1223       struct arg_list *U;
1224       struct arg_list *u;
1225       char *d;
1226
1227       void *regexes, *snapshot;
1228       int signal;
1229       pid_t self, match;
1230     } pgrep;
1231   };
1232
1233   struct sysinfo si;
1234   struct ptr_len gg, GG, pp, PP, ss, tt, uu, UU;
1235   struct dirtree *threadparent;
1236   unsigned width, height;
1237   dev_t tty;
1238   void *fields, *kfields;
1239   long long ticks, bits, time;
1240   int kcount, forcek, sortpos;
1241   int (*match_process)(long long *slot);
1242   void (*show_process)(void *tb);
1243 };
1244
1245 // toys/posix/renice.c
1246
1247 struct renice_data {
1248   long nArgu;
1249 };
1250
1251 // toys/posix/sed.c
1252
1253 struct sed_data {
1254   struct arg_list *f;
1255   struct arg_list *e;
1256
1257   // processed pattern list
1258   struct double_list *pattern;
1259
1260   char *nextline, *remember;
1261   void *restart, *lastregex;
1262   long nextlen, rememberlen, count;
1263   int fdout, noeol;
1264   unsigned xx;
1265 };
1266
1267 // toys/posix/sort.c
1268
1269 struct sort_data {
1270   char *key_separator;
1271   struct arg_list *raw_keys;
1272   char *outfile;
1273   char *ignore1, ignore2;   // GNU compatability NOPs for -S and -T.
1274
1275   void *key_list;
1276   int linecount;
1277   char **lines;
1278 };
1279
1280 // toys/posix/split.c
1281
1282 struct split_data {
1283   long lines;
1284   long bytes;
1285   long suflen;
1286
1287   char *outfile;
1288 };
1289
1290 // toys/posix/strings.c
1291
1292 struct strings_data {
1293   long num;
1294 };
1295
1296 // toys/posix/tail.c
1297
1298 struct tail_data {
1299   long lines;
1300   long bytes;
1301
1302   int file_no, ffd, *files;
1303 };
1304
1305 // toys/posix/tee.c
1306
1307 struct tee_data {
1308   void *outputs;
1309 };
1310
1311 // toys/posix/touch.c
1312
1313 struct touch_data {
1314   char *time;
1315   char *file;
1316   char *date;
1317 };
1318
1319 // toys/posix/ulimit.c
1320
1321 struct ulimit_data {
1322   long pid;
1323 };
1324
1325 // toys/posix/uniq.c
1326
1327 struct uniq_data {
1328   long maxchars;
1329   long nchars;
1330   long nfields;
1331   long repeats;
1332 };
1333
1334 // toys/posix/uudecode.c
1335
1336 struct uudecode_data {
1337   char *o;
1338 };
1339
1340 // toys/posix/wc.c
1341
1342 struct wc_data {
1343   unsigned long totals[4];
1344 };
1345
1346 // toys/posix/xargs.c
1347
1348 struct xargs_data {
1349   long max_bytes;
1350   long max_entries;
1351   long L;
1352   char *eofstr;
1353   char *I;
1354
1355   long entries, bytes;
1356   char delim;
1357 };
1358
1359 extern union global_union {
1360         struct getprop_data getprop;
1361         struct log_data log;
1362         struct hello_data hello;
1363         struct skeleton_data skeleton;
1364         struct dmesg_data dmesg;
1365         struct hostname_data hostname;
1366         struct killall_data killall;
1367         struct md5sum_data md5sum;
1368         struct mknod_data mknod;
1369         struct mktemp_data mktemp;
1370         struct mount_data mount;
1371         struct passwd_data passwd;
1372         struct pidof_data pidof;
1373         struct seq_data seq;
1374         struct su_data su;
1375         struct umount_data umount;
1376         struct ifconfig_data ifconfig;
1377         struct netcat_data netcat;
1378         struct netstat_data netstat;
1379         struct acpi_data acpi;
1380         struct base64_data base64;
1381         struct blockdev_data blockdev;
1382         struct dos2unix_data dos2unix;
1383         struct fallocate_data fallocate;
1384         struct free_data free;
1385         struct hexedit_data hexedit;
1386         struct hwclock_data hwclock;
1387         struct ionice_data ionice;
1388         struct login_data login;
1389         struct losetup_data losetup;
1390         struct lspci_data lspci;
1391         struct makedevs_data makedevs;
1392         struct mix_data mix;
1393         struct mkpasswd_data mkpasswd;
1394         struct mkswap_data mkswap;
1395         struct modinfo_data modinfo;
1396         struct nsenter_data nsenter;
1397         struct oneit_data oneit;
1398         struct setfattr_data setfattr;
1399         struct shred_data shred;
1400         struct stat_data stat;
1401         struct swapon_data swapon;
1402         struct switch_root_data switch_root;
1403         struct timeout_data timeout;
1404         struct truncate_data truncate;
1405         struct xxd_data xxd;
1406         struct arp_data arp;
1407         struct arping_data arping;
1408         struct bootchartd_data bootchartd;
1409         struct brctl_data brctl;
1410         struct compress_data compress;
1411         struct crond_data crond;
1412         struct crontab_data crontab;
1413         struct dd_data dd;
1414         struct dhcp_data dhcp;
1415         struct dhcp6_data dhcp6;
1416         struct dhcpd_data dhcpd;
1417         struct diff_data diff;
1418         struct dumpleases_data dumpleases;
1419         struct expr_data expr;
1420         struct fdisk_data fdisk;
1421         struct fold_data fold;
1422         struct fsck_data fsck;
1423         struct ftpget_data ftpget;
1424         struct getfattr_data getfattr;
1425         struct getty_data getty;
1426         struct groupadd_data groupadd;
1427         struct host_data host;
1428         struct iconv_data iconv;
1429         struct ip_data ip;
1430         struct ipcrm_data ipcrm;
1431         struct ipcs_data ipcs;
1432         struct klogd_data klogd;
1433         struct last_data last;
1434         struct logger_data logger;
1435         struct lsof_data lsof;
1436         struct mke2fs_data mke2fs;
1437         struct modprobe_data modprobe;
1438         struct more_data more;
1439         struct openvt_data openvt;
1440         struct ping_data ping;
1441         struct route_data route;
1442         struct sh_data sh;
1443         struct sulogin_data sulogin;
1444         struct syslogd_data syslogd;
1445         struct tar_data tar;
1446         struct tcpsvd_data tcpsvd;
1447         struct telnet_data telnet;
1448         struct telnetd_data telnetd;
1449         struct tftp_data tftp;
1450         struct tftpd_data tftpd;
1451         struct tr_data tr;
1452         struct traceroute_data traceroute;
1453         struct useradd_data useradd;
1454         struct vi_data vi;
1455         struct watch_data watch;
1456         struct wget_data wget;
1457         struct chgrp_data chgrp;
1458         struct chmod_data chmod;
1459         struct cksum_data cksum;
1460         struct cmp_data cmp;
1461         struct cp_data cp;
1462         struct cpio_data cpio;
1463         struct cut_data cut;
1464         struct date_data date;
1465         struct df_data df;
1466         struct du_data du;
1467         struct env_data env;
1468         struct expand_data expand;
1469         struct file_data file;
1470         struct find_data find;
1471         struct grep_data grep;
1472         struct head_data head;
1473         struct id_data id;
1474         struct kill_data kill;
1475         struct ls_data ls;
1476         struct mkdir_data mkdir;
1477         struct mkfifo_data mkfifo;
1478         struct nice_data nice;
1479         struct nl_data nl;
1480         struct od_data od;
1481         struct paste_data paste;
1482         struct patch_data patch;
1483         struct ps_data ps;
1484         struct renice_data renice;
1485         struct sed_data sed;
1486         struct sort_data sort;
1487         struct split_data split;
1488         struct strings_data strings;
1489         struct tail_data tail;
1490         struct tee_data tee;
1491         struct touch_data touch;
1492         struct ulimit_data ulimit;
1493         struct uniq_data uniq;
1494         struct uudecode_data uudecode;
1495         struct wc_data wc;
1496         struct xargs_data xargs;
1497 } this;