2 * applets.h - a listing of all busybox applets.
4 * If you write a new applet, you need to add an entry to this list to make
7 * It is CRUCIAL that this listing be kept in ascii order, otherwise the binary
8 * search lookup contributed by Gaute B Strokkenes stops working. If you value
9 * your kneecaps, you'll be sure to *make sure* that any changes made to this
10 * file result in the listing remaining in ascii order. You have been warned.
17 #if defined(PROTOTYPES)
18 #define APPLET(a,b,c) \
19 extern int b(int argc, char **argv);
20 #define APPLET_ODDNAME(a,b,c,d,e) APPLET(a,b,c)
21 #define APPLET_NOUSAGE(a,b,c) \
22 extern int b(int argc, char **argv);
23 #elif defined(MAKE_LINKS)
24 #define APPLET(a,b,c) LINK c #a
25 #define APPLET_ODDNAME(a,b,c,d,e) LINK c a
26 #define APPLET_NOUSAGE(a,b,c) LINK c #a
27 #elif defined(APPLET_ENUM)
28 #define APPLET(a,b,c) a##_applet_number,
29 #define APPLET_ODDNAME(a,b,c,d,e) e##_applet_number,
30 #define APPLET_NOUSAGE(a,b,c) a##applet_number,
34 const struct BB_applet applets[] = {
35 #define APPLET(a,b,c) {#a,b,c,a##_usage_index},
36 #define APPLET_ODDNAME(a,b,c,d,e) {a,b,c,d},
37 #define APPLET_NOUSAGE(a,b,c) {#a,b,c,-1},
38 #define zcat_usage_index gunzip_usage_index
39 #define sh_usage_index shell_usage_index
43 APPLET_ODDNAME("[", test_main, _BB_DIR_USR_BIN, test_usage_index, open_bracket)
46 APPLET(ar, ar_main, _BB_DIR_USR_BIN)
49 APPLET(basename, basename_main, _BB_DIR_USR_BIN)
51 APPLET_NOUSAGE(busybox, busybox_main, _BB_DIR_BIN)
53 APPLET(cat, cat_main, _BB_DIR_BIN)
55 #ifdef BB_CHMOD_CHOWN_CHGRP
56 APPLET(chgrp, chmod_chown_chgrp_main, _BB_DIR_BIN)
58 #ifdef BB_CHMOD_CHOWN_CHGRP
59 APPLET(chmod, chmod_chown_chgrp_main, _BB_DIR_BIN)
61 #ifdef BB_CHMOD_CHOWN_CHGRP
62 APPLET(chown, chmod_chown_chgrp_main, _BB_DIR_BIN)
65 APPLET(chroot, chroot_main, _BB_DIR_USR_SBIN)
68 APPLET(chvt, chvt_main, _BB_DIR_USR_BIN)
71 APPLET(clear, clear_main, _BB_DIR_USR_BIN)
74 APPLET(cmp, cmp_main, _BB_DIR_USR_BIN)
77 APPLET(cp, cp_mv_main, _BB_DIR_BIN)
80 APPLET(cut, cut_main, _BB_DIR_USR_BIN)
83 APPLET(date, date_main, _BB_DIR_BIN)
86 APPLET(dc, dc_main, _BB_DIR_USR_BIN)
89 APPLET(dd, dd_main, _BB_DIR_BIN)
92 APPLET(deallocvt, deallocvt_main, _BB_DIR_USR_BIN)
95 APPLET(df, df_main, _BB_DIR_BIN)
98 APPLET(dirname, dirname_main, _BB_DIR_USR_BIN)
101 APPLET(dmesg, dmesg_main, _BB_DIR_BIN)
104 APPLET(dos2unix, dos2unix_main, _BB_DIR_USR_BIN)
107 APPLET(dpkg, dpkg_main, _BB_DIR_USR_BIN)
110 APPLET_ODDNAME("dpkg-deb", dpkg_deb_main, _BB_DIR_USR_BIN, dpkg_deb_usage_index, dpkg_deb)
113 APPLET(du, du_main, _BB_DIR_USR_BIN)
116 APPLET(dumpkmap, dumpkmap_main, _BB_DIR_BIN)
119 APPLET(dutmp, dutmp_main, _BB_DIR_USR_SBIN)
122 APPLET(echo, echo_main, _BB_DIR_BIN)
125 APPLET(expr, expr_main, _BB_DIR_USR_BIN)
128 APPLET(false, false_main, _BB_DIR_BIN)
131 APPLET_NOUSAGE(fbset, fbset_main, _BB_DIR_USR_SBIN)
134 APPLET(fdflush, fdflush_main, _BB_DIR_BIN)
137 APPLET(find, find_main, _BB_DIR_USR_BIN)
140 APPLET(free, free_main, _BB_DIR_USR_BIN)
142 #ifdef BB_FREERAMDISK
143 APPLET(freeramdisk, freeramdisk_main, _BB_DIR_SBIN)
146 APPLET_ODDNAME("fsck.minix", fsck_minix_main, _BB_DIR_SBIN, fsck_minix_usage_index, fsck_minix)
149 APPLET(getopt, getopt_main, _BB_DIR_BIN)
152 APPLET(grep, grep_main, _BB_DIR_BIN)
155 APPLET(gunzip, gunzip_main, _BB_DIR_BIN)
158 APPLET(gzip, gzip_main, _BB_DIR_BIN)
161 APPLET(halt, halt_main, _BB_DIR_SBIN)
164 APPLET(head, head_main, _BB_DIR_USR_BIN)
167 APPLET(hostid, hostid_main, _BB_DIR_USR_BIN)
170 APPLET(hostname, hostname_main, _BB_DIR_BIN)
173 APPLET(id, id_main, _BB_DIR_USR_BIN)
176 APPLET(ifconfig, ifconfig_main, _BB_DIR_SBIN)
179 APPLET(init, init_main, _BB_DIR_SBIN)
182 APPLET(insmod, insmod_main, _BB_DIR_SBIN)
185 APPLET(kill, kill_main, _BB_DIR_BIN)
188 APPLET(killall, kill_main, _BB_DIR_USR_BIN)
191 APPLET(length, length_main, _BB_DIR_USR_BIN)
194 APPLET_NOUSAGE(linuxrc, init_main, _BB_DIR_ROOT)
197 APPLET(ln, ln_main, _BB_DIR_BIN)
200 APPLET(loadacm, loadacm_main, _BB_DIR_USR_BIN)
203 APPLET(loadfont, loadfont_main, _BB_DIR_USR_BIN)
206 APPLET(loadkmap, loadkmap_main, _BB_DIR_SBIN)
209 APPLET(logger, logger_main, _BB_DIR_USR_BIN)
212 APPLET(logname, logname_main, _BB_DIR_USR_BIN)
215 APPLET(ls, ls_main, _BB_DIR_BIN)
218 APPLET(lsmod, lsmod_main, _BB_DIR_SBIN)
221 APPLET(makedevs, makedevs_main, _BB_DIR_SBIN)
224 APPLET(md5sum, md5sum_main, _BB_DIR_USR_BIN)
227 APPLET(mkdir, mkdir_main, _BB_DIR_BIN)
230 APPLET(mkfifo, mkfifo_main, _BB_DIR_USR_BIN)
233 APPLET_ODDNAME("mkfs.minix", mkfs_minix_main, _BB_DIR_SBIN, mkfs_minix_usage_index, mkfs_minix)
236 APPLET(mknod, mknod_main, _BB_DIR_BIN)
239 APPLET(mkswap, mkswap_main, _BB_DIR_SBIN)
242 APPLET(mktemp, mktemp_main, _BB_DIR_BIN)
245 APPLET(more, more_main, _BB_DIR_BIN)
248 APPLET(mount, mount_main, _BB_DIR_BIN)
251 APPLET(mt, mt_main, _BB_DIR_BIN)
254 APPLET(mv, cp_mv_main, _BB_DIR_BIN)
257 APPLET(nc, nc_main, _BB_DIR_USR_BIN)
260 APPLET(nslookup, nslookup_main, _BB_DIR_USR_BIN)
263 APPLET(ping, ping_main, _BB_DIR_BIN)
266 APPLET(pivot_root, pivot_root_main, _BB_DIR_SBIN)
269 APPLET(poweroff, poweroff_main, _BB_DIR_SBIN)
272 APPLET(printf, printf_main, _BB_DIR_USR_BIN)
275 APPLET(ps, ps_main, _BB_DIR_BIN)
278 APPLET(pwd, pwd_main, _BB_DIR_BIN)
281 APPLET(rdate, rdate_main, _BB_DIR_USR_BIN)
284 APPLET(readlink, readlink_main, _BB_DIR_USR_BIN)
287 APPLET(reboot, reboot_main, _BB_DIR_SBIN)
290 APPLET(renice, renice_main, _BB_DIR_USR_BIN)
293 APPLET(reset, reset_main, _BB_DIR_USR_BIN)
296 APPLET(rm, rm_main, _BB_DIR_BIN)
299 APPLET(rmdir, rmdir_main, _BB_DIR_BIN)
302 APPLET(rmmod, rmmod_main, _BB_DIR_SBIN)
305 APPLET(route, route_main, _BB_DIR_USR_BIN)
308 APPLET(rpmunpack, rpmunpack_main, _BB_DIR_USR_BIN)
311 APPLET(sed, sed_main, _BB_DIR_BIN)
313 #ifdef BB_SETKEYCODES
314 APPLET(setkeycodes, setkeycodes_main, _BB_DIR_USR_BIN)
317 APPLET(sh, shell_main, _BB_DIR_BIN)
320 APPLET(sleep, sleep_main, _BB_DIR_BIN)
323 APPLET(sort, sort_main, _BB_DIR_USR_BIN)
326 APPLET(stty, stty_main, _BB_DIR_BIN)
329 APPLET(swapoff, swap_on_off_main, _BB_DIR_SBIN)
332 APPLET(swapon, swap_on_off_main, _BB_DIR_SBIN)
335 APPLET(sync, sync_main, _BB_DIR_BIN)
338 APPLET(syslogd, syslogd_main, _BB_DIR_SBIN)
341 APPLET(tail, tail_main, _BB_DIR_USR_BIN)
344 APPLET(tar, tar_main, _BB_DIR_BIN)
347 APPLET(tee, tee_main, _BB_DIR_USR_BIN)
350 APPLET(telnet, telnet_main, _BB_DIR_USR_BIN)
353 APPLET(test, test_main, _BB_DIR_USR_BIN)
356 APPLET(touch, touch_main, _BB_DIR_BIN)
359 APPLET(tr, tr_main, _BB_DIR_USR_BIN)
362 APPLET(true, true_main, _BB_DIR_BIN)
365 APPLET(tty, tty_main, _BB_DIR_USR_BIN)
368 APPLET(umount, umount_main, _BB_DIR_BIN)
371 APPLET(uname, uname_main, _BB_DIR_BIN)
374 APPLET(uniq, uniq_main, _BB_DIR_USR_BIN)
377 APPLET(unix2dos, unix2dos_main, _BB_DIR_USR_BIN)
380 APPLET(update, update_main, _BB_DIR_SBIN)
383 APPLET(uptime, uptime_main, _BB_DIR_USR_BIN)
386 APPLET(usleep, usleep_main, _BB_DIR_BIN)
389 APPLET(uudecode, uudecode_main, _BB_DIR_USR_BIN)
392 APPLET(uuencode, uuencode_main, _BB_DIR_USR_BIN)
395 APPLET(watchdog, watchdog_main, _BB_DIR_SBIN)
398 APPLET(wc, wc_main, _BB_DIR_USR_BIN)
401 APPLET(wget, wget_main, _BB_DIR_USR_BIN)
404 APPLET(which, which_main, _BB_DIR_USR_BIN)
407 APPLET(whoami, whoami_main, _BB_DIR_USR_BIN)
410 APPLET(xargs, xargs_main, _BB_DIR_USR_BIN)
413 APPLET(yes, yes_main, _BB_DIR_USR_BIN)
416 APPLET(zcat, gunzip_main, _BB_DIR_BIN)
419 #if !defined(PROTOTYPES) && !defined(MAKE_LINKS) && !defined(APPLET_ENUM)
423 /* The -1 arises because of the {0,NULL,0,-1} entry above. */
424 size_t NUM_APPLETS = (sizeof (applets) / sizeof (struct BB_applet) - 1);