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