aboutsummaryrefslogtreecommitdiff
path: root/docs/new-applet-HOWTO.txt
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2005-09-02 23:06:30 +0000
committerMike Frysinger <vapier@gentoo.org>2005-09-02 23:06:30 +0000
commit9754b91c16288fd0f4d6301fd6d01aa8b3c3b1d9 (patch)
treed59686d3aceca098b3010cc59b08d269efe7189e /docs/new-applet-HOWTO.txt
parentf46f1b4d8a6effe99975aa6960bb865511712cab (diff)
downloadbusybox-w32-9754b91c16288fd0f4d6301fd6d01aa8b3c3b1d9.tar.gz
busybox-w32-9754b91c16288fd0f4d6301fd6d01aa8b3c3b1d9.tar.bz2
busybox-w32-9754b91c16288fd0f4d6301fd6d01aa8b3c3b1d9.zip
touchup some grammar, formatting, and remove some outdated notes
Diffstat (limited to 'docs/new-applet-HOWTO.txt')
-rw-r--r--docs/new-applet-HOWTO.txt29
1 files changed, 17 insertions, 12 deletions
diff --git a/docs/new-applet-HOWTO.txt b/docs/new-applet-HOWTO.txt
index 605974c3a..24bc1d824 100644
--- a/docs/new-applet-HOWTO.txt
+++ b/docs/new-applet-HOWTO.txt
@@ -11,10 +11,11 @@ Thomas Lundquist - Added stuff for the new directory layout.
11Initial Write 11Initial Write
12------------- 12-------------
13 13
14First, write your applet. Be sure to include copyright information at the 14First, write your applet. Be sure to include copyright information at the top,
15top, such as who you stole the code from and so forth. Also include the 15such as who you stole the code from and so forth. Also include the mini-GPL
16mini-GPL boilerplate. Be sure to name the main function <applet>_main instead 16boilerplate. Be sure to name the main function <applet>_main instead of main.
17of main. And be sure to put it in <applet>.c. Usage do not have to be taken care of by your applet. 17And be sure to put it in <applet>.c. Usage does not have to be taken care of by
18your applet.
18 19
19For a new applet mu, here is the code that would go in mu.c: 20For a new applet mu, here is the code that would go in mu.c:
20 21
@@ -78,8 +79,7 @@ As you are writing your applet, please be aware of the body of pre-existing
78useful functions in libbb. Use these instead of reinventing the wheel. 79useful functions in libbb. Use these instead of reinventing the wheel.
79 80
80Additionally, if you have any useful, general-purpose functions in your 81Additionally, if you have any useful, general-purpose functions in your
81program that could be useful in another program, consider putting them in 82applet that could be useful in other applets, consider putting them in libbb.
82libbb.
83 83
84 84
85Placement / Directory 85Placement / Directory
@@ -90,11 +90,11 @@ Find the appropriate directory for your new applet.
90Make sure you find the appropriate places in the files, the applets are 90Make sure you find the appropriate places in the files, the applets are
91sorted alphabetically. 91sorted alphabetically.
92 92
93Add the applet to Makefile.in in the chosen applet directory: 93Add the applet to Makefile.in in the chosen directory:
94 94
95obj-$(CONFIG_MU) += mu.o 95obj-$(CONFIG_MU) += mu.o
96 96
97Add the applet to Config.in in the chosen applet directory: 97Add the applet to Config.in in the chosen directory:
98 98
99config CONFIG_MU 99config CONFIG_MU
100 bool "MU" 100 bool "MU"
@@ -116,6 +116,7 @@ This should look like the following:
116 "Options:\n" \ 116 "Options:\n" \
117 "\t-a\t\tfirst function\n" \ 117 "\t-a\t\tfirst function\n" \
118 "\t-b\t\tsecond function\n" \ 118 "\t-b\t\tsecond function\n" \
119 ...
119 120
120If your program supports flags, the flags should be mentioned on the first 121If your program supports flags, the flags should be mentioned on the first
121line (-[abcde]) and a detailed description of each flag should go in the 122line (-[abcde]) and a detailed description of each flag should go in the
@@ -149,10 +150,14 @@ Adding some text to docs/Configure.help is a nice start.
149The Grand Announcement 150The Grand Announcement
150---------------------- 151----------------------
151 152
152Then create a diff -urN of the files you added (<appletdir/><applet>.c, 153Then create a diff -urN of the files you added and/or modified. Typically:
153include/usage.c, include/applets.h, include/config.h, <appletdir>/Makefile.in, <appletdir>/config.in) 154 <appletdir>/<applet>.c
155 include/usage.c
156 include/applets.h
157 <appletdir>/Makefile.in
158 <appletdir>/config.in
154and send it to the mailing list: 159and send it to the mailing list:
155busybox@busybox.net. 160 busybox@busybox.net
161 http://busybox.net/mailman/listinfo/busybox
156 162
157Sending patches as attachments is preferred, but not required. 163Sending patches as attachments is preferred, but not required.
158