aboutsummaryrefslogtreecommitdiff
path: root/android
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2020-05-11 16:34:39 -0700
committerElliott Hughes <enh@google.com>2020-05-11 16:35:55 -0700
commit3c43f1535c0bb3ff04ef795f457a05d7f4df08f4 (patch)
treed3e0c7cc33c7eedc6943a2d0bff32c6828e4134c /android
parent1a92447be505af5e2d5d9c6442421ccf9519d1b4 (diff)
parent975187f670cf5aac9036230369c62258d5332d25 (diff)
downloadtoybox-3c43f1535c0bb3ff04ef795f457a05d7f4df08f4.tar.gz
Merge remote-tracking branch 'toybox/master' into HEAD
Change-Id: I04e4249a3bbb7f12a7597eca55734ac64637c495
Diffstat (limited to 'android')
-rw-r--r--android/device/generated/flags.h22
-rw-r--r--android/device/generated/globals.h4
-rw-r--r--android/device/generated/help.h6
-rw-r--r--android/device/generated/newtoys.h8
-rw-r--r--android/linux/generated/flags.h22
-rw-r--r--android/linux/generated/globals.h4
-rw-r--r--android/linux/generated/help.h8
-rw-r--r--android/linux/generated/newtoys.h8
-rw-r--r--android/mac/generated/flags.h22
-rw-r--r--android/mac/generated/globals.h4
-rw-r--r--android/mac/generated/help.h8
-rw-r--r--android/mac/generated/newtoys.h8
12 files changed, 65 insertions, 59 deletions
diff --git a/android/device/generated/flags.h b/android/device/generated/flags.h
index e5f13aab..bb24784d 100644
--- a/android/device/generated/flags.h
+++ b/android/device/generated/flags.h
@@ -268,14 +268,14 @@
#undef FLAG_h
#endif
-// chmod <2?vRf[-vf] <2?vRf[-vf]
+// chmod <2?vfR[-vf] <2?vfR[-vf]
#undef OPTSTR_chmod
-#define OPTSTR_chmod "<2?vRf[-vf]"
+#define OPTSTR_chmod "<2?vfR[-vf]"
#ifdef CLEANUP_chmod
#undef CLEANUP_chmod
#undef FOR_chmod
-#undef FLAG_f
#undef FLAG_R
+#undef FLAG_f
#undef FLAG_v
#endif
@@ -1793,9 +1793,9 @@
#undef FLAG_s
#endif
-// microcom <1>1s:X <1>1s:X
+// microcom <1>1s#=115200X <1>1s#=115200X
#undef OPTSTR_microcom
-#define OPTSTR_microcom "<1>1s:X"
+#define OPTSTR_microcom "<1>1s#=115200X"
#ifdef CLEANUP_microcom
#undef CLEANUP_microcom
#undef FOR_microcom
@@ -1986,9 +1986,9 @@
#undef FLAG_n
#endif
-// netcat ^tlLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U] ^tlLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]
+// netcat ^tElLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U] ^tElLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]
#undef OPTSTR_netcat
-#define OPTSTR_netcat "^tlLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]"
+#define OPTSTR_netcat "^tElLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]"
#ifdef CLEANUP_netcat
#undef CLEANUP_netcat
#undef FOR_netcat
@@ -2004,6 +2004,7 @@
#undef FLAG_w
#undef FLAG_L
#undef FLAG_l
+#undef FLAG_E
#undef FLAG_t
#endif
@@ -3725,8 +3726,8 @@
#ifndef TT
#define TT this.chmod
#endif
-#define FLAG_f (1<<0)
-#define FLAG_R (1<<1)
+#define FLAG_R (1<<0)
+#define FLAG_f (1<<1)
#define FLAG_v (1<<2)
#endif
@@ -5183,7 +5184,8 @@
#define FLAG_w (1<<9)
#define FLAG_L (1<<10)
#define FLAG_l (1<<11)
-#define FLAG_t (1<<12)
+#define FLAG_E (1<<12)
+#define FLAG_t (1<<13)
#endif
#ifdef FOR_netstat
diff --git a/android/device/generated/globals.h b/android/device/generated/globals.h
index 9f701ac6..1edc420f 100644
--- a/android/device/generated/globals.h
+++ b/android/device/generated/globals.h
@@ -159,7 +159,7 @@ struct ifconfig_data {
// toys/net/microcom.c
struct microcom_data {
- char *s;
+ long s;
int fd;
struct termios original_stdin_state, original_fd_state;
@@ -831,7 +831,7 @@ struct sh_data {
// keep lineno here, we use it to work around a compiler bug
long lineno;
- char *ifs;
+ char *ifs, *isexec;
struct double_list functions;
unsigned options, jobcnt;
int hfd, pid, varslen, shift, cdcount;
diff --git a/android/device/generated/help.h b/android/device/generated/help.h
index 69d280cb..7dcaeb8b 100644
--- a/android/device/generated/help.h
+++ b/android/device/generated/help.h
@@ -124,9 +124,9 @@
#define HELP_netstat "usage: netstat [-pWrxwutneal]\n\nDisplay networking information. Default is netstat -tuwx\n\n-r Routing table\n-a All sockets (not just connected)\n-l Listening server sockets\n-t TCP sockets\n-u UDP sockets\n-w Raw sockets\n-x Unix sockets\n-e Extended info\n-n Don't resolve names\n-W Wide display\n-p Show PID/program name of sockets"
-#define HELP_netcat "usage: netcat [-46Ut] [-lL COMMAND...] [-u] [-wpq #] [-s addr] {IPADDR PORTNUM|-f FILENAME}\n\nForward stdin/stdout to a file or network connection.\n\n-4 Force IPv4\n-6 Force IPv6\n-L Listen for multiple incoming connections (server mode)\n-U Use a UNIX domain socket\n-W SECONDS timeout for more data on an idle connection\n-f Use FILENAME (ala /dev/ttyS0) instead of network\n-l Listen for one incoming connection\n-p Local port number\n-q Quit SECONDS after EOF on stdin, even if stdout hasn't closed yet\n-s Local source address\n-t Allocate tty (must come before -l or -L)\n-u Use UDP\n-w SECONDS timeout to establish connection\n\nUse \"stty 115200 -F /dev/ttyS0 && stty raw -echo -ctlecho\" with\nnetcat -f to connect to a serial port.\n\nThe command line after -l or -L is executed (as a child process) to handle\neach incoming connection. If blank -l waits for a connection and forwards\nit to stdin/stdout. If no -p specified, -l prints port it bound to and\nbackgrounds itself (returning immediately).\n\nFor a quick-and-dirty server, try something like:\nnetcat -s 127.0.0.1 -p 1234 -tL /bin/bash -l"
+#define HELP_netcat "usage: netcat [-46ELUlt] [-u] [-wpq #] [-s addr] {IPADDR PORTNUM|-f FILENAME|COMMAND...}\n\nForward stdin/stdout to a file or network connection.\n\n-4 Force IPv4\n-6 Force IPv6\n-E Forward stderr\n-L Listen and background each incoming connection (server mode)\n-U Use a UNIX domain socket\n-W SECONDS timeout for more data on an idle connection\n-f Use FILENAME (ala /dev/ttyS0) instead of network\n-l Listen for one incoming connection, then exit\n-p Local port number\n-q Quit SECONDS after EOF on stdin, even if stdout hasn't closed yet\n-s Local source address\n-t Allocate tty\n-u Use UDP\n-w SECONDS timeout to establish connection\n\nUse \"stty 115200 -F /dev/ttyS0 && stty raw -echo -ctlecho\" with\nnetcat -f to connect to a serial port.\n\nWhen listening the COMMAND line is executed as a child process to handle\nan incoming connection. With no COMMAND -l forwards the connection\nto stdin/stdout. If no -p specified, -l prints the port it bound to and\nbackgrounds itself (returning immediately).\n\nFor a quick-and-dirty server, try something like:\nnetcat -s 127.0.0.1 -p 1234 -tL sh -l"
-#define HELP_microcom "usage: microcom [-s SPEED] [-X] DEVICE\n\nSimple serial console.\n\n-s Set baud rate to SPEED\n-X Ignore ^@ (send break) and ^] (exit)"
+#define HELP_microcom "usage: microcom [-s SPEED] [-X] DEVICE\n\nSimple serial console.\n\n-s Set baud rate to SPEED (default 115200)\n-X Ignore ^@ (send break) and ^] (exit)"
#define HELP_ifconfig "usage: ifconfig [-aS] [INTERFACE [ACTION...]]\n\nDisplay or configure network interface.\n\nWith no arguments, display active interfaces. First argument is interface\nto operate on, one argument by itself displays that interface.\n\n-a All interfaces displayed, not just active ones\n-S Short view, one line per interface\n\nStandard ACTIONs to perform on an INTERFACE:\n\nADDR[/MASK] - set IPv4 address (1.2.3.4/5) and activate interface\nadd|del ADDR[/LEN] - add/remove IPv6 address (1111::8888/128)\nup|down - activate or deactivate interface\n\nAdvanced ACTIONs (default values usually suffice):\n\ndefault - remove IPv4 address\nnetmask ADDR - set IPv4 netmask via 255.255.255.0 instead of /24\ntxqueuelen LEN - number of buffered packets before output blocks\nmtu LEN - size of outgoing packets (Maximum Transmission Unit)\nbroadcast ADDR - Set broadcast address\npointopoint ADDR - PPP and PPPOE use this instead of \"route add default gw\"\nhw TYPE ADDR - set hardware (mac) address (type = ether|infiniband)\n\nFlags you can set on an interface (or -remove by prefixing with -):\n\narp - don't use Address Resolution Protocol to map LAN routes\npromisc - don't discard packets that aren't to this LAN hardware address\nmulticast - force interface into multicast mode if the driver doesn't\nallmulti - promisc for multicast packets"
@@ -498,7 +498,7 @@
#define HELP_sleep "usage: sleep DURATION\n\nWait before exiting.\n\nDURATION can be a decimal fraction. An optional suffix can be \"m\"\n(minutes), \"h\" (hours), \"d\" (days), or \"s\" (seconds, the default)."
-#define HELP_sed "usage: sed [-inrzE] [-e SCRIPT]...|SCRIPT [-f SCRIPT_FILE]... [FILE...]\n\nStream editor. Apply one or more editing SCRIPTs to each line of input\n(from FILE or stdin) producing output (by default to stdout).\n\n-e Add SCRIPT to list\n-f Add contents of SCRIPT_FILE to list\n-i Edit each file in place (-iEXT keeps backup file with extension EXT)\n-n No default output (use the p command to output matched lines)\n-r Use extended regular expression syntax\n-E POSIX alias for -r\n-s Treat input files separately (implied by -i)\n-z Use \\0 rather than \\n as the input line separator\n\nA SCRIPT is a series of one or more COMMANDs separated by newlines or\nsemicolons. All -e SCRIPTs are concatenated together as if separated\nby newlines, followed by all lines from -f SCRIPT_FILEs, in order.\nIf no -e or -f SCRIPTs are specified, the first argument is the SCRIPT.\n\nEach COMMAND may be preceded by an address which limits the command to\napply only to the specified line(s). Commands without an address apply to\nevery line. Addresses are of the form:\n\n [ADDRESS[,ADDRESS]][!]COMMAND\n\nThe ADDRESS may be a decimal line number (starting at 1), a /regular\nexpression/ within a pair of forward slashes, or the character \"$\" which\nmatches the last line of input. (In -s or -i mode this matches the last\nline of each file, otherwise just the last line of the last file.) A single\naddress matches one line, a pair of comma separated addresses match\neverything from the first address to the second address (inclusive). If\nboth addresses are regular expressions, more than one range of lines in\neach file can match. The second address can be +N to end N lines later.\n\nREGULAR EXPRESSIONS in sed are started and ended by the same character\n(traditionally / but anything except a backslash or a newline works).\nBackslashes may be used to escape the delimiter if it occurs in the\nregex, and for the usual printf escapes (\\abcefnrtv and octal, hex,\nand unicode). An empty regex repeats the previous one. ADDRESS regexes\n(above) require the first delimiter to be escaped with a backslash when\nit isn't a forward slash (to distinguish it from the COMMANDs below).\n\nSed mostly operates on individual lines one at a time. It reads each line,\nprocesses it, and either writes it to the output or discards it before\nreading the next line. Sed can remember one additional line in a separate\nbuffer (using the h, H, g, G, and x commands), and can read the next line\nof input early (using the n and N command), but other than that command\nscripts operate on individual lines of text.\n\nEach COMMAND starts with a single character. The following commands take\nno arguments:\n\n ! Run this command when the test _didn't_ match.\n\n { Start a new command block, continuing until a corresponding \"}\".\n Command blocks may nest. If the block has an address, commands within\n the block are only run for lines within the block's address range.\n\n } End command block (this command cannot have an address)\n\n d Delete this line and move on to the next one\n (ignores remaining COMMANDs)\n\n D Delete one line of input and restart command SCRIPT (same as \"d\"\n unless you've glued lines together with \"N\" or similar)\n\n g Get remembered line (overwriting current line)\n\n G Get remembered line (appending to current line)\n\n h Remember this line (overwriting remembered line)\n\n H Remember this line (appending to remembered line, if any)\n\n l Print line, escaping \\abfrtv (but not newline), octal escaping other\n nonprintable characters, wrapping lines to terminal width with a\n backslash, and appending $ to actual end of line.\n\n n Print default output and read next line, replacing current line\n (If no next line available, quit processing script)\n\n N Append next line of input to this line, separated by a newline\n (This advances the line counter for address matching and \"=\", if no\n next line available quit processing script without default output)\n\n p Print this line\n\n P Print this line up to first newline (from \"N\")\n\n q Quit (print default output, no more commands processed or lines read)\n\n x Exchange this line with remembered line (overwrite in both directions)\n\n = Print the current line number (followed by a newline)\n\nThe following commands (may) take an argument. The \"text\" arguments (to\nthe \"a\", \"b\", and \"c\" commands) may end with an unescaped \"\\\" to append\nthe next line (for which leading whitespace is not skipped), and also\ntreat \";\" as a literal character (use \"\\;\" instead).\n\n a [text] Append text to output before attempting to read next line\n\n b [label] Branch, jumps to :label (or with no label, to end of SCRIPT)\n\n c [text] Delete line, output text at end of matching address range\n (ignores remaining COMMANDs)\n\n i [text] Print text\n\n r [file] Append contents of file to output before attempting to read\n next line.\n\n s/S/R/F Search for regex S, replace matched text with R using flags F.\n The first character after the \"s\" (anything but newline or\n backslash) is the delimiter, escape with \\ to use normally.\n\n The replacement text may contain \"&\" to substitute the matched\n text (escape it with backslash for a literal &), or \\1 through\n \\9 to substitute a parenthetical subexpression in the regex.\n You can also use the normal backslash escapes such as \\n and\n a backslash at the end of the line appends the next line.\n\n The flags are:\n\n [0-9] A number, substitute only that occurrence of pattern\n g Global, substitute all occurrences of pattern\n i/I Ignore case when matching\n p Print the line if match was found and replaced\n w [file] Write (append) line to file if match replaced\n\n t [label] Test, jump to :label only if an \"s\" command found a match in\n this line since last test (replacing with same text counts)\n\n T [label] Test false, jump only if \"s\" hasn't found a match.\n\n w [file] Write (append) line to file\n\n y/old/new/ Change each character in 'old' to corresponding character\n in 'new' (with standard backslash escapes, delimiter can be\n any repeated character except \\ or \\n)\n\n : [label] Labeled target for jump commands\n\n # Comment, ignore rest of this line of SCRIPT\n\nDeviations from POSIX: allow extended regular expressions with -r,\nediting in place with -i, separate with -s, NUL-separated input with -z,\nprintf escapes in text, line continuations, semicolons after all commands,\n2-address anywhere an address is allowed, \"T\" command, multiline\ncontinuations for [abc], \\; to end [abc] argument before end of line."
+#define HELP_sed "usage: sed [-inrzE] [-e SCRIPT]...|SCRIPT [-f SCRIPT_FILE]... [FILE...]\n\nStream editor. Apply editing SCRIPTs to lines of input.\n\n-e Add SCRIPT to list\n-f Add contents of SCRIPT_FILE to list\n-i Edit each file in place (-iEXT keeps backup file with extension EXT)\n-n No default output (use the p command to output matched lines)\n-r Use extended regular expression syntax\n-E POSIX alias for -r\n-s Treat input files separately (implied by -i)\n-z Use \\0 rather than \\n as input line separator\n\nA SCRIPT is one or more COMMANDs separated by newlines or semicolons.\nAll -e SCRIPTs are combined as if separated by newlines, followed by all -f\nSCRIPT_FILEs. If no -e or -f then first argument is the SCRIPT.\n\nCOMMANDs apply to every line unless prefixed with an ADDRESS of the form:\n\n [ADDRESS[,ADDRESS]][!]COMMAND\n\nADDRESS is a line number (starting at 1), a /REGULAR EXPRESSION/, or $ for\nlast line (-s or -i makes it last line of each file). One address matches one\nline, ADDRESS,ADDRESS matches from first to second inclusive. Two regexes can\nmatch multiple ranges. ADDRESS,+N ends N lines later. ! inverts the match.\n\nREGULAR EXPRESSIONS start and end with the same character (anything but\nbackslash or newline). To use the delimiter in the regex escape it with a\nbackslash, and printf escapes (\\abcefnrtv and octal, hex, and unicode) work.\nAn empty regex repeats the previous one. ADDRESS regexes require any\nfirst delimiter except / to be \\escaped to distinguish it from COMMANDs.\n\nSed reads each line of input, processes it, and writes it out or discards it\nbefore reading the next. Sed can remember one additional line in a separate\nbuffer (the h, H, g, G, and x commands), and can read the next line of input\nearly (the n and N commands), but otherwise operates on individual lines.\n\nEach COMMAND starts with a single character. Commands with no arguments are:\n\n ! Run this command when the ADDRESS _didn't_ match.\n { Start new command block, continuing until a corresponding \"}\".\n Command blocks nest and can have ADDRESSes applying to the whole block.\n } End command block (this COMMAND cannot have an address)\n d Delete this line and move on to the next one\n (ignores remaining COMMANDs)\n D Delete one line of input and restart command SCRIPT (same as \"d\"\n unless you've glued lines together with \"N\" or similar)\n g Get remembered line (overwriting current line)\n G Get remembered line (appending to current line)\n h Remember this line (overwriting remembered line)\n H Remember this line (appending to remembered line, if any)\n l Print line escaping \\abfrtv (but not \\n), octal escape other nonprintng\n chars, wrap lines to terminal width with \\, append $ to end of line.\n n Print default output and read next line over current line (quit at EOF)\n N Append \\n and next line of input to this line. Quit at EOF without\n default output. Advances line counter for ADDRESS and \"=\".\n p Print this line\n P Print this line up to first newline (from \"N\")\n q Quit (print default output, no more commands processed or lines read)\n x Exchange this line with remembered line (overwrite in both directions)\n = Print the current line number (plus newline)\n # Comment, ignores rest of this line of SCRIPT (until newline)\n\nCommands that take an argument:\n\n : LABEL Target for jump commands\n a TEXT Append text to output before reading next line\n b LABEL Branch, jumps to :LABEL (with no LABEL to end of SCRIPT)\n c TEXT Delete matching ADDRESS range and output TEXT instead\n i TEXT Insert text (output immediately)\n r FILE Append contents of FILIE to output before reading next line.\n s/S/R/F Search for regex S replace match with R using flags F. Delimiter\n is anything but \\n or \\, escape with \\ to use in S or R. Printf\n escapes work. Unescaped & in R becomes full matched text, \\1\n through \\9 = parenthetical subexpression from S. \\ at end of\n line appends next line of SCRIPT. The flags in F are:\n [0-9] A number N, substitute only Nth match\n g Global, substitute all matches\n i/I Ignore case when matching\n p Print resulting line when match found and replaced\n w [file] Write (append) line to file when match replaced\n t LABEL Test, jump if s/// command matched this line since last test\n T LABEL Test false, jump to :LABEL only if no s/// found a match\n w FILE Write (append) line to file\n y/old/new/ Change each character in 'old' to corresponding character\n in 'new' (with standard backslash escapes, delimiter can be\n any repeated character except \\ or \\n)\n\nThe TEXT arguments (to a c i) may end with an unescaped \"\\\" to append\nthe next line (leading whitespace is not skipped), and treat \";\" as a\nliteral character (use \"\\;\" instead)."
#define HELP_rmdir "usage: rmdir [-p] [DIR...]\n\nRemove one or more directories.\n\n-p Remove path\n--ignore-fail-on-non-empty Ignore failures caused by non-empty directories"
diff --git a/android/device/generated/newtoys.h b/android/device/generated/newtoys.h
index 0a5aa949..95fa3082 100644
--- a/android/device/generated/newtoys.h
+++ b/android/device/generated/newtoys.h
@@ -29,7 +29,7 @@ USE_SH(NEWTOY(cd, ">1LP[-LP]", TOYFLAG_NOFORK))
USE_CHATTR(NEWTOY(chattr, "?p#v#R", TOYFLAG_BIN))
USE_CHCON(NEWTOY(chcon, "<2hvR", TOYFLAG_USR|TOYFLAG_BIN))
USE_CHGRP(NEWTOY(chgrp, "<2hPLHRfv[-HLP]", TOYFLAG_BIN))
-USE_CHMOD(NEWTOY(chmod, "<2?vRf[-vf]", TOYFLAG_BIN))
+USE_CHMOD(NEWTOY(chmod, "<2?vfR[-vf]", TOYFLAG_BIN))
USE_CHOWN(OLDTOY(chown, chgrp, TOYFLAG_BIN))
USE_CHROOT(NEWTOY(chroot, "^<1", TOYFLAG_USR|TOYFLAG_SBIN|TOYFLAG_ARGFAIL(125)))
USE_CHRT(NEWTOY(chrt, "^mp#<0iRbrfo[!ibrfo]", TOYFLAG_USR|TOYFLAG_BIN))
@@ -161,7 +161,7 @@ USE_MAN(NEWTOY(man, "k:M:", TOYFLAG_USR|TOYFLAG_BIN))
USE_MCOOKIE(NEWTOY(mcookie, "v(verbose)V(version)", TOYFLAG_USR|TOYFLAG_BIN))
USE_MD5SUM(NEWTOY(md5sum, "bc(check)s(status)[!bc]", TOYFLAG_USR|TOYFLAG_BIN))
USE_MDEV(NEWTOY(mdev, "s", TOYFLAG_USR|TOYFLAG_BIN|TOYFLAG_UMASK))
-USE_MICROCOM(NEWTOY(microcom, "<1>1s:X", TOYFLAG_USR|TOYFLAG_BIN))
+USE_MICROCOM(NEWTOY(microcom, "<1>1s#=115200X", TOYFLAG_USR|TOYFLAG_BIN))
USE_MIX(NEWTOY(mix, "c:d:l#r#", TOYFLAG_USR|TOYFLAG_BIN))
USE_MKDIR(NEWTOY(mkdir, "<1"USE_MKDIR_Z("Z:")"vp(parent)(parents)m:", TOYFLAG_BIN|TOYFLAG_UMASK))
USE_MKE2FS(NEWTOY(mke2fs, "<1>2g:Fnqm#N#i#b#", TOYFLAG_SBIN))
@@ -179,7 +179,7 @@ USE_MV(NEWTOY(mv, "<2vnF(remove-destination)fiT[-ni]", TOYFLAG_BIN))
USE_NBD_CLIENT(OLDTOY(nbd-client, nbd_client, TOYFLAG_USR|TOYFLAG_BIN))
USE_NBD_CLIENT(NEWTOY(nbd_client, "<3>3ns", 0))
USE_NETCAT(OLDTOY(nc, netcat, TOYFLAG_USR|TOYFLAG_BIN))
-USE_NETCAT(NEWTOY(netcat, USE_NETCAT_LISTEN("^tlL")"w#<1W#<1p#<1>65535q#<1s:f:46uU"USE_NETCAT_LISTEN("[!tlL][!Lw]")"[!46U]", TOYFLAG_BIN))
+USE_NETCAT(NEWTOY(netcat, USE_NETCAT_LISTEN("^tElL")"w#<1W#<1p#<1>65535q#<1s:f:46uU"USE_NETCAT_LISTEN("[!tlL][!Lw]")"[!46U]", TOYFLAG_BIN))
USE_NETSTAT(NEWTOY(netstat, "pWrxwutneal", TOYFLAG_BIN))
USE_NICE(NEWTOY(nice, "^<1n#", TOYFLAG_BIN))
USE_NL(NEWTOY(nl, "v#=1l#w#<0=6Eb:n:s:", TOYFLAG_USR|TOYFLAG_BIN))
@@ -220,7 +220,7 @@ USE_RFKILL(NEWTOY(rfkill, "<1>2", TOYFLAG_USR|TOYFLAG_SBIN))
USE_RM(NEWTOY(rm, "fiRrv[-fi]", TOYFLAG_BIN))
USE_RMDIR(NEWTOY(rmdir, "<1(ignore-fail-on-non-empty)p", TOYFLAG_BIN))
USE_RMMOD(NEWTOY(rmmod, "<1wf", TOYFLAG_SBIN|TOYFLAG_NEEDROOT))
-USE_ROUTE(NEWTOY(route, "?neA:", TOYFLAG_BIN))
+USE_ROUTE(NEWTOY(route, "?neA:", TOYFLAG_SBIN))
USE_RTCWAKE(NEWTOY(rtcwake, "(list-modes);(auto)a(device)d:(local)l(mode)m:(seconds)s#(time)t#(utc)u(verbose)v[!alu]", TOYFLAG_USR|TOYFLAG_BIN))
USE_RUNCON(NEWTOY(runcon, "<2", TOYFLAG_USR|TOYFLAG_SBIN))
USE_SED(NEWTOY(sed, "(help)(version)e*f*i:;nErz(null-data)[+Er]", TOYFLAG_BIN|TOYFLAG_LOCALE|TOYFLAG_NOHELP))
diff --git a/android/linux/generated/flags.h b/android/linux/generated/flags.h
index ca6276cc..14137cd3 100644
--- a/android/linux/generated/flags.h
+++ b/android/linux/generated/flags.h
@@ -268,14 +268,14 @@
#undef FLAG_h
#endif
-// chmod <2?vRf[-vf] <2?vRf[-vf]
+// chmod <2?vfR[-vf] <2?vfR[-vf]
#undef OPTSTR_chmod
-#define OPTSTR_chmod "<2?vRf[-vf]"
+#define OPTSTR_chmod "<2?vfR[-vf]"
#ifdef CLEANUP_chmod
#undef CLEANUP_chmod
#undef FOR_chmod
-#undef FLAG_f
#undef FLAG_R
+#undef FLAG_f
#undef FLAG_v
#endif
@@ -1793,9 +1793,9 @@
#undef FLAG_s
#endif
-// microcom <1>1s:X <1>1s:X
+// microcom <1>1s#=115200X <1>1s#=115200X
#undef OPTSTR_microcom
-#define OPTSTR_microcom "<1>1s:X"
+#define OPTSTR_microcom "<1>1s#=115200X"
#ifdef CLEANUP_microcom
#undef CLEANUP_microcom
#undef FOR_microcom
@@ -1986,9 +1986,9 @@
#undef FLAG_n
#endif
-// netcat ^tlLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]
+// netcat ^tElLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]
#undef OPTSTR_netcat
-#define OPTSTR_netcat "^tlLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]"
+#define OPTSTR_netcat "^tElLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]"
#ifdef CLEANUP_netcat
#undef CLEANUP_netcat
#undef FOR_netcat
@@ -2004,6 +2004,7 @@
#undef FLAG_w
#undef FLAG_L
#undef FLAG_l
+#undef FLAG_E
#undef FLAG_t
#endif
@@ -3725,8 +3726,8 @@
#ifndef TT
#define TT this.chmod
#endif
-#define FLAG_f (1<<0)
-#define FLAG_R (1<<1)
+#define FLAG_R (1<<0)
+#define FLAG_f (1<<1)
#define FLAG_v (1<<2)
#endif
@@ -5183,7 +5184,8 @@
#define FLAG_w (FORCED_FLAG<<9)
#define FLAG_L (FORCED_FLAG<<10)
#define FLAG_l (FORCED_FLAG<<11)
-#define FLAG_t (FORCED_FLAG<<12)
+#define FLAG_E (FORCED_FLAG<<12)
+#define FLAG_t (FORCED_FLAG<<13)
#endif
#ifdef FOR_netstat
diff --git a/android/linux/generated/globals.h b/android/linux/generated/globals.h
index 9f701ac6..1edc420f 100644
--- a/android/linux/generated/globals.h
+++ b/android/linux/generated/globals.h
@@ -159,7 +159,7 @@ struct ifconfig_data {
// toys/net/microcom.c
struct microcom_data {
- char *s;
+ long s;
int fd;
struct termios original_stdin_state, original_fd_state;
@@ -831,7 +831,7 @@ struct sh_data {
// keep lineno here, we use it to work around a compiler bug
long lineno;
- char *ifs;
+ char *ifs, *isexec;
struct double_list functions;
unsigned options, jobcnt;
int hfd, pid, varslen, shift, cdcount;
diff --git a/android/linux/generated/help.h b/android/linux/generated/help.h
index 24358961..fe814ec0 100644
--- a/android/linux/generated/help.h
+++ b/android/linux/generated/help.h
@@ -124,11 +124,11 @@
#define HELP_netstat "usage: netstat [-pWrxwutneal]\n\nDisplay networking information. Default is netstat -tuwx\n\n-r Routing table\n-a All sockets (not just connected)\n-l Listening server sockets\n-t TCP sockets\n-u UDP sockets\n-w Raw sockets\n-x Unix sockets\n-e Extended info\n-n Don't resolve names\n-W Wide display\n-p Show PID/program name of sockets"
-#define HELP_netcat_listen "usage: netcat [-t] [-lL COMMAND...]\n\n-l Listen for one incoming connection\n-L Listen for multiple incoming connections (server mode)\n-t Allocate tty (must come before -l or -L)\n\nThe command line after -l or -L is executed (as a child process) to handle\neach incoming connection. If blank -l waits for a connection and forwards\nit to stdin/stdout. If no -p specified, -l prints port it bound to and\nbackgrounds itself (returning immediately).\n\nFor a quick-and-dirty server, try something like:\nnetcat -s 127.0.0.1 -p 1234 -tL /bin/bash -l"
+#define HELP_netcat_listen "usage: netcat [-tElL]\n\n-l Listen for one incoming connection, then exit\n-L Listen and background each incoming connection (server mode)\n-t Allocate tty\n-E Forward stderr\n\nWhen listening the COMMAND line is executed as a child process to handle\nan incoming connection. With no COMMAND -l forwards the connection\nto stdin/stdout. If no -p specified, -l prints the port it bound to and\nbackgrounds itself (returning immediately).\n\nFor a quick-and-dirty server, try something like:\nnetcat -s 127.0.0.1 -p 1234 -tL sh -l"
-#define HELP_netcat "usage: netcat [-46U] [-u] [-wpq #] [-s addr] {IPADDR PORTNUM|-f FILENAME}\n\nForward stdin/stdout to a file or network connection.\n\n-4 Force IPv4\n-6 Force IPv6\n-f Use FILENAME (ala /dev/ttyS0) instead of network\n-p Local port number\n-q Quit SECONDS after EOF on stdin, even if stdout hasn't closed yet\n-s Local source address\n-u Use UDP\n-U Use a UNIX domain socket\n-w SECONDS timeout to establish connection\n-W SECONDS timeout for more data on an idle connection\n\nUse \"stty 115200 -F /dev/ttyS0 && stty raw -echo -ctlecho\" with\nnetcat -f to connect to a serial port."
+#define HELP_netcat "usage: netcat [-46U] [-u] [-wpq #] [-s addr] {IPADDR PORTNUM|-f FILENAME|COMMAND...}\n\nForward stdin/stdout to a file or network connection.\n\n-4 Force IPv4\n-6 Force IPv6\n-f Use FILENAME (ala /dev/ttyS0) instead of network\n-p Local port number\n-q Quit SECONDS after EOF on stdin, even if stdout hasn't closed yet\n-s Local source address\n-u Use UDP\n-U Use a UNIX domain socket\n-w SECONDS timeout to establish connection\n-W SECONDS timeout for more data on an idle connection\n\nUse \"stty 115200 -F /dev/ttyS0 && stty raw -echo -ctlecho\" with\nnetcat -f to connect to a serial port."
-#define HELP_microcom "usage: microcom [-s SPEED] [-X] DEVICE\n\nSimple serial console.\n\n-s Set baud rate to SPEED\n-X Ignore ^@ (send break) and ^] (exit)"
+#define HELP_microcom "usage: microcom [-s SPEED] [-X] DEVICE\n\nSimple serial console.\n\n-s Set baud rate to SPEED (default 115200)\n-X Ignore ^@ (send break) and ^] (exit)"
#define HELP_ifconfig "usage: ifconfig [-aS] [INTERFACE [ACTION...]]\n\nDisplay or configure network interface.\n\nWith no arguments, display active interfaces. First argument is interface\nto operate on, one argument by itself displays that interface.\n\n-a All interfaces displayed, not just active ones\n-S Short view, one line per interface\n\nStandard ACTIONs to perform on an INTERFACE:\n\nADDR[/MASK] - set IPv4 address (1.2.3.4/5) and activate interface\nadd|del ADDR[/LEN] - add/remove IPv6 address (1111::8888/128)\nup|down - activate or deactivate interface\n\nAdvanced ACTIONs (default values usually suffice):\n\ndefault - remove IPv4 address\nnetmask ADDR - set IPv4 netmask via 255.255.255.0 instead of /24\ntxqueuelen LEN - number of buffered packets before output blocks\nmtu LEN - size of outgoing packets (Maximum Transmission Unit)\nbroadcast ADDR - Set broadcast address\npointopoint ADDR - PPP and PPPOE use this instead of \"route add default gw\"\nhw TYPE ADDR - set hardware (mac) address (type = ether|infiniband)\n\nFlags you can set on an interface (or -remove by prefixing with -):\n\narp - don't use Address Resolution Protocol to map LAN routes\npromisc - don't discard packets that aren't to this LAN hardware address\nmulticast - force interface into multicast mode if the driver doesn't\nallmulti - promisc for multicast packets"
@@ -500,7 +500,7 @@
#define HELP_sleep "usage: sleep DURATION\n\nWait before exiting.\n\nDURATION can be a decimal fraction. An optional suffix can be \"m\"\n(minutes), \"h\" (hours), \"d\" (days), or \"s\" (seconds, the default)."
-#define HELP_sed "usage: sed [-inrzE] [-e SCRIPT]...|SCRIPT [-f SCRIPT_FILE]... [FILE...]\n\nStream editor. Apply one or more editing SCRIPTs to each line of input\n(from FILE or stdin) producing output (by default to stdout).\n\n-e Add SCRIPT to list\n-f Add contents of SCRIPT_FILE to list\n-i Edit each file in place (-iEXT keeps backup file with extension EXT)\n-n No default output (use the p command to output matched lines)\n-r Use extended regular expression syntax\n-E POSIX alias for -r\n-s Treat input files separately (implied by -i)\n-z Use \\0 rather than \\n as the input line separator\n\nA SCRIPT is a series of one or more COMMANDs separated by newlines or\nsemicolons. All -e SCRIPTs are concatenated together as if separated\nby newlines, followed by all lines from -f SCRIPT_FILEs, in order.\nIf no -e or -f SCRIPTs are specified, the first argument is the SCRIPT.\n\nEach COMMAND may be preceded by an address which limits the command to\napply only to the specified line(s). Commands without an address apply to\nevery line. Addresses are of the form:\n\n [ADDRESS[,ADDRESS]][!]COMMAND\n\nThe ADDRESS may be a decimal line number (starting at 1), a /regular\nexpression/ within a pair of forward slashes, or the character \"$\" which\nmatches the last line of input. (In -s or -i mode this matches the last\nline of each file, otherwise just the last line of the last file.) A single\naddress matches one line, a pair of comma separated addresses match\neverything from the first address to the second address (inclusive). If\nboth addresses are regular expressions, more than one range of lines in\neach file can match. The second address can be +N to end N lines later.\n\nREGULAR EXPRESSIONS in sed are started and ended by the same character\n(traditionally / but anything except a backslash or a newline works).\nBackslashes may be used to escape the delimiter if it occurs in the\nregex, and for the usual printf escapes (\\abcefnrtv and octal, hex,\nand unicode). An empty regex repeats the previous one. ADDRESS regexes\n(above) require the first delimiter to be escaped with a backslash when\nit isn't a forward slash (to distinguish it from the COMMANDs below).\n\nSed mostly operates on individual lines one at a time. It reads each line,\nprocesses it, and either writes it to the output or discards it before\nreading the next line. Sed can remember one additional line in a separate\nbuffer (using the h, H, g, G, and x commands), and can read the next line\nof input early (using the n and N command), but other than that command\nscripts operate on individual lines of text.\n\nEach COMMAND starts with a single character. The following commands take\nno arguments:\n\n ! Run this command when the test _didn't_ match.\n\n { Start a new command block, continuing until a corresponding \"}\".\n Command blocks may nest. If the block has an address, commands within\n the block are only run for lines within the block's address range.\n\n } End command block (this command cannot have an address)\n\n d Delete this line and move on to the next one\n (ignores remaining COMMANDs)\n\n D Delete one line of input and restart command SCRIPT (same as \"d\"\n unless you've glued lines together with \"N\" or similar)\n\n g Get remembered line (overwriting current line)\n\n G Get remembered line (appending to current line)\n\n h Remember this line (overwriting remembered line)\n\n H Remember this line (appending to remembered line, if any)\n\n l Print line, escaping \\abfrtv (but not newline), octal escaping other\n nonprintable characters, wrapping lines to terminal width with a\n backslash, and appending $ to actual end of line.\n\n n Print default output and read next line, replacing current line\n (If no next line available, quit processing script)\n\n N Append next line of input to this line, separated by a newline\n (This advances the line counter for address matching and \"=\", if no\n next line available quit processing script without default output)\n\n p Print this line\n\n P Print this line up to first newline (from \"N\")\n\n q Quit (print default output, no more commands processed or lines read)\n\n x Exchange this line with remembered line (overwrite in both directions)\n\n = Print the current line number (followed by a newline)\n\nThe following commands (may) take an argument. The \"text\" arguments (to\nthe \"a\", \"b\", and \"c\" commands) may end with an unescaped \"\\\" to append\nthe next line (for which leading whitespace is not skipped), and also\ntreat \";\" as a literal character (use \"\\;\" instead).\n\n a [text] Append text to output before attempting to read next line\n\n b [label] Branch, jumps to :label (or with no label, to end of SCRIPT)\n\n c [text] Delete line, output text at end of matching address range\n (ignores remaining COMMANDs)\n\n i [text] Print text\n\n r [file] Append contents of file to output before attempting to read\n next line.\n\n s/S/R/F Search for regex S, replace matched text with R using flags F.\n The first character after the \"s\" (anything but newline or\n backslash) is the delimiter, escape with \\ to use normally.\n\n The replacement text may contain \"&\" to substitute the matched\n text (escape it with backslash for a literal &), or \\1 through\n \\9 to substitute a parenthetical subexpression in the regex.\n You can also use the normal backslash escapes such as \\n and\n a backslash at the end of the line appends the next line.\n\n The flags are:\n\n [0-9] A number, substitute only that occurrence of pattern\n g Global, substitute all occurrences of pattern\n i/I Ignore case when matching\n p Print the line if match was found and replaced\n w [file] Write (append) line to file if match replaced\n\n t [label] Test, jump to :label only if an \"s\" command found a match in\n this line since last test (replacing with same text counts)\n\n T [label] Test false, jump only if \"s\" hasn't found a match.\n\n w [file] Write (append) line to file\n\n y/old/new/ Change each character in 'old' to corresponding character\n in 'new' (with standard backslash escapes, delimiter can be\n any repeated character except \\ or \\n)\n\n : [label] Labeled target for jump commands\n\n # Comment, ignore rest of this line of SCRIPT\n\nDeviations from POSIX: allow extended regular expressions with -r,\nediting in place with -i, separate with -s, NUL-separated input with -z,\nprintf escapes in text, line continuations, semicolons after all commands,\n2-address anywhere an address is allowed, \"T\" command, multiline\ncontinuations for [abc], \\; to end [abc] argument before end of line."
+#define HELP_sed "usage: sed [-inrzE] [-e SCRIPT]...|SCRIPT [-f SCRIPT_FILE]... [FILE...]\n\nStream editor. Apply editing SCRIPTs to lines of input.\n\n-e Add SCRIPT to list\n-f Add contents of SCRIPT_FILE to list\n-i Edit each file in place (-iEXT keeps backup file with extension EXT)\n-n No default output (use the p command to output matched lines)\n-r Use extended regular expression syntax\n-E POSIX alias for -r\n-s Treat input files separately (implied by -i)\n-z Use \\0 rather than \\n as input line separator\n\nA SCRIPT is one or more COMMANDs separated by newlines or semicolons.\nAll -e SCRIPTs are combined as if separated by newlines, followed by all -f\nSCRIPT_FILEs. If no -e or -f then first argument is the SCRIPT.\n\nCOMMANDs apply to every line unless prefixed with an ADDRESS of the form:\n\n [ADDRESS[,ADDRESS]][!]COMMAND\n\nADDRESS is a line number (starting at 1), a /REGULAR EXPRESSION/, or $ for\nlast line (-s or -i makes it last line of each file). One address matches one\nline, ADDRESS,ADDRESS matches from first to second inclusive. Two regexes can\nmatch multiple ranges. ADDRESS,+N ends N lines later. ! inverts the match.\n\nREGULAR EXPRESSIONS start and end with the same character (anything but\nbackslash or newline). To use the delimiter in the regex escape it with a\nbackslash, and printf escapes (\\abcefnrtv and octal, hex, and unicode) work.\nAn empty regex repeats the previous one. ADDRESS regexes require any\nfirst delimiter except / to be \\escaped to distinguish it from COMMANDs.\n\nSed reads each line of input, processes it, and writes it out or discards it\nbefore reading the next. Sed can remember one additional line in a separate\nbuffer (the h, H, g, G, and x commands), and can read the next line of input\nearly (the n and N commands), but otherwise operates on individual lines.\n\nEach COMMAND starts with a single character. Commands with no arguments are:\n\n ! Run this command when the ADDRESS _didn't_ match.\n { Start new command block, continuing until a corresponding \"}\".\n Command blocks nest and can have ADDRESSes applying to the whole block.\n } End command block (this COMMAND cannot have an address)\n d Delete this line and move on to the next one\n (ignores remaining COMMANDs)\n D Delete one line of input and restart command SCRIPT (same as \"d\"\n unless you've glued lines together with \"N\" or similar)\n g Get remembered line (overwriting current line)\n G Get remembered line (appending to current line)\n h Remember this line (overwriting remembered line)\n H Remember this line (appending to remembered line, if any)\n l Print line escaping \\abfrtv (but not \\n), octal escape other nonprintng\n chars, wrap lines to terminal width with \\, append $ to end of line.\n n Print default output and read next line over current line (quit at EOF)\n N Append \\n and next line of input to this line. Quit at EOF without\n default output. Advances line counter for ADDRESS and \"=\".\n p Print this line\n P Print this line up to first newline (from \"N\")\n q Quit (print default output, no more commands processed or lines read)\n x Exchange this line with remembered line (overwrite in both directions)\n = Print the current line number (plus newline)\n # Comment, ignores rest of this line of SCRIPT (until newline)\n\nCommands that take an argument:\n\n : LABEL Target for jump commands\n a TEXT Append text to output before reading next line\n b LABEL Branch, jumps to :LABEL (with no LABEL to end of SCRIPT)\n c TEXT Delete matching ADDRESS range and output TEXT instead\n i TEXT Insert text (output immediately)\n r FILE Append contents of FILIE to output before reading next line.\n s/S/R/F Search for regex S replace match with R using flags F. Delimiter\n is anything but \\n or \\, escape with \\ to use in S or R. Printf\n escapes work. Unescaped & in R becomes full matched text, \\1\n through \\9 = parenthetical subexpression from S. \\ at end of\n line appends next line of SCRIPT. The flags in F are:\n [0-9] A number N, substitute only Nth match\n g Global, substitute all matches\n i/I Ignore case when matching\n p Print resulting line when match found and replaced\n w [file] Write (append) line to file when match replaced\n t LABEL Test, jump if s/// command matched this line since last test\n T LABEL Test false, jump to :LABEL only if no s/// found a match\n w FILE Write (append) line to file\n y/old/new/ Change each character in 'old' to corresponding character\n in 'new' (with standard backslash escapes, delimiter can be\n any repeated character except \\ or \\n)\n\nThe TEXT arguments (to a c i) may end with an unescaped \"\\\" to append\nthe next line (leading whitespace is not skipped), and treat \";\" as a\nliteral character (use \"\\;\" instead)."
#define HELP_rmdir "usage: rmdir [-p] [DIR...]\n\nRemove one or more directories.\n\n-p Remove path\n--ignore-fail-on-non-empty Ignore failures caused by non-empty directories"
diff --git a/android/linux/generated/newtoys.h b/android/linux/generated/newtoys.h
index 0a5aa949..95fa3082 100644
--- a/android/linux/generated/newtoys.h
+++ b/android/linux/generated/newtoys.h
@@ -29,7 +29,7 @@ USE_SH(NEWTOY(cd, ">1LP[-LP]", TOYFLAG_NOFORK))
USE_CHATTR(NEWTOY(chattr, "?p#v#R", TOYFLAG_BIN))
USE_CHCON(NEWTOY(chcon, "<2hvR", TOYFLAG_USR|TOYFLAG_BIN))
USE_CHGRP(NEWTOY(chgrp, "<2hPLHRfv[-HLP]", TOYFLAG_BIN))
-USE_CHMOD(NEWTOY(chmod, "<2?vRf[-vf]", TOYFLAG_BIN))
+USE_CHMOD(NEWTOY(chmod, "<2?vfR[-vf]", TOYFLAG_BIN))
USE_CHOWN(OLDTOY(chown, chgrp, TOYFLAG_BIN))
USE_CHROOT(NEWTOY(chroot, "^<1", TOYFLAG_USR|TOYFLAG_SBIN|TOYFLAG_ARGFAIL(125)))
USE_CHRT(NEWTOY(chrt, "^mp#<0iRbrfo[!ibrfo]", TOYFLAG_USR|TOYFLAG_BIN))
@@ -161,7 +161,7 @@ USE_MAN(NEWTOY(man, "k:M:", TOYFLAG_USR|TOYFLAG_BIN))
USE_MCOOKIE(NEWTOY(mcookie, "v(verbose)V(version)", TOYFLAG_USR|TOYFLAG_BIN))
USE_MD5SUM(NEWTOY(md5sum, "bc(check)s(status)[!bc]", TOYFLAG_USR|TOYFLAG_BIN))
USE_MDEV(NEWTOY(mdev, "s", TOYFLAG_USR|TOYFLAG_BIN|TOYFLAG_UMASK))
-USE_MICROCOM(NEWTOY(microcom, "<1>1s:X", TOYFLAG_USR|TOYFLAG_BIN))
+USE_MICROCOM(NEWTOY(microcom, "<1>1s#=115200X", TOYFLAG_USR|TOYFLAG_BIN))
USE_MIX(NEWTOY(mix, "c:d:l#r#", TOYFLAG_USR|TOYFLAG_BIN))
USE_MKDIR(NEWTOY(mkdir, "<1"USE_MKDIR_Z("Z:")"vp(parent)(parents)m:", TOYFLAG_BIN|TOYFLAG_UMASK))
USE_MKE2FS(NEWTOY(mke2fs, "<1>2g:Fnqm#N#i#b#", TOYFLAG_SBIN))
@@ -179,7 +179,7 @@ USE_MV(NEWTOY(mv, "<2vnF(remove-destination)fiT[-ni]", TOYFLAG_BIN))
USE_NBD_CLIENT(OLDTOY(nbd-client, nbd_client, TOYFLAG_USR|TOYFLAG_BIN))
USE_NBD_CLIENT(NEWTOY(nbd_client, "<3>3ns", 0))
USE_NETCAT(OLDTOY(nc, netcat, TOYFLAG_USR|TOYFLAG_BIN))
-USE_NETCAT(NEWTOY(netcat, USE_NETCAT_LISTEN("^tlL")"w#<1W#<1p#<1>65535q#<1s:f:46uU"USE_NETCAT_LISTEN("[!tlL][!Lw]")"[!46U]", TOYFLAG_BIN))
+USE_NETCAT(NEWTOY(netcat, USE_NETCAT_LISTEN("^tElL")"w#<1W#<1p#<1>65535q#<1s:f:46uU"USE_NETCAT_LISTEN("[!tlL][!Lw]")"[!46U]", TOYFLAG_BIN))
USE_NETSTAT(NEWTOY(netstat, "pWrxwutneal", TOYFLAG_BIN))
USE_NICE(NEWTOY(nice, "^<1n#", TOYFLAG_BIN))
USE_NL(NEWTOY(nl, "v#=1l#w#<0=6Eb:n:s:", TOYFLAG_USR|TOYFLAG_BIN))
@@ -220,7 +220,7 @@ USE_RFKILL(NEWTOY(rfkill, "<1>2", TOYFLAG_USR|TOYFLAG_SBIN))
USE_RM(NEWTOY(rm, "fiRrv[-fi]", TOYFLAG_BIN))
USE_RMDIR(NEWTOY(rmdir, "<1(ignore-fail-on-non-empty)p", TOYFLAG_BIN))
USE_RMMOD(NEWTOY(rmmod, "<1wf", TOYFLAG_SBIN|TOYFLAG_NEEDROOT))
-USE_ROUTE(NEWTOY(route, "?neA:", TOYFLAG_BIN))
+USE_ROUTE(NEWTOY(route, "?neA:", TOYFLAG_SBIN))
USE_RTCWAKE(NEWTOY(rtcwake, "(list-modes);(auto)a(device)d:(local)l(mode)m:(seconds)s#(time)t#(utc)u(verbose)v[!alu]", TOYFLAG_USR|TOYFLAG_BIN))
USE_RUNCON(NEWTOY(runcon, "<2", TOYFLAG_USR|TOYFLAG_SBIN))
USE_SED(NEWTOY(sed, "(help)(version)e*f*i:;nErz(null-data)[+Er]", TOYFLAG_BIN|TOYFLAG_LOCALE|TOYFLAG_NOHELP))
diff --git a/android/mac/generated/flags.h b/android/mac/generated/flags.h
index c2d1dd3c..8f156ba1 100644
--- a/android/mac/generated/flags.h
+++ b/android/mac/generated/flags.h
@@ -268,14 +268,14 @@
#undef FLAG_h
#endif
-// chmod <2?vRf[-vf] <2?vRf[-vf]
+// chmod <2?vfR[-vf] <2?vfR[-vf]
#undef OPTSTR_chmod
-#define OPTSTR_chmod "<2?vRf[-vf]"
+#define OPTSTR_chmod "<2?vfR[-vf]"
#ifdef CLEANUP_chmod
#undef CLEANUP_chmod
#undef FOR_chmod
-#undef FLAG_f
#undef FLAG_R
+#undef FLAG_f
#undef FLAG_v
#endif
@@ -1793,9 +1793,9 @@
#undef FLAG_s
#endif
-// microcom <1>1s:X <1>1s:X
+// microcom <1>1s#=115200X <1>1s#=115200X
#undef OPTSTR_microcom
-#define OPTSTR_microcom "<1>1s:X"
+#define OPTSTR_microcom "<1>1s#=115200X"
#ifdef CLEANUP_microcom
#undef CLEANUP_microcom
#undef FOR_microcom
@@ -1986,9 +1986,9 @@
#undef FLAG_n
#endif
-// netcat ^tlLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]
+// netcat ^tElLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]
#undef OPTSTR_netcat
-#define OPTSTR_netcat "^tlLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]"
+#define OPTSTR_netcat "^tElLw#<1W#<1p#<1>65535q#<1s:f:46uU[!tlL][!Lw][!46U]"
#ifdef CLEANUP_netcat
#undef CLEANUP_netcat
#undef FOR_netcat
@@ -2004,6 +2004,7 @@
#undef FLAG_w
#undef FLAG_L
#undef FLAG_l
+#undef FLAG_E
#undef FLAG_t
#endif
@@ -3725,8 +3726,8 @@
#ifndef TT
#define TT this.chmod
#endif
-#define FLAG_f (1<<0)
-#define FLAG_R (1<<1)
+#define FLAG_R (1<<0)
+#define FLAG_f (1<<1)
#define FLAG_v (1<<2)
#endif
@@ -5183,7 +5184,8 @@
#define FLAG_w (FORCED_FLAG<<9)
#define FLAG_L (FORCED_FLAG<<10)
#define FLAG_l (FORCED_FLAG<<11)
-#define FLAG_t (FORCED_FLAG<<12)
+#define FLAG_E (FORCED_FLAG<<12)
+#define FLAG_t (FORCED_FLAG<<13)
#endif
#ifdef FOR_netstat
diff --git a/android/mac/generated/globals.h b/android/mac/generated/globals.h
index 9f701ac6..1edc420f 100644
--- a/android/mac/generated/globals.h
+++ b/android/mac/generated/globals.h
@@ -159,7 +159,7 @@ struct ifconfig_data {
// toys/net/microcom.c
struct microcom_data {
- char *s;
+ long s;
int fd;
struct termios original_stdin_state, original_fd_state;
@@ -831,7 +831,7 @@ struct sh_data {
// keep lineno here, we use it to work around a compiler bug
long lineno;
- char *ifs;
+ char *ifs, *isexec;
struct double_list functions;
unsigned options, jobcnt;
int hfd, pid, varslen, shift, cdcount;
diff --git a/android/mac/generated/help.h b/android/mac/generated/help.h
index 24358961..fe814ec0 100644
--- a/android/mac/generated/help.h
+++ b/android/mac/generated/help.h
@@ -124,11 +124,11 @@
#define HELP_netstat "usage: netstat [-pWrxwutneal]\n\nDisplay networking information. Default is netstat -tuwx\n\n-r Routing table\n-a All sockets (not just connected)\n-l Listening server sockets\n-t TCP sockets\n-u UDP sockets\n-w Raw sockets\n-x Unix sockets\n-e Extended info\n-n Don't resolve names\n-W Wide display\n-p Show PID/program name of sockets"
-#define HELP_netcat_listen "usage: netcat [-t] [-lL COMMAND...]\n\n-l Listen for one incoming connection\n-L Listen for multiple incoming connections (server mode)\n-t Allocate tty (must come before -l or -L)\n\nThe command line after -l or -L is executed (as a child process) to handle\neach incoming connection. If blank -l waits for a connection and forwards\nit to stdin/stdout. If no -p specified, -l prints port it bound to and\nbackgrounds itself (returning immediately).\n\nFor a quick-and-dirty server, try something like:\nnetcat -s 127.0.0.1 -p 1234 -tL /bin/bash -l"
+#define HELP_netcat_listen "usage: netcat [-tElL]\n\n-l Listen for one incoming connection, then exit\n-L Listen and background each incoming connection (server mode)\n-t Allocate tty\n-E Forward stderr\n\nWhen listening the COMMAND line is executed as a child process to handle\nan incoming connection. With no COMMAND -l forwards the connection\nto stdin/stdout. If no -p specified, -l prints the port it bound to and\nbackgrounds itself (returning immediately).\n\nFor a quick-and-dirty server, try something like:\nnetcat -s 127.0.0.1 -p 1234 -tL sh -l"
-#define HELP_netcat "usage: netcat [-46U] [-u] [-wpq #] [-s addr] {IPADDR PORTNUM|-f FILENAME}\n\nForward stdin/stdout to a file or network connection.\n\n-4 Force IPv4\n-6 Force IPv6\n-f Use FILENAME (ala /dev/ttyS0) instead of network\n-p Local port number\n-q Quit SECONDS after EOF on stdin, even if stdout hasn't closed yet\n-s Local source address\n-u Use UDP\n-U Use a UNIX domain socket\n-w SECONDS timeout to establish connection\n-W SECONDS timeout for more data on an idle connection\n\nUse \"stty 115200 -F /dev/ttyS0 && stty raw -echo -ctlecho\" with\nnetcat -f to connect to a serial port."
+#define HELP_netcat "usage: netcat [-46U] [-u] [-wpq #] [-s addr] {IPADDR PORTNUM|-f FILENAME|COMMAND...}\n\nForward stdin/stdout to a file or network connection.\n\n-4 Force IPv4\n-6 Force IPv6\n-f Use FILENAME (ala /dev/ttyS0) instead of network\n-p Local port number\n-q Quit SECONDS after EOF on stdin, even if stdout hasn't closed yet\n-s Local source address\n-u Use UDP\n-U Use a UNIX domain socket\n-w SECONDS timeout to establish connection\n-W SECONDS timeout for more data on an idle connection\n\nUse \"stty 115200 -F /dev/ttyS0 && stty raw -echo -ctlecho\" with\nnetcat -f to connect to a serial port."
-#define HELP_microcom "usage: microcom [-s SPEED] [-X] DEVICE\n\nSimple serial console.\n\n-s Set baud rate to SPEED\n-X Ignore ^@ (send break) and ^] (exit)"
+#define HELP_microcom "usage: microcom [-s SPEED] [-X] DEVICE\n\nSimple serial console.\n\n-s Set baud rate to SPEED (default 115200)\n-X Ignore ^@ (send break) and ^] (exit)"
#define HELP_ifconfig "usage: ifconfig [-aS] [INTERFACE [ACTION...]]\n\nDisplay or configure network interface.\n\nWith no arguments, display active interfaces. First argument is interface\nto operate on, one argument by itself displays that interface.\n\n-a All interfaces displayed, not just active ones\n-S Short view, one line per interface\n\nStandard ACTIONs to perform on an INTERFACE:\n\nADDR[/MASK] - set IPv4 address (1.2.3.4/5) and activate interface\nadd|del ADDR[/LEN] - add/remove IPv6 address (1111::8888/128)\nup|down - activate or deactivate interface\n\nAdvanced ACTIONs (default values usually suffice):\n\ndefault - remove IPv4 address\nnetmask ADDR - set IPv4 netmask via 255.255.255.0 instead of /24\ntxqueuelen LEN - number of buffered packets before output blocks\nmtu LEN - size of outgoing packets (Maximum Transmission Unit)\nbroadcast ADDR - Set broadcast address\npointopoint ADDR - PPP and PPPOE use this instead of \"route add default gw\"\nhw TYPE ADDR - set hardware (mac) address (type = ether|infiniband)\n\nFlags you can set on an interface (or -remove by prefixing with -):\n\narp - don't use Address Resolution Protocol to map LAN routes\npromisc - don't discard packets that aren't to this LAN hardware address\nmulticast - force interface into multicast mode if the driver doesn't\nallmulti - promisc for multicast packets"
@@ -500,7 +500,7 @@
#define HELP_sleep "usage: sleep DURATION\n\nWait before exiting.\n\nDURATION can be a decimal fraction. An optional suffix can be \"m\"\n(minutes), \"h\" (hours), \"d\" (days), or \"s\" (seconds, the default)."
-#define HELP_sed "usage: sed [-inrzE] [-e SCRIPT]...|SCRIPT [-f SCRIPT_FILE]... [FILE...]\n\nStream editor. Apply one or more editing SCRIPTs to each line of input\n(from FILE or stdin) producing output (by default to stdout).\n\n-e Add SCRIPT to list\n-f Add contents of SCRIPT_FILE to list\n-i Edit each file in place (-iEXT keeps backup file with extension EXT)\n-n No default output (use the p command to output matched lines)\n-r Use extended regular expression syntax\n-E POSIX alias for -r\n-s Treat input files separately (implied by -i)\n-z Use \\0 rather than \\n as the input line separator\n\nA SCRIPT is a series of one or more COMMANDs separated by newlines or\nsemicolons. All -e SCRIPTs are concatenated together as if separated\nby newlines, followed by all lines from -f SCRIPT_FILEs, in order.\nIf no -e or -f SCRIPTs are specified, the first argument is the SCRIPT.\n\nEach COMMAND may be preceded by an address which limits the command to\napply only to the specified line(s). Commands without an address apply to\nevery line. Addresses are of the form:\n\n [ADDRESS[,ADDRESS]][!]COMMAND\n\nThe ADDRESS may be a decimal line number (starting at 1), a /regular\nexpression/ within a pair of forward slashes, or the character \"$\" which\nmatches the last line of input. (In -s or -i mode this matches the last\nline of each file, otherwise just the last line of the last file.) A single\naddress matches one line, a pair of comma separated addresses match\neverything from the first address to the second address (inclusive). If\nboth addresses are regular expressions, more than one range of lines in\neach file can match. The second address can be +N to end N lines later.\n\nREGULAR EXPRESSIONS in sed are started and ended by the same character\n(traditionally / but anything except a backslash or a newline works).\nBackslashes may be used to escape the delimiter if it occurs in the\nregex, and for the usual printf escapes (\\abcefnrtv and octal, hex,\nand unicode). An empty regex repeats the previous one. ADDRESS regexes\n(above) require the first delimiter to be escaped with a backslash when\nit isn't a forward slash (to distinguish it from the COMMANDs below).\n\nSed mostly operates on individual lines one at a time. It reads each line,\nprocesses it, and either writes it to the output or discards it before\nreading the next line. Sed can remember one additional line in a separate\nbuffer (using the h, H, g, G, and x commands), and can read the next line\nof input early (using the n and N command), but other than that command\nscripts operate on individual lines of text.\n\nEach COMMAND starts with a single character. The following commands take\nno arguments:\n\n ! Run this command when the test _didn't_ match.\n\n { Start a new command block, continuing until a corresponding \"}\".\n Command blocks may nest. If the block has an address, commands within\n the block are only run for lines within the block's address range.\n\n } End command block (this command cannot have an address)\n\n d Delete this line and move on to the next one\n (ignores remaining COMMANDs)\n\n D Delete one line of input and restart command SCRIPT (same as \"d\"\n unless you've glued lines together with \"N\" or similar)\n\n g Get remembered line (overwriting current line)\n\n G Get remembered line (appending to current line)\n\n h Remember this line (overwriting remembered line)\n\n H Remember this line (appending to remembered line, if any)\n\n l Print line, escaping \\abfrtv (but not newline), octal escaping other\n nonprintable characters, wrapping lines to terminal width with a\n backslash, and appending $ to actual end of line.\n\n n Print default output and read next line, replacing current line\n (If no next line available, quit processing script)\n\n N Append next line of input to this line, separated by a newline\n (This advances the line counter for address matching and \"=\", if no\n next line available quit processing script without default output)\n\n p Print this line\n\n P Print this line up to first newline (from \"N\")\n\n q Quit (print default output, no more commands processed or lines read)\n\n x Exchange this line with remembered line (overwrite in both directions)\n\n = Print the current line number (followed by a newline)\n\nThe following commands (may) take an argument. The \"text\" arguments (to\nthe \"a\", \"b\", and \"c\" commands) may end with an unescaped \"\\\" to append\nthe next line (for which leading whitespace is not skipped), and also\ntreat \";\" as a literal character (use \"\\;\" instead).\n\n a [text] Append text to output before attempting to read next line\n\n b [label] Branch, jumps to :label (or with no label, to end of SCRIPT)\n\n c [text] Delete line, output text at end of matching address range\n (ignores remaining COMMANDs)\n\n i [text] Print text\n\n r [file] Append contents of file to output before attempting to read\n next line.\n\n s/S/R/F Search for regex S, replace matched text with R using flags F.\n The first character after the \"s\" (anything but newline or\n backslash) is the delimiter, escape with \\ to use normally.\n\n The replacement text may contain \"&\" to substitute the matched\n text (escape it with backslash for a literal &), or \\1 through\n \\9 to substitute a parenthetical subexpression in the regex.\n You can also use the normal backslash escapes such as \\n and\n a backslash at the end of the line appends the next line.\n\n The flags are:\n\n [0-9] A number, substitute only that occurrence of pattern\n g Global, substitute all occurrences of pattern\n i/I Ignore case when matching\n p Print the line if match was found and replaced\n w [file] Write (append) line to file if match replaced\n\n t [label] Test, jump to :label only if an \"s\" command found a match in\n this line since last test (replacing with same text counts)\n\n T [label] Test false, jump only if \"s\" hasn't found a match.\n\n w [file] Write (append) line to file\n\n y/old/new/ Change each character in 'old' to corresponding character\n in 'new' (with standard backslash escapes, delimiter can be\n any repeated character except \\ or \\n)\n\n : [label] Labeled target for jump commands\n\n # Comment, ignore rest of this line of SCRIPT\n\nDeviations from POSIX: allow extended regular expressions with -r,\nediting in place with -i, separate with -s, NUL-separated input with -z,\nprintf escapes in text, line continuations, semicolons after all commands,\n2-address anywhere an address is allowed, \"T\" command, multiline\ncontinuations for [abc], \\; to end [abc] argument before end of line."
+#define HELP_sed "usage: sed [-inrzE] [-e SCRIPT]...|SCRIPT [-f SCRIPT_FILE]... [FILE...]\n\nStream editor. Apply editing SCRIPTs to lines of input.\n\n-e Add SCRIPT to list\n-f Add contents of SCRIPT_FILE to list\n-i Edit each file in place (-iEXT keeps backup file with extension EXT)\n-n No default output (use the p command to output matched lines)\n-r Use extended regular expression syntax\n-E POSIX alias for -r\n-s Treat input files separately (implied by -i)\n-z Use \\0 rather than \\n as input line separator\n\nA SCRIPT is one or more COMMANDs separated by newlines or semicolons.\nAll -e SCRIPTs are combined as if separated by newlines, followed by all -f\nSCRIPT_FILEs. If no -e or -f then first argument is the SCRIPT.\n\nCOMMANDs apply to every line unless prefixed with an ADDRESS of the form:\n\n [ADDRESS[,ADDRESS]][!]COMMAND\n\nADDRESS is a line number (starting at 1), a /REGULAR EXPRESSION/, or $ for\nlast line (-s or -i makes it last line of each file). One address matches one\nline, ADDRESS,ADDRESS matches from first to second inclusive. Two regexes can\nmatch multiple ranges. ADDRESS,+N ends N lines later. ! inverts the match.\n\nREGULAR EXPRESSIONS start and end with the same character (anything but\nbackslash or newline). To use the delimiter in the regex escape it with a\nbackslash, and printf escapes (\\abcefnrtv and octal, hex, and unicode) work.\nAn empty regex repeats the previous one. ADDRESS regexes require any\nfirst delimiter except / to be \\escaped to distinguish it from COMMANDs.\n\nSed reads each line of input, processes it, and writes it out or discards it\nbefore reading the next. Sed can remember one additional line in a separate\nbuffer (the h, H, g, G, and x commands), and can read the next line of input\nearly (the n and N commands), but otherwise operates on individual lines.\n\nEach COMMAND starts with a single character. Commands with no arguments are:\n\n ! Run this command when the ADDRESS _didn't_ match.\n { Start new command block, continuing until a corresponding \"}\".\n Command blocks nest and can have ADDRESSes applying to the whole block.\n } End command block (this COMMAND cannot have an address)\n d Delete this line and move on to the next one\n (ignores remaining COMMANDs)\n D Delete one line of input and restart command SCRIPT (same as \"d\"\n unless you've glued lines together with \"N\" or similar)\n g Get remembered line (overwriting current line)\n G Get remembered line (appending to current line)\n h Remember this line (overwriting remembered line)\n H Remember this line (appending to remembered line, if any)\n l Print line escaping \\abfrtv (but not \\n), octal escape other nonprintng\n chars, wrap lines to terminal width with \\, append $ to end of line.\n n Print default output and read next line over current line (quit at EOF)\n N Append \\n and next line of input to this line. Quit at EOF without\n default output. Advances line counter for ADDRESS and \"=\".\n p Print this line\n P Print this line up to first newline (from \"N\")\n q Quit (print default output, no more commands processed or lines read)\n x Exchange this line with remembered line (overwrite in both directions)\n = Print the current line number (plus newline)\n # Comment, ignores rest of this line of SCRIPT (until newline)\n\nCommands that take an argument:\n\n : LABEL Target for jump commands\n a TEXT Append text to output before reading next line\n b LABEL Branch, jumps to :LABEL (with no LABEL to end of SCRIPT)\n c TEXT Delete matching ADDRESS range and output TEXT instead\n i TEXT Insert text (output immediately)\n r FILE Append contents of FILIE to output before reading next line.\n s/S/R/F Search for regex S replace match with R using flags F. Delimiter\n is anything but \\n or \\, escape with \\ to use in S or R. Printf\n escapes work. Unescaped & in R becomes full matched text, \\1\n through \\9 = parenthetical subexpression from S. \\ at end of\n line appends next line of SCRIPT. The flags in F are:\n [0-9] A number N, substitute only Nth match\n g Global, substitute all matches\n i/I Ignore case when matching\n p Print resulting line when match found and replaced\n w [file] Write (append) line to file when match replaced\n t LABEL Test, jump if s/// command matched this line since last test\n T LABEL Test false, jump to :LABEL only if no s/// found a match\n w FILE Write (append) line to file\n y/old/new/ Change each character in 'old' to corresponding character\n in 'new' (with standard backslash escapes, delimiter can be\n any repeated character except \\ or \\n)\n\nThe TEXT arguments (to a c i) may end with an unescaped \"\\\" to append\nthe next line (leading whitespace is not skipped), and treat \";\" as a\nliteral character (use \"\\;\" instead)."
#define HELP_rmdir "usage: rmdir [-p] [DIR...]\n\nRemove one or more directories.\n\n-p Remove path\n--ignore-fail-on-non-empty Ignore failures caused by non-empty directories"
diff --git a/android/mac/generated/newtoys.h b/android/mac/generated/newtoys.h
index 0a5aa949..95fa3082 100644
--- a/android/mac/generated/newtoys.h
+++ b/android/mac/generated/newtoys.h
@@ -29,7 +29,7 @@ USE_SH(NEWTOY(cd, ">1LP[-LP]", TOYFLAG_NOFORK))
USE_CHATTR(NEWTOY(chattr, "?p#v#R", TOYFLAG_BIN))
USE_CHCON(NEWTOY(chcon, "<2hvR", TOYFLAG_USR|TOYFLAG_BIN))
USE_CHGRP(NEWTOY(chgrp, "<2hPLHRfv[-HLP]", TOYFLAG_BIN))
-USE_CHMOD(NEWTOY(chmod, "<2?vRf[-vf]", TOYFLAG_BIN))
+USE_CHMOD(NEWTOY(chmod, "<2?vfR[-vf]", TOYFLAG_BIN))
USE_CHOWN(OLDTOY(chown, chgrp, TOYFLAG_BIN))
USE_CHROOT(NEWTOY(chroot, "^<1", TOYFLAG_USR|TOYFLAG_SBIN|TOYFLAG_ARGFAIL(125)))
USE_CHRT(NEWTOY(chrt, "^mp#<0iRbrfo[!ibrfo]", TOYFLAG_USR|TOYFLAG_BIN))
@@ -161,7 +161,7 @@ USE_MAN(NEWTOY(man, "k:M:", TOYFLAG_USR|TOYFLAG_BIN))
USE_MCOOKIE(NEWTOY(mcookie, "v(verbose)V(version)", TOYFLAG_USR|TOYFLAG_BIN))
USE_MD5SUM(NEWTOY(md5sum, "bc(check)s(status)[!bc]", TOYFLAG_USR|TOYFLAG_BIN))
USE_MDEV(NEWTOY(mdev, "s", TOYFLAG_USR|TOYFLAG_BIN|TOYFLAG_UMASK))
-USE_MICROCOM(NEWTOY(microcom, "<1>1s:X", TOYFLAG_USR|TOYFLAG_BIN))
+USE_MICROCOM(NEWTOY(microcom, "<1>1s#=115200X", TOYFLAG_USR|TOYFLAG_BIN))
USE_MIX(NEWTOY(mix, "c:d:l#r#", TOYFLAG_USR|TOYFLAG_BIN))
USE_MKDIR(NEWTOY(mkdir, "<1"USE_MKDIR_Z("Z:")"vp(parent)(parents)m:", TOYFLAG_BIN|TOYFLAG_UMASK))
USE_MKE2FS(NEWTOY(mke2fs, "<1>2g:Fnqm#N#i#b#", TOYFLAG_SBIN))
@@ -179,7 +179,7 @@ USE_MV(NEWTOY(mv, "<2vnF(remove-destination)fiT[-ni]", TOYFLAG_BIN))
USE_NBD_CLIENT(OLDTOY(nbd-client, nbd_client, TOYFLAG_USR|TOYFLAG_BIN))
USE_NBD_CLIENT(NEWTOY(nbd_client, "<3>3ns", 0))
USE_NETCAT(OLDTOY(nc, netcat, TOYFLAG_USR|TOYFLAG_BIN))
-USE_NETCAT(NEWTOY(netcat, USE_NETCAT_LISTEN("^tlL")"w#<1W#<1p#<1>65535q#<1s:f:46uU"USE_NETCAT_LISTEN("[!tlL][!Lw]")"[!46U]", TOYFLAG_BIN))
+USE_NETCAT(NEWTOY(netcat, USE_NETCAT_LISTEN("^tElL")"w#<1W#<1p#<1>65535q#<1s:f:46uU"USE_NETCAT_LISTEN("[!tlL][!Lw]")"[!46U]", TOYFLAG_BIN))
USE_NETSTAT(NEWTOY(netstat, "pWrxwutneal", TOYFLAG_BIN))
USE_NICE(NEWTOY(nice, "^<1n#", TOYFLAG_BIN))
USE_NL(NEWTOY(nl, "v#=1l#w#<0=6Eb:n:s:", TOYFLAG_USR|TOYFLAG_BIN))
@@ -220,7 +220,7 @@ USE_RFKILL(NEWTOY(rfkill, "<1>2", TOYFLAG_USR|TOYFLAG_SBIN))
USE_RM(NEWTOY(rm, "fiRrv[-fi]", TOYFLAG_BIN))
USE_RMDIR(NEWTOY(rmdir, "<1(ignore-fail-on-non-empty)p", TOYFLAG_BIN))
USE_RMMOD(NEWTOY(rmmod, "<1wf", TOYFLAG_SBIN|TOYFLAG_NEEDROOT))
-USE_ROUTE(NEWTOY(route, "?neA:", TOYFLAG_BIN))
+USE_ROUTE(NEWTOY(route, "?neA:", TOYFLAG_SBIN))
USE_RTCWAKE(NEWTOY(rtcwake, "(list-modes);(auto)a(device)d:(local)l(mode)m:(seconds)s#(time)t#(utc)u(verbose)v[!alu]", TOYFLAG_USR|TOYFLAG_BIN))
USE_RUNCON(NEWTOY(runcon, "<2", TOYFLAG_USR|TOYFLAG_SBIN))
USE_SED(NEWTOY(sed, "(help)(version)e*f*i:;nErz(null-data)[+Er]", TOYFLAG_BIN|TOYFLAG_LOCALE|TOYFLAG_NOHELP))