xref: /third_party/toybox/www/roadmap.html (revision 0f66f451)
10f66f451Sopenharmony_ci<html><head><title>toybox roadmap</title>
20f66f451Sopenharmony_ci<!--#include file="header.html" -->
30f66f451Sopenharmony_ci<title>Toybox Roadmap</title>
40f66f451Sopenharmony_ci
50f66f451Sopenharmony_ci<h2>Roadmap sections</h2>
60f66f451Sopenharmony_ci
70f66f451Sopenharmony_ci<ul>
80f66f451Sopenharmony_ci<li><a href=#goals>Introduction</a></li>
90f66f451Sopenharmony_ci<li><a href=#susv4>POSIX-2008/SUSv4</a></li>
100f66f451Sopenharmony_ci<li><a href=#sigh>Linux "Standard" Base</a></li>
110f66f451Sopenharmony_ci<li><a href=#rfc>IETF RFCs and Man Pages</a></li>
120f66f451Sopenharmony_ci<li><a href=#dev_env>Development Environment</a></li>
130f66f451Sopenharmony_ci<li><a href=#android>Android Toolbox</a></li>
140f66f451Sopenharmony_ci<li><a href=#aosp>Building AOSP</a></li>
150f66f451Sopenharmony_ci<li><a href=#tizen>Tizen Core</a></li>
160f66f451Sopenharmony_ci<li><a href=#yocto>Yocto</a></li>
170f66f451Sopenharmony_ci<li><a href=#fhs>Filesystem Hierachy Standard</a></li>
180f66f451Sopenharmony_ci<li><a href=#buildroot>buildroot</a></li>
190f66f451Sopenharmony_ci<li>Miscelaneous: <a href=#klibc>klibc</a>, <a href=#glibc>glibc</a>,
200f66f451Sopenharmony_ci<a href=#sash>sash</a>, <a href=#sbase>sbase</a>,
210f66f451Sopenharmony_ci<a href=#uclinux>uclinux</a>...</li>
220f66f451Sopenharmony_ci<li><a href=#packages>Other Packages</a></li>
230f66f451Sopenharmony_ci</ul>
240f66f451Sopenharmony_ci
250f66f451Sopenharmony_ci<a name="goals" />
260f66f451Sopenharmony_ci<h2>Introduction (Goals and use cases)</h2>
270f66f451Sopenharmony_ci
280f66f451Sopenharmony_ci<p>We have several potential use cases for a new set of command line
290f66f451Sopenharmony_ciutilities, and are using those to determine which commands to implement
300f66f451Sopenharmony_cifor Toybox's 1.0 release. Most of these have their own section in the
310f66f451Sopenharmony_ci<a href=status.html>status page</a>, showing current progress towards
320f66f451Sopenharmony_cicommplation.</p>
330f66f451Sopenharmony_ci
340f66f451Sopenharmony_ci<p>The most interesting publicly available standards are A) POSIX-2008 (also
350f66f451Sopenharmony_ciknown as SUSv4), B) the Linux Standard Base version 4.1, and C) the official
360f66f451Sopenharmony_ci<a href=https://www.kernel.org/doc/man-pages/>Linux man pages</a>.
370f66f451Sopenharmony_ciBut they include commands we've decided not implement, exclude
380f66f451Sopenharmony_cicommands or features we have, and don't always entirely match reality.</p>
390f66f451Sopenharmony_ci
400f66f451Sopenharmony_ci<p>The most thorough real world test (other than a large interactive
410f66f451Sopenharmony_ciuserbase) is using toybox as the command line in a build system such as
420f66f451Sopenharmony_ci<a href=https://landley.net/aboriginal/about.html>Aboriginal
430f66f451Sopenharmony_ciLinux</a>, having it rebuild itself from source code, and using the result
440f66f451Sopenharmony_cito <a href=https://github.com/landley/control-images>build Linux From Scratch</a>.
450f66f451Sopenharmony_ciThe current "minimal native development system" goal is to use
460f66f451Sopenharmony_ci<a href=faq.html#mkroot>mkroot</a>
470f66f451Sopenharmony_ciplus <a href=faq.html#cross>musl-cross-make</a> to hermetically build
480f66f451Sopenharmony_ci<a href=https://source.android.com>AOSP</a>.</p>
490f66f451Sopenharmony_ci
500f66f451Sopenharmony_ci<p>We've also checked what commands were provided by similar projects
510f66f451Sopenharmony_ci(klibc, sash, sbase, embutils,
520f66f451Sopenharmony_cinash, and beastiebox), looked at various vendor configurations of busybox,
530f66f451Sopenharmony_ciand collected end user requests.</p>
540f66f451Sopenharmony_ci
550f66f451Sopenharmony_ci<p>Finally, we'd like to provide a good replacement for the Bash shell,
560f66f451Sopenharmony_ciwhich was the first program Linux ever ran and remains the standard shell
570f66f451Sopenharmony_ciof Linux (no matter what Ubuntu says). This doesn't necessarily mean including
580f66f451Sopenharmony_cievery last Bash 5.x feature, but does involve {various,features} &lt(beyond)
590f66f451Sopenharmony_ciposix.</p>
600f66f451Sopenharmony_ci
610f66f451Sopenharmony_ci<p>See the <a href=status.html>status page</a> for the categorized command list
620f66f451Sopenharmony_ciand progress towards implementing it. There's also a
630f66f451Sopenharmony_ci<a href=todo.html>historical todo list</a> from the project's 2011 relaunch.</p>
640f66f451Sopenharmony_ci
650f66f451Sopenharmony_ci<hr />
660f66f451Sopenharmony_ci<a name="standards">
670f66f451Sopenharmony_ci<h2>Use case: standards compliance.</h2>
680f66f451Sopenharmony_ci
690f66f451Sopenharmony_ci<h3><a name=susv4 /><a href="#susv4">POSIX-2008/SUSv4</a></h3>
700f66f451Sopenharmony_ci<p>The best standards describe reality rather than attempting to impose a
710f66f451Sopenharmony_cinew one. A good standard should document, not legislate.
720f66f451Sopenharmony_ciStandards which document existing reality tend to be approved by
730f66f451Sopenharmony_cimore than one standards body, such ANSI and ISO both approving <a href=https://landley.net/c99-draft.html>C99</a>. That's why IEEE 1003.1-2008,
740f66f451Sopenharmony_cithe Single Unix Specification version 4, and the Open Group Base Specification
750f66f451Sopenharmony_ciedition 7 are all the same standard from three sources, but most people just
760f66f451Sopenharmony_cicall it "posix" (portable operating system derived from unix).
770f66f451Sopenharmony_ciIt's available <a href=https://pubs.opengroup.org/onlinepubs/9699919799>online in full</a>, and may be downloaded as a tarball.
780f66f451Sopenharmony_ciPrevious versions (<a href=https://pubs.opengroup.org/onlinepubs/009695399/>SUSv3</a> and
790f66f451Sopenharmony_ci<a href=https://pubs.opengroup.org/onlinepubs/7990989775/>SUSv2</a>)
800f66f451Sopenharmony_ciare also available.
810f66f451Sopenharmony_ci(Note: 
820f66f451Sopenharmony_ci<a href=https://pubs.opengroup.org/onlinepubs/9699919799.2008edition/>Posix
830f66f451Sopenharmony_ci2008</a> was reissued in 2013 and 2018, the first was minor wordsmithing
840f66f451Sopenharmony_ciwith no behavioral changes, the second was to renew a ten year timeout
850f66f451Sopenharmony_cito still be considered a "current standard" by some government regulations.
860f66f451Sopenharmony_ciIt's still posix-2008/SUSv4/issue 7.)</p>
870f66f451Sopenharmony_ci
880f66f451Sopenharmony_ci<h3>Why not just use posix for everything?</h3>
890f66f451Sopenharmony_ci
900f66f451Sopenharmony_ci<p>Unfortunately, Posix describes an incomplete subset of reality, because
910f66f451Sopenharmony_ciit was designed to. It started with proprietary unix vendors collaborating to
920f66f451Sopenharmony_cidescribe the functionality their fragmented APIs could agree on, which was then
930f66f451Sopenharmony_ciincorporated into <a href=https://nvlpubs.nist.gov/nistpubs/Legacy/FIPS/fipspub151-2-1993.pdf>US federal procurement standards</a>
940f66f451Sopenharmony_cias a <a href=https://www.youtube.com/watch?v=nwrTTXOg-KI>compliance requirement</a>
950f66f451Sopenharmony_cifor things like navy contracts, giving large corporations
960f66f451Sopenharmony_cilike IBM and Microsoft millions of dollars of incentive
970f66f451Sopenharmony_cito punch holes in the standard big enough to drive
980f66f451Sopenharmony_ci<a href=https://en.wikipedia.org/wiki/Microsoft_POSIX_subsystem>Windows NT</a> and
990f66f451Sopenharmony_ci<a href=http://www.naspa.net/magazine/1996/May/T9605006.PDF>OS/360</a> through.
1000f66f451Sopenharmony_ciWhen open source projects like Linux started developing on the internet
1010f66f451Sopenharmony_ci(enabled by the 1993 relaxation of the National Science Foundation's
1020f66f451Sopenharmony_ci"Acceptable Use Policy" allowing everyone to connect to the internet,
1030f66f451Sopenharmony_cipreviously restricted to approved government/military/university organizations),
1040f66f451Sopenharmony_ciPosix <a href=http://www.opengroup.org/testing/fips/policy_info.html>ignored
1050f66f451Sopenharmony_cithe upstarts</a> and Linux eventually
1060f66f451Sopenharmony_ci<a href=https://www.linuxjournal.com/article/3417>returned the favor</a>,
1070f66f451Sopenharmony_cileaving Posix behind.</p>
1080f66f451Sopenharmony_ci
1090f66f451Sopenharmony_ci<p>The result is a "standard" that lacks any mention of commands like
1100f66f451Sopenharmony_ci"init" or "mount" required to actually boot a system.
1110f66f451Sopenharmony_ciIt describes logname but not login. It provides ipcrm
1120f66f451Sopenharmony_ciand ipcs, but not ipcmk, so you can use System V IPC resources but not create
1130f66f451Sopenharmony_cithem. And widely used real-world commands such as tar and cpio (the basis
1140f66f451Sopenharmony_ciof initramfs and RPM) which were present in earlier
1150f66f451Sopenharmony_civersions of the standard have been removed, while obsolete commands like
1160f66f451Sopenharmony_cicksum, compress, sccs and uucp remain with no mention of modern counterparts
1170f66f451Sopenharmony_cilike crc32/sha1sum, gzip/xz, svn/git or scp/rsync. Meanwhile posix' description
1180f66f451Sopenharmony_ciof the commands
1190f66f451Sopenharmony_cithemselves are missing dozens of features and specify silly things like ebcdic
1200f66f451Sopenharmony_cisupport in dd or that wc should use %d (not %lld) for byte counts. So
1210f66f451Sopenharmony_ciwe have to extensively filter posix to get a useful set of recommendations.</p>
1220f66f451Sopenharmony_ci
1230f66f451Sopenharmony_ci<h3>Analysis</h3>
1240f66f451Sopenharmony_ci
1250f66f451Sopenharmony_ci<p>Starting with the
1260f66f451Sopenharmony_ci<a href="http://pubs.opengroup.org/onlinepubs/9699919799.2008edition/idx/utilities.html">full "utilities" list</a>,
1270f66f451Sopenharmony_ciwe first remove generally obsolete
1280f66f451Sopenharmony_cicommands (compress ed ex pr uncompress uccp uustat uux), commands for the
1290f66f451Sopenharmony_cipre-CVS "SCCS" source control system (admin delta get prs rmdel sact sccs unget
1300f66f451Sopenharmony_cival what), fortran support (asa fort77), and batch processing support (batch
1310f66f451Sopenharmony_ciqalter qdel qhold qmove qmsg qrerun qrls qselect qsig qstat qsub).</p>
1320f66f451Sopenharmony_ci
1330f66f451Sopenharmony_ci<p>Some commands are for a compiler toolchain (ar c99 cflow ctags cxref gencat
1340f66f451Sopenharmony_ciiconv lex m4 make nm strings strip tsort yacc) which is outside of toybox's
1350f66f451Sopenharmony_cimandate and should be supplied externally. (Again, some of these may be
1360f66f451Sopenharmony_cirevisited later, but not for toybox 1.0.)</p>
1370f66f451Sopenharmony_ci
1380f66f451Sopenharmony_ci<p>Some commands are part of a command shell, and can't be implemented as
1390f66f451Sopenharmony_ciseparate executables (alias bg cd command fc fg getopts hash jobs kill read
1400f66f451Sopenharmony_citype ulimit umask unalias wait). These may be revisited as part of the built-in
1410f66f451Sopenharmony_citoybox shell, but are not exported into $PATH via symlinks. (If you fork a
1420f66f451Sopenharmony_cichild process and have it "cd" then exit, you've accomplished nothing.)
1430f66f451Sopenharmony_ciAgain, what posix provides is incomplete: a shell also needs exit, if, while,
1440f66f451Sopenharmony_cifor, case, export, set, unset, trap, exec... (And for bash compatibility
1450f66f451Sopenharmony_cifunction, source, declare...)</p>
1460f66f451Sopenharmony_ci
1470f66f451Sopenharmony_ci<p>A few other commands are judgement calls, providing command-line
1480f66f451Sopenharmony_ciinternationalization support (iconv locale localedef), System V inter-process
1490f66f451Sopenharmony_cicommunication (ipcrm ipcs), and cross-tty communication from the minicomputer
1500f66f451Sopenharmony_cidays (talk mesg write).  The "pax" utility <a href=https://slashdot.org/story/06/09/04/1335226/debian-kicks-jrg-schilling>failed</a> to replace tar,
1510f66f451Sopenharmony_ci"mailx" is
1520f66f451Sopenharmony_cia command line email client, and "lp" submits files for printing to... what
1530f66f451Sopenharmony_ciexactly?  (cups?)  The standard defines crontab but not crond. What is
1540f66f451Sopenharmony_cipathchk supposed to be portable _to_? (Linux accepts 255 byte path components
1550f66f451Sopenharmony_ciwith any char except NUL or / and no max length on the total path, and
1560f66f451Sopenharmony_ci<a href=https://yarchive.net/comp/linux/utf8.html>EXPLICITLY</a>
1570f66f451Sopenharmony_cidoesn't care if it's an invalid utf8 sequence.)</p>
1580f66f451Sopenharmony_ci
1590f66f451Sopenharmony_ci<p>Removing all of that leaves the following commands, which toybox should
1600f66f451Sopenharmony_ciimplement:</p>
1610f66f451Sopenharmony_ci
1620f66f451Sopenharmony_ci<blockquote><b>
1630f66f451Sopenharmony_ci<span id=posix>
1640f66f451Sopenharmony_ciat awk basename bc cal cat chgrp chmod chown cksum cmp comm cp
1650f66f451Sopenharmony_cicsplit cut date dd df diff dirname du echo env expand expr false file find
1660f66f451Sopenharmony_cifold fuser getconf grep head id join kill link ln logger logname ls man
1670f66f451Sopenharmony_cimkdir mkfifo more mv newgrp nice nl nohup od paste patch printf ps
1680f66f451Sopenharmony_cipwd renice rm rmdir sed sh sleep sort split stty tabs tail tee test time
1690f66f451Sopenharmony_citouch tput tr true tty uname unexpand uniq unlink uudecode uuencode vi wc
1700f66f451Sopenharmony_ciwho xargs zcat
1710f66f451Sopenharmony_ci</span>
1720f66f451Sopenharmony_ci</b></blockquote>
1730f66f451Sopenharmony_ci
1740f66f451Sopenharmony_ci<h3><a name=sigh /><a href="#sigh">Linux Standard Base</a></h3>
1750f66f451Sopenharmony_ci
1760f66f451Sopenharmony_ci<p>One attempt to supplement POSIX towards an actual usable system was the
1770f66f451Sopenharmony_ciLinux Standard Base. Unfortunately, the quality of this "standard" is
1780f66f451Sopenharmony_cifairly low, largely due to the Free Standards Group that maintained it
1790f66f451Sopenharmony_cibeing consumed by <a href=https://landley.net/notes-2010.html#18-07-2010>the Linux Foundation</a> in 2007.</p>
1800f66f451Sopenharmony_ci
1810f66f451Sopenharmony_ci<p>Where POSIX allowed its standards process to be compromised
1820f66f451Sopenharmony_ciby leaving things out (but what
1830f66f451Sopenharmony_cithey DID standardize tends to be respected, if sometimes obsolete),
1840f66f451Sopenharmony_cithe Linux Standard Base's failure mode is different. They respond to
1850f66f451Sopenharmony_cipressure by including anything their members pay them enough to promote,
1860f66f451Sopenharmony_cisuch as allowing Red Hat to push
1870f66f451Sopenharmony_ciRPM into the standard even though all sorts of distros (Debian, Slackware, Arch,
1880f66f451Sopenharmony_ciGentoo, Android) don't use it and never will. This means anything in the LSB is
1890f66f451Sopenharmony_ciat best a suggestion: arbitrary portions of this standard are widely
1900f66f451Sopenharmony_ciignored.</p>
1910f66f451Sopenharmony_ci
1920f66f451Sopenharmony_ci<p>The <a href=https://mjg59.dreamwidth.org/39546.html>community perception</a>
1930f66f451Sopenharmony_ciseems to be that the Linux Standard Base is
1940f66f451Sopenharmony_cithe best standard money can buy, I.E. the Linux Foundation is supported by
1950f66f451Sopenharmony_cifinancial donations from large companies and the LSB
1960f66f451Sopenharmony_ci<a href=https://www.softwarefreedom.org/blog/2016/apr/11/lf/>represents the interests
1970f66f451Sopenharmony_ciof those donors</a> regardless of technical merit. (The Linux Foundation, which
1980f66f451Sopenharmony_cimaintains the LSB, isn't a 501c3. It's a 501c6, the
1990f66f451Sopenharmony_cisame kind of legal entity as the Tobacco Institute and
2000f66f451Sopenharmony_ci<a href=https://lwn.net/Articles/706585/>Microsoft's</a>
2010f66f451Sopenharmony_ciold "<a href=https://en.wikipedia.org/wiki/Don%27t_Copy_That_Floppy>Don't Copy That Floppy</a>" program.) Debian officially
2020f66f451Sopenharmony_ci<a href=http://lwn.net/Articles/658809>washed its hands of LSB</a> by
2030f66f451Sopenharmony_cirefusing to adopt release 5.0 in 2015, and no longer even pretends to support
2040f66f451Sopenharmony_ciit (which affect Debian derivatives like Ubuntu and Knoppix). Toybox has
2050f66f451Sopenharmony_cistayed on 4.1 for similar reasons: a lot of historical effort went into
2060f66f451Sopenharmony_ciproducing the standard before the Linux Foundation took over.</p>
2070f66f451Sopenharmony_ci
2080f66f451Sopenharmony_ci<p>That said, Posix by itself isn't enough, and this is the next most
2090f66f451Sopenharmony_cicomprehensive standards effort for Linux so far, so we salvage what we can.</p>
2100f66f451Sopenharmony_ci
2110f66f451Sopenharmony_ci<h3>Analysis</h3>
2120f66f451Sopenharmony_ci
2130f66f451Sopenharmony_ci<p>The LSB specifies a <a href=http://refspecs.linuxfoundation.org/LSB_4.1.0/LSB-Core-generic/LSB-Core-generic/cmdbehav.html>list of command line
2140f66f451Sopenharmony_ciutilities</a>:</p>
2150f66f451Sopenharmony_ci
2160f66f451Sopenharmony_ci<blockquote><b>
2170f66f451Sopenharmony_ciar at awk batch bc chfn chsh col cpio crontab df dmesg du echo egrep 
2180f66f451Sopenharmony_cifgrep file fuser gettext grep groupadd groupdel groupmod groups 
2190f66f451Sopenharmony_cigunzip gzip hostname install install_initd ipcrm ipcs killall lpr ls 
2200f66f451Sopenharmony_cilsb_release m4 md5sum mknod mktemp more mount msgfmt newgrp od passwd 
2210f66f451Sopenharmony_cipatch pidof remove_initd renice sed sendmail seq sh shutdown su sync 
2220f66f451Sopenharmony_citar umount useradd userdel usermod xargs zcat
2230f66f451Sopenharmony_ci</b></blockquote>
2240f66f451Sopenharmony_ci
2250f66f451Sopenharmony_ci<p>Where posix specifies one of those commands, LSB's deltas tend to be
2260f66f451Sopenharmony_ciaccomodations for broken tool versions which aren't up to date with the
2270f66f451Sopenharmony_cistandard yet. (See <a href=http://refspecs.linuxfoundation.org/LSB_4.1.0/LSB-Core-generic/LSB-Core-generic/more.html>more</a> and <a href=http://refspecs.linuxfoundation.org/LSB_4.1.0/LSB-Core-generic/LSB-Core-generic/xargs.html>xargs</a>
2280f66f451Sopenharmony_cifor examples.)</p>
2290f66f451Sopenharmony_ci
2300f66f451Sopenharmony_ci<p>Since we've already committed to using our own judgement to skip bits of
2310f66f451Sopenharmony_ciPOSIX, and LSB's "judgement" in this regard is purely bug workarounds to declare
2320f66f451Sopenharmony_civarious legacy tool implementations "compliant", this means we're mostly
2330f66f451Sopenharmony_ciinterested in the set of LSB tools that aren't mentioned in posix.</p>
2340f66f451Sopenharmony_ci
2350f66f451Sopenharmony_ci<p>Of these, gettext and msgfmt are internationalization, install_initd and
2360f66f451Sopenharmony_ciremove_initd weren't present in Ubuntu 10.04, lpr is out of scope,
2370f66f451Sopenharmony_cilsb_release just reports information in /etc/os-release, and sendmail's
2380f66f451Sopenharmony_citurned into a pile of cryptographic verification and DNS shenanigans due
2390f66f451Sopenharmony_cito spammers.</p>
2400f66f451Sopenharmony_ci
2410f66f451Sopenharmony_ci<p>This leaves:</p>
2420f66f451Sopenharmony_ci
2430f66f451Sopenharmony_ci<blockquote><b>
2440f66f451Sopenharmony_ci<span id=lsb>
2450f66f451Sopenharmony_cichfn chsh dmesg egrep fgrep groupadd groupdel groupmod groups
2460f66f451Sopenharmony_cigunzip gzip hostname install killall md5sum
2470f66f451Sopenharmony_cimknod mktemp mount passwd pidof seq shutdown
2480f66f451Sopenharmony_cisu sync tar umount useradd userdel usermod zcat
2490f66f451Sopenharmony_ci</span>
2500f66f451Sopenharmony_ci</b></blockquote>
2510f66f451Sopenharmony_ci
2520f66f451Sopenharmony_ci<h3><a name=rfc /><a href="#rfc">IETF RFCs and Man Pages</a></h3>
2530f66f451Sopenharmony_ci
2540f66f451Sopenharmony_ci<p>They're very nice, but there's thousands of them.</p>
2550f66f451Sopenharmony_ci
2560f66f451Sopenharmony_ci<p>Discussion of standards wouldn't be complete without the Internet
2570f66f451Sopenharmony_ciEngineering Task Force's "<a href=https://www.rfc-editor.org/in-notes/rfc-index.txt>Request For Comments</a>" collection and Michael Kerrisk's
2580f66f451Sopenharmony_ci<a href=https://www.kernel.org/doc/man-pages/>Linux man-pages project</a>.
2590f66f451Sopenharmony_ciExcept these aren't standards, they're collections of documentation with
2600f66f451Sopenharmony_cilow barriers to inclusion. They're not saying "you should support
2610f66f451Sopenharmony_ciX", they're saying "if you do, here's how".
2620f66f451Sopenharmony_ciThus neither really helps us select which commands to include.</p>
2630f66f451Sopenharmony_ci
2640f66f451Sopenharmony_ci<p>The man pages website includes the commands in git, yum, perf, postgres,
2650f66f451Sopenharmony_ciflatpack... Great for examining the features of a command you've
2660f66f451Sopenharmony_cialready decided to include, useless for deciding _what_ to include.</p>
2670f66f451Sopenharmony_ci
2680f66f451Sopenharmony_ci<p>The RFCs are more about protocols than commands. The noise level is
2690f66f451Sopenharmony_ciextremely high: there's thousands of RFCs, many describing a proposed idea
2700f66f451Sopenharmony_cithat never took off, and less than 1% of the resulting documents are
2710f66f451Sopenharmony_cicurrently relevant to toybox. And the documents are numbered based on the
2720f66f451Sopenharmony_ciorder they were received, with no real attempt at coherently indexing
2730f66f451Sopenharmony_cithe result. As with man pages they can be <a href=https://www.ietf.org/rfc/rfc0610.txt>long and complicated</a> or
2740f66f451Sopenharmony_ci<a href=https://www.ietf.org/rfc/rfc1951.txt>terse and impenetrable</a>,
2750f66f451Sopenharmony_cihave developed a certain amount of <a href=https://www.ietf.org/rfc/rfc8179.txt>bureaucracy</a> over the years, and often the easiest way to understand what
2760f66f451Sopenharmony_cithey <a href=https://www.ietf.org/rfc/rfc4330.txt>document</a> is to find an <a href=https://www.ietf.org/rfc/rfc1769.txt>earlier version</a> to read first.</p>
2770f66f451Sopenharmony_ci
2780f66f451Sopenharmony_ci<p>That said, RFC documents can be useful (especially for networking protocols)
2790f66f451Sopenharmony_ciand the four URL templates the recommended starting files
2800f66f451Sopenharmony_cifor new commands (toys/example/skeleton.c or toys/example/hello.c depending on how much
2810f66f451Sopenharmony_ciplumbing you want to start with) provide point to posix, lsb, man, and
2820f66f451Sopenharmony_cirfc pages.</p>
2830f66f451Sopenharmony_ci
2840f66f451Sopenharmony_ci<hr />
2850f66f451Sopenharmony_ci<a name="dev_env">
2860f66f451Sopenharmony_ci<h2><a href="#dev_env">Use case: provide a self-hosting development environment</a></h2>
2870f66f451Sopenharmony_ci
2880f66f451Sopenharmony_ci<p>The following commands were enough to build the <a href=http://landley.net/aboriginal/about.html>Aboriginal Linux</a> development
2890f66f451Sopenharmony_cienvironment, boot it to a shell prompt, and build <a href=http://www.linuxfromscratch.org/lfs/view/6.8/>Linux From Scratch 6.8</a> under it.</p>
2900f66f451Sopenharmony_ci
2910f66f451Sopenharmony_ci<blockquote><b>
2920f66f451Sopenharmony_ci<span id=development>
2930f66f451Sopenharmony_cibzcat cat cp dirname echo env patch rmdir sha1sum sleep sort sync
2940f66f451Sopenharmony_citrue uname wc which yes zcat
2950f66f451Sopenharmony_ciawk basename chmod chown cmp cut date dd diff
2960f66f451Sopenharmony_ciegrep expr fdisk find grep gzip head hostname id install ln ls
2970f66f451Sopenharmony_cimkdir mktemp mv od readlink rm sed sh tail tar touch tr uniq
2980f66f451Sopenharmony_ciwget whoami xargs chgrp comm gunzip less logname split
2990f66f451Sopenharmony_citee test time bunzip2 chgrp chroot comm cpio dmesg
3000f66f451Sopenharmony_cidnsdomainname ftpd ftpget ftpput gunzip ifconfig init less
3010f66f451Sopenharmony_cilogname losetup mdev mount mountpoint nc pgrep pkill 
3020f66f451Sopenharmony_cipwd route split stat switch_root tac umount vi
3030f66f451Sopenharmony_ciresize2fs tune2fs fsck.ext2 genext2fs mke2fs xzcat
3040f66f451Sopenharmony_ci</span>
3050f66f451Sopenharmony_ci</b></blockquote>
3060f66f451Sopenharmony_ci
3070f66f451Sopenharmony_ci<p>This use case includes running init scripts and other shell scripts, running
3080f66f451Sopenharmony_ciconfigure, make, and install in each package, and providing basic command line
3090f66f451Sopenharmony_cifacilities such as a text editor. (It does not include a compiler toolchain or
3100f66f451Sopenharmony_ciC library, those are outside the scope of the toybox project, although mkroot
3110f66f451Sopenharmony_cihas a <a href=https://landley.net/code/qcc>potentialy follow-up project</a>.
3120f66f451Sopenharmony_ciFor now we use distro toolchains,
3130f66f451Sopenharmony_ci<a href=https://github.com/richfelker/musl-cross-make>musl-cross-make</a>,
3140f66f451Sopenharmony_ciand the Android NDK for build testing.)
3150f66f451Sopenharmony_ciThat build system also instaled bash 2.05b as #!/bin/sh and its scripts
3160f66f451Sopenharmony_cirequired bash extensions not present in shells such as busybox ash.
3170f66f451Sopenharmony_ciTo replace that toysh needs to supply several bash extensions _and_ work
3180f66f451Sopenharmony_ciwhen called under the name "bash".</p>
3190f66f451Sopenharmony_ci
3200f66f451Sopenharmony_ci<p>The development methodology used a <a href=http://landley.net/aboriginal/FAQ.html#debug_logging>command logging wrapper</a>
3210f66f451Sopenharmony_cithat intercepted each command called out of the $PATH and append the
3220f66f451Sopenharmony_cicommand line to a log file, then <a href=https://github.com/landley/aboriginal/blob/master/more/report-recorded-commands.sh>analyze</a> the result to create a
3230f66f451Sopenharmony_ci<a href=https://landley.net/notes-2008.html#23-01-2008>list of commands</a>,
3240f66f451Sopenharmony_cithen <a href=https://github.com/landley/aboriginal/blob/master/host-tools.sh>create a directory of symlinks</a> pointing to those commands out of the
3250f66f451Sopenharmony_cihost $PATH. Then the new implementation can replace these commands one
3260f66f451Sopenharmony_ciat a time, checking the results and the log output to spot any behavior
3270f66f451Sopenharmony_cichanges.</p>
3280f66f451Sopenharmony_ci
3290f66f451Sopenharmony_ci<h3>Stages and moving targets</h3>
3300f66f451Sopenharmony_ci
3310f66f451Sopenharmony_ci<p>This use case has two stages: 1) building a bootable system that can
3320f66f451Sopenharmony_cirebuild itself from source, and 2) a build environment capable
3330f66f451Sopenharmony_ciof bootstrapping up to arbitrary complexity (as exemplified by building
3340f66f451Sopenharmony_ciLinux From Scratch and Beyond Linux From Scratch under the resulting
3350f66f451Sopenharmony_cisystem). To accomplish just the first goal, the old build
3360f66f451Sopenharmony_cistill needs the following busybox commands for which toybox does not yet
3370f66f451Sopenharmony_cisupply adequate replacements:</p>
3380f66f451Sopenharmony_ci
3390f66f451Sopenharmony_ci<blockquote><b>
3400f66f451Sopenharmony_ciawk dd diff expr fdisk ftpd gzip less route sh tr unxz vi wget xzcat
3410f66f451Sopenharmony_ci</b></blockquote>
3420f66f451Sopenharmony_ci
3430f66f451Sopenharmony_ci<p>All of those except awk, ftpd, and less have partial implementations
3440f66f451Sopenharmony_ciin "pending".</p>
3450f66f451Sopenharmony_ci
3460f66f451Sopenharmony_ci<p>In 2017 Aboriginal Linux development ended, replaced by the
3470f66f451Sopenharmony_ci<a href=https://github.com/landley/mkroot>mkroot</a> project
3480f66f451Sopenharmony_cidesigned to use an existing cross+native toolchain (such as
3490f66f451Sopenharmony_ci<a href=https://github.com/richfelker/musl-cross-make>musl-cross-make</a>
3500f66f451Sopenharmony_cior the Android NDK) instead of building its own. In 2019 the still-incomplete
3510f66f451Sopenharmony_cimkroot was merged into toybox as the "make root" target. This is intended
3520f66f451Sopenharmony_cias a simpler way of providing essentially the same build environment, and doesn't
3530f66f451Sopenharmony_cisignificantly affect the rest of this analysis (although the "rebuild itself
3540f66f451Sopenharmony_cifrom source" test now includes building musl-cross-make under either mkroot
3550f66f451Sopenharmony_cior toybox's "make airlock" host environment).</p>
3560f66f451Sopenharmony_ci
3570f66f451Sopenharmony_ci<p>Building Linux From Scratch is not the same as building the
3580f66f451Sopenharmony_ci<a href=https://source.android.com>Android Open Source Project</a>,
3590f66f451Sopenharmony_cibut after toybox 1.0 we plan to try
3600f66f451Sopenharmony_ci<a href=http://landley.net/aboriginal/about.html#hairball>modifying the AOSP build</a>
3610f66f451Sopenharmony_cito reduce dependencies. (It's fairly likely we'll have to add at least
3620f66f451Sopenharmony_cia read-only git utility so repo can download the build's source code,
3630f66f451Sopenharmony_cibut that's actually <a href=https://www.youtube.com/watch?v=P7n6G2IL6eo>not
3640f66f451Sopenharmony_cithat hard</a>. We'll probably also need our own "make" at some point after
3650f66f451Sopenharmony_ci1.0, which is its own moving target thanks to cmake and ninja and so on.)
3660f66f451Sopenharmony_ciThe ongoing Android <a href=http://lists.landley.net/pipermail/toybox-landley.net/2018-January/009330.html>hermetic build</a> work is already advancing
3670f66f451Sopenharmony_cithis goal.</p>
3680f66f451Sopenharmony_ci
3690f66f451Sopenharmony_ci<hr />
3700f66f451Sopenharmony_ci<h2><a name=android /><a href="#android">Use case: Replacing Android Toolbox</a></h2>
3710f66f451Sopenharmony_ci
3720f66f451Sopenharmony_ci<p>Android has a policy against GPL in userspace, so even though BusyBox
3730f66f451Sopenharmony_cipredates Android by many years, they couldn't use it. Instead they grabbed
3740f66f451Sopenharmony_cian old version of ash (later replaced by
3750f66f451Sopenharmony_ci<a href="https://www.mirbsd.org/mksh.htm">mksh</a>)
3760f66f451Sopenharmony_ciand implemented their own command line utility set
3770f66f451Sopenharmony_cicalled "toolbox" (which toybox has already mostly replaced).</p>
3780f66f451Sopenharmony_ci
3790f66f451Sopenharmony_ci<p>Toolbox doesn't have its own repository, instead it's part of Android's
3800f66f451Sopenharmony_ci<a href=https://android.googlesource.com/platform/system/core>system/core
3810f66f451Sopenharmony_cigit repository</a>. Android's Native Development Kit (their standalone
3820f66f451Sopenharmony_cidownloadable toolchain)  has its own
3830f66f451Sopenharmony_ci<a href=https://android.googlesource.com/platform/ndk/+/master/docs/Roadmap.md>roadmap</a>, and each version has
3840f66f451Sopenharmony_ci<a href=https://developer.android.com/ndk/downloads/revision_history>release
3850f66f451Sopenharmony_cinotes</a>.</p>
3860f66f451Sopenharmony_ci
3870f66f451Sopenharmony_ci<h3>Toolbox commands:</h3>
3880f66f451Sopenharmony_ci
3890f66f451Sopenharmony_ci<p>According to <a href=https://android.googlesource.com/platform/system/core/+/master/toolbox/Android.bp>
3900f66f451Sopenharmony_cisystem/core/toolbox/Android.bp</a> the toolbox directory builds the
3910f66f451Sopenharmony_cifollowing commands:</p>
3920f66f451Sopenharmony_ci
3930f66f451Sopenharmony_ci<blockquote><b>
3940f66f451Sopenharmony_cigetevent getprop modprobe setprop start
3950f66f451Sopenharmony_ci</b></blockquote>
3960f66f451Sopenharmony_ci
3970f66f451Sopenharmony_ci<p>getprop/setprop/start were in toybox and moved back because they're so
3980f66f451Sopenharmony_citied to non-public system interfaces. modprobe shares the implementation
3990f66f451Sopenharmony_ciused in init. getevent is a board bringup tool built with a python script
4000f66f451Sopenharmony_cithat pulls all the constants from the latest kernel headers.</p>
4010f66f451Sopenharmony_ci
4020f66f451Sopenharmony_ci<h3>Other Android /system/bin commands</h3>
4030f66f451Sopenharmony_ci
4040f66f451Sopenharmony_ci<p>Other than the toolbox links, the currently interesting
4050f66f451Sopenharmony_cibinaries in /system/bin are:</p>
4060f66f451Sopenharmony_ci
4070f66f451Sopenharmony_ci<ul>
4080f66f451Sopenharmony_ci<li><b>arping</b> - ARP REQUEST tool (iputils)</li>
4090f66f451Sopenharmony_ci<li><b>blkid</b> - identify block devices (e2fsprogs)</li>
4100f66f451Sopenharmony_ci<li><b>e2fsck</b> - fsck for ext2/ext3/ext4 (e2fsprogs)</li>
4110f66f451Sopenharmony_ci<li><b>fsck.f2fs</b> - fsck for f2fs (f2fs-tools)</li>
4120f66f451Sopenharmony_ci<li><b>fsck_msdos</b> - fsck for FAT (BSD)</li>
4130f66f451Sopenharmony_ci<li><b>gzip</b> - compression/decompression tool (zlib)</li>
4140f66f451Sopenharmony_ci<li><b>ip</b> - network routing tool (iproute2)</li>
4150f66f451Sopenharmony_ci<li><b>iptables/ip6tables</b> - IPv4/IPv6 NAT admin (iptables)</li>
4160f66f451Sopenharmony_ci<li><b>iw</b> - wireless device config tool (iw)</li>
4170f66f451Sopenharmony_ci<li><b>logwrapper</b> - redirect stdio to android log (Android)</li>
4180f66f451Sopenharmony_ci<li><b>make_ext4fs</b> - make ext4 fs (Android)</li>
4190f66f451Sopenharmony_ci<li><b>make_f2fs</b> - make f2fs fs (f2fs-tools)</li>
4200f66f451Sopenharmony_ci<li><b>ping/ping6</b> - ICMP ECHO_REQUEST tool (iputils)</li>
4210f66f451Sopenharmony_ci<li><b>reboot</b> - reboot (Android)</li>
4220f66f451Sopenharmony_ci<li><b>resize2fs</b> - resize ext2/ext3/ext4 fs (e2fsprogs)</li>
4230f66f451Sopenharmony_ci<li><b>sh</b> - mksh (BSD)</li>
4240f66f451Sopenharmony_ci<li><b>ss</b> - socket statistics (iproute2)</li>
4250f66f451Sopenharmony_ci<li><b>tc</b> - traffic control (iproute2)</li>
4260f66f451Sopenharmony_ci<li><b>tracepath/tracepath6</b> - trace network path (iputils)</li>
4270f66f451Sopenharmony_ci<li><b>traceroute/traceroute6</b> - trace network route (iputils)</li>
4280f66f451Sopenharmony_ci</ul>
4290f66f451Sopenharmony_ci
4300f66f451Sopenharmony_ci<p>The names in parentheses are the upstream source of the command.</p>
4310f66f451Sopenharmony_ci
4320f66f451Sopenharmony_ci<h3>Analysis</h3>
4330f66f451Sopenharmony_ci
4340f66f451Sopenharmony_ci<p>For reference, combining everything listed above that's still "fair game"
4350f66f451Sopenharmony_cifor toybox, we get:</p>
4360f66f451Sopenharmony_ci
4370f66f451Sopenharmony_ci<blockquote><b>
4380f66f451Sopenharmony_ciarping blkid e2fsck dd fsck.f2fs fsck_msdos gzip ip iptables
4390f66f451Sopenharmony_ciip6tables iw logwrapper make_ext4fs make_f2fs modpobe newfs_msdos ping ping6
4400f66f451Sopenharmony_cireboot resize2fs sh ss tc tracepath tracepath6 traceroute traceroute6
4410f66f451Sopenharmony_ci</b></blockquote>
4420f66f451Sopenharmony_ci
4430f66f451Sopenharmony_ci<p>We may eventually implement all of that, but for toybox 1.0 we need to
4440f66f451Sopenharmony_cifocus a bit. If Android has an acceptable external package, and the command
4450f66f451Sopenharmony_ciisn't needed for system bootstrapping, replacing the external package is
4460f66f451Sopenharmony_cinot a priority.</p>
4470f66f451Sopenharmony_ci
4480f66f451Sopenharmony_ci<p>However, several commands toybox plans to implement anyway could potentially
4490f66f451Sopenharmony_cireplace existing Android versions, so we should take into account Android's use
4500f66f451Sopenharmony_cicases when doing so. This includes:</p>
4510f66f451Sopenharmony_ci<blockquote><b>
4520f66f451Sopenharmony_ci<span id=toolbox>
4530f66f451Sopenharmony_cidd getevent gzip modprobe newfs_msdos sh
4540f66f451Sopenharmony_ci</span>
4550f66f451Sopenharmony_ci</b></blockquote>
4560f66f451Sopenharmony_ci
4570f66f451Sopenharmony_ci<p>Update: <a href=https://android.googlesource.com/platform/system/core/+/master/system/core/Android.bp>
4580f66f451Sopenharmony_ciexternal/toybox/Android.bp</a> has symlinks for the following toys out
4590f66f451Sopenharmony_ciof "pending". (The toybox modprobe is also built for the device, but
4600f66f451Sopenharmony_ciit isn't actually used and is only there for sanity checking against
4610f66f451Sopenharmony_cithe libmodprobe-based implementation.) These should be a priority for
4620f66f451Sopenharmony_cicleanup:</p>
4630f66f451Sopenharmony_ci
4640f66f451Sopenharmony_ci<blockquote><b>
4650f66f451Sopenharmony_cibc dd diff expr getfattr lsof more stty tr traceroute
4660f66f451Sopenharmony_ci</b></blockquote>
4670f66f451Sopenharmony_ci
4680f66f451Sopenharmony_ci<p>Android wishlist:</p>
4690f66f451Sopenharmony_ci
4700f66f451Sopenharmony_ci<blockquote><b>
4710f66f451Sopenharmony_cimtools genvfatfs mke2fs gene2fs
4720f66f451Sopenharmony_ci</b></blockquote>
4730f66f451Sopenharmony_ci
4740f66f451Sopenharmony_ci<hr />
4750f66f451Sopenharmony_ci<h2><a name=aosp /><a href="#aosp">Use case: Building AOSP</a></h2>
4760f66f451Sopenharmony_ci
4770f66f451Sopenharmony_ci<p>The list of external tools used to build AOSP was
4780f66f451Sopenharmony_ci<a href="https://android.googlesource.com/platform/build/soong/+/master/ui/build/paths/config.go">here</a>,
4790f66f451Sopenharmony_cibut as they're switched over to toybox they disappear and reappear
4800f66f451Sopenharmony_ci<a href="https://android.googlesource.com/platform/prebuilts/build-tools/+/refs/heads/master/path/linux-x86/">here</a>.</p>
4810f66f451Sopenharmony_ci
4820f66f451Sopenharmony_ci<blockquote><b>
4830f66f451Sopenharmony_ciawk basename bash bc bzip2 cat chmod cmp comm cp cut date dd diff dirname du
4840f66f451Sopenharmony_ciecho egrep env expr find fuser getconf getopt git grep gzip head hexdump
4850f66f451Sopenharmony_cihostname id jar java javap ln ls lsof m4 make md5sum mkdir mktemp mv od openssl
4860f66f451Sopenharmony_cipaste patch pgrep pkill ps pstree pwd python python2.7 python3 readlink
4870f66f451Sopenharmony_cirealpath rm rmdir rsync sed setsid sh sha1sum sha256sum sha512sum
4880f66f451Sopenharmony_cisleep sort stat tar tail tee todos touch tr true uname uniq unix2dos unzip
4890f66f451Sopenharmony_ciwc which whoami xargs xxd xz zip zipinfo
4900f66f451Sopenharmony_ci</b></blockquote>
4910f66f451Sopenharmony_ci
4920f66f451Sopenharmony_ci<p>The following are already in the tree and will be used directly:</p>
4930f66f451Sopenharmony_ci
4940f66f451Sopenharmony_ci<blockquote><b>
4950f66f451Sopenharmony_ciawk bzip2 jar java javap m4 make python python2.7 python3 xz
4960f66f451Sopenharmony_ci</b></blockquote>
4970f66f451Sopenharmony_ci
4980f66f451Sopenharmony_ci<p>Subtracting what's already in toybox (including the following toybox toys
4990f66f451Sopenharmony_cithat are still in pending: <code>bc dd diff expr gzip lsof tar tr</code>),
5000f66f451Sopenharmony_cithat leaves:</p>
5010f66f451Sopenharmony_ci
5020f66f451Sopenharmony_ci<blockquote><b>
5030f66f451Sopenharmony_cibash fuser getopt git hexdump openssl pstree rsync sh todos unzip zip zipinfo
5040f66f451Sopenharmony_ci</b></blockquote>
5050f66f451Sopenharmony_ci
5060f66f451Sopenharmony_ci<p>For AOSP, zip/zipinfo/unzip are likely to be libziparchive based. The
5070f66f451Sopenharmony_citodos callers will use unix2dos instead if it's available. git/openssl
5080f66f451Sopenharmony_ciseem like they should just be brought in to the tree. rsync is used to
5090f66f451Sopenharmony_ciwork around a Mac <code>cp -Rf</code> bug with broken symbolic links. That
5100f66f451Sopenharmony_cileaves:</p>
5110f66f451Sopenharmony_ci
5120f66f451Sopenharmony_ci<blockquote><b>
5130f66f451Sopenharmony_cibash fuser getopt hexdump pstree
5140f66f451Sopenharmony_ci</b></blockquote>
5150f66f451Sopenharmony_ci
5160f66f451Sopenharmony_ci<p>(Why are fuser and pstree used during the AOSP build? They're used for
5170f66f451Sopenharmony_cidiagnostics if something goes wrong. So it's really just bash, getopt,
5180f66f451Sopenharmony_ciand hexdump that are actually used to build.)</p>
5190f66f451Sopenharmony_ci
5200f66f451Sopenharmony_ci<hr />
5210f66f451Sopenharmony_ci<h2><a name=tizen /><a href="#tizen">Use case: Tizen Core</a></h2>
5220f66f451Sopenharmony_ci
5230f66f451Sopenharmony_ci<p>A side effect of the Linux Foundation following the money to the
5240f66f451Sopenharmony_ciexclusion of all else is they "support" their donors' myriad often
5250f66f451Sopenharmony_cicontradictory pet projects with elaborate announcements and press releases.
5260f66f451Sopenharmony_ciLong ago when Nokia's Maemo merged
5270f66f451Sopenharmony_ciwith Intel's Moblin to form <a href=https://www.linuxfoundation.org/press-release/linux-foundation-to-host-meego-project/>MeeGo</a>, there were believable <a href=https://www.linuxfoundation.org/press-release/public-support-for-the-meego-project/>statements</a>
5280f66f451Sopenharmony_ciabout unifying fragmented vendor efforts. Then MeeGo merged with
5290f66f451Sopenharmony_ci<a href=http://en.wikipedia.org/wiki/LiMo_Foundation>LiMo</a> to
5300f66f451Sopenharmony_ci<a href=notes-2012.html#16-05-2012>form Tizen</a>,
5310f66f451Sopenharmony_ciwhich became a Samsung-only project (that <a href=https://www.androidheadlines.com/2021/05/samsung-tvs-continue-use-tizen-os.html>still ships</a>
5320f66f451Sopenharmony_ciinside <a href=https://twitter.com/cstross/status/1453747613686288385>televisions</a>,
5330f66f451Sopenharmony_cibut was otherwise subsumed into <a href=https://www.theverge.com/2021/5/18/22440483/samsung-smartwatch-google-wearos-tizen-watch>Android GO</a>).</p>
5340f66f451Sopenharmony_ci
5350f66f451Sopenharmony_ci<p>Along the way, the Tizen project expressed a desire to eliminate GPLv3 software
5360f66f451Sopenharmony_cifrom its core system, and in installing toybox as
5370f66f451Sopenharmony_ci<a href=https://wiki.tizen.org/wiki/Toybox>part of this process</a>.</p>
5380f66f451Sopenharmony_ci
5390f66f451Sopenharmony_ci<p>They had a fairly long list of new commands they wanted to see in toybox:</p>
5400f66f451Sopenharmony_ci
5410f66f451Sopenharmony_ci<blockquote><b>
5420f66f451Sopenharmony_ci<span id=tizen_cmd>
5430f66f451Sopenharmony_ciarch base64 users unexpand shred join csplit
5440f66f451Sopenharmony_cihostid nproc runcon sha224sum sha256sum sha384sum sha512sum sha3sum mkfs.vfat fsck.vfat 
5450f66f451Sopenharmony_cidosfslabel uname pinky diff3 sdiff zcmp zdiff zegrep zfgrep zless zmore
5460f66f451Sopenharmony_ci</span>
5470f66f451Sopenharmony_ci</b></blockquote>
5480f66f451Sopenharmony_ci
5490f66f451Sopenharmony_ci<p>In addition, they wanted to use several commands then in pending:</p>
5500f66f451Sopenharmony_ci
5510f66f451Sopenharmony_ci<blockquote><b>
5520f66f451Sopenharmony_ci<span id=tizen>
5530f66f451Sopenharmony_citar diff printf wget rsync fdisk vi less tr test stty fold expr dd
5540f66f451Sopenharmony_ci</span>
5550f66f451Sopenharmony_ci</b></blockquote>
5560f66f451Sopenharmony_ci
5570f66f451Sopenharmony_ci<p>Also, tizen uses a different Linux Security Module called SMACK, so
5580f66f451Sopenharmony_cimany of the SELinux options ala ls -Z needed smack alternatives in an
5590f66f451Sopenharmony_ciif/else setup. (We added lib/lsm.h to abstract this.)</p>
5600f66f451Sopenharmony_ci
5610f66f451Sopenharmony_ci<hr />
5620f66f451Sopenharmony_ci<h2><a name=yocto /><a href="#yocto">Use case: Yocto</a></h2>
5630f66f451Sopenharmony_ci
5640f66f451Sopenharmony_ci<p>Another project the Linux Foundation is paid to appreciate is Yocto,
5650f66f451Sopenharmony_ciwhich was designed to fix the ongoing proprietary fragmentation problem
5660f66f451Sopenharmony_ci(now in Linux build systems instead of vendor unix forks) by being the
5670f66f451Sopenharmony_cibuild system equivalent of a glue trap. While proclaiming that having the
5680f66f451Sopenharmony_ci"minimum level of standardization" contributes to a "strong ecosystem",
5690f66f451Sopenharmony_ciYocto uses a "<a href=https://www.yoctoproject.org/software-overview/layers/>layered</a>"
5700f66f451Sopenharmony_cidesign where everybody who touches it is encouraged to add more and more layers
5710f66f451Sopenharmony_ciof metadata on top of what came before, until they wind up <a href=https://github.com/varigit/variscite-bsp-platform>using repo</a> just to manage
5720f66f451Sopenharmony_cithe layers (let alone their contents). But -- and this is the
5730f66f451Sopenharmony_ciimportant bit -- all these dispirate forks are called "yocto" and built on
5740f66f451Sopenharmony_citop of giant piles of code the Linux Foundation can take credit for
5750f66f451Sopenharmony_cisince they filed the serial numbers off OpenEmbedded.</p>
5760f66f451Sopenharmony_ci
5770f66f451Sopenharmony_ci<p>Yocto's "core-image-minimal" target (only 3,106 build steps in the 3.3
5780f66f451Sopenharmony_cirelease, which believe it or not is
5790f66f451Sopenharmony_ci<a href=https://landley.net/notes-2019.html#06-02-2019>an improvement</a>) builds a busybox-based system with the following commands:</p>
5800f66f451Sopenharmony_ci
5810f66f451Sopenharmony_ci<blockquote><b>
5820f66f451Sopenharmony_ci<span id=yocto_cmd>
5830f66f451Sopenharmony_ciaddgroup adduser ascii sh awk base32 basename blkid bunzip2 bzcat bzip2 cat
5840f66f451Sopenharmony_cichattr chgrp chmod chown chroot chvt clear cmp cp cpio crc32 cut date dc dd
5850f66f451Sopenharmony_cideallocvt delgroup deluser depmod df diff dirname dmesg dnsdomainname du
5860f66f451Sopenharmony_cidumpkmap dumpleases echo egrep env expr false fbset fdisk fgrep find flock
5870f66f451Sopenharmony_cifree fsck fstrim fuser getopt getty grep groups gunzip gzip head hexdump
5880f66f451Sopenharmony_cihostname hwclock id ifconfig ifdown ifup insmod ip kill killall klogd less
5890f66f451Sopenharmony_ciln loadfont loadkmap logger logname logread losetup ls lsmod lzcat md5sum
5900f66f451Sopenharmony_cimesg microcom mkdir mkfifo mknod mkswap mktemp modprobe more mount mountpoint
5910f66f451Sopenharmony_cimv nc netstat nohup nproc nslookup od openvt patch pgrep pidof pivot_root
5920f66f451Sopenharmony_ciprintf ps pwd rdate readlink realpath reboot renice reset resize rev rfkill
5930f66f451Sopenharmony_cirm rmdir rmmod route run-parts sed seq setconsole setsid sh sha1sum sha256sum
5940f66f451Sopenharmony_cishuf sleep sort start-stop-daemon stat strings stty sulogin swapoff swapon
5950f66f451Sopenharmony_ciswitch_root sync sysctl syslogd tail tar tee telnet test tftp time top touch
5960f66f451Sopenharmony_citr true ts tty udhcpc udhcpd umount uname uniq unlink unzip uptime users
5970f66f451Sopenharmony_ciusleep vi watch wc wget which who whoami xargs xzcat yes zcat
5980f66f451Sopenharmony_ci</span>
5990f66f451Sopenharmony_ci</b></blockquote>
6000f66f451Sopenharmony_ci
6010f66f451Sopenharmony_ci
6020f66f451Sopenharmony_ci
6030f66f451Sopenharmony_ci<a name="fhs" />
6040f66f451Sopenharmony_ci<hr /><a href=fhs>Filesystem Hierachy Standard</a>
6050f66f451Sopenharmony_ci<h2>Filesystem Hierarchy Standard:</h2>
6060f66f451Sopenharmony_ci
6070f66f451Sopenharmony_ci<p>Another standard taken over by the Linux Foundation. (At least the
6080f66f451Sopenharmony_cilinks to this one didn't <a href=http://lanana.org/>go 404</a> the
6090f66f451Sopenharmony_ciinstant they took it over). Of historical interest due to what it
6100f66f451Sopenharmony_cimanaged to achieve before they chased away the hobbyists maintaining it.
6110f66f451Sopenharmony_ciOnly one version (3.0 in 2015) has been released since the Linux Foundation
6120f66f451Sopenharmony_ciabsorbed the FHS. The previous release, Version 2.3, was released in 2004.
6130f66f451Sopenharmony_ciThe Linux Foundation did not retain earlier versions. The contents of
6140f66f451Sopenharmony_cithe relevant sections appear identical between the two versions, the
6150f66f451Sopenharmony_ciLinux Foundation just added section numbers.</p>
6160f66f451Sopenharmony_ci
6170f66f451Sopenharmony_ci<p><a href=https://refspects.linuxfoundation.org/FHS_3.0/fhs-3.0.html>FHS 3.0</a>
6180f66f451Sopenharmony_cisection 3.4.2 requires commands to be in the /bin directory, and then 3.4.3
6190f66f451Sopenharmony_cihas an optional list,
6200f66f451Sopenharmony_ciand then 3.16.2 and 3.16.3 similarly cover /sbin. There are linux
6210f66f451Sopenharmony_cispecific sections in 6.1.2 and 6.1.6 but everything in them is obsolete.</p>
6220f66f451Sopenharmony_ci
6230f66f451Sopenharmony_ci<p>The /bin options include csh but not bash, and ed but not vi.
6240f66f451Sopenharmony_ciThe /sbin options have update which seems obsolete (filesystem
6250f66f451Sopenharmony_cibuffers haven't needed a userspace process to flush them for DECADES),
6260f66f451Sopenharmony_cifastboot and fasthalt (reboot and halt have -nf), and
6270f66f451Sopenharmony_cifsck.* and mkfs.* that don't actually specify any specific filesystems.
6280f66f451Sopenharmony_ciRemoving that gives us:</p>
6290f66f451Sopenharmony_ci
6300f66f451Sopenharmony_ci<blockquote><b>
6310f66f451Sopenharmony_ci<span id=fhs_cmd>
6320f66f451Sopenharmony_cicat chgrp chmod chown cp date dd df dmesg echo false hostname kill ln
6330f66f451Sopenharmony_cilogin ls mkdir mknod more mount mv ps pwd rm rmdir sed sh stty su sync true
6340f66f451Sopenharmony_ciumount uname tar cpio gzip gunzip zcat netstat ping
6350f66f451Sopenharmony_cishutdown fdisk getty halt ifconfig init mkswap reboot route swapon swapoff
6360f66f451Sopenharmony_ci</span>
6370f66f451Sopenharmony_ci</b></blockquote>
6380f66f451Sopenharmony_ci
6390f66f451Sopenharmony_ci<hr /><a name=buildroot />
6400f66f451Sopenharmony_ci<h2>buildroot:</h2>
6410f66f451Sopenharmony_ci
6420f66f451Sopenharmony_ci<p>If a toybox-based development environment is to support running
6430f66f451Sopenharmony_cibuildroot under it, the <a href=https://buildroot.org/downloads/manual/manual.html#requirement-mandatory>mandatory packages</a>
6440f66f451Sopenharmony_cisection of the buildroot manual lists:</p>
6450f66f451Sopenharmony_ci
6460f66f451Sopenharmony_ci<blockquote><p><b>
6470f66f451Sopenharmony_ciwhich sed make bash patch gzip bzip2 tar cpio unzip rsync file bc wget
6480f66f451Sopenharmony_ci</b></p></blockquote>
6490f66f451Sopenharmony_ci
6500f66f451Sopenharmony_ci<p>(It also lists binutils gcc g++ perl python, and for debian it wants
6510f66f451Sopenharmony_cibuild-essential. And it wants file to be in /usr/bin because
6520f66f451Sopenharmony_ci<a href=https://git.busybox.net/buildroot/tree/support/dependencies/dependencies.sh?h=2018.02.x#n84>libtool
6530f66f451Sopenharmony_cibreaks otherwise</a>.)</p>
6540f66f451Sopenharmony_ci
6550f66f451Sopenharmony_ci<p>Oddly, buildroot can't NOT cross compile. Buildroot does not support a cross toolchain that lives in "/usr/bin"
6560f66f451Sopenharmony_ciwith a prefix of "" (if you try, and chop out the test for a blank prefix,
6570f66f451Sopenharmony_ciit dies trying to run "/usr/bin/-gcc"). You can patch your way to
6580f66f451Sopenharmony_cimaking it work if you try, but buildroot's developers explicitly do not
6590f66f451Sopenharmony_cisupport this.</p>
6600f66f451Sopenharmony_ci
6610f66f451Sopenharmony_ci<hr /><a name=klibc />
6620f66f451Sopenharmony_ci<h2>klibc:</h2>
6630f66f451Sopenharmony_ci
6640f66f451Sopenharmony_ci<p>Long ago some kernel developers came up with a project called
6650f66f451Sopenharmony_ci<a href=http://en.wikipedia.org/wiki/Klibc>klibc</a>.
6660f66f451Sopenharmony_ciAfter a decade of development it still has no web page or HOWTO,
6670f66f451Sopenharmony_ciand nobody's quite sure if the license is BSD or GPL. It inexplicably
6680f66f451Sopenharmony_ci<a href=http://www.infoworld.com/d/data-center/perl-isnt-going-anywhere-better-or-worse-211580>requires perl to build</a>, and seems like an ideal candidate for
6690f66f451Sopenharmony_cireplacement.</p>
6700f66f451Sopenharmony_ci
6710f66f451Sopenharmony_ci<p>In addition to a C library less general-purpose than bionic (let alone
6720f66f451Sopenharmony_cimusl), klibc builds a random assortment of executables to run init scripts
6730f66f451Sopenharmony_ciwith. There's no multiplexer command, these are individual executables:</p>
6740f66f451Sopenharmony_ci
6750f66f451Sopenharmony_ci<blockquote><p><b>
6760f66f451Sopenharmony_cicat chroot cpio dd dmesg false fixdep fstype gunzip gzip halt ipconfig kill
6770f66f451Sopenharmony_cikinit ln losetup ls minips mkdir mkfifo mknodes
6780f66f451Sopenharmony_cimksyntax mount mv nfsmount nuke pivot_root poweroff readlink reboot resume
6790f66f451Sopenharmony_cirun-init sh sha1hash sleep sync true umount uname zcat
6800f66f451Sopenharmony_ci</b></p></blockquote>
6810f66f451Sopenharmony_ci
6820f66f451Sopenharmony_ci<p>To get that list, build klibc according to the instructions (I
6830f66f451Sopenharmony_ci<a href=http://landley.net/notes-2013.html#23-01-2013>looked at</a> version
6840f66f451Sopenharmony_ci2.0.2 and did cd klibc-*; ln -s /output/of/kernel/make/headers_install
6850f66f451Sopenharmony_cilinux; make) then <b>echo $(for i in $(find . -type f); do file $i | grep -q
6860f66f451Sopenharmony_ciexecutable && basename $i; done | grep -v '[.]g$' | sort -u)</b> to find
6870f66f451Sopenharmony_ciexecutables, then eliminate the *.so files and *.shared duplicates.</p>
6880f66f451Sopenharmony_ci
6890f66f451Sopenharmony_ci<p>Some of those binaries are build-time tools that don't get installed,
6900f66f451Sopenharmony_ciwhich removes mknodes, mksyntax, sha1hash, and fixdep from the list.
6910f66f451Sopenharmony_ci(And sha1hash is just an unpolished sha1sum anyway.)</p>
6920f66f451Sopenharmony_ci
6930f66f451Sopenharmony_ci<p>The run-init command is more commonly called switch_root, nuke is just
6940f66f451Sopenharmony_ci"rm -rf -- $@", and minips is more commonly called "ps": I'm not doing aliases
6950f66f451Sopenharmony_cifor these oddball names.
6960f66f451Sopenharmony_ciThe "kinit" command is another gratuitous rename, it's init running as PID 1.
6970f66f451Sopenharmony_ciThe halt, poweroff, and reboot commands work with it.</p>
6980f66f451Sopenharmony_ci
6990f66f451Sopenharmony_ci<p>Yet more stale forks of dash and gzip got sucked in here (see "dubious
7000f66f451Sopenharmony_cilicense terms" above).
7010f66f451Sopenharmony_ci
7020f66f451Sopenharmony_ci<p>In theory "blkid" or "file" handle fstype (and df for mounted filesystems),
7030f66f451Sopenharmony_cibut we could do fstype.</p>
7040f66f451Sopenharmony_ci
7050f66f451Sopenharmony_ci<p>We should implement nfsmount, and probably smbmount
7060f66f451Sopenharmony_ciand p9mount even though this hasn't got one. The reason these aren't
7070f66f451Sopenharmony_ciin the base "mount" command is they interactively query login credentials.</p>
7080f66f451Sopenharmony_ci
7090f66f451Sopenharmony_ci<p>The ipconfig command here has a built in dhcp client, so it's ifconfig
7100f66f451Sopenharmony_ciand dhcpcd and maybe some other stuff.</p>
7110f66f451Sopenharmony_ci
7120f66f451Sopenharmony_ci<p>The resume command is... weird. It finds a swap partition and reads data
7130f66f451Sopenharmony_cifrom it into a /proc file, something the kernel is capable of doing itself.
7140f66f451Sopenharmony_ci(Even though the klibc author
7150f66f451Sopenharmony_ci<a href=http://www.zytor.com/pipermail/klibc/2006-June/001748.html>attempted
7160f66f451Sopenharmony_cito remove</a> that capability from the kernel, current kernel/power/hibernate.c
7170f66f451Sopenharmony_cistill parses "resume=" on the command line). And yet various distros seem to
7180f66f451Sopenharmony_cimake use of klibc for this.
7190f66f451Sopenharmony_ciGiven the history of swsusp/hibernate (and 
7200f66f451Sopenharmony_ci<a href=http://lwn.net/Articles/333007>TuxOnIce</a>
7210f66f451Sopenharmony_ciand <a href=http://lwn.net/Articles/242107>kexec jump</a>...) I've lost track
7220f66f451Sopenharmony_ciof the current state of the art here. Ah, Documentation/power/userland-swsusp.txt
7230f66f451Sopenharmony_cihas the API docs, and <a href=http://suspend.sf.net>here's a better
7240f66f451Sopenharmony_citool</a>...</p>
7250f66f451Sopenharmony_ci
7260f66f451Sopenharmony_ci<p>This gives us a klibc command list:</p>
7270f66f451Sopenharmony_ci
7280f66f451Sopenharmony_ci<blockquote><b>
7290f66f451Sopenharmony_ci<span id=klibc_cmd>
7300f66f451Sopenharmony_cicat chroot dmesg false kill ln losetup ls mkdir mkfifo readlink rm switch_root
7310f66f451Sopenharmony_cisleep sync true uname
7320f66f451Sopenharmony_ci
7330f66f451Sopenharmony_cicpio dd ps mv pivot_root
7340f66f451Sopenharmony_cimount nfsmount fstype umount
7350f66f451Sopenharmony_cish gunzip gzip zcat
7360f66f451Sopenharmony_cikinit halt poweroff reboot
7370f66f451Sopenharmony_ciipconfig
7380f66f451Sopenharmony_ciresume
7390f66f451Sopenharmony_ci</span>
7400f66f451Sopenharmony_ci</b></blockquote>
7410f66f451Sopenharmony_ci
7420f66f451Sopenharmony_ci<hr />
7430f66f451Sopenharmony_ci<a name=glibc />
7440f66f451Sopenharmony_ci<h2>glibc</h2>
7450f66f451Sopenharmony_ci
7460f66f451Sopenharmony_ci<p>Rather a lot of command line utilities come bundled with glibc:</p>
7470f66f451Sopenharmony_ci
7480f66f451Sopenharmony_ci<blockquote><b>
7490f66f451Sopenharmony_cicatchsegv getconf getent iconv iconvconfig ldconfig ldd locale localedef
7500f66f451Sopenharmony_cimtrace nscd rpcent rpcinfo tzselect zdump zic
7510f66f451Sopenharmony_ci</b></blockquote>
7520f66f451Sopenharmony_ci
7530f66f451Sopenharmony_ci<p>Of those, musl libc only implements ldd. Of the rest:</p>
7540f66f451Sopenharmony_ci
7550f66f451Sopenharmony_ci<ul>
7560f66f451Sopenharmony_ci<li><b>catchsegv</b> is a rudimentary debugger, probably out of scope for toybox.</li>
7570f66f451Sopenharmony_ci<li><b>iconv</b> has been <a href="#susv4">previously discussed</a>.</li>
7580f66f451Sopenharmony_ci<li><b>iconvconfig</b> is only relevant if iconv is user-configurable; musl uses a
7590f66f451Sopenharmony_cinon-configurable iconv.</li>
7600f66f451Sopenharmony_ci<li><b>getconf</b> is a posix utility which displays several variables from 
7610f66f451Sopenharmony_ciunistd.h; it probably belongs in the development toolchain.</li>
7620f66f451Sopenharmony_ci<li><b>getent</b> handles retrieving entries from passwd-style databases
7630f66f451Sopenharmony_ci(in a rather lame way) and is trivially replacable by grep.</li>
7640f66f451Sopenharmony_ci<li><b>locale</b> was discussed under <a href=#susv4>posix</a>.
7650f66f451Sopenharmony_cilocaledef compiles locale definitions, which musl currently does not use.</li>
7660f66f451Sopenharmony_ci<li><b>mtrace</b> is a perl script to use the malloc debugging that glibc has built-in;
7670f66f451Sopenharmony_cithis is not relevant for musl, and would necessarily vary with libc.</li>
7680f66f451Sopenharmony_ci<li><b>nscd</b> is a name service caching daemon, which is not yet relevant for musl.</li>
7690f66f451Sopenharmony_ci<li><b>rpcinfo</b> and <b>rpcent</b> are related to the Remote Procedure Calls
7700f66f451Sopenharmony_cilayer (an old sun technology used by some userspace NFS implementations),
7710f66f451Sopenharmony_ciwhich musl does not include and debian does not install by default.</li>
7720f66f451Sopenharmony_ci</ul>
7730f66f451Sopenharmony_ci
7740f66f451Sopenharmony_ci<p>The remaining commands involve glibc's bundled timezone database,
7750f66f451Sopenharmony_ciwhich seems to be derived from the <a href=http://www.iana.org/time-zones>IANA
7760f66f451Sopenharmony_citimezone database</a>. Unless we want to maintain our own fork of the
7770f66f451Sopenharmony_cistandards body's database like glibc does, these are of no interest,
7780f66f451Sopenharmony_cibut for completeness:</p>
7790f66f451Sopenharmony_ci
7800f66f451Sopenharmony_ci<ul>
7810f66f451Sopenharmony_ci<li><b>tzselect</b> outputs a TZ variable correponding to user input. 
7820f66f451Sopenharmony_ciThe documentation does not indicate how to use it in a script, but it seems
7830f66f451Sopenharmony_cithat Debian may have done so.</li>
7840f66f451Sopenharmony_ci<li><b>zdump</b> prints current time in each of several timezones, optionally
7850f66f451Sopenharmony_cioutputting a great deal of extra information about each timezone.</li>
7860f66f451Sopenharmony_ci<li><b>zic</b> converts a description of a timezone to a file in tz format.</li>
7870f66f451Sopenharmony_ci</ul>
7880f66f451Sopenharmony_ci
7890f66f451Sopenharmony_ci<p>We implemented getconf, and I could see maybe arguing for ncsd.
7900f66f451Sopenharmony_ciThe rest are not relevant to toybox.</p>
7910f66f451Sopenharmony_ci
7920f66f451Sopenharmony_ci</b></blockquote>
7930f66f451Sopenharmony_ci
7940f66f451Sopenharmony_ci<hr />
7950f66f451Sopenharmony_ci<a name=sash />
7960f66f451Sopenharmony_ci<h2>Stand-Alone Shell</h2>
7970f66f451Sopenharmony_ci
7980f66f451Sopenharmony_ci<p>Wikipedia has <a href=http://en.wikipedia.org/wiki/Stand-alone_shell>a good
7990f66f451Sopenharmony_cisummary of sash</a>, with links. The original Stand-Alone Shell project reached
8000f66f451Sopenharmony_cia stopping point, and then <a href=http://www.baiti.net/sash>"sash plus
8010f66f451Sopenharmony_cipatches"</a> extended it a bit further. The result is a megabyte executable
8020f66f451Sopenharmony_cithat provides 40 commands.</p>
8030f66f451Sopenharmony_ci
8040f66f451Sopenharmony_ci<p>Sash is a shell with built-in commands. It doesn't have a multiplexer
8050f66f451Sopenharmony_cicommand, meaning "sash ls -l" doesn't work (you have to go "sash -c 'ls -l'").
8060f66f451Sopenharmony_ci</p>
8070f66f451Sopenharmony_ci
8080f66f451Sopenharmony_ci<p>The list of commands can be obtained via building it and doing
8090f66f451Sopenharmony_ci"echo help | ./sash | awk '{print $1}' | sed 's/^-//' | xargs echo", which
8100f66f451Sopenharmony_cigives us:</p>
8110f66f451Sopenharmony_ci
8120f66f451Sopenharmony_ci<blockquote><b>
8130f66f451Sopenharmony_cialias aliasall ar cd chattr chgrp chmod chown cmp cp chroot dd echo ed exec
8140f66f451Sopenharmony_ciexit file find grep gunzip gzip help kill losetup losetup ln ls lsattr mkdir
8150f66f451Sopenharmony_cimknod more mount mv pivot_root printenv prompt pwd quit rm rmdir setenv source
8160f66f451Sopenharmony_cisum sync tar touch umask umount unalias where
8170f66f451Sopenharmony_ci</b></blockquote>
8180f66f451Sopenharmony_ci
8190f66f451Sopenharmony_ci<p>Plus sh because it's a shell. A dozen or so commands can only sanely be
8200f66f451Sopenharmony_ciimplemented as shell builtins (alias aliasall cd exec exit prompt quit setenv
8210f66f451Sopenharmony_cisource umask unalias), where is an alias for which, and at triage time toybox
8220f66f451Sopenharmony_cialready has chgrp, chmod, chown, cmp, cp, chroot, echo, help, kill, losetup,
8230f66f451Sopenharmony_ciln, ls, mkdir, mknod, printenv, pwd, rm, rmdir, sync, and touch.</p>
8240f66f451Sopenharmony_ci
8250f66f451Sopenharmony_ci<p>This leaves:</p>
8260f66f451Sopenharmony_ci
8270f66f451Sopenharmony_ci<blockquote><b>
8280f66f451Sopenharmony_ci<span id=sash_cmd>
8290f66f451Sopenharmony_ciar chattr dd ed file find grep gunzip gzip lsattr more mount mv pivot_root
8300f66f451Sopenharmony_cish tar umount
8310f66f451Sopenharmony_ci</span>
8320f66f451Sopenharmony_ci</b></blockquote>
8330f66f451Sopenharmony_ci
8340f66f451Sopenharmony_ci<p>(For once, this project doesn't include a fork of gzip, instead
8350f66f451Sopenharmony_ciit sucks in -lz from the host.)</p>
8360f66f451Sopenharmony_ci
8370f66f451Sopenharmony_ci<hr />
8380f66f451Sopenharmony_ci<a name=sbase />
8390f66f451Sopenharmony_ci<h2>sbase:</h2>
8400f66f451Sopenharmony_ci
8410f66f451Sopenharmony_ci<p>It's <a href=http://git.suckless.org/sbase>on suckless</a> in
8420f66f451Sopenharmony_ci<a href=http://git.suckless.org/ubase>two parts</a>. As of November 2015 it's
8430f66f451Sopenharmony_ciimplemented the following (renaming "cron" to "crond" for
8440f66f451Sopenharmony_ciconsistency, and yanking "sponge", "mesg", "pagesize", "respawn", and
8450f66f451Sopenharmony_ci"vtallow"):</p>
8460f66f451Sopenharmony_ci
8470f66f451Sopenharmony_ci<blockquote><p>
8480f66f451Sopenharmony_ci<span id=sbase_cmd>
8490f66f451Sopenharmony_cibasename cal cat chgrp chmod chown chroot cksum cmp comm cp crond cut date
8500f66f451Sopenharmony_cidirname du echo env expand expr false find flock fold getconf grep head
8510f66f451Sopenharmony_cihostname join kill link ln logger logname ls md5sum mkdir mkfifo mktemp mv
8520f66f451Sopenharmony_cinice nl nohup od paste printenv printf pwd readlink renice rm rmdir sed seq
8530f66f451Sopenharmony_cisetsid sha1sum sha256sum sha512sum sleep sort split strings sync tail
8540f66f451Sopenharmony_citar tee test tftp time touch tr true tty uname unexpand uniq unlink uudecode
8550f66f451Sopenharmony_ciuuencode wc which xargs yes
8560f66f451Sopenharmony_ci</span>
8570f66f451Sopenharmony_ci</p></blockquote>
8580f66f451Sopenharmony_ci
8590f66f451Sopenharmony_ci<p>and<p>
8600f66f451Sopenharmony_ci
8610f66f451Sopenharmony_ci<blockquote><p>
8620f66f451Sopenharmony_ci<span id=sbase_cmd>
8630f66f451Sopenharmony_cichvt clear dd df dmesg eject fallocate free id login mknod mountpoint
8640f66f451Sopenharmony_cipasswd pidof ps stat su truncate unshare uptime watch
8650f66f451Sopenharmony_ciwho
8660f66f451Sopenharmony_ci</span>
8670f66f451Sopenharmony_ci</p></blockquote>
8680f66f451Sopenharmony_ci
8690f66f451Sopenharmony_ci<hr />
8700f66f451Sopenharmony_ci<a name=nash />
8710f66f451Sopenharmony_ci<h2>nash:</h2>
8720f66f451Sopenharmony_ci
8730f66f451Sopenharmony_ci<p>Red Hat's nash was part of its "mkinitrd" package, replacement for a shell
8740f66f451Sopenharmony_ciand utilities on the boot floppy back in the 1990's (the same general idea
8750f66f451Sopenharmony_cias BusyBox, developed independently). Red Hat discontinued nash development
8760f66f451Sopenharmony_ciin 2010, replacing it with dracut (which collects together existing packages,
8770f66f451Sopenharmony_ciincluding busybox).</p>
8780f66f451Sopenharmony_ci
8790f66f451Sopenharmony_ci<p>I couldn't figure out how to beat source code out of
8800f66f451Sopenharmony_ci<a href=http://pkgs.fedoraproject.org/git/mkinitrd>Fedora's current git</a>
8810f66f451Sopenharmony_cirepository. The last release version that used it was Fedora Core 12
8820f66f451Sopenharmony_ciwhich has <a href=http://archive.fedoraproject.org/pub/archive/fedora/linux/releases/12/Fedora/source/SRPMS/mkinitrd-6.0.93-1.fc12.src.rpm>a source rpm</a>
8830f66f451Sopenharmony_cithat can be unwound with "rpm2cpio mkinitrd.src.rpm | cpio -i -d -H newc
8840f66f451Sopenharmony_ci--no-absolute-filenames" and in there is a mkinitrd-6.0.93.tar.bz2 which
8850f66f451Sopenharmony_cihas the source.</p>
8860f66f451Sopenharmony_ci
8870f66f451Sopenharmony_ci<p>In addition to being a bit like a command shell, the nash man page lists the
8880f66f451Sopenharmony_cifollowing commands:</p>
8890f66f451Sopenharmony_ci
8900f66f451Sopenharmony_ci<blockquote><p>
8910f66f451Sopenharmony_ciaccess echo find losetup mkdevices mkdir mknod mkdmnod mkrootdev mount
8920f66f451Sopenharmony_cipivot_root readlink raidautorun setquiet showlabels sleep switchroot umount
8930f66f451Sopenharmony_ci</p></blockquote>
8940f66f451Sopenharmony_ci
8950f66f451Sopenharmony_ci<p>Oddly, the only occurrence of the string pivot_root in the nash source code
8960f66f451Sopenharmony_ciis in the man page, the command isn't there. (It seems to have been removed
8970f66f451Sopenharmony_ciwhen the underscoreless switchroot went in.)</p>
8980f66f451Sopenharmony_ci
8990f66f451Sopenharmony_ci<p>A more complete list seems to be the handlers[] array in nash.c:</p>
9000f66f451Sopenharmony_ci
9010f66f451Sopenharmony_ci<blockquote><p>
9020f66f451Sopenharmony_ciaccess buildEnv cat cond cp daemonize dm echo exec exit find kernelopt
9030f66f451Sopenharmony_ciloadDrivers loadpolicy mkchardevs mkblktab mkblkdevs mkdir mkdmnod mknod
9040f66f451Sopenharmony_cimkrootdev mount netname network null plymouth hotplug killplug losetup
9050f66f451Sopenharmony_ciln ls raidautorun readlink resume resolveDevice rmparts setDeviceEnv
9060f66f451Sopenharmony_cisetquiet setuproot showelfinterp showlabels sleep stabilized status switchroot
9070f66f451Sopenharmony_ciumount waitdev
9080f66f451Sopenharmony_ci</p></blockquote>
9090f66f451Sopenharmony_ci
9100f66f451Sopenharmony_ci<p>This list is nuts: "plymouth" is an alias for "null" which is basically
9110f66f451Sopenharmony_ci"true" (which thie above list doesn't have). Things like buildEnv and
9120f66f451Sopenharmony_ciloadDrivers are bespoke Red Hat behavior that might as well be hardwired in
9130f66f451Sopenharmony_cito nash's main() without being called.</p>
9140f66f451Sopenharmony_ci
9150f66f451Sopenharmony_ci<p>Instead of eliminating items
9160f66f451Sopenharmony_cifrom the list with an explanation for each, I'm just going to cherry pick
9170f66f451Sopenharmony_cia few: the device mapper (dm, raidautorun) is probably interesting,
9180f66f451Sopenharmony_cihotplug (may be obsolete due to kernel changes that now load firmware
9190f66f451Sopenharmony_cidirectly), and another "resume" ala klibc.</p>
9200f66f451Sopenharmony_ci
9210f66f451Sopenharmony_ci<p>But mostly: I don't care about this one. And neither does Red Hat anymore.</p>
9220f66f451Sopenharmony_ci
9230f66f451Sopenharmony_ci<p>Verdict: ignore</p>
9240f66f451Sopenharmony_ci
9250f66f451Sopenharmony_ci<hr />
9260f66f451Sopenharmony_ci<a name=beastiebox />
9270f66f451Sopenharmony_ci<h2>Beastiebox</h2>
9280f66f451Sopenharmony_ci
9290f66f451Sopenharmony_ci<p>Back in 2008, the BSD guys vented some busybox-envy
9300f66f451Sopenharmony_ci<a href=http://beastiebox.sourceforge.net>on sourceforge</a>. Then stopped.
9310f66f451Sopenharmony_ciTheir repository is still in CVS, hasn't been touched in years, it's a giant
9320f66f451Sopenharmony_cihairball of existing code sucked together. (The web page says the author
9330f66f451Sopenharmony_ciis aware of crunchgen, but decided to do this by hand anyway. This is not
9340f66f451Sopenharmony_cia collection of new code, it's a katamari of existing code rolled up in a
9350f66f451Sopenharmony_ciball.)</p>
9360f66f451Sopenharmony_ci
9370f66f451Sopenharmony_ci<p>Combining the set of commands listed on the web page with the set of
9380f66f451Sopenharmony_ciman pages in the source gives us:</P>
9390f66f451Sopenharmony_ci
9400f66f451Sopenharmony_ci<blockquote><p>
9410f66f451Sopenharmony_ci[ cat chmod cp csh date df disklabel dmesg echo ex fdisk fsck fsck_ffs getty
9420f66f451Sopenharmony_cihalt hostname ifconfig init kill less lesskey ln login ls lv mksh more mount
9430f66f451Sopenharmony_cimount_ffs mv pfctl ping poweroff ps reboot rm route sed sh stty sysctl tar test
9440f66f451Sopenharmony_citraceroute umount vi wiconfig
9450f66f451Sopenharmony_ci</p></blockquote>
9460f66f451Sopenharmony_ci
9470f66f451Sopenharmony_ci<p>Apparently lv is the missing link between ed and vi, copyright 1982-1997 (do
9480f66f451Sopenharmony_cinot want), ex is another obsolete vi mode, lesskey is "used to
9490f66f451Sopenharmony_cispecify a set of key bindings to be used with less", and csh is a shell they
9500f66f451Sopenharmony_cisucked in (even though they have mksh?), [ is an alias for test. Several more bsd-isms that don't have Linux
9510f66f451Sopenharmony_ciequivalents (even in the ubuntu "install this package" search) are
9520f66f451Sopenharmony_cidisklabel, fsck_ffs, mount_ffs, and pfctl. And wiconfig is a
9530f66f451Sopenharmony_ciwavelan interface network card driver utility. Subtracting all that and the
9540f66f451Sopenharmony_cicommands toybox already implements at triage time, we get:</p>
9550f66f451Sopenharmony_ci
9560f66f451Sopenharmony_ci<blockquote><p>
9570f66f451Sopenharmony_ci<span id=beastiebox_cmd>
9580f66f451Sopenharmony_cifdisk fsck getty halt ifconfig init kill less more mount mv ping poweroff
9590f66f451Sopenharmony_cips reboot route sed sh stty sysctl tar test traceroute umount vi
9600f66f451Sopenharmony_ci</span>
9610f66f451Sopenharmony_ci</p></blockquote>
9620f66f451Sopenharmony_ci
9630f66f451Sopenharmony_ci<p>Not a hugely interesting list, but eh.</p>
9640f66f451Sopenharmony_ci
9650f66f451Sopenharmony_ci<p>Verdict: ignore</p>
9660f66f451Sopenharmony_ci
9670f66f451Sopenharmony_ci<hr />
9680f66f451Sopenharmony_ci<a name=BsdBox />
9690f66f451Sopenharmony_ci<h2>BsdBox</h2>
9700f66f451Sopenharmony_ci
9710f66f451Sopenharmony_ci<p>Somebody decided to do a <a href=https://wiki.freebsd.org/AdrianChadd/BsdBox>multicall binary for freebsd</a>.</p>
9720f66f451Sopenharmony_ci
9730f66f451Sopenharmony_ci<p>They based it on crunchgen, a tool that glues existing programs together
9740f66f451Sopenharmony_ciinto an archive and uses the name to execute the right one. It has no
9750f66f451Sopenharmony_cisimplification or code sharing benefits whatsoever, it's basically an
9760f66f451Sopenharmony_ciarchiver that produces executables.</p>
9770f66f451Sopenharmony_ci
9780f66f451Sopenharmony_ci<p>That's about where I stopped reading.</p>
9790f66f451Sopenharmony_ci
9800f66f451Sopenharmony_ci<p>Verdict: ignore.</p>
9810f66f451Sopenharmony_ci
9820f66f451Sopenharmony_ci<hr />
9830f66f451Sopenharmony_ci<a name=slowaris />
9840f66f451Sopenharmony_ci<h2>OpenSolaris Busybox</h2>
9850f66f451Sopenharmony_ci
9860f66f451Sopenharmony_ci<p>Somebody <a href=http://hub.opensolaris.org/bin/view/Project+busybox/>wrote
9870f66f451Sopenharmony_cia wiki page</a> saying that Busybox for OpenSolaris would be a good idea.</p>
9880f66f451Sopenharmony_ci
9890f66f451Sopenharmony_ci<p>The corresponding "files" tab is an auto-generated stub. The project never
9900f66f451Sopenharmony_cieven got as far as suggesting commands to include before Oracle discontinued
9910f66f451Sopenharmony_ciOpenSolaris.</p>
9920f66f451Sopenharmony_ci
9930f66f451Sopenharmony_ci<p>Verdict: ignore.</p>
9940f66f451Sopenharmony_ci
9950f66f451Sopenharmony_ci<hr />
9960f66f451Sopenharmony_ci<a name=uclinux />
9970f66f451Sopenharmony_ci<h2>uClinux</h2>
9980f66f451Sopenharmony_ci
9990f66f451Sopenharmony_ci<p>Long ago a hardware developer named Jeff Dionne put together a
10000f66f451Sopenharmony_cinommu Linux distribution, which involved rewriting a lot of command line
10010f66f451Sopenharmony_ciutilities that relied on <a href=http://nommu.org/memory-faq.txt>features
10020f66f451Sopenharmony_ciunavailable on nommu</a> hardware.</p>
10030f66f451Sopenharmony_ci
10040f66f451Sopenharmony_ci<p>In 2003 Jeff moved to Japan and handed
10050f66f451Sopenharmony_cithe project off to people who allowed it to roll to a stop. The website
10060f66f451Sopenharmony_citurned into a mess of 404 links, the navigation indexes stopped being
10070f66f451Sopenharmony_ciupdated over a decade ago, and the project's CVS repository suffered a
10080f66f451Sopenharmony_cihard drive failure for which there were no backups. The project continued
10090f66f451Sopenharmony_cito put out "releases" through 2014 (you have to scroll down in the "news"
10100f66f451Sopenharmony_cisection to find them, the "HTTP download" section in the nav bar on the
10110f66f451Sopenharmony_cileft hasn't been updated in over a decade), which were hand-updated tarball
10120f66f451Sopenharmony_cisnapshots mostly consisting of software from the 1990's. For example the
10130f66f451Sopenharmony_ci2014 release still contained ipfwadm, the package which predated ipchains,
10140f66f451Sopenharmony_ciwhich predated iptables, which is in the process of being replaced by
10150f66f451Sopenharmony_cinftables.</p>
10160f66f451Sopenharmony_ci
10170f66f451Sopenharmony_ci<p>Nevertheless, people still try to use this because (at least until the
10180f66f451Sopenharmony_cilaunch of <a href=http://nommu.org>nommu.org</a>) the project was viewed
10190f66f451Sopenharmony_cias the place to discuss, develop, and learn about nommu Linux.
10200f66f451Sopenharmony_ciThe role of uclinux.org as an educational resource kept people coming
10210f66f451Sopenharmony_cito it long after it had collapsed as a Linux distro.</p>
10220f66f451Sopenharmony_ci
10230f66f451Sopenharmony_ci<p>Starting around 0.6.0 toybox began to address nommu support with the goal
10240f66f451Sopenharmony_ciof putting uClinux out of its misery.</p>
10250f66f451Sopenharmony_ci
10260f66f451Sopenharmony_ci<p>An analysis of <a href=http://www.uclinux.org/pub/uClinux/dist/uClinux-dist-20140504.tar.bz2>uClinux-dist-20140504</a> found 312 package
10270f66f451Sopenharmony_cisubdirectories under "user".</p>
10280f66f451Sopenharmony_ci
10290f66f451Sopenharmony_ci<h3>Taking out the trash</h3>
10300f66f451Sopenharmony_ci
10310f66f451Sopenharmony_ci<p>A bunch of packages (<b>inotify-tools, input-event-demon, ipsec-tools, netifd,
10320f66f451Sopenharmony_cikeepalived, mobile-broadband-provider-info, nuttp, readline, snort,
10330f66f451Sopenharmony_cisnort-barnyard, socat, sqlite, sysklogd, sysstat, tcl, ubus, uci, udev,
10340f66f451Sopenharmony_ciunionfs, uqmi, usb_modeswitch, usbutils, util-linux</b>)
10350f66f451Sopenharmony_ciare hard to evaluate because
10360f66f451Sopenharmony_ciuclinux has directories for them, but their source isn't actually in the
10370f66f451Sopenharmony_ciuclinux tree. In some of these the makefiles download a git repo during
10380f66f451Sopenharmony_cithe build, so I'm assuming you can build the external package if you really
10390f66f451Sopenharmony_cicare. (Even when I know what these packages do, I'm skipping them
10400f66f451Sopenharmony_cibecause uclinux doesn't actually contain them, and any given snapshot
10410f66f451Sopenharmony_ciof the build system will bitrot as external web links change over time.)</p>
10420f66f451Sopenharmony_ci
10430f66f451Sopenharmony_ci<p>Other packages are orphaned, meaning they're not mentioned from any Kconfig
10440f66f451Sopenharmony_cior Makefiles outside of their directory, so uclinux can't actually build
10450f66f451Sopenharmony_cithem: <b>mbus</b> is an orphaned i2c test program expecting to run in some sort
10460f66f451Sopenharmony_ciof hardwired hardware context, <b>mkeccbin</b> is an orphaned "ECC annotated
10470f66f451Sopenharmony_cibinary file" generator (meaning it's half of a flash writer),
10480f66f451Sopenharmony_ci<b>wsc_upnp</b> is a "Ralink WPS" driver (some sort of stale wifi chip)...</p>
10490f66f451Sopenharmony_ci
10500f66f451Sopenharmony_ci<p>The majority of the remaining packages are probably not of interest to
10510f66f451Sopenharmony_citoybox due to being so obsolete or special purpose they may not actually be
10520f66f451Sopenharmony_ciof interest to anybody anymore. (This list also includes a lot of
10530f66f451Sopenharmony_cispecial-purpose network back-end stuff that's hard for anybody but
10540f66f451Sopenharmony_cidatacenter admins to evaluate the current relevance of.)</p>
10550f66f451Sopenharmony_ci
10560f66f451Sopenharmony_ci<blockquote><b><p>
10570f66f451Sopenharmony_ciarj asterisk boottools bpalogin br2684ctl camserv can4linux cgi_generic
10580f66f451Sopenharmony_cicgihtml clamav clamsmtp conntrack-tools cramfs crypto-tools cxxtest
10590f66f451Sopenharmony_ciddns3-client de2ts-cal debug demo diald discard dnsmasq dnsmasq2
10600f66f451Sopenharmony_ciethattach expat-examples ez-ipupdate fakeidentd
10610f66f451Sopenharmony_cifconfig ferret flatfs flthdr freeradius freeswan frob-led frox fswcert
10620f66f451Sopenharmony_cigame gettyd gnugk haserl horch
10630f66f451Sopenharmony_cihostap hping httptunnel ifattach ipchains
10640f66f451Sopenharmony_ciipfwadm ipmasqadm ipportfw ipredir ipset iso_client
10650f66f451Sopenharmony_cijamvm jffs-tools jpegview jquery-ui kendin-config kismet klaxon kmod
10660f66f451Sopenharmony_cil2tpd lcd ledcmd ledcon lha lilo lirc lissa load loattach
10670f66f451Sopenharmony_cilpr lrpstat lrzsz mail mbus mgetty microwin ModemManager msntp musicbox
10680f66f451Sopenharmony_cinooom null openswan openvpn palmbot pam_* pcmcia-cs playrt plugdaemon pop3proxy
10690f66f451Sopenharmony_cipotrace qspitest quagga radauth
10700f66f451Sopenharmony_ciramimage readprofile rdate readprofile routed rrdtool rtc-ds1302
10710f66f451Sopenharmony_cisendip ser sethdlc setmac setserial sgutool sigs siproxd slattach
10720f66f451Sopenharmony_cismtpclient snmpd net-snmp snortrules speedtouch squashfs scep sslwrap stp
10730f66f451Sopenharmony_cistunnel tcpblast tcpdump tcpwrappers threaddemos tinylogin tinyproxy
10740f66f451Sopenharmony_citpt tripwire unrar unzoo version vpnled w3cam xl2tpd zebra
10750f66f451Sopenharmony_ci</p></b></blockquote>
10760f66f451Sopenharmony_ci    
10770f66f451Sopenharmony_ci<p>This stuff is all over the place: arj, lha, rar, and zoo are DOS archivers,
10780f66f451Sopenharmony_ciethattach describes itself as just "a network tool",
10790f66f451Sopenharmony_cimail is a textmode smtp mailer literally described as "Some kind of mail
10800f66f451Sopenharmony_ciproggy" in uclinux's kconfig (as opposed to clamsmtp and smtpclient and
10810f66f451Sopenharmony_ciso on), this gettyd isn't a generic version but specifically a
10820f66f451Sopenharmony_cihardwired ppp dialin utility, mgetty isn't a generic version but is combined
10830f66f451Sopenharmony_ciwith "sendfax", hostap is an intersil prism driver, wlan-ng is also an
10840f66f451Sopenharmony_ciintersil prism dirver, null is a program to intentionally dereference a
10850f66f451Sopenharmony_cinull pointer (in case you needed one), iso_client is a
10860f66f451Sopenharmony_ci"Demo Application for the USB Device Driver", kendin-config is
10870f66f451Sopenharmony_ci"for configuring the Micrel Kendin KS8995M over QSPI", speedtouch configures
10880f66f451Sopenharmony_cia specific brand of asdl modem, portmap is part of Anfs,
10890f66f451Sopenharmony_ciferret, linux-igd, and miniupnp are all upnp packages,
10900f66f451Sopenharmony_cilanbypass "can be used to control the LAN
10910f66f451Sopenharmony_cibypass switches on the Advantech x86 based hardware platforms", lcd is
10920f66f451Sopenharmony_ci"test of lcddma device driver" (an out-of-tree Coldfire driver apparently
10930f66f451Sopenharmony_cilost to history, the uclinux linux-2.4.x directory has a config symbol for
10940f66f451Sopenharmony_ciit, but nothing in the code actually _uses_ it...), qspitest is another
10950f66f451Sopenharmony_cicoldfire thing, mii-tool-fec is
10960f66f451Sopenharmony_ci"strictly for the FEC Ethernet driver as implemented (and modified) for
10970f66f451Sopenharmony_cithe uCdimm5272", rtc-ds1302 and rtc-m41t11 are usermode drivers for specific
10980f66f451Sopenharmony_ciclock chips, stunnel is basically "openssl s_client -quiet -connect",
10990f66f451Sopenharmony_cipotrace is a bitmap to vector graphic converter, radauth performs command line
11000f66f451Sopenharmony_ciauthentication against a radius server,
11010f66f451Sopenharmony_ciclamav, klaxon, ferret, l7-protocols, and nessus are very old network security
11020f66f451Sopenharmony_cisoftware (it's got a stale snapshot of nmap too), xl2tpd is a PPP over UDP
11030f66f451Sopenharmony_citunnel (rfc 2661), zebra is the package quagga replaced,
11040f66f451Sopenharmony_cililo is the x86-only bootloader that predated grub (and recently discontinued
11050f66f451Sopenharmony_cidevelopment), lissa is a "framebuffer graphics demo" from
11060f66f451Sopenharmony_ci1998, the squashfs package here is the out of tree patches for 2.4 kernels
11070f66f451Sopenharmony_ciand such before the filesystem was merged upstream (as opposed to the
11080f66f451Sopenharmony_cisquashfs-new package which is a snapshot of the userspace tool from 2011),
11090f66f451Sopenharmony_ciload is basically "dd file /dev/spi", version is basically "cat /proc/version",
11100f66f451Sopenharmony_cimicrowin is a port of the WinCE graphics API to Linux, scep is a 2003
11110f66f451Sopenharmony_ciimplementation of an IETF draft abandoned in 2010, tpt depends on
11120f66f451Sopenharmony_ciAndrew Morton's 15 year old unmerged "timepegs" kernel patch using the pentium
11130f66f451Sopenharmony_cicycle counter, vpnled controls a light that reboots systems (what?),
11140f66f451Sopenharmony_ciw3cam is a video4linux 1.0 client (v4l2 showed up during 2.5 and support for
11150f66f451Sopenharmony_cithe old v4l1 was removed in 2.6.38 back in 2011), busybox ate tinylogin
11160f66f451Sopenharmony_ciover a decade ago, lrpstat is a java network monitor
11170f66f451Sopenharmony_cifrom 2001, lrzsz is zmodem/ymodem/zmodem, msntp and stp implement rfc2030
11180f66f451Sopenharmony_cimeaning it overflows in 2036 (the package was last updated in 2000), rdate
11190f66f451Sopenharmony_ciis rfc 868 meaning it also overflows in 2036 (which is why ntp was invented
11200f66f451Sopenharmony_cia few decades back), reiserfsprogs development stopped abruptly after
11210f66f451Sopenharmony_ciHans Reiser was convicted of murdering his wife Nina (denying it on the
11220f66f451Sopenharmony_cistand and then leading them to the body as part of his plea bargain during
11230f66f451Sopenharmony_cisentencing)...
11240f66f451Sopenharmony_ci</p>
11250f66f451Sopenharmony_ci
11260f66f451Sopenharmony_ci<p>Seriously, there's a lot of crap in there. It's hard to analyze most
11270f66f451Sopenharmony_ciof it far enough to prove it _doesn't_ do anything.</p>
11280f66f451Sopenharmony_ci
11290f66f451Sopenharmony_ci<h3>Non-toybox programs</h3>
11300f66f451Sopenharmony_ci
11310f66f451Sopenharmony_ci<p>The following software may actually still do something intelligible
11320f66f451Sopenharmony_ci(although the package versions tend to be years out of date), but
11330f66f451Sopenharmony_ciit's not a direction toybox has chosen to go in.</p>
11340f66f451Sopenharmony_ci
11350f66f451Sopenharmony_ci<p>There are several programming languages (<b>bash, lua, jamvm, tinytcl,
11360f66f451Sopenharmony_ciperl, python</b>) in there. Maybe someone somewhere wants a 2008 release of a
11370f66f451Sopenharmony_cijava virtual machine tested to work on nommu systems (jamvm), but it's out
11380f66f451Sopenharmony_ciof scope for toybox.</p>
11390f66f451Sopenharmony_ci
11400f66f451Sopenharmony_ci<p>A bunch of benchmark programs: <b>cpu, dhrystone, mathtest, nbench, netperf,
11410f66f451Sopenharmony_cinetpipe, and whetstone</b>.</p>
11420f66f451Sopenharmony_ci
11430f66f451Sopenharmony_ci<p>A bunch of web servers: <b>appWeb, boa, fnord (via tcpserver), goahead, httpd,
11440f66f451Sopenharmony_cimini_httpd, and thttpd</b>.</p>
11450f66f451Sopenharmony_ci
11460f66f451Sopenharmony_ci<p>A bunch of shells: <b>msh</b> is a clever (I.E. obfuscated) little shell,
11470f66f451Sopenharmony_ci<b>nwsh</b> is "new shell" (that's what it called itself in 1999 anyway),
11480f66f451Sopenharmony_ci<b>sash</b> is another shell with a bunch of builtins (ls, ps, df, cp, date, reboot,
11490f66f451Sopenharmony_ciand shutdown, this roadmap analyzes it <a href="#sash">elsewhere</a>),
11500f66f451Sopenharmony_ci<b>sh</b> is a very old minix shell fork, and <b>tcsh</b> is also a shell.</p>
11510f66f451Sopenharmony_ci
11520f66f451Sopenharmony_ci<p>Also in this category, we have:</p>
11530f66f451Sopenharmony_ci
11540f66f451Sopenharmony_ci<blockquote><b><p>
11550f66f451Sopenharmony_cidropbear jffs-tools jpegview kexec-tools bind ctorrent
11560f66f451Sopenharmony_ciiperf iproute2 ip-sentinel iptables kexec
11570f66f451Sopenharmony_cinmap oggplay openssl oprofile p7zip pppd pptp play vplay
11580f66f451Sopenharmony_cihdparm mp3play at clock
11590f66f451Sopenharmony_cimtd-utils mysql logrotate brcfg bridge-utils flashw
11600f66f451Sopenharmony_ciebtables etherwake ethtool expect gdb gdbserver hostapd
11610f66f451Sopenharmony_cilm_sensors load netflash netstat-nat
11620f66f451Sopenharmony_ciradvd recover rootloader resolveip rp-pppoe
11630f66f451Sopenharmony_cirsyslog rsyslogd samba smbmount squashfs-new squid ssh strace tip
11640f66f451Sopenharmony_ciuboot-envtools ulogd usbhubctrl vconfig vixie-cron watchdogd
11650f66f451Sopenharmony_ciwireless_tools wpa_supplicant
11660f66f451Sopenharmony_ci</p></b></blockquote>
11670f66f451Sopenharmony_ci
11680f66f451Sopenharmony_ci<p>An awful lot of those are borderline: play and vplay are wav file
11690f66f451Sopenharmony_ciaudio players, there's oprofile _and_ readprofile (which just reads kernel
11700f66f451Sopenharmony_ciprofiling data from /proc/profile),
11710f66f451Sopenharmony_ciradvd is a "routr advertisement daemon" (ipv6 stateless autoconf),
11720f66f451Sopenharmony_cictorrent is a bittorent client, 
11730f66f451Sopenharmony_cilm_sensors is hardware (heat?) monitoring,
11740f66f451Sopenharmony_ciresolveip is dig only less so,
11750f66f451Sopenharmony_cirp-pppoe is ppp over ethernet,
11760f66f451Sopenharmony_ciebtables is an ethernet version of iptables (for bridging),
11770f66f451Sopenharmony_citheir dropbear is from 2012, and that ssh version is from 2011
11780f66f451Sopenharmony_ci(which means it's about nine months too _old_ to have the heartbleed bug).
11790f66f451Sopenharmony_ciThere's both ulogd and ulogd2 (no idea why), and pppd is version 2.4 but
11800f66f451Sopenharmony_cithere's a ppd-2.3 directory also.</p>
11810f66f451Sopenharmony_ci
11820f66f451Sopenharmony_ci<p>Lots of flash stuff:
11830f66f451Sopenharmony_ciflashw is a flash writer, load is an spi flash loader, netflash writes
11840f66f451Sopenharmony_cito flash via tftp,
11850f66f451Sopenharmony_cirecover is also a reflash daemon intended to come up when the system can't boot,
11860f66f451Sopenharmony_cirootloader seems to be another reflash daemon but without dhcp.</p>
11870f66f451Sopenharmony_ci
11880f66f451Sopenharmony_ci<h3>Already in roadmap</h3>
11890f66f451Sopenharmony_ci
11900f66f451Sopenharmony_ci<p>The following packages contain commands already in the toybox roadmap:</p>
11910f66f451Sopenharmony_ci
11920f66f451Sopenharmony_ci<blockquote><b><p>
11930f66f451Sopenharmony_ciagetty cal cksum cron dhcpcd dhcpcd-new dhcpd dhcp-isc dosfstools e2fsprogs
11940f66f451Sopenharmony_cielvis-tiny levee fdisk fileutils ftp ftpd grep hd hwclock inetd init ntp
11950f66f451Sopenharmony_ciiputils login module-init-tools netcat shutils ntpdate lspci ping procps
11960f66f451Sopenharmony_ciproftpd rsync shadow shutils stty sysutils telnet telnetd tftp tftpd traceroute
11970f66f451Sopenharmony_ciunzip wget mawk net-tools
11980f66f451Sopenharmony_ci</p></b></blockquote>
11990f66f451Sopenharmony_ci
12000f66f451Sopenharmony_ci<p>There are some duplicates in there, levee is a tiny vi implementation
12010f66f451Sopenharmony_cilike elvis-tiny, ntp and ntpdate overlap, etc.</p>
12020f66f451Sopenharmony_ci
12030f66f451Sopenharmony_ci<p>Verdict: We don't really need to do a whole lot special for nommu
12040f66f451Sopenharmony_cisystems, just get the existing toybox roadmap working on nommu and
12050f66f451Sopenharmony_ciwe're good. The uClinux project can rest in peace.</p>
12060f66f451Sopenharmony_ci
12070f66f451Sopenharmony_ci<hr />
12080f66f451Sopenharmony_ci<h2>Requests:</h2>
12090f66f451Sopenharmony_ci
12100f66f451Sopenharmony_ci<p>The following additional commands have been requested (and often submitted)
12110f66f451Sopenharmony_ciby various users. I _really_ need to clean up this section.</p>
12120f66f451Sopenharmony_ci
12130f66f451Sopenharmony_ci<p>Also:</p>
12140f66f451Sopenharmony_ci<blockquote><b>
12150f66f451Sopenharmony_ci<span id=request>
12160f66f451Sopenharmony_cidig freeramdisk getty halt hexdump hwclock klogd modprobe ping ping6 pivot_root
12170f66f451Sopenharmony_cipoweroff readahead rev sfdisk sudo syslogd taskset telnet telnetd tracepath
12180f66f451Sopenharmony_citraceroute unzip usleep vconfig zip free login modinfo unshare netcat help w
12190f66f451Sopenharmony_ciiwconfig iwlist rdate
12200f66f451Sopenharmony_cidos2unix unix2dos catv clear
12210f66f451Sopenharmony_cipmap realpath setsid timeout truncate
12220f66f451Sopenharmony_cimkswap swapon swapoff
12230f66f451Sopenharmony_cicount oneit fstype
12240f66f451Sopenharmony_ciacpi blkid eject pwdx
12250f66f451Sopenharmony_cisulogin rfkill bootchartd
12260f66f451Sopenharmony_ciarp makedevs sysctl killall5 crond crontab deluser last mkpasswd watch
12270f66f451Sopenharmony_ciblockdev rpm2cpio arping brctl dumpleases fsck
12280f66f451Sopenharmony_citcpsvd tftpd
12290f66f451Sopenharmony_cifactor fallocate fsfreeze inotifyd lspci nbd-client partprobe strings
12300f66f451Sopenharmony_cibase32 base64 mix
12310f66f451Sopenharmony_cireset hexedit nsenter shred
12320f66f451Sopenharmony_cifsync insmod ionice lsmod lsusb rmmod vmstat xxd top iotop
12330f66f451Sopenharmony_cilsof ionice compress dhcp dhcpd addgroup delgroup host iconv ip
12340f66f451Sopenharmony_ciipcrm ipcs netstat openvt
12350f66f451Sopenharmony_cideallocvt iorenice
12360f66f451Sopenharmony_ciudpsvd adduser
12370f66f451Sopenharmony_cimicrocom tunctl chrt getfattr setfattr
12380f66f451Sopenharmony_cikexec
12390f66f451Sopenharmony_ciascii crc32 devmem fmt i2cdetect i2cdump i2cget i2cset mcookie prlimit sntp ulimit uuidgen dhcp6 ipaddr iplink iproute iprule iptunnel cd exit toysh bash traceroute6
12400f66f451Sopenharmony_ciblkdiscard rtcwake
12410f66f451Sopenharmony_ciwatchdog
12420f66f451Sopenharmony_cipwgen readelf unicode
12430f66f451Sopenharmony_cirsync
12440f66f451Sopenharmony_cilinux32 hd strace
12450f66f451Sopenharmony_ci</span>
12460f66f451Sopenharmony_ci</b></blockquote>
12470f66f451Sopenharmony_ci
12480f66f451Sopenharmony_ci<hr />
12490f66f451Sopenharmony_ci<a name=packages />
12500f66f451Sopenharmony_ci<h2>Other packages</h2>
12510f66f451Sopenharmony_ci
12520f66f451Sopenharmony_ci<p>System administrators have <a href=https://github.com/landley/toybox/issues/168#issuecomment-583725500>asked</a> what other Linux packages toybox commands
12530f66f451Sopenharmony_cireplace, so they can annotate alternatives in their package management system.</p>
12540f66f451Sopenharmony_ci
12550f66f451Sopenharmony_ci<p>This section uses the package definitions from Chapter 6 of
12560f66f451Sopenharmony_ci<a href=http://www.linuxfromscratch.org/lfs/downloads/9.0/LFS-BOOK-9.0-NOCHUNKS.html>Linux From Scratch 9.0</a>). Each package lists what we currently
12570f66f451Sopenharmony_cireplace, pending commands [in square brackets], and what we DON'T plan to
12580f66f451Sopenharmony_ciimplement.</p>
12590f66f451Sopenharmony_ci
12600f66f451Sopenharmony_ci<p>Each "see also" note means the listed package also installs the listed shared
12610f66f451Sopenharmony_cilibraries. (While toybox contains equivalent functionality to a lot of these
12620f66f451Sopenharmony_cishared libraries in its lib/ directory, it does not currently provide a shared
12630f66f451Sopenharmony_cilibrary interface.)</p>
12640f66f451Sopenharmony_ci
12650f66f451Sopenharmony_ci<h3>Packages toybox plans to provide complete-ish replacents for:</h3>
12660f66f451Sopenharmony_ci<ul>
12670f66f451Sopenharmony_ci<li><b>file</b>: file (see also: libmagic)</li>
12680f66f451Sopenharmony_ci<li><b>m4</b>: [m4]</li>
12690f66f451Sopenharmony_ci<li><b>bc</b>: [bc] [dc]</li>
12700f66f451Sopenharmony_ci<li><b>bison</b>: [yacc] (not: bison, see also: liby)</li>
12710f66f451Sopenharmony_ci<li><b>flex</b>: [lex] (not: flex flex++, see also: libfl)</li>
12720f66f451Sopenharmony_ci<li><b>make</b>: [make]</li>
12730f66f451Sopenharmony_ci<li><b>sed</b>: sed</li>
12740f66f451Sopenharmony_ci<li><b>grep</b>: grep egrep fgrep</li>
12750f66f451Sopenharmony_ci<li><b>bash</b>: bash sh (not: bashbug)</li>
12760f66f451Sopenharmony_ci<li><b>diffutils</b>: cmp [diff] [diff3] [sdiff]</li>
12770f66f451Sopenharmony_ci<li><b>gawk</b>: [awk] (not: gawk gawk-5.0.1)</li>
12780f66f451Sopenharmony_ci<li><b>findutils</b>: find xargs (not: locate updatedb)</li>
12790f66f451Sopenharmony_ci<li><b>less</b>: less (not: lessecho lesskey)</li>
12800f66f451Sopenharmony_ci<li><b>gzip</b>: zcat [gzip] [gunzip] [zcmp] [zdiff] [zegrep] [zfgrep] [zgrep] [zless] [zmore]
12810f66f451Sopenharmony_ci(not: gzexe uncompress zforce znew)</li>
12820f66f451Sopenharmony_ci<li><b>make</b>: [make]</li>
12830f66f451Sopenharmony_ci<li><b>patch</b>: patch</li>
12840f66f451Sopenharmony_ci<li><b>tar</b>: tar</li>
12850f66f451Sopenharmony_ci<li><b>procps-ng</b>: free pgrep pidof pkill ps sysctl top uptime vmstat w watch
12860f66f451Sopenharmony_ci[pmap] [pwdx] [slabtop]
12870f66f451Sopenharmony_ci(not: tload, see also libprocps)</li>
12880f66f451Sopenharmony_ci<li><b>sysklogd</b>: [klogd] [syslogd]</li>
12890f66f451Sopenharmony_ci<li><b>sysvinit</b>: [init] halt poweroff reboot killall5 [shutdown]
12900f66f451Sopenharmony_ci(not telinit runlevel fstab-decode bootlogd)</li>
12910f66f451Sopenharmony_ci<li><b>man</b>: man (but not accessdb apropos catman lexgrog mandb manpath whatis,
12920f66f451Sopenharmony_cisee also libman libmandb)</li>
12930f66f451Sopenharmony_ci<li><b>vim</b>: vi xxd (but not ex, rview, rvim, view, vim, vimdiff, vimtutor)</li>
12940f66f451Sopenharmony_ci<li><b>sysvinit</b>: [init] halt poweroff reboot killall5 [shutdown]
12950f66f451Sopenharmony_ci(not telinit runlevel fstab-decode bootlogd)</li>
12960f66f451Sopenharmony_ci<li><b>kmod</b>: insmod lsmod rmmod modinfo [modprobe]
12970f66f451Sopenharmony_ci(not: depmod kmod)</li>
12980f66f451Sopenharmony_ci<li><b>attr</b>: [getfattr] setfattr (not: attr, see also: libattr)</li>
12990f66f451Sopenharmony_ci<li><b>shadow</b>: [chfn] [chpasswd] [chsh] [groupadd] [groupdel] [groupmod]
13000f66f451Sopenharmony_ci[newusers] passwd [su] [useradd] [userdel] [usermod]
13010f66f451Sopenharmony_ci[lastlog] [login] [newgidmap] [newuidmap]
13020f66f451Sopenharmony_ci(not: chage expiry faillog groupmems grpck logoutd newgrp nologin pwck sg
13030f66f451Sopenharmony_civigr vipw, grpconv grpunconv pwconv pwunconv, chgpasswd gpasswd)</li>
13040f66f451Sopenharmony_ci<li><b>psmisc</b>: killall [fuser] [pstree] [peekfd] [prtstat]
13050f66f451Sopenharmony_ci(not: pslog pstree.x11)</li>
13060f66f451Sopenharmony_ci<li><b>inetutils</b>: dnsdomainname [ftp] hostname ifconfig ping ping6 [telnet] [tftp] [traceroute] (not: talk)</li>
13070f66f451Sopenharmony_ci<li><b>coreutils</b>: [ base32 base64 basename cat chgrp chmod chown chroot cksum comm cp cut date
13080f66f451Sopenharmony_cidd df dirname du echo env expand factor false fmt fold groups head hostid id install
13090f66f451Sopenharmony_cilink ln logname ls md5sum mkdir mkfifo mknod mktemp mv nice nl nohup nproc od
13100f66f451Sopenharmony_cipaste printenv printf pwd readlink realpath rm rmdir seq sha1sum shred
13110f66f451Sopenharmony_cisleep sort split stat sync tac tail tee test timeout touch true truncate
13120f66f451Sopenharmony_citty uname uniq unlink wc who whoami yes
13130f66f451Sopenharmony_ci[expr] [fold] [join] [numfmt] [runcon] [sha224sum] [sha256sum] [sha384sum]
13140f66f451Sopenharmony_ci[sha512sum] [stty] [b2sum] [tr] [unexpand]
13150f66f451Sopenharmony_ci(not: basenc chcon csplit dir dircolors pathchk
13160f66f451Sopenharmony_cipinky pr ptx shuf stdbuf sum tsort users vdir, see also libstdbuf)</li>
13170f66f451Sopenharmony_ci<li><b>util-linux</b>: blkid blockdev cal chrt dmesg eject fallocate flock hwclock
13180f66f451Sopenharmony_ciionice kill logger losetup mcookie mkswap more mount mountpoint nsenter
13190f66f451Sopenharmony_cipivot_root prlimit rename renice rev setsid swapoff swapon switch_root taskset
13200f66f451Sopenharmony_ciumount unshare uuidgen
13210f66f451Sopenharmony_ci[addpart] [fdisk] [findfs] [findmnt] [fsck] [fsfreeze] [fstrim] [getopt]
13220f66f451Sopenharmony_ci[hexdump] [linux32] [linux64] [lsblk] [lscpu] [lsns] [setarch]
13230f66f451Sopenharmony_ci(not: agetty blkdiscard blkzone cfdisk chcpu chmem choom col
13240f66f451Sopenharmony_cicolcrt colrm column ctrlaltdel delpart fdformat fincore fsck.cramfs
13250f66f451Sopenharmony_cifsck.minix ipcmk ipcrm ipcs isosize last lastb ldattach look lsipc
13260f66f451Sopenharmony_cilslocks lslogins lsmem mesg mkfs mkfs.bfs mkfs.cramfs mkfs.minix namei partx
13270f66f451Sopenharmony_ciraw readprofile resizepart rfkill rtcwake script scriptreplay
13280f66f451Sopenharmony_cisetterm sfdisk sulogin swaplabel ul
13290f66f451Sopenharmony_ciuname26 utmpdump uuidd uuidparse wall wdctl whereis wipefs
13300f66f451Sopenharmony_cii386 x86_64 zramctl)</li>
13310f66f451Sopenharmony_ci</ul>
13320f66f451Sopenharmony_ci
13330f66f451Sopenharmony_ci<p>Commentary: toybox init doesn't do runlevels, man and vim are just the
13340f66f451Sopenharmony_cirelevant commands without the piles of strange overgrowth, and if you want
13350f66f451Sopenharmony_cito call a toybox binary by another name you can create a symlink to a
13360f66f451Sopenharmony_cisymlink. If somebody really wants to argue for "gzexe" or similar, be
13370f66f451Sopenharmony_cimy guest, but there's a lot of obsolete crap in shadow, coreutils,
13380f66f451Sopenharmony_ciutil-linux...</p>
13390f66f451Sopenharmony_ci
13400f66f451Sopenharmony_ci<p>No idea why LFS is installing inetutils instead of net-tools
13410f66f451Sopenharmony_ci(which contains arp route ifconfig mii-tool nameif netstat and rarp that
13420f66f451Sopenharmony_citoybox does or might implement, and plipconfig slattach that it probably won't.)</p>
13430f66f451Sopenharmony_ci
13440f66f451Sopenharmony_ci<h3>Packages toybox plans to provide partial replacents for:</h3>
13450f66f451Sopenharmony_ci
13460f66f451Sopenharmony_ci<p>Toybox provides replacements for some binaries from these packages,
13470f66f451Sopenharmony_cibut there are other useful binaries which this package provides that toybox
13480f66f451Sopenharmony_cicurrently considers out of scope for the project:</p>
13490f66f451Sopenharmony_ci
13500f66f451Sopenharmony_ci<ul>
13510f66f451Sopenharmony_ci<li><b>binutils</b>: strings [ar] [nm] [readelf] [size] [objcopy] [strip]
13520f66f451Sopenharmony_ci(not c++filt, dwp, elfedit, gprof. The following commands belong
13530f66f451Sopenharmony_ciin <a href=/code/qcc>qcc</a>: addr2line as ld objdump ranlib)</li>
13540f66f451Sopenharmony_ci<li><b>bzip2</b>: bunzip2 bzcat [bzcmp] [bzdiff] [bzegrep] [bzfgrep] [bzgrep] [bzless]
13550f66f451Sopenharmony_ci[bzmore] (not: bzip2, bzip2recover, see also libbz2)</li>
13560f66f451Sopenharmony_ci<li><b>xz</b>: [xzcat] [lzcat] [lzcmp] [lzdiff] [lzegrep] [lzfgrep] [lzgrep]
13570f66f451Sopenharmony_ci[lzless] [lzmadec, lzmainfo] [lzmore] [unlzma] [unxz] [xzcat]
13580f66f451Sopenharmony_ci[xzcmp] [xzdec] [xzdiff] [xzegrep] [xzfgrep] [xzgrep] [xzless] [xzmore]
13590f66f451Sopenharmony_ci(not: compression side, see also: liblzma)</li>
13600f66f451Sopenharmony_ci<li><b>ncurses</b>: clear reset (not: everything else, see also: libcurses)</li>
13610f66f451Sopenharmony_ci<li><b>e2fsprogs</b>: chattr lsattr [e2fsck] [mkfs.ext2] [mkfs.ext3]
13620f66f451Sopenharmony_ci[fsck.ext2] [fsck.ext3] [e2label] [resize2fs] [tune2fs]
13630f66f451Sopenharmony_ci(not badblocks compile_et debugfs dumpe2fse2freefrag e2image
13640f66f451Sopenharmony_cie2mmpstatus e2scrub e2scrub_all e2undo e4crypt e4defrag filefrag
13650f66f451Sopenharmony_cifsck.ext4 logsave mk_cmds mkfs.ext4 mklost+found)</li>
13660f66f451Sopenharmony_ci</ul>
13670f66f451Sopenharmony_ci
13680f66f451Sopenharmony_ci<p>Toybox provides several decompressors but compresses to a single format
13690f66f451Sopenharmony_ci(deflate, ala gzip/zlib). Our e2fsprogs doesn't currently plan to support
13700f66f451Sopenharmony_ciext4 or defrag. The "qcc" reference is because someday an external project to glue
13710f66f451Sopenharmony_ciQEMU's <a href=https://git.qemu.org/?p=qemu.git;a=blob;f=tcg/README;h=bfa2e4ed246c;hb=HEAD>Tiny Code Generator</a>
13720f66f451Sopenharmony_cito Fabrice Bellard's old <a href=http://landley.net/hg/tinycc>Tiny C Compiler</a>
13730f66f451Sopenharmony_cimaking a multicall binary that does cc/ld/as for all the targets QEMU
13740f66f451Sopenharmony_cisupports (then use the
13750f66f451Sopenharmony_ci<a href=https://github.com/JuliaComputing/llvm-cbe>LLVM C Backend</a>
13760f66f451Sopenharmony_cito compile LLVM itself to C for use as a modern replacement for
13770f66f451Sopenharmony_ci<a href=https://en.wikipedia.org/wiki/Cfront>cfront</a> to bootstrap
13780f66f451Sopenharmony_ciC++ code) is under consideration
13790f66f451Sopenharmony_cias a successor project to toybox. Until then things like objdump -d
13800f66f451Sopenharmony_ci(requiring target-specific disassembly for an unbounded number of architectures)
13810f66f451Sopenharmony_ciare out of scope for toybox. (This means drawing the line somewhere between
13820f66f451Sopenharmony_ciarchitecture-specific support in file and strace, and including a full
13830f66f451Sopenharmony_ciassembler for each architecture.)</p>
13840f66f451Sopenharmony_ci</span>
13850f66f451Sopenharmony_ci
13860f66f451Sopenharmony_ci<h3>Packages from LFS ch6 toybox does NOT plan to replace:</h3>
13870f66f451Sopenharmony_ci
13880f66f451Sopenharmony_ci<ul>
13890f66f451Sopenharmony_ci<li><b>linux-api-headers</b></li>
13900f66f451Sopenharmony_ci<li><b>man-pages glibc</b></li>
13910f66f451Sopenharmony_ci<li><b>zlib</b></li>
13920f66f451Sopenharmony_ci<li><b>readline</b></li>
13930f66f451Sopenharmony_ci<li><b>gmp</b></li>
13940f66f451Sopenharmony_ci<li><b>mpfr</b></li>
13950f66f451Sopenharmony_ci<li><b>mpc</b></li>
13960f66f451Sopenharmony_ci<li><b>gcc</b></li>
13970f66f451Sopenharmony_ci<li><b>pkg-config</b></li>
13980f66f451Sopenharmony_ci<li><b>ncurses</b></li>
13990f66f451Sopenharmony_ci<li><b>acl</b></li>
14000f66f451Sopenharmony_ci<li><b>libcap</b></li>
14010f66f451Sopenharmony_ci<li><b>psmisc</b></li>
14020f66f451Sopenharmony_ci<li><b>iana-etc</b></li>
14030f66f451Sopenharmony_ci<li><b>libtool</b></li>
14040f66f451Sopenharmony_ci<li><b>gdbm</b></li>
14050f66f451Sopenharmony_ci<li><b>gperf</b></li>
14060f66f451Sopenharmony_ci<li><b>expat</b></li>
14070f66f451Sopenharmony_ci<li><b>perl</b></li>
14080f66f451Sopenharmony_ci<li><b>XML::Parser</b></li>
14090f66f451Sopenharmony_ci<li><b>intltool</b></li>
14100f66f451Sopenharmony_ci<li><b>autoconf</b></li>
14110f66f451Sopenharmony_ci<li><b>automake</b></li>
14120f66f451Sopenharmony_ci<li><b>gettext</b></li>
14130f66f451Sopenharmony_ci<li><b>libelf</b></li>
14140f66f451Sopenharmony_ci<li><b>libffi</b></li>
14150f66f451Sopenharmony_ci<li><b>openssl</b></li>
14160f66f451Sopenharmony_ci<li><b>python</b></li>
14170f66f451Sopenharmony_ci<li><b>ninja</b></li>
14180f66f451Sopenharmony_ci<li><b>meson</b></li>
14190f66f451Sopenharmony_ci<li><b>check</b></li>
14200f66f451Sopenharmony_ci<li><b>groff</b></li>
14210f66f451Sopenharmony_ci<li><b>grub</b></li>
14220f66f451Sopenharmony_ci<li><b>libpipeline</b></li>
14230f66f451Sopenharmony_ci<li><b>texinfo</b></li>
14240f66f451Sopenharmony_ci</ul>
14250f66f451Sopenharmony_ci
14260f66f451Sopenharmony_ci<p>That said, we do implement our own zlib and readline replacements, and
14270f66f451Sopenharmony_cipresumably _could_ export them as library bindings. Plus we provide
14280f66f451Sopenharmony_ciour own version of a bunch of the section 1 man pages (as command help).
14290f66f451Sopenharmony_ciPossibly libcap and acl are interesting?</p>
14300f66f451Sopenharmony_ci
14310f66f451Sopenharmony_ci<h3>Misc</h3>
14320f66f451Sopenharmony_ci
14330f66f451Sopenharmony_ci<p>The kbd package has over a dozen commands, we only implement chvt. The
14340f66f451Sopenharmony_ciiproute2 package implements over a dozen commands, there's an "ip" in
14350f66f451Sopenharmony_cipending but I'm not a fan (ifconfig and route and such should be extended
14360f66f451Sopenharmony_cito work properly). We don't implement eudev, but toybox's maintainer
14370f66f451Sopenharmony_cicreated busybox mdev way back when (which replaces it) and plans to do a
14380f66f451Sopenharmony_cinew one for toybox as soon as we work out what subset is still needed now that
14390f66f451Sopenharmony_cidevtmpfs is available.</p>
14400f66f451Sopenharmony_ci
14410f66f451Sopenharmony_ci<!-- #include "footer.html" -->
14420f66f451Sopenharmony_ci
1443