Changeset 1765 in MondoRescue for branches/2.2.5/mindi-busybox/docs
- Timestamp:
- Nov 4, 2007, 3:16:40 AM (18 years ago)
- Location:
- branches/2.2.5/mindi-busybox/docs
- Files:
-
- 14 added
- 17 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.2.5/mindi-busybox/docs/autodocifier.pl
r902 r1765 26 26 $text =~ s/SKIP_\w+\(.*?"\s*\)//sxg; 27 27 $text =~ s/USE_\w+\(\s*?(.*?)"\s*\)/$1"/sxg; 28 $text =~ s/USAGE_\w+\(\s*?(.*?)"\s*\)/$1"/sxg; 28 29 last if ( $text2 eq $text ); 29 30 } … … 301 302 =cut 302 303 303 # $Id: autodocifier.pl,v 1.26 2004/04/06 15:26:25 andersen Exp $ -
branches/2.2.5/mindi-busybox/docs/busybox.net/FAQ.html
r821 r1765 11 11 <li><a href="#getting_started">How can I get started using BusyBox?</a></li> 12 12 <li><a href="#configure">How do I configure busybox?</a></li> 13 <li><a href="#build">How do I build BusyBox with a cross-compiler?</a></li> 13 14 <li><a href="#build_system">How do I build a BusyBox-based system?</a></li> 14 15 <li><a href="#kernel">Which Linux kernel versions are supported?</a></li> … … 25 26 <ol> 26 27 <li><a href="#bugs">I think I found a bug in BusyBox! What should I do?!</a></li> 28 <li><a href="#backporting">I'm using an ancient version from the dawn of time and something's broken. Can you backport fixes for free?</a></li> 27 29 <li><a href="#init">Busybox init isn't working!</a></li> 28 30 <li><a href="#sed">I can't configure busybox on my system.</a></li> 29 31 <li><a href="#job_control">Why do I keep getting "sh: can't access tty; job control turned off" errors? Why doesn't Control-C work within my shell?</a></li> 32 </ol> 33 34 <h2>Misc. questions</h2> 35 <ol> 36 <li><a href="#tz">How do I change the time zone in busybox?</a></li> 30 37 </ol> 31 38 … … 51 58 <li><a href="#tips_kernel_headers">Including Linux kernel headers.</a></li> 52 59 </ul> 53 <li><a href="#who">Who are the BusyBox developers?</a></li> 54 </ul> 55 56 60 <li><a href="#who">Who are the BusyBox developers?</a></li> 61 </ul> 57 62 </ol> 58 63 64 65 <hr /> 59 66 <h1>General questions</h1> 60 67 61 68 <hr /> 62 <p>63 69 <h2><a name="getting_started">How can I get started using BusyBox?</a></h2> 70 64 71 <p> If you just want to try out busybox without installing it, download the 65 72 tarball, extract it, run "make defconfig", and then run "make". … … 82 89 </p> 83 90 <p> 84 BusyBox also has a feature called the "standalone shell", where the busybox 91 BusyBox also has a feature called the 92 <a name="standalone_shell">"standalone shell"</a>, where the busybox 85 93 shell runs any built-in applets before checking the command path. This 86 94 feature is also enabled by "make allyesconfig", and to try it out run … … 88 96 and run busybox as your command shell, so the only commands it can find 89 97 (without an explicit path such as /bin/ls) are the built-in busybox ones. 90 This is another good way to see what's built into busybox. (Note that the 91 standalone shell is dependent on the existence of /proc/self/exe, so before 92 using it in a chroot environment you must mount /proc.) 93 </p> 94 95 <hr /> 96 <p> 98 This is another good way to see what's built into busybox. 99 Note that the standalone shell requires CONFIG_BUSYBOX_EXEC_PATH 100 to be set appropriately, depending on whether or not /proc/self/exe is 101 available or not. If you do not have /proc, then point that config option 102 to the location of your busybox binary, usually /bin/busybox. 103 (So if you set it to /proc/self/exe, and happen to be able to chroot into 104 your rootfs, you must mount /proc beforehand.) 105 </p> 106 <p> 107 A typical indication that you set CONFIG_BUSYBOX_EXEC_PATH to proc but 108 forgot to mount proc is: 109 <pre> 110 $ /bin/echo $PATH 111 /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/bin/X11 112 $ echo $PATH 113 /bin/sh: echo: not found 114 </pre> 115 116 <hr /> 97 117 <h2><a name="configure">How do I configure busybox?</a></h2> 118 98 119 <p> Busybox is configured similarly to the linux kernel. Create a default 99 120 configuration and then run "make menuconfig" to modify it. The end … … 141 162 busybox features, and get help about each feature. 142 163 143 144 145 164 <p> 146 165 To build a smaller busybox binary, run "make menuconfig" and disable the … … 149 168 with "make" once you've finished configuring.) 150 169 </p> 151 <hr/> 152 <p/> 170 171 <hr /> 172 <h2><a name="build">How do I build BusyBox with a cross-compiler?</a></h2> 173 174 <p> 175 To build busybox with a cross-compiler, specify CROSS_COMPILE=<prefix>. 176 </p> 177 <p> 178 CROSS_COMPILE specifies the prefix used for all executables used 179 during compilation. Only gcc and related binutils executables 180 are prefixed with $(CROSS_COMPILE) in the makefiles. 181 CROSS_COMPILE can be set on the command line: 182 <pre> 183 make CROSS_COMPILE=arm-linux-uclibcgnueabi- 184 </pre> 185 Alternatively CROSS_COMPILE can be set in the environment. 186 Default value for CROSS_COMPILE is not to prefix executables. 187 </p> 188 189 <hr /> 153 190 <h2><a name="build_system">How do I build a BusyBox-based system?</a></h2> 191 154 192 <p> 155 193 BusyBox is a package that replaces a dozen standard packages, but it is … … 192 230 193 231 <hr /> 194 <p>195 232 <h2><a name="kernel">Which Linux kernel versions are supported?</a></h2> 233 196 234 <p> 197 235 Full functionality requires Linux 2.4.x or better. (Earlier versions may … … 202 240 are into that sort of thing). 203 241 </p> 204 <hr /> 205 < p>242 243 <hr /> 206 244 <h2><a name="arch">Which architectures does BusyBox run on?</a></h2> 245 207 246 <p> 208 247 BusyBox in general will build on any architecture supported by gcc. … … 214 253 With 2.6.x kernels, module loading support should work on all architectures. 215 254 </p> 216 <hr /> 217 < p>255 256 <hr /> 218 257 <h2><a name="libc">Which C libraries are supported?</a></h2> 258 219 259 <p> 220 260 On Linux, BusyBox releases are tested against uClibc (0.9.27 or later) and … … 236 276 237 277 <hr /> 238 <p>239 278 <h2><a name="commercial">Can I include BusyBox as part of the software on my device?</a></h2> 240 <p>241 279 242 280 <p> … … 247 285 248 286 <hr /> 249 <p> 250 <h2><a name="external">where can i find other small utilities since busybox 287 <h2><a name="external">Where can I find other small utilities since busybox 251 288 does not include the features i want?</a></h2> 289 252 290 <p> 253 291 we maintain such a <a href="tinyutils.html">list</a> on this site! … … 255 293 256 294 <hr /> 257 <p>258 295 <h2><a name="demanding">I demand that you to add <favorite feature> right now! How come you don't answer all my questions on the mailing list instantly? I demand that you help me with all of my problems <em>Right Now</em>!</a></h2> 259 <p> 260 296 297 <p> 261 298 You have not paid us a single cent and yet you still have the product of 262 299 many years of our work. We are not your slaves! We work on BusyBox … … 264 301 will ignore you. 265 302 266 267 <hr /> 268 <p> 303 <hr /> 269 304 <h2><a name="helpme">I need help with BusyBox! What should I do?</a></h2> 270 <p> 271 305 306 <p> 272 307 If you find that you need help with BusyBox, you can ask for help on the 273 308 BusyBox mailing list at busybox@busybox.net.</p> … … 297 332 298 333 <hr /> 299 <p>300 334 <h2><a name="contracts">I need you to add <favorite feature>! Are the BusyBox developers willing to be paid in order to fix bugs or add in <favorite feature>? Are you willing to provide support contracts?</a></h2> 301 </p>302 335 303 336 <p> … … 317 350 318 351 319 320 352 <hr /> 321 353 <h1>Troubleshooting</h1> 322 354 323 355 <hr /> 324 <p></p>325 356 <h2><a name="bugs">I think I found a bug in BusyBox! What should I do?</a></h2> 326 <p></p>327 357 328 358 <p> … … 337 367 338 368 <p> 339 The developers of BusyBox are busy people, and have only so much they can 340 keep in their brains at a time. As a result, bug reports and new feature 341 patches sometimes get lost when posted to the mailing list. To prevent 342 your bug report from getting lost, if you find a bug in BusyBox that isn't 343 immediately addressed, please use the <a 344 href="http://bugs.busybox.net/">BusyBox Bug and Patch Tracking System</a> 345 to submit a detailed explanation and we'll get to it as soon as we can. 346 </p> 347 348 <hr /> 349 <p> 369 Bug reports and new feature patches sometimes get lost when posted to the 370 mailing list, because the developers of BusyBox are busy people and have 371 only so much they can keep in their brains at a time. You can post a 372 polite reminder after 2-3 days without offending anybody. If that doesn't 373 result in a solution, please use the 374 <a href="http://bugs.busybox.net/">BusyBox Bug 375 and Patch Tracking System</a> to submit a detailed explanation and we'll 376 get to it as soon as we can. 377 </p> 378 379 <p> 380 Note that bugs entered into the bug system without being mentioned on the 381 mailing list first may languish there for months before anyone even notices 382 them. We generally go through the bug system when preparing for new 383 development releases, to see what fell through the cracks while we were 384 off writing new features. (It's a fast/unreliable vs slow/reliable thing. 385 Saves retransits, but the latency sucks.) 386 </p> 387 388 <hr /> 389 <h2><a name="backporting">I'm using an ancient version from the dawn of time and something's broken. Can you backport fixes for free?</h2> 390 391 <p>Variants of this one get asked a lot.</p> 392 393 <p>The purpose of the BusyBox mailing list is to develop and improve BusyBox, 394 and we're happy to respond to our users' needs. But if you're coming to the 395 list for free tech support we're going to ask you to upgrade to a current 396 version before we try to diagnose your problem.</p> 397 398 <p>If you're building BusyBox 0.50 with uClibc 0.9.19 and gcc 0.9.26 there's a 399 fairly large chance that whatever problem you're seeing has already been fixed. 400 To get that fix, all you have to do is upgrade to a newer version. If you 401 don't at least _try_ that, you're wasting our time.</p> 402 403 <p>The volunteers are happy to fix any bugs you point out in the current 404 versions because doing so helps everybody and makes the project better. We 405 want to make the current version work for you. But diagnosing, debugging, and 406 backporting fixes to old versions isn't something we do for free, because it 407 doesn't help anybody but you. The cost of volunteer tech support is using a 408 reasonably current version of the project.</p> 409 410 <p>If you don't want to upgrade, you have the complete source code and thus 411 the ability to fix it yourself, or hire a consultant to do it for you. If you 412 got your version from a vendor who still supports the older version, they can 413 help you. But there are limits as to what the volunteers will feel obliged to 414 do for you.</p> 415 416 <p>As a rule of thumb, volunteers will generally answer polite questions about 417 a given version for about three years after its release before it's so old 418 we don't remember the answer off the top of our head. And if you want us to 419 put any _effort_ into tracking it down, we want you to put in a little effort 420 of your own by confirming it's still a problem with the current version. It's 421 also hard for us to fix a problem of yours if we can't reproduce it because 422 we don't have any systems running an environment that old.</p> 423 424 <p>A consultant will happily set up a special environment just to reproduce 425 your problem, and you can always ask on the list if any of the developers 426 have consulting rates.</p> 427 428 <hr /> 350 429 <h2><a name="init">Busybox init isn't working!</a></h2> 430 351 431 <p> 352 432 Init is the first program that runs, so it might be that no programs are … … 381 461 382 462 <hr /> 383 <p>384 463 <h2><a name="sed">I can't configure busybox on my system.</a></h2> 464 385 465 <p> 386 466 Configuring Busybox depends on a recent version of sed. Older … … 409 489 410 490 <hr /> 411 <p>412 491 <h2><a name="job_control">Why do I keep getting "sh: can't access tty; job control turned off" errors? Why doesn't Control-C work within my shell?</a></h2> 413 <p> 414 492 493 <p> 415 494 Job control will be turned off since your shell can not obtain a controlling 416 495 terminal. This typically happens when you run your shell on /dev/console. … … 424 503 </p> 425 504 505 <hr /> 506 <h1>Misc. questions</h1> 507 508 <hr /> 509 <h2><a name="tz">How do I change the time zone in busybox?</a></h2> 510 511 <p>Busybox has nothing to do with the timezone. Please consult your libc 512 documentation. (<a href='http://google.com/search?q=uclibc+glibc+timezone'>http://google.com/search?q=uclibc+glibc+timezone</a>).</p> 513 514 <hr /> 426 515 <h1>Development</h1> 427 516 428 <h2><b><a name="goals">What are the goals of busybox?</a></b></h2> 517 <hr /> 518 <h2><a name="goals">What are the goals of busybox?</a></h2> 429 519 430 520 <p>Busybox aims to be the smallest and simplest correct implementation of the … … 435 525 take over the world.</p> 436 526 437 <h2><b><a name="design">What is the design of busybox?</a></b></h2> 527 <hr /> 528 <h2><a name="design">What is the design of busybox?</a></h2> 438 529 439 530 <p>Busybox is like a swiss army knife: one thing with many functions. … … 459 550 <a name="source"></a> 460 551 461 <h2><a name="source_applets"><b>The applet directories</b></a></h2> 552 <hr /> 553 <h2><a name="source_applets">The applet directories</a></h2> 462 554 463 555 <p>The directory "applets" contains the busybox startup code (applets.c and … … 466 558 467 559 <p>Busybox execution starts with the main() function in applets/busybox.c, 468 which sets the global variable bb_applet_name to argv[0] and calls469 run_applet_ by_name() in applets/applets.c. That uses the applets[] array560 which sets the global variable applet_name to argv[0] and calls 561 run_applet_and_exit() in applets/applets.c. That uses the applets[] array 470 562 (defined in include/busybox.h and filled out in include/applets.h) to 471 563 transfer control to the appropriate APPLET_main() function (such as … … 499 591 information.</p> 500 592 593 <hr /> 501 594 <h2><a name="source_libbb"><b>libbb</b></a></h2> 502 595 … … 512 605 of open(), close(), read(), and write() that test for their own failures 513 606 and/or retry automatically, linked list management functions (llist.c), 514 command line argument parsing (getopt_ulflags.c), and a whole lot more.</p> 515 516 <hr /> 517 <p> 607 command line argument parsing (getopt32.c), and a whole lot more.</p> 608 609 <hr /> 518 610 <h2><a name="optimize">I want to make busybox even smaller, how do I go about it?</a></h2> 611 519 612 <p> 520 613 To conserve bytes it's good to know where they're being used, and the … … 567 660 for a sepecific symbol. 568 661 </p> 569 <hr /> 570 571 572 573 <h2><a name="adding"><b>Adding an applet to busybox</b></a></h2> 662 663 <hr /> 664 <h2><a name="adding">Adding an applet to busybox</a></h2> 574 665 575 666 <p>To add a new applet to busybox, first pick a name for the applet and … … 612 703 </ul> 613 704 705 <hr /> 614 706 <h2><a name="standards">What standards does busybox adhere to?</a></h2> 615 707 … … 641 733 document where we (intentionally) fall short.</p> 642 734 735 <hr /> 643 736 <h2><a name="portability">Portability.</a></h2> 644 737 … … 717 810 something we're trying to avoid.</p> 718 811 812 <hr /> 719 813 <h2><a name="tips" />Programming tips and tricks.</a></h2> 720 814 … … 722 816 elsewhere.</p> 723 817 818 <hr /> 724 819 <h2><a name="tips_encrypted_passwords">Encrypted Passwords</a></h2> 725 820 … … 773 868 second argument to pw_encrypt(text,buffer).</p> 774 869 870 <hr /> 775 871 <h2><a name="tips_vfork">Fork and vfork</a></h2> 776 872 … … 851 947 something subtle and thus even more dangerous.)</p> 852 948 949 <hr /> 853 950 <h2><a name="tips_sort_read">Short reads and writes</a></h2> 854 951 … … 877 974 <p>So will data always be read from the far end of a pipe at the 878 975 same chunk sizes it was written in? Nope. Don't rely on that. For one 879 counterexample, see <a href="http://www.faqs.org/rfcs/rfc896.html">rfc 896 976 counterexample, see <a href="http://www.faqs.org/rfcs/rfc896.html">rfc 896 880 977 for Nagle's algorithm</a>, which waits a fraction of a second or so before 881 978 sending out small amounts of data through a TCP/IP connection in case more … … 884 981 on their their sockets, now you know.)</p> 885 982 983 <hr /> 886 984 <h2><a name="tips_memory">Memory used by relocatable code, PIC, and static linking.</a></h2> 887 985 … … 948 1046 </blockquote> 949 1047 1048 <hr /> 950 1049 <h2><a name="tips_kernel_headers"></a>Including kernel headers</h2> 951 1050 … … 985 1084 is not a better way.</p> 986 1085 1086 <hr /> 987 1087 <h2><a name="who">Who are the BusyBox developers?</a></h2> 988 1088 … … 993 1093 <pre> 994 1094 aldot :Bernhard Fischer 995 andersen :Erik Andersen <- uClibc and BuildRoot maintainer.1095 andersen :Erik Andersen - uClibc and BuildRoot maintainer. 996 1096 bug1 :Glenn McGrath 997 1097 davidm :David McCullough 998 gkajmowi :Garrett Kajmowicz <- uClibc++ maintainer1098 gkajmowi :Garrett Kajmowicz - uClibc++ maintainer 999 1099 jbglaw :Jan-Benedict Glaw 1000 1100 jocke :Joakim Tjernlund 1001 landley :Rob Landley <- BusyBox maintainer1101 landley :Rob Landley - BusyBox maintainer 1002 1102 lethal :Paul Mundt 1003 1103 mjn3 :Manuel Novoa III … … 1017 1117 1018 1118 <p>The following accounts used to exist on busybox.net, but don't anymore so 1019 I can't ask /etc/passwd for their names. (If anybody would like to make1020 a stab at it...)</p>1119 I can't ask /etc/passwd for their names. Rob Wentworth <robwen@gmail.com> 1120 asked Google and recovered the names:</p> 1021 1121 1022 1122 <pre> 1023 aaronl 1024 beppu 1025 dwhedon 1026 erik : Also Erik Andersen?1027 gfeldman 1028 jimg 1029 kraai 1030 markw 1031 miles 1032 proski 1033 rjune 1034 tausq 1035 vodz 1123 aaronl :Aaron Lehmann 1124 beppu :John Beppu 1125 dwhedon :David Whedon 1126 erik :Erik Andersen 1127 gfeldman :Gennady Feldman 1128 jimg :Jim Gleason 1129 kraai :Matt Kraai 1130 markw :Mark Whitley 1131 miles :Miles Bader 1132 proski :Pavel Roskin 1133 rjune :Richard June 1134 tausq :Randolph Chung 1135 vodz :Vladimir N. Oleynik 1036 1136 </pre> 1037 1137 -
branches/2.2.5/mindi-busybox/docs/busybox.net/about.html
r821 r1765 17 17 nodes in /dev, a few configuration files in /etc, and a Linux kernel.</p> 18 18 19 <p>BusyBox is maintained by <a href="http://www.landley.net/">Rob Landley</a>, 19 <p>BusyBox is maintained by 20 <a href="mailto:vda.linux@googlemail.com">Denis Vlasenko</a>, 20 21 and licensed under the <a href="/license.html">GNU GENERAL PUBLIC LICENSE</a> 21 version 2 or later.</p>22 version 2.</p> 22 23 23 24 <!--#include file="footer.html" --> -
branches/2.2.5/mindi-busybox/docs/busybox.net/footer.html
r821 r1765 17 17 Mail all comments, insults, suggestions and bribes to 18 18 <br> 19 Rob Landley <a href="mailto:rob@landley.net">rob@landley.net</a><br>19 Denis Vlasenko <a href="mailto:vda.linux@googlemail.com">vda.linux@googlemail.com</a><br> 20 20 </font> 21 21 </td> -
branches/2.2.5/mindi-busybox/docs/busybox.net/header.html
r821 r1765 46 46 <b>About</b> 47 47 <ul> 48 <li><a href="about.html">About BusyBox</a></li> 49 <li><a href="screenshot.html">Screenshot</a></li> 50 <li><a href="news.html">Latest News</a></li> 48 <li><a href="about.html">About BusyBox</a></li> 49 <li><a href="screenshot.html">Screenshot</a></li> 50 <li><a href="news.html">Announcements</a></li> 51 <li><a href="downloads/news">BusyBox Weekly News</a></li> 51 52 </ul> 52 53 <b>Documentation</b> … … 66 67 <li><a href="/cgi-bin/viewcvs.cgi/trunk/busybox/">Browse Source</a></li> 67 68 <li><a href="subversion.html">Source Control</a></li> 69 <li><a href="/downloads/patches/recent.html">Recent Changes</a></li> 68 70 <li><a href="lists.html">Mailing Lists</a></li> 69 71 <li><a href="http://bugs.busybox.net/">Bug Tracking</a></li> … … 72 74 <ul> 73 75 <li><a href="links.html">Related Sites</a></li> 74 <li><a href="tinyutils.html">Tiny Utilities</a></li> 75 <li><a href="sponsors.html">Sponsors</a></li> 76 <li><a href="tinyutils.html">Tiny Utilities</a></li> 77 <li><a href="sponsors.html">Sponsors</a></li> 78 </ul> 79 <p><b>Developer Pages</b> 80 <ul> 81 <li><a href="http://busybox.net/~landley">Rob</a></li> 82 <li><a href="http://busybox.net/~aldot">Bernhard</a></li> 83 <li><a href="http://busybox.net/~vda">Denis</a></li> 76 84 </ul> 77 85 -
branches/2.2.5/mindi-busybox/docs/busybox.net/license.html
r821 r1765 2 2 3 3 <p> 4 <h3>BusyBox is licensed under the GNU General Public License </h3>4 <h3>BusyBox is licensed under the GNU General Public License, version 2</h3> 5 5 6 6 <p>BusyBox is licensed under <a href="http://www.gnu.org/licenses/gpl.html#SEC1">the 7 GNU General Public License</a> version 2 or later, which is generally 8 abbreviated as the GPL. (This is the same license the Linux kernel is under, 9 so you may be somewhat familiar with it by now.)</p> 7 GNU General Public License</a> version 2, which is often abbreviated as GPLv2. 8 (This is the same license the Linux kernel is under, so you may be somewhat 9 familiar with it by now.)</p> 10 11 <p>A complete copy of the license text is included in the file LICENSE in 12 the BusyBox source code.</p> 10 13 11 14 <p><a href="/products.html">Anyone thinking of shipping BusyBox as part of a … … 23 26 license terms still apply to you.) Read the license text for the details.</p> 24 27 28 <h3>A note on GPL versions</h3> 29 30 <p>Version 2 of the GPL is the only version of the GPL which current versions 31 of BusyBox may be distributed under. New code added to the tree is licensed 32 GPL version 2, and the project's license is GPL version 2.</p> 33 34 <p>Older versions of BusyBox (versions 1.2.2 and earlier, up through about svn 35 16112) included variants of the recommended "GPL version 2 or (at your option) 36 later versions" boilerplate permission grant. Ancient versions of BusyBox 37 (before svn 49) did not specify any version at all, and section 9 of GPLv2 38 (the most recent version at the time) says those old versions may be 39 redistributed under any version of GPL (including the obsolete V1). This was 40 conceptually similar to a dual license, except that the different licenses were 41 different versions of the GPL.</p> 42 43 <p>However, BusyBox has apparently always contained chunks of code that were 44 licensed under GPL version 2 only. Examples include applets written by Linus 45 Torvalds (util-linux/mkfs_minix.c and util_linux/mkswap.c) which stated they 46 "may be redistributed as per the Linux copyright" (which Linus clarified in the 47 2.4.0-pre8 release announcement in 2000 was GPLv2 only), and Linux kernel code 48 copied into libbb/loop.c (after Linus's announcement). There are probably 49 more, because all we used to check was that the code was GPL, not which 50 version. (Before the GPLv3 draft proceedings in 2006, it was a purely 51 theoretical issue that didn't come up much.)</p> 52 53 <p>To summarize: every version of BusyBox may be distributed under the terms of 54 GPL version 2. New versions (after 1.2.2) may <b>only</b> be distributed under 55 GPLv2, not under other versions of the GPL. Older versions of BusyBox might 56 (or might not) be distributable under other versions of the GPL. If you 57 want to use a GPL version other than 2, you should start with one of the old 58 versions such as release 1.2.2 or SVN 16112, and do your own homework to 59 identify and remove any code that can't be licensed under the GPL version you 60 want to use. New development is all GPLv2.</p> 61 62 <h3>License enforcement</h3> 63 25 64 <p>BusyBox's copyrights are enforced by the <a 26 href="http://www.softwarefreedom.org">Software Freedom Law Center</a>, which 65 href="http://www.softwarefreedom.org">Software Freedom Law Center</a> 66 (you can contact them at gpl@busybox.net), which 27 67 "accepts primary responsibility for enforcement of US copyrights on the 28 68 software... and coordinates international copyright enforcement efforts for -
branches/2.2.5/mindi-busybox/docs/busybox.net/news.html
r821 r1765 1 1 <!--#include file="header.html" --> 2 2 3 4 3 <ul> 4 <li><b>24 August 2007 -- BusyBox 1.7.0 (unstable)</b> 5 <p><a href=http://busybox.net/downloads/busybox-1.7.0.tar.bz2>BusyBox 1.7.0</a>. 6 (<a href=http://busybox.net/cgi-bin/viewcvs.cgi/branches/busybox_1_7_stable/>svn</a>, 7 <a href=http://busybox.net/downloads/fixes-1.7.0/>patches</a>, 8 <a href=http://busybox.net/fix.html>how to add a patch</a>)</p> 9 10 <p>Applets which had many changes since 1.6.x: 11 <p>httpd: 12 <ul> 13 <li>works in standalone mode on NOMMU machines now (partly by Alex Landau <landau_alex@yahoo.com>) 14 <li>indexer example is rewritten in C 15 <li>optional support for error pages (by Pierre Metras <genepi@sympatico.ca>) 16 <li>stop reading headers using 1-byte reads 17 <li>new option -v[v]: prints client addresses, HTTP codes returned, URLs 18 <li>extended -p PORT to -p [IP[v6]:]PORT 19 <li>sendfile support 20 <li>add support for Status: CGI header 21 <li>fix CGI handling bug (we were closing wrong fd) 22 <li>CGI I/O loop still doesn't look 100% ok to me... 23 </ul> 24 25 <p>udhcp[cd]: 26 <ul> 27 <li>add -f "foreground" and -S "syslog" options 28 <li>fixed "ifupdown + udhcpc_without_pidpile_creation" bug 29 <li>new config option "Rewrite the lease file at every new acknowledge" (Mats Erik Andersson <mats@blue2net.com> (Blue2Net AB)) 30 <li>consistently treat server_config.start/end IPs as host-order 31 <li>fix IP parsing for 64bit machines 32 <li>fix unsafe hton macro usage in read_opt() 33 <li>do not chdir to / when daemonizing 34 </ul> 35 36 <p>top, ps, killall, pidof 37 <ul> 38 <li>simpler loadavg processing 39 <li>truncate usernames to 8 chars 40 <li>fix non-CONFIG_DESKTOP ps -ww (by rockeychu) 41 <li>improve /proc/PID/cmdinfo reading code 42 <li>use cmdline, not comm field (fixes problems with re-execed applets showing as processes with name "exe", and not being found by pidof/killall by applet name) 43 <li>reduce CPU usage in decimal conversion (optional) (corresponding speedup on kernel side is accepted in mainline Linux kernel, yay!) 44 <li>make percentile (0.1%) calculations configurable 45 <li>add config option and code for global CPU% display 46 <li>reorder columns, so that [P]PIDs are together and VSZ/%MEM are together - makes more sense 47 </ul> 48 49 <p>Build system improvements: doesn't link against libraries we don't need, 50 generates verbose link output and map file, allows for custom link 51 stripts (useful for removing extra padding, among other things). 52 53 <p>Code and data size in comparison with 1.6.1:<pre> 54 Equivalent .config, i386 glibc dynamic builds: 55 text data bss dec hex filename 56 672671 2768 16808 692247 a9017 busybox-1.6.1/busybox 57 662948 2660 13528 679136 a5ce0 busybox-1.7.0/busybox 58 662783 2631 13416 678830 a5bae busybox-1.7.0/busybox.customld 59 60 Same .config built against static uclibc: 61 765021 1059 11020 777100 bdb8c busybox-1.7.0/busybox_uc</pre> 62 63 <p>Code/data shrink done in applets: crond, hdparm, dd, cal, od, nc, expr, uuencode, 64 test, slattach, diff, ping, tr, syslogd, hwclock, zcip, find, pidof, ash, uudecode, 65 runit/*, in libbb. 66 67 <p>New applets: 68 <ul> 69 <li>pscan, expand, unexpand (from Tito <farmatito@tiscali.it>) 70 <li>setfiles, restorecon (by Yuichi Nakamura <ynakam@hitachisoft.jp>) 71 <li>chpasswd (by Alexander Shishkin <virtuoso@slind.org>) 72 <li>slattach, ttysize 73 </ul> 74 75 <p>Unfortunately, not much work is done on shells. This was mostly stalled 76 by lack of time (read: laziness) on my part to learn how to adapt existing 77 qemu-runnable image for a NOMMU architechture (available on qemu website) 78 for local testing of cross-compiled busybox on my machine. 79 80 <p>Other changes since previous release (abridged): 81 <ul> 82 <li>addgroup: disallow addgroup -g num user group; make -g 0 work (Tito <farmatito@tiscali.it>) 83 <li>adduser: close /etc/{passwd,shadow} before calling passwd etc. Spotted by Natanael Copa <natanael.copa@gmail.com> 84 <li>arping: -i should be -I, fixed 85 <li>ash: make "jobs | cat" work like in bash (was giving empty output) 86 <li>ash: recognize -l as --login equivalent; do not recognize +-login 87 <li>ash: fix buglet in DEBUG code (Nguyen Thai Ngoc Duy <pclouds@gmail.com>) 88 <li>ash: fix SEGV if type has zero parameters 89 <li>awk: fix -F 'regex' bug (miscounted fields if last field is empty) 90 <li>catv: catv without arguments was trying to use environ as argv (Alex Landau <landau_alex@yahoo.com>) 91 <li>catv: don't die on open error (emit warning) 92 <li>chown/chgrp: completely match coreutils 6.8 wrt symlink handling 93 <li>correct_password: do not print "no shadow passwd..." message 94 <li>crond: don't start sendmail with absolute path, don't report obsolete version (report true bbox version) 95 <li>dd: fix bug where we assume count=INT_MAX when count is unspecified 96 <li>devfsd: sanitization by Tito <farmatito@tiscali.it> 97 <li>echo: fix non-fancy echo 98 <li>fdisk: make it work with big disks (read: typical today's disks) even if CONFIG_LFS is unset 99 <li>find: -context support for SELinux (KaiGai Kohei <kaigai@kaigai.gr.jp>) 100 <li>find: add conditional support for -maxdepth and -regex, make -size match GNU find 101 <li>find: fix build failure on certain configs (found by Cristian Ionescu-Idbohrn <cristian.ionescu-idbohrn@axis.com>) 102 <li>fsck_minix: make it print bb version, not it's own (outdated/irrelevant) one 103 <li>grep: implement -m MAX_MATCHES, fix buglets with context printing 104 <li>grep: fix selection done by FEATURE_GREP_EGREP_ALIAS (Maxime Bizon <mbizon@freebox.fr> (Freebox)) 105 <li>hush: add missing dependencies (Maxime Bizon <mbizon@freebox.fr> (Freebox)) 106 <li>hush: fix read builtin to not read ahead past EOL and to not use insane amounts of stack 107 <li>ifconfig: make it work with ifaces with interface no. > 255 108 <li>ifup/ifdown: make location of ifstate configurable 109 <li>ifupdown: make netmask parsing smaller and more strict (was accepting 255.0.255.0, 255.1234.0.0 etc...) 110 <li>install: fix -s (strip) option, fix install a b /a/link/to/dir 111 <li>libbb: consolidate ARRAY_SIZE macro (Walter Harms <wharms@bfs.de>) 112 <li>libbb: make /etc/network parsing configurable. -200 bytes when off 113 <li>libbb: nuke BB_GETOPT_ERROR, always die if there are mutually exclusive options 114 <li>libbb: xioctl and friends by Tito <farmatito@tiscali.it> 115 <li>login: optional support for PAM 116 <li>login: make /etc/nologin support configurable (-240 bytes) 117 <li>login: ask passwords even for wrong usernames 118 <li>md5_sha1_sum: fix mishandling when run as /bin/md5sum 119 <li>mdev: add support for firmware loading 120 <li>mdev: work even when CONFIG_SYSFS_DEPRECATED in kernel is off 121 <li>modprobe: add scanning of /lib/modules/`uname -r`/modules.symbols (by Yann E. MORIN) 122 <li>more: fixes by Tristan Schmelcher <tpkschme@engmail.uwaterloo.ca> 123 <li>nc: make connecting to IPv4 from IPv6-enabled hosts easier (was requiring -s local_addr) 124 <li>passwd: fix bug "updating shadow even if user's record is in passwd" 125 <li>patch: fix -p -1 handling 126 <li>patch: fix bad line ending handling (Nguyen Thai Ngoc Duy <pclouds@gmail.com>) 127 <li>ping: display roundtrip times with 1/1000th of ms, not 1/10 ms precision. 128 <li>ping: fix incorrect handling of -I (Iouri Kharon <bc-info@styx.cabel.net>>) 129 <li>ping: fix non-fancy ping6 130 <li>printenv: fix "printenv VAR1 VAR2" bug (spotted by Kalyanatejaswi Balabhadrapatruni <kalyanatejaswi@yahoo.co.in>) 131 <li>ps: fix -Z (by Yuichi Nakamura <ynakam@hitachisoft.jp>) 132 <li>rpm: add optional support for bz2 data. +50 bytes of code 133 <li>rpm: fix bogus "package is not installed" case 134 <li>sed: fix 'q' command handling (by Nguyen Thai Ngoc Duy <pclouds@gmail.com>) 135 <li>start_stop_daemon: NOMMU fixes by Alex Landau <landau_alex@yahoo.com> 136 <li>stat: fix option -Z SEGV 137 <li>strings: strings a b was processing a twice, fix that 138 <li>svlogd: fix timestamping, do not warn if config is missing 139 <li>syslogd, logread: get rid of head pointer, fix logread bug in the process 140 <li>syslogd: do not convert tabs to ^I, set syslog IPC buffer to mode 0644 141 <li>tar: improve OLDGNU compat, make old SUN compat configurable 142 <li>test: fix testing primary expressions like '"-u" = "-u"' 143 <li>uudecode: fix to base64 decode by Jorgen Cederlof <jcz@google.com> 144 <li>vi: multiple fixes by Natanael Copa <natanael.copa@gmail.com> 145 <li>wget: fix bug in base64 encoding (bug 1404). +10 bytes 146 <li>wget: lift 256 chars limitation on terminal width 147 <li>wget, zcip: use monotonic_sec instead of gettimeofday 148 </ul> 149 </p> 150 </li> 151 152 <li><b>30 June 2007 -- BusyBox 1.6.1 (stable)</b> 153 <p><a href=http://busybox.net/downloads/busybox-1.6.1.tar.bz2>BusyBox 1.6.1</a>. 154 (<a href=http://busybox.net/cgi-bin/viewcvs.cgi/branches/busybox_1_6_stable/>svn</a>, 155 <a href=http://busybox.net/downloads/fixes-1.6.1/>patches</a>, 156 <a href=http://busybox.net/fix.html>how to add a patch</a>)</p> 157 158 <p>This is a bugfix-only release, with fixes to echo, hush, and wget.</p> 159 </li> 160 161 <li><b>1 June 2007 -- BusyBox 1.6.0 (unstable)</b> 162 <p><a href=http://busybox.net/downloads/busybox-1.6.0.tar.bz2>BusyBox 1.6.0</a>. 163 (<a href=http://busybox.net/cgi-bin/viewcvs.cgi/branches/busybox_1_6_stable/>svn</a>, 164 <a href=http://busybox.net/downloads/fixes-1.6.0/>patches</a>, 165 <a href=http://busybox.net/fix.html>how to add a patch</a>)</p> 166 167 <p>Since this is a x.x.0 release, it probably does not deserve "stable" 168 label. Please help making 1.6.1 stable by testing 1.6.0.</p> 169 <p>Note that hush shell had many changes and (hopefully) is much improved now, 170 but there is a possibility that it regressed in some obscure cases. Please 171 report any such cases.</p> 172 <p>lash users please note: lash is going to be deprecated in busybox 1.7.0 173 and removed in the more distant future. Please migrate to hush.</p> 174 <p><a href=http://busybox.net/~vda/mem_usage-1.6.0.txt>Memory usage has decreased, but we can do better still</a></p> 175 <p>Other changes since previous release: 176 <ul> 177 <li>NOFORK: audit small applets and mark some of them as NOFORK. Put big scary warnings in relevant places 178 <li>NOFORK: factor out NOFORK/NOEXEC code from find. Use NOFORK/NOEXEC in find and xargs 179 <li>NOFORK: remove potential xmalloc from NOFORK path in bb_full_fd_action 180 <li>NOMMU: random fixes; compressed --help now works for NOMMU 181 <li>SELinux: load_policy applet 182 <li>[u]mount: extend -t option (Roy Marples <uberlord@gentoo.org>) 183 <li>addgroup: clean up, fix adding users to existing groups and make it optional (Tito) 184 <li>adduser: don't bomb out if shadow password file doesn't exist (from Tito <farmatito@tiscali.it>) 185 <li>applet.c: do not even try to read config if run by real root; fix suid config handling 186 <li>ash: fix infinite loop on exit if tty is not there anymore 187 <li>ash: fix kill -l (by Mats Erik Andersson <mats.andersson64@comhem.se>) 188 <li>ash: implement type -p, costs less than 10 bytes (patch by Mats Erik Andersson <mats.andersson64@comhem.se>) 189 <li>awk: don't segfault on printf(%*s). Closes bug 1337 190 <li>awk: guard against empty environment 191 <li>awk: some 'lineno' vars were shorts, made them ints (code got smaller) 192 <li>cat: stop using stdio.h opens 193 <li>config system: clarify PREFER_APPLETS/SH_STANDALONE effects in help text 194 <li>cryptpw: new applet (by Thomas Lundquist <lists@zelow.no>) 195 <li>cttyhack: new applet 196 <li>dd: NOEXEC fix; fix skip= parse error (spotted by Dirk Clemens <develop@cle-mens.de>) 197 <li>deluser: add optional support for removing users from groups (by Tito <farmatito@tiscali.it>) 198 <li>diff: fix SEGV (NULL deref) in diff -N 199 <li>diff: fix segfault on empty dirs (Peter Korsgaard <peter.korsgaard@barco.com>) 200 <li>dnsd: fix several buglets, make smaller; openlog(), so that applet's name is logged 201 <li>dpkg: run_package_script() returns 0 if all ok and non-zero if failure. The result code was checked incorrectly in two places. (from Kim B. Heino <Kim.Heino@bluegiga.com>) 202 <li>dpkg: use bitfields which are a bit closer to typical short/char. Code size -800 bytes 203 <li>dumpleases: getopt32()-ization (from Mats Erik Andersson <mats.andersson64@comhem.se>) 204 <li>e2fsprogs: stop using statics in chattr. Minor code shrinkage (-130 bytes) 205 <li>ether-wake: close bug 1317. Reorder fuctions to avoid forward refs while at it 206 <li>ether-wake: save a few more bytes of code 207 <li>find: -group, -depth (Natanael Copa <natanael.copa@gmail.com>) 208 <li>find: add support for -delete, -path (by Natanael Copa) 209 <li>find: fix -prune. Add big comment about it 210 <li>find: improve usage text (Natanael Copa <natanael.copa@gmail.com>) 211 <li>find: missed 'static' on const data; size and prune were mixed up; use index_in_str_array 212 <li>find: un-DESKTOPize (Kai Schwenzfeier <niteblade@gmx.net>) 213 <li>find_root_device: teach to deal with /dev/ subdirs (by Kirill K. Smirnov <lich@math.spbu.ru>) 214 <li>find_root_device: use lstat - don't follow links 215 <li>getopt32: fix llist_t options ordering. llist_rev is now unused 216 <li>getopt: use getopt32 for option parsing - inspired by patch by Mats Erik Andersson <mats.andersson64@comhem.se> 217 <li>hdparm: fix multisector mode setting (from Toni Mirabete <amirabete@catix.cat>) 218 <li>hdparm: make -T -t code smaller (-194 bytes), and output prettier 219 <li>ifupdown: make it possible to use DHCP clients different from udhcp 220 <li>ifupdown: reread state file before rewriting it. Fixes "ifup started another ifup" state corruption bug. Patch by Natanael Copa <natanael.copa@gmail.com> 221 <li>ifupdown: small optimization (avoid doing useless work if we are not going to update state file) 222 <li>ip: fix compilation if FEATURE_TR_CLASSES is off 223 <li>ip: mv ip*_main into ip.c; use a dispatcher to save on needless duplication. Saves a minor 12b 224 <li>ip: rewrite the ip applet to be less bloaty. Convert to index_in_(sub)str_array() 225 <li>ip: set the scope properly. Thanks to Jean Wolter 226 <li>iplink: shrink iplink; sanitize libiproute a bit (-916 bytes) 227 <li>iproute: shrink a bit (-200 bytes) 228 <li>kill: know much more signals; make code smaller; use common code for kill applet and ash kill builtin 229 <li>klogd: remove dependency on syslogd 230 <li>lash: "forking" applets are actually can be treated the same way as "non-forked". Also save a bit of space on trailing NULL array elements. 231 <li>lash: fix kill buglet (didn't properly recognize ESRCH) 232 <li>lash: make -c work; crush buffer overrun and free of non-malloced ptr (from Mats Erik Andersson <mats.andersson64@comhem.se>) 233 <li>lash: recognize and use NOFORK applets 234 <li>less: fix case when regex search finds nothing; fix very obscure memory corruption bug; fix less <HUGEFILE + [End] busy loop 235 <li>libbb: add xsendto, xunlink, xpipe 236 <li>libbb: fix segfault in reset_ino_dev_hashtable() when *hashtable was NULL 237 <li>libbb: make pidfile writing configurable 238 <li>libbb: make xsocket die with address family printed (if VERBOSE_RESOLUTION_ERRORS=y) 239 <li>libbb: rework NOMMU helper API so that it makes more sense and easier to use 240 <li>libiproute: audit callgraph, shortcut error paths into die() functions 241 <li>lineedit: do not try to open NULL history file 242 <li>lineedit: nuke two unused variables and code which sets them 243 <li>login: remove setpgrp call (makes it work from shell prompt again); sanitize stdio descriptors (we are suid, need to be careful!) 244 <li>login: shrink login and set_environment by ~100 bytes 245 <li>mount: fix incorrect usage of strtok (inadvertently used NULL sometimes) 246 <li>mount: fix mounting of symlinks (mount from util-linux allows that) 247 <li>msh: data/bss reduction (more than 9k of it); fix "underscore bug" (a_b=1111 didn't work); fix obscure case with backticks and closed fd 1 248 <li>nc: port nc 1.10 to busybox 249 <li>netstat: fix for bogus state value for raw sockets 250 <li>netstat: introduce -W: wide, ipv6-friendly output; shrink by ~500 bytes 251 <li>nmeter: should die if stdout doesn't like him anymore 252 <li>patch: do not try to delete same file twice 253 <li>ping: fix wrong sign extension of packet id (bug 1373) 254 <li>ps: add -o tty and -o rss support; make a bit smaller; work around libc bug: printf("%.*s\n", MAX_INT, buffer) 255 <li>run_parts: rewrite 256 <li>run_parts: do not check path portion of a name for "bad chars". Needed for ifupdown. Patch by Gabriel L. Somlo <somlo@cmu.edu> 257 <li>sed: fix escaped newlines in -f 258 <li>split: new applet 259 <li>stat: remove superfluous bss user (flags) and manually unswitch some areas 260 <li>stty: fix option parsing bug (spotted by Sascha Hauer <s.hauer@pengutronix.de>) 261 <li>svlogd: fix 'SEGV on uninitialized data' and make it honor TERM 262 <li>tail: fix SEGV on "tail -N" 263 <li>ipsvd: tcpsvd,udpsvd are new applets, GPL-ed 'clones' of Dan Bernstein's tcpserver. Author: Gerrit Pape <pape@smarden.org>, http://smarden.sunsite.dk/ipsvd/ 264 <li>test: close bug 1371; plug a memory leak; code size reduction 265 <li>tftp: code diet, and I think retransmits were broken 266 <li>tr: fix bug where we did not reject invalid classes like '[[:alpha'. debloat while at it 267 <li>udhcp: MAC_BCAST_ADDR and blank_chaddr are in fact constant, move to rodata; use pipe instead of socketpair 268 <li>udhcp[cd]: stop using atexit magic fir pidfile removal; stop deleting our own pidfile if we daemonize 269 <li>xargs: shrink code, ~80 bytes; simplify word list management 270 <li>zcip: make it work on NOMMU (+ improve NOMMU support machinery) 271 </ul> 272 </p> 273 </li> 274 275 <li><b>20 May 2007 -- BusyBox 1.5.1 (stable)</b> 276 <p><a href=http://busybox.net/downloads/busybox-1.5.1.tar.bz2>BusyBox 1.5.1</a>. 277 (<a href=http://busybox.net/downloads/fixes-1.5.1/>patches</a>, 278 <a href=http://busybox.net/fix.html>how to add a patch</a>)</p> 279 280 <p>This is a bugfix-only release, with fixes to hdparm, hush, ifupdown, ps 281 and sed.</p> 282 </li> 283 284 <li><b>23 March 2007 -- BusyBox 1.5.0 (unstable)</b> 285 <p><a href=http://busybox.net/downloads/busybox-1.5.0.tar.bz2>BusyBox 1.5.0</a>. 286 (<a href=http://busybox.net/downloads/fixes-1.5.0/>patches</a>, 287 <a href=http://busybox.net/fix.html>how to add a patch</a>)</p> 288 289 <p>Since this is a x.x.0 release, it probably does not deserve "stable" 290 label. Please help making 1.5.1 stable by testing 1.5.0.</p> 291 <p>Notable changes since previous release: 292 <ul> 293 <li>find: added support for -user, -not, fixed -mtime, -mmin, -perm 294 <li>[de]archivers: merge common logic into one module 295 <li>ping[6]: unified code for both 296 <li>less: regex search improved 297 <li>ash: more readable code, testsuite added 298 <li>sed: several very obscure bugs fixed 299 <li>chown: -H, -L, -P support (required by POSIX) 300 <li>tar: handle (broken) checksums a-la Sun; tar restores mode again 301 <li>grep: implement -w, "implement" -a and -I by ignoring them 302 <li>cp: more sane behavior when overwriting existing files 303 <li>init: stop doing silly things with the console (-400 bytes) 304 <li>httpd: make httpd usable for NOMMU CPUs; fix POSTDATA handling bugs 305 <li>httpd: run interpreter for configured file extensions in any dir, 306 not only in /cgi-bin/ 307 <li>chrt: new applet 308 <li>SELinux: SELinux-related code and -Z option added to several applets, 309 new SELinux-specific applets: chcon, runcon. 310 <li>Build system: produces link map, uses -Wwrite-strings to catch 311 improper usage of string constants. 312 <li>Data and bss section usage audited and reduced - should help NOMMU 313 targets. 314 <li>Applets with bug fixes: gunzip, vi, syslogd, dpkg, ls, adjtimex, resize, 315 sv, printf, diff, awk, sort, dpkg, diff, tftp 316 <li>Applets with usability improvements: swapon, more, ifup/ifdown, hwclock, 317 udhcpd, start_stop_daemon, cmp 318 <li>Applets with code cleaned up: telnet, fdisk, fsck_minix, mkfs_minix, 319 syslogd, swapon, runsv, svlogd, klogd 320 </ul> 321 </p> 322 </li> 323 324 <li><b>18 March 2007 -- BusyBox 1.4.2 (stable)</b> 325 <p><a href=http://busybox.net/downloads/busybox-1.4.2.tar.bz2>BusyBox 1.4.2</a>. 326 </p> 327 328 <p>This release includes only trivial fixes accumulated since 1.4.1. 329 </p> 330 </li> 331 332 <li><b>25 January 2007 -- BusyBox 1.4.1 (stable)</b> 333 <p><a href=http://busybox.net/downloads/busybox-1.4.1.tar.bz2>BusyBox 1.4.1</a>. 334 (<a href=http://busybox.net/downloads/fixes-1.4.1/>patches</a>)</p> 335 336 <p>This release includes only trivial fixes accumulated since 1.4.0. 337 </p> 338 </li> 339 340 <li><b>20 January 2007 -- BusyBox 1.4.0 (stable)</b> 341 <p><a href=http://busybox.net/downloads/busybox-1.4.0.tar.bz2>BusyBox 1.4.0</a>. 342 (<a href=http://busybox.net/downloads/fixes-1.4.0/>patches</a>)</p> 343 344 <p>Since this is a x.x.0 release, it probably is a bit less "stable" 345 than usual.</p> 346 <p>Changes since previous release: 347 <ul> 348 <li>e2fsprogs are mostly removed from busybox. Some smaller parts remain, 349 the rest of it sits disabled in e2fsprogs/old_e2fsprogs/*, because 350 it's too bloated. Really. I'm afraid it's about the only way we can 351 ever get e2fsprogs cleaned up. 352 <li>less: many improvements. Now can display binary files 353 (although I expect it to have trouble with displays where 8bit chars 354 don't have 1-to-1 char/glyph relationship). Regexp search is not buggy 355 anymore. Less does not read entire input up-front. Reads input 356 as it appears (yay!). Works rather nice as man pager. I recommend it 357 for general use now. 358 <li>IPv6: generic support is in place, many networking applets are 359 upgraded to be IPv6 capable. Probably some work remains, but it is 360 already much better than what we had previously. 361 <li>arp: new applet (thanks to Eric Spakman). 362 <li>fakeidentd: non-forking standalone server part was taking ~90% 363 of the applet. Factored it out (in fact, rewrote it). 364 <li>syslogd: mostly rewritten. 365 <li>decompress_unzip, gzip: sanitized a bit. 366 <li>sed: better hadling of NULs 367 <li>httpd: stop adding our own "Content-type:" to CGI output 368 <li>chown: user.grp works again. 369 <li>minor bugfixes to: passwd, date, tftp, start_stop_daemon, tar, 370 ps, ifupdown, time, su, stty, awk, ping[6], sort,... 371 </ul> 372 </p> 373 </li> 374 375 <li><b>20 January 2007 -- BusyBox 1.3.2 (stable)</b> 376 <p><a href=http://busybox.net/downloads/busybox-1.3.2.tar.bz2>BusyBox 1.3.2</a>.</p> 377 378 <p>This release includes only one trivial fix accumulated since 1.3.1 379 </p> 380 </li> 381 382 <li><b>27 December 2006 -- BusyBox 1.3.1 (stable)</b> 383 <p><a href=http://busybox.net/downloads/busybox-1.3.1.tar.bz2>BusyBox 1.3.1</a>. 384 (<a href=http://busybox.net/downloads/fixes-1.3.1/>patches</a>)</p> 385 386 <p>Closing 2006 with new release. It includes only trivial fixes accumulated since 1.3.0 387 </p> 388 </li> 389 390 <li><b>14 December 2006 -- BusyBox 1.3.0 (stable)</b> 391 <p><a href=http://busybox.net/downloads/busybox-1.3.0.tar.bz2>BusyBox 1.3.0</a>. 392 (<a href=http://busybox.net/downloads/fixes-1.3.0/>patches</a>)</p> 393 394 <p>This release has CONFIG_DESKTOP option which enables features 395 needed for busybox usage on desktop machine. For example, find, chmod 396 and chown get several less frequently used options, od is significantly 397 bigger but matches GNU coreutils, etc. Intended to eventually make 398 busybox a viable alternative for "standard" utilities for slightly 399 adventurous desktop users. 400 <p>Changes since previous release: 401 <ul> 402 <li>find: taking many more of standard options 403 <li>ps: POSIX-compliant -o implemented 404 <li>cp: added -s, -l 405 <li>grep: added -r, fixed -h 406 <li>watch: make it exec child like standard one does (was totally 407 incompatible) 408 <li>tar: fix limitations which were preventing bbox tar usage 409 on big directories: long names and linknames, pax headers 410 (Linux kernel tarballs have that). Fixed a number of obscure bugs. 411 Raised max file limit (now 64Gb). Security fixes (/../ attacks). 412 <li>httpd: added -i (inetd), -f (foreground), support for 413 directory indexer CGI (example is included), bugfixes. 414 <li>telnetd: fixed/improved IPv6 support, inetd+standalone support, 415 other fixes. Useful IPv6 stuff factored out into libbb. 416 <li>runit/*: new applets adapted from http://smarden.sunsite.dk/runit/ 417 (these are my personal favorite small-and-beautiful toys) 418 <li>minor bugfixes to: login, dd, mount, umount, chmod, chown, ln, udhcp, 419 fdisk, ifconfig, sort, tee, mkswap, wget, insmod. 420 </ul> 421 <p>Note that GnuPG key used to sign this release is different. 422 1.2.2.1 is also signed post-factum now. Sorry for the mess. 423 </p> 424 </li> 425 426 <li><b>29 October 2006 -- BusyBox 1.2.2.1 (fix)</b> 427 <p><a href=http://busybox.net/downloads/busybox-1.2.2.1.tar.bz2>BusyBox 1.2.2.1</a>.</p> 428 429 <p>Added compile-time warning that static linking against glibc 430 produces buggy executables. 431 </li> 432 433 <li><b>24 October 2006 -- BusyBox 1.2.2 (stable)</b> 434 <p>It's a bit overdue, but 435 <a href=http://busybox.net/downloads/busybox-1.2.2.tar.bz2>here is 436 BusyBox 1.2.2</a>.</p> 437 438 <p>This release has dozens of fixes backported from the ongoing development 439 branch. There are a couple of bugfixes to sed, two fixes to documentation 440 generation (BusyBox.html shouldn't have USE() macros in it anymore), fix 441 umount to report the right errno on failure and to umount block devices by 442 name with newer kernels, fix mount to handle symlinks properly, make mdev 443 delete device nodes when called for hotplug remove, fix a segfault 444 in traceroute, a minor portability fix to md5sum option parsing, a build 445 fix for httpd with old gccs, an options parsing tweak to hdparm, make test 446 fail gracefully when getgroups() returns -1, fix a race condition in 447 modprobe when two instances run at once (hotplug does this), make "tar xf 448 foo.tar dir/dir" extract all subdirectories, make our getty initialize the 449 terminal more like mingetty, an selinux build fix, an endianness fix in 450 ping6, fix for zcip defending addresses, clean up some global variables in 451 gzip to save memory, fix sulogin -tNNN, a help text tweak, several warning 452 fixes and build fixes, fixup dnsd a bit, and a partridge in a pear tree.</p> 453 454 <p>As <a href=http://lwn.net/Articles/202106/>Linux Weekly News noted</a>, 455 this is my (Rob's) last release of BusyBox. The new maintainer is Denis 456 Vlasenko, I'm off to do <a href=http://landley.net/code>other things</a>. 457 </p> 458 </li> 459 460 <li><b>29 September 2006 -- New license email address.</b> 461 <p>The email address gpl@busybox.net is now the recommended way to contact 462 the Software Freedom Law Center to report BusyBox license violations.</p> 463 464 <li><b>31 July 2006 -- BusyBox 1.2.1 (stable)</b> 465 <p>Since nobody seems to have objected too loudly over the weekend, I 466 might as well point you all at 467 <a href="http://busybox.net/downloads/busybox-1.2.1.tar.bz2">Busybox 468 1.2.1</a>, a bugfix-only release with no new features.</p> 469 470 <p>It has three shell fixes (two to lash: going "var=value" without 471 saying "export" should now work, plus a missing null pointer check, and 472 one to ash when redirecting output to a file that fills up.) Fix three 473 embarassing thinkos in the new dmesg command. Two build tweaks 474 (dependencies for the compressed usage messages and running make in the 475 libbb subdirectory). One fix to tar so it can extract git-generated 476 tarballs (rather than barfing on the pax extensions). And a partridge 477 in a pear... Ahem.</p> 478 479 <p>But wait, there's more! A passwd changing fix so an empty 480 gecos field doesn't trigger a false objection that the new passwd contains 481 the gecos field. Make all our setuid() and setgid() calls check the return 482 value in case somebody's using per-process resource limits that prevent 483 a user from having too many processes (and thus prevent a process from 484 switching away from root, in which case the process will now _die_ rather 485 than continue with root privileges). A fix to adduser to make sure that 486 /etc/group gets updated. And a fix to modprobe to look for modules.conf 487 in the right place on 2.6 kernels.</p> 488 5 489 <li><b>30 June 2006 -- BusyBox 1.2.0</b> 6 490 <p>The -devel branch has been stabilized and the result is … … 13 497 try a longer one. Expect 1.3.0 in December. (Expect 1.2.1 any time 14 498 we fix enough bugs. :)</p> 499 500 <p>Update: Here are <a href="http://busybox.net/downloads/busybox-1.2.0.fixes.patch">the first few bug fixes</a> that will go into 1.2.1.</p> 15 501 16 502 <li><b>17 May 2006 -- BusyBox 1.1.3 (stable)</b> … … 36 522 to have a 1.x.0 new development release every 3 months, with 1.x.y stable 37 523 bugfix only releases based on that as appropriate.)</p> 38 524 39 525 <li><b>27 March 2006 -- Software Freedom Law Center representing BusyBox and uClibc</b> 40 526 <p>One issue Erik Andersen wanted to resolve when handing off BusyBox -
branches/2.2.5/mindi-busybox/docs/busybox.net/oldnews.html
r821 r1765 5 5 <li><b>31 October 2005 -- 1.1.0-pre1</b> 6 6 <p>The development branch of busybox is stable enough for wider testing, so 7 you can now 7 you can now 8 8 <a href="http://www.busybox.net/downloads/busybox-1.1.0-pre1.tar.bz2">download</a>, 9 9 the first prerelease of 1.1.0. This prerelease includes a lot of … … 28 28 in their brains at a time. In my case, I'm lucky if I can remember my own 29 29 name, much less a bug report posted last week... To prevent your bug report 30 from getting lost, if you find a bug in BusyBox, please use the 30 from getting lost, if you find a bug in BusyBox, please use the 31 31 <a href="http://bugs.busybox.net/">shiny new Bug and Patch Tracking System</a> 32 32 to post all the gory details. … … 857 857 <pre> 858 858 mount ./busybox.floppy.img /mnt -o loop -t msdos 859 cp /mnt/initrd.gz /tmp 859 cp /mnt/initrd.gz /tmp 860 860 umount /mnt 861 861 gunzip /tmp/initrd.gz -
branches/2.2.5/mindi-busybox/docs/busybox.net/products.html
r821 r1765 13 13 <ul> 14 14 15 <li><a href="http://buildroot.uclibc.org/">buildroot</a><br>A configurable 16 means for building your own busybox/uClibc based system systems, maintained 17 by the uClibc developers. 15 18 16 <li><a href="http:// buildroot.uclibc.org/">buildroot</a><br>A configurable17 means for building your own busybox/uClibc based system systems.19 <li><a href="http://openwrt.org">OpenWrt</a> a Linux distribution for embedded 20 devices, based on buildroot. 18 21 19 22 <li><a href="http://www.pengutronix.de/software/ptxdist_en.html">PTXdist</a><br>another … … 156 159 with source <a href="http://now-portal.c-lab.de/projects/gigaset/">here, I think...</a> 157 160 with some details <a href="http://heinz.hippenstiel.org/familie/hp/hobby/gigaset_se515dsl.html">here.</a> 158 </li><li><a href="http://fr wt.stim.ru/">Free Remote Windows Terminal</a>159 161 </li><li><a href="http://freeterm.spb.ru/frwt/">Free Remote Windows Terminal</a> 162 160 163 </li><li><a href="http://www.zyxel.com/">ZyXEL Routers</a> 161 164 -
branches/2.2.5/mindi-busybox/docs/busybox.net/screenshot.html
r821 r1765 12 12 font-family: monospace; font-size: smaller;" width="100"> 13 13 14 15 14 $ ./busybox 16 BusyBox v1. 1.2 (2006.04.11-08:27+0000) multi-call binary15 BusyBox v1.6.0.svn (2007-04-07 04:27:00 CEST) multi-call binary 17 16 18 17 Usage: busybox [function] [arguments]... 19 18 or: [function] [arguments]... 20 19 21 22 23 24 20 BusyBox is a multi-call binary that combines many common Unix 21 utilities into a single executable. Most people will create a 22 link to busybox for each function they wish to use and BusyBox 23 will act like whatever it was invoked as! 25 24 26 25 Currently defined functions: 27 [, [[, addgroup, adduser, adjtimex, ar, arping, ash, awk, basename, 28 bbconfig, bunzip2, busybox, bzcat, cal, cat, chattr, chgrp, chmod, 29 chown, chroot, chvt, clear, cmp, comm, cp, cpio, crond, crontab, 30 cut, date, dc, dd, deallocvt, delgroup, deluser, devfsd, df, dirname, 31 dmesg, dnsd, dos2unix, dpkg, dpkg-deb, du, dumpkmap, dumpleases, 32 e2fsck, e2label, echo, egrep, eject, env, ether-wake, expr, fakeidentd, 33 false, fbset, fdflush, fdformat, fdisk, fgrep, find, findfs, fold, 34 free, freeramdisk, fsck, fsck.ext2, fsck.ext3, fsck.minix, ftpget, 35 ftpput, fuser, getopt, getty, grep, gunzip, gzip, halt, hdparm, 36 head, hexdump, hostid, hostname, httpd, hush, hwclock, id, ifconfig, 37 ifdown, ifup, inetd, init, insmod, install, ip, ipaddr, ipcalc, 38 ipcrm, ipcs, iplink, iproute, iptunnel, kill, killall, klogd, 39 lash, last, length, less, linux32, linux64, linuxrc, ln, loadfont, 40 loadkmap, logger, login, logname, logread, losetup, ls, lsattr, 41 lsmod, lzmacat, makedevs, md5sum, mdev, mesg, mkdir, mke2fs, mkfifo, 42 mkfs.ext2, mkfs.ext3, mkfs.minix, mknod, mkswap, mktemp, modprobe, 43 more, mount, mountpoint, msh, mt, mv, nameif, nc, netstat, nice, 44 nohup, nslookup, od, openvt, passwd, patch, pidof, ping, ping6, 45 pipe_progress, pivot_root, poweroff, printenv, printf, ps, pwd, 46 rdate, readlink, readprofile, realpath, reboot, renice, reset, 47 rm, rmdir, rmmod, route, rpm, rpm2cpio, run-parts, runlevel, rx, 48 sed, seq, setarch, setconsole, setkeycodes, setsid, sha1sum, sleep, 49 sort, start-stop-daemon, stat, strings, stty, su, sulogin, sum, 50 swapoff, swapon, switch_root, sync, sysctl, syslogd, tail, tar, 51 tee, telnet, telnetd, test, tftp, time, top, touch, tr, traceroute, 52 true, tty, tune2fs, udhcpc, udhcpd, umount, uname, uncompress, 53 uniq, unix2dos, unlzma, unzip, uptime, usleep, uudecode, uuencode, 54 vconfig, vi, vlock, watch, watchdog, wc, wget, which, who, whoami, 55 xargs, yes, zcat, zcip 26 [, [[, addgroup, adduser, adjtimex, ar, arp, arping, ash, 27 awk, basename, bunzip2, bzcat, cal, cat, catv, chattr, 28 chgrp, chmod, chown, chpst, chroot, chvt, cksum, clear, 29 cmp, comm, cp, cpio, crond, crontab, cut, date, dc, dd, 30 deallocvt, delgroup, deluser, df, dhcprelay, diff, dirname, 31 dmesg, dnsd, dos2unix, dpkg, dpkg-deb, du, dumpkmap, dumpleases, 32 echo, ed, egrep, eject, env, envdir, envuidgid, expr, 33 fakeidentd, false, fbset, fdflush, fdformat, fdisk, fgrep, 34 find, fold, free, freeramdisk, fsck, fsck.minix, ftpget, 35 ftpput, fuser, getopt, getty, grep, gunzip, gzip, halt, 36 hdparm, head, hexdump, hostid, hostname, httpd, hwclock, 37 id, ifconfig, ifdown, ifup, inetd, init, insmod, install, 38 ip, ipaddr, ipcalc, ipcrm, ipcs, iplink, iproute, iprule, 39 iptunnel, kill, killall, killall5, klogd, lash, last, 40 length, less, linux32, linux64, linuxrc, ln, loadfont, 41 loadkmap, logger, login, logname, logread, losetup, ls, 42 lsattr, lsmod, lzmacat, makedevs, md5sum, mdev, mesg, 43 mkdir, mkfifo, mkfs.minix, mknod, mkswap, mktemp, modprobe, 44 more, mount, mountpoint, msh, mt, mv, nameif, nc, netstat, 45 nice, nmeter, nohup, nslookup, od, openvt, passwd, patch, 46 pidof, ping, ping6, pipe_progress, pivot_root, poweroff, 47 printenv, printf, ps, pwd, raidautorun, rdate, readahead, 48 readlink, readprofile, realpath, reboot, renice, reset, 49 resize, rm, rmdir, rmmod, route, rpm, rpm2cpio, run-parts, 50 runlevel, runsv, runsvdir, rx, sed, seq, setarch, setconsole, 51 setkeycodes, setlogcons, setsid, setuidgid, sha1sum, sleep, 52 softlimit, sort, split, start-stop-daemon, stat, strings, 53 stty, su, sulogin, sum, sv, svlogd, swapoff, swapon, switch_root, 54 sync, sysctl, syslogd, tail, tar, tcpsvd, tee, telnet, 55 telnetd, test, tftp, time, top, touch, traceroute, true, 56 tty, udhcpc, udhcpd, udpsvd, umount, uname, uncompress, 57 uniq, unix2dos, unlzma, unzip, uptime, usleep, uudecode, 58 uuencode, vconfig, vi, vlock, watch, watchdog, wc, wget, 59 which, who, whoami, xargs, yes, zcat, zcip 56 60 57 61 $ <span style="text-decoration:blink;">_</span> … … 60 64 61 65 <!--#include file="footer.html" --> 62 -
branches/2.2.5/mindi-busybox/docs/busybox.net/shame.html
r821 r1765 72 72 </li><li><a href="http://www.a-link.com/RR64AP.html">Avaks alink Roadrunner 64</a> 73 73 <br> Partial source available, based on source distributed under NDA from <a href="http://www.lsilogic.com/products/dsl_platform_solutions/hb_linuxr2_2.html"> LSILogic</a>. Why the NDA LSILogic, what are you hiding ? 74 <br>To verify the Avaks infrigment see my slashdot <a href="http://slashdot.org/~bug1/journal/">journal</a>. 74 <br>To verify the Avaks infrigment see my slashdot <a href="http://slashdot.org/~bug1/journal/">journal</a>. 75 75 <br>The ZipIt wireless IM device appears to be using Busybox-1.00-pre1 in the ramdisk, however no source has been made available. 76 76 </li><li>Undoubtedly there are others... Please report them so we can shame them (or if necessary sue them) into compliance. -
branches/2.2.5/mindi-busybox/docs/busybox.net/sponsors.html
r821 r1765 9 9 10 10 <ul> 11 <li><a href="http://osuosl.org/">OSU OSL</a><br> 12 OSU OSL kindly provides hosting for BusyBox and uClibc. 13 </li> 14 11 15 <li><a href="http://www.penguru.net">Penguru Consulting</a><br> 12 16 Custom development for embedded Linux systems and multimedia platforms -
branches/2.2.5/mindi-busybox/docs/busybox.net/tinyutils.html
r821 r1765 4 4 <h3>External Tiny Utilities</h3> 5 5 6 This is a list of tiny utilities whose functionality is not provided by 7 busybox. If you have additional suggestions, please send an e-mail to our 6 This is a list of tiny utilities whose functionality is not provided by 7 busybox. If you have additional suggestions, please send an e-mail to our 8 8 dev mailing list. 9 9 10 10 <br><br> 11 11 12 <table >12 <table border=1> 13 13 <tr> 14 14 <th>Feature</th> … … 18 18 <tr> 19 19 <td>SSH</td> 20 <td><a href="http://matt.ucc.asn.au/dropbear/">Dropbear</a> has both an ssh server and an ssh client.</td> 20 <td><a href="http://matt.ucc.asn.au/dropbear/">Dropbear</a> has both an ssh server and an ssh client that together come in around 100k. It has no external 21 dependencies (I.E. it does not depend on OpenSSL, using a built-in copy of 22 LibTomCrypt instead). It's actively maintained, with a quiet but responsive 23 mailing list.</td> 21 24 </tr> 22 25 23 26 <tr> 24 27 <td>SMTP</td> 25 <td><a href="ftp://ftp.debian.org/debian/pool/main/s/ssmtp/">ssmtp</a> is an extremely simple M TA.</td>28 <td><a href="ftp://ftp.debian.org/debian/pool/main/s/ssmtp/">ssmtp</a> is an extremely simple Mail Transfer Agent.</td> 26 29 </tr> 27 30 31 <tr> 32 <td>ntp</td> 33 <td><a href="http://doolittle.icarus.com/ntpclient/">ntpclient</a> is a 34 tiny ntp client. BusyBox has rdate to set the date from a remote server, but 35 if you want a daemon to repeatedly adjust the clock over time, try that.</td> 28 36 </table> 29 37 … … 34 42 version of links</a>.</p> 35 43 44 <h3>SCRIPTING LANGUAGES</h3> 45 <p>Although busybox has built-in support for shell scripts, plenty of other 46 small scripting languages are available on the net. A few examples:</p> 47 <table border=1> 48 <tr> 49 <th><language></th> 50 <th><description></th> 51 </tr> 52 <tr> 53 <td> <a href=http://www.foo.be/docs/tpj/issues/vol5_3/tpj0503-0003.html>microperl</a> </td> 54 <td> A small standalone perl interpreter that can be built from the perl source 55 s via "make -f Makefile.micro". If you really feel the need for perl on an embe 56 dded system, this is where to start. 57 </tr> 58 <tr> 59 60 <td><a href=http://www.lua.org/pil/>Lua</a></td> 61 <td>If you just want a small embedded scripting language to write <em>new</en> 62 code in, this Brazilian import is lightweight, fairly popular, and has 63 a complete book about it online.</td> 64 </tr> 65 66 <tr> 67 <td><a href= http://www.star.le.ac.uk/%7Etjg/rc/>rc</a></td> 68 <td>The PLAN9 shell. Not compatible with conventional bourne shell syntax, 69 but fairly lightweight and small.</td> 70 </tr> 71 72 </tr> 73 <tr> 74 <td><a href=http://www.forth.org>forth</a></td> 75 <td>A well known language for fast and small programs, decades old but still 76 in use for everything from OpenBIOS to computer controlled engine timing.</td> 77 </tr> 78 </table> 79 80 <p>For more information, you probably want to look at 81 <a href=http://buildroot.uclibc.org>buildroot</a> and 82 <a href=http://gentoo-wiki.com/TinyGentoo>TinyGentoo</a>, which 83 build and use tiny utilities for all sorts of things.</p> 84 36 85 <!--#include file="footer.html" --> 37 86 -
branches/2.2.5/mindi-busybox/docs/busybox_footer.pod
r821 r1765 26 26 =head1 MAINTAINER 27 27 28 Rob Landley <rob@landley.net>28 Denis Vlasenko <vda.linux@googlemail.com> 29 29 30 30 =head1 AUTHORS … … 255 255 =cut 256 256 257 # $Id: busybox_footer.pod,v 1.18 2004/04/25 06:05:14 bug1 Exp $258 -
branches/2.2.5/mindi-busybox/docs/busybox_header.pod
r821 r1765 34 34 After the compile has finished, you should use 'make install' to install 35 35 BusyBox. This will install the 'bin/busybox' binary, in the target directory 36 specified by PREFIX. PREFIX can be set when configuring BusyBox, or you can37 specify an alternative location at install time (i.e., with a command line 38 like 'make PREFIX=/tmp/foo install'). If you enabled any applet installation 39 scheme (either as symlinks or hardlinks), these will also be installed in 40 the location pointed to byPREFIX.36 specified by CONFIG_PREFIX. CONFIG_PREFIX can be set when configuring BusyBox, 37 or you can specify an alternative location at install time (i.e., with a 38 command line like 'make CONFIG_PREFIX=/tmp/foo install'). If you enabled 39 any applet installation scheme (either as symlinks or hardlinks), these will 40 also be installed in the location pointed to by CONFIG_PREFIX. 41 41 42 42 =head1 USAGE -
branches/2.2.5/mindi-busybox/docs/new-applet-HOWTO.txt
r821 r1765 7 7 Matt Kraai - initial writeup 8 8 Mark Whitley - the remix 9 Thomas Lundquist - Added stuff for the new directory layout. 9 Thomas Lundquist - Trying to keep it updated. 10 11 When doing this you should consider using the latest svn trunk. 12 This is a good thing if you plan to getting it commited into mainline. 10 13 11 14 Initial Write … … 17 20 And be sure to put it in <applet>.c. Usage does not have to be taken care of by 18 21 your applet. 19 Make sure to #include " busybox.h" as the first include file in your applet so22 Make sure to #include "libbb.h" as the first include file in your applet so 20 23 the bb_config.h and appropriate platform specific files are included properly. 21 24 22 25 For a new applet mu, here is the code that would go in mu.c: 26 27 (busybox.h already includes most usual header files. You do not need 28 #include <stdio.h> etc...) 29 23 30 24 31 ----begin example code------ … … 33 40 */ 34 41 35 #include " busybox.h"36 #include <other.h>42 #include "libbb.h" 43 #include "other.h" 37 44 45 int mu_main(int argc, char **argv); 38 46 int mu_main(int argc, char **argv) 39 47 { … … 41 49 char mu; 42 50 43 fd = bb_xopen("/dev/random", O_RDONLY);51 fd = xopen("/dev/random", O_RDONLY); 44 52 45 53 if ((n = safe_read(fd, &mu, 1)) < 1) … … 69 77 applet that could be useful in other applets, consider putting them in libbb. 70 78 79 And it may be possible that some of the other applets uses functions you 80 could use. If so, you have to rip the function out of the applet and make 81 a libbb function out of it. 82 83 Adding a libbb function: 84 ------------------------ 85 86 Make a new file named <function_name>.c 87 88 ----start example code------ 89 90 #include "libbb.h" 91 #include "other.h" 92 93 int function(char *a) 94 { 95 return *a; 96 } 97 98 ----end example code------ 99 100 Add <function_name>.o in the right alphabetically sorted place 101 in libbb/Kbuild. You should look at the conditional part of 102 libbb/Kbuild aswell. 103 104 You should also try to find a suitable place in include/libbb.h for 105 the function declaration. If not, add it somewhere anyway, with or without 106 ifdefs to include or not. 107 108 You can look at libbb/Config.in and try to find out if the function is 109 tuneable and add it there if it is. 110 71 111 72 112 Placement / Directory … … 78 118 sorted alphabetically. 79 119 80 Add the applet to Makefile.inin the chosen directory:120 Add the applet to Kbuild in the chosen directory: 81 121 82 obj-$(CONFIG_MU) += mu.o122 lib-$(CONFIG_MU) += mu.o 83 123 84 124 Add the applet to Config.in in the chosen directory: … … 119 159 algorithm in busybox.c and the Gods of BusyBox smite you. Yea, verily: 120 160 161 Be sure to read the top of applets.h before adding your applet. 162 121 163 /* all programs above here are alphabetically "less than" 'mu' */ 122 #ifdef CONFIG_MU 123 APPLET("mu", mu_main, _BB_DIR_USR_BIN, mu_usage) 124 #endif 164 USE_MU(APPLET(mu, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) 125 165 /* all programs below here are alphabetically "greater than" 'mu' */ 126 127 128 Documentation129 -------------130 131 If you're feeling especially nice, you should also document your applet in the132 docs directory (but nobody ever does that).133 134 Adding some text to docs/Configure.help is a nice start.135 166 136 167 … … 138 169 ---------------------- 139 170 140 Then create a diff -urN of the files you added and/or modified. Typically:141 <appletdir>/<applet>.c142 include/usage.c 143 include/applets.h144 <appletdir>/Makefile.in145 <appletdir>/config.in171 Then create a diff by adding the new files with svn (remember your libbb files) 172 svn add <where you put it>/mu.c 173 eventually also: 174 svn add libbb/function.c 175 then 176 svn diff 146 177 and send it to the mailing list: 147 178 busybox@busybox.net -
branches/2.2.5/mindi-busybox/docs/style-guide.txt
r821 r1765 21 21 ----------------- 22 22 23 Here is the order in which code should be laid out in a file:23 Here is the preferred order in which code should be laid out in a file: 24 24 25 25 - commented program name and one-line description … … 52 52 multi-line comments that use an asterisk at the beginning of each line, i.e.: 53 53 54 /t/*55 /t * This is a block comment.56 /t * Note that it has multiple lines57 /t * and that the beginning of each line has a tab plus a space58 /t * except for the opening '/*' line where the slash59 /t * is used instead of a space.60 /t */54 \t/* 55 \t * This is a block comment. 56 \t * Note that it has multiple lines 57 \t * and that the beginning of each line has a tab plus a space 58 \t * except for the opening '/*' line where the slash 59 \t * is used instead of a space. 60 \t */ 61 61 62 62 Furthermore, The preference is that tabs be set to display at four spaces … … 127 127 do { 128 128 129 Exceptions: 130 131 - if you have long logic statements that need to be wrapped, then uncuddling 132 the bracket to improve readability is allowed: 133 134 if (some_really_long_checks && some_other_really_long_checks \ 135 && some_more_really_long_checks) 136 { 129 If you have long logic statements that need to be wrapped, then uncuddling 130 the bracket to improve readability is allowed. Generally, this style makes 131 it easier for reader to notice that 2nd and following lines are still 132 inside 'if': 133 134 if (some_really_long_checks && some_other_really_long_checks 135 && some_more_really_long_checks 136 && even_more_of_long_checks 137 ) { 137 138 do_foo_now; 138 139 … … 209 210 210 211 212 Labels 213 ~~~~~~ 214 215 Labels should start at the beginning of the line, not indented to the block 216 level (because they do not "belong" to block scope, only to whole function). 217 218 if (foo) { 219 stmt; 220 label: 221 stmt2; 222 stmt; 223 } 224 225 (Putting label at position 1 prevents diff -p from confusing label for function 226 name, but it's not a policy of busybox project to enforce such a minor detail). 227 228 211 229 212 230 Variable and Function Names … … 235 253 236 254 - Enums, macros, and constant variables are occasionally written in all 237 upper-case with words optionally seperatedy by underscores (i.e. FIFO TYPE,255 upper-case with words optionally seperatedy by underscores (i.e. FIFO_TYPE, 238 256 ISBLKDEV()). 239 257 … … 300 318 Don't do this: 301 319 302 #define var80320 #define CONST 80 303 321 304 322 Do this instead, when the variable is in a header file and will be used in 305 323 several source files: 306 324 307 const int var = 80; 308 309 Or do this when the variable is used only in a single source file: 310 311 static const int var = 80; 312 313 Declaring variables as '[static] const' gives variables an actual type and 314 makes the compiler do type checking for you; the preprocessor does _no_ type 315 checking whatsoever, making it much more error prone. Declaring variables with 316 '[static] const' also makes debugging programs much easier since the value of 317 the variable can be easily queried and displayed. 325 enum { CONST = 80 }; 326 327 Although enum may look ugly to some people, it is better for code size. 328 With "const int" compiler may fail to optimize it out and will reserve 329 a real storage in rodata for it! (Hopefully, newer gcc will get better 330 at it...). With "define", you have slight risk of polluting namespace 331 (#define doesn't allow you to redefine the name in the inner scopes), 332 and complex "define" are evaluated each time they uesd, not once 333 at declarations like enums. Also, the preprocessor does _no_ type checking 334 whatsoever, making it much more error prone. 318 335 319 336 … … 361 378 (in .h header file) 362 379 363 #if def CONFIG_FEATURE_FUNKY364 static inline void maybe_do_funky_stuff 380 #if ENABLE_FEATURE_FUNKY 381 static inline void maybe_do_funky_stuff(int bar, int baz) 365 382 { 366 383 /* lotsa code in here */ 367 384 } 368 385 #else 369 static inline void maybe_do_funky_stuff 386 static inline void maybe_do_funky_stuff(int bar, int baz) {} 370 387 #endif 371 388 … … 433 450 of some of the more notorious troublemakers: 434 451 435 function overflows preferred 436 ---------------------------------------- 437 strcpy dest string strncpy 438 strcat dest string strncat 439 gets string it gets fgets 440 getwd buf string getcwd 441 [v]sprintf str buffer [v]snprintf 442 realpath path buffer use with pathconf 443 [vf]scanf its arguments just avoid it 452 function overflows preferred 453 ------------------------------------------------- 454 strcpy dest string safe_strncpy 455 strncpy may fail to 0-terminate dst safe_strncpy 456 strcat dest string strncat 457 gets string it gets fgets 458 getwd buf string getcwd 459 [v]sprintf str buffer [v]snprintf 460 realpath path buffer use with pathconf 461 [vf]scanf its arguments just avoid it 444 462 445 463 … … 451 469 ------------------------ 452 470 453 First, some background to put this discussion in context: Static buffers look471 First, some background to put this discussion in context: static buffers look 454 472 like this in code: 455 473 … … 501 519 and the right thing will happen, based on your configuration. 502 520 521 Another relatively new trick of similar nature is explained 522 in keep_data_small.txt. 523 503 524 504 525 … … 528 549 - The difference is minor or cosmetic 529 550 530 A note on the 'cosmetic' case: Output differences might be considered551 A note on the 'cosmetic' case: output differences might be considered 531 552 cosmetic, but if the output is significant enough to break other scripts that 532 553 use the output, it should really be fixed. … … 578 599 stmt1; 579 600 new_line(); 580 stmt2 601 stmt2; 581 602 stmt3; 582 603 … … 620 641 Furthermore, you should put a single comment (not necessarily one line, just 621 642 one comment) before the block, rather than commenting each and every line. 622 There is an optimal am mount of commenting that a program can have; you can643 There is an optimal amount of commenting that a program can have; you can 623 644 comment too much as well as too little. 624 645 … … 626 647 illustrates how to emphasize logical blocks: 627 648 628 while (line = get_line_from_file(fp)) {649 while (line = xmalloc_fgets(fp)) { 629 650 630 651 /* eat the newline, if any */ … … 650 671 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 651 672 652 If your applet needs to process command-line switches, please use getopt() to673 If your applet needs to process command-line switches, please use getopt32() to 653 674 do so. Numerous examples can be seen in many of the existing applets, but 654 675 basically it boils down to two things: at the top of the .c file, have this 655 line in the midst of your #includes :676 line in the midst of your #includes, if you need to parse long options: 656 677 657 678 #include <getopt.h> 679 680 Then have long options defined: 681 682 static const struct option <applet>_long_options[] = { 683 { "list", 0, NULL, 't' }, 684 { "extract", 0, NULL, 'x' }, 685 { NULL, 0, NULL, 0 } 686 }; 658 687 659 688 And a code block similar to the following near the top of your applet_main() 660 689 routine: 661 690 662 while ((opt = getopt(argc, argv, "abc")) > 0) { 663 switch (opt) { 664 case 'a': 665 do_a_opt = 1; 666 break; 667 case 'b': 668 do_b_opt = 1; 669 break; 670 case 'c': 671 do_c_opt = 1; 672 break; 673 default: 674 show_usage(); /* in utility.c */ 675 } 676 } 691 char *str_b; 692 693 opt_complementary = "cryptic_string"; 694 applet_long_options = <applet>_long_options; /* if you have them */ 695 opt = getopt32(argc, argv, "ab:c", &str_b); 696 if (opt & 1) { 697 handle_option_a(); 698 } 699 if (opt & 2) { 700 handle_option_b(str_b); 701 } 702 if (opt & 4) { 703 handle_option_c(); 704 } 677 705 678 706 If your applet takes no options (such as 'init'), there should be a line … … 684 712 use getopt, they won't get false positives. 685 713 686 Additional Note: Do not use the getopt_long library function and do not try to 687 hand-roll your own long option parsing. Busybox applets should only support 688 short options. Explanations and examples of the short options should be 689 documented in usage.h. 714 For more info and examples, examine getopt32.c, tar.c, wget.c etc.
Note:
See TracChangeset
for help on using the changeset viewer.