diff options
Diffstat (limited to 'procps')
-rw-r--r-- | procps/Config.src | 4 | ||||
-rw-r--r-- | procps/free.c | 8 | ||||
-rw-r--r-- | procps/fuser.c | 8 | ||||
-rw-r--r-- | procps/iostat.c | 4 | ||||
-rw-r--r-- | procps/kill.c | 26 | ||||
-rw-r--r-- | procps/lsof.c | 6 | ||||
-rw-r--r-- | procps/mpstat.c | 4 | ||||
-rw-r--r-- | procps/nmeter.c | 4 | ||||
-rw-r--r-- | procps/pgrep.c | 55 | ||||
-rw-r--r-- | procps/pidof.c | 14 | ||||
-rw-r--r-- | procps/pmap.c | 8 | ||||
-rw-r--r-- | procps/powertop.c | 8 | ||||
-rw-r--r-- | procps/ps.c | 18 | ||||
-rw-r--r-- | procps/pstree.c | 4 | ||||
-rw-r--r-- | procps/pwdx.c | 4 | ||||
-rw-r--r-- | procps/smemcap.c | 6 | ||||
-rw-r--r-- | procps/sysctl.c | 4 | ||||
-rw-r--r-- | procps/top.c | 32 | ||||
-rw-r--r-- | procps/uptime.c | 10 | ||||
-rw-r--r-- | procps/watch.c | 6 |
20 files changed, 130 insertions, 103 deletions
diff --git a/procps/Config.src b/procps/Config.src index 35fef2eda..515d79938 100644 --- a/procps/Config.src +++ b/procps/Config.src | |||
@@ -12,7 +12,7 @@ config FEATURE_SHOW_THREADS | |||
12 | default y | 12 | default y |
13 | depends on PS || TOP || PSTREE | 13 | depends on PS || TOP || PSTREE |
14 | help | 14 | help |
15 | Enables the ps -T option, showing of threads in pstree, | 15 | Enables the ps -T option, showing of threads in pstree, |
16 | and 'h' command in top. | 16 | and 'h' command in top. |
17 | 17 | ||
18 | endmenu | 18 | endmenu |
diff --git a/procps/free.c b/procps/free.c index f3a2c3c0c..618664e08 100644 --- a/procps/free.c +++ b/procps/free.c | |||
@@ -7,13 +7,13 @@ | |||
7 | * Licensed under GPLv2, see file LICENSE in this source tree. | 7 | * Licensed under GPLv2, see file LICENSE in this source tree. |
8 | */ | 8 | */ |
9 | //config:config FREE | 9 | //config:config FREE |
10 | //config: bool "free" | 10 | //config: bool "free (2.4 kb)" |
11 | //config: default y | 11 | //config: default y |
12 | //config: select PLATFORM_LINUX #sysinfo() | 12 | //config: select PLATFORM_LINUX #sysinfo() |
13 | //config: help | 13 | //config: help |
14 | //config: free displays the total amount of free and used physical and swap | 14 | //config: free displays the total amount of free and used physical and swap |
15 | //config: memory in the system, as well as the buffers used by the kernel. | 15 | //config: memory in the system, as well as the buffers used by the kernel. |
16 | //config: The shared memory column should be ignored; it is obsolete. | 16 | //config: The shared memory column should be ignored; it is obsolete. |
17 | 17 | ||
18 | //applet:IF_FREE(APPLET(free, BB_DIR_USR_BIN, BB_SUID_DROP)) | 18 | //applet:IF_FREE(APPLET(free, BB_DIR_USR_BIN, BB_SUID_DROP)) |
19 | 19 | ||
diff --git a/procps/fuser.c b/procps/fuser.c index db28cca79..2585a4203 100644 --- a/procps/fuser.c +++ b/procps/fuser.c | |||
@@ -7,12 +7,12 @@ | |||
7 | * Licensed under GPLv2, see file LICENSE in this source tree. | 7 | * Licensed under GPLv2, see file LICENSE in this source tree. |
8 | */ | 8 | */ |
9 | //config:config FUSER | 9 | //config:config FUSER |
10 | //config: bool "fuser" | 10 | //config: bool "fuser (7 kb)" |
11 | //config: default y | 11 | //config: default y |
12 | //config: help | 12 | //config: help |
13 | //config: fuser lists all PIDs (Process IDs) that currently have a given | 13 | //config: fuser lists all PIDs (Process IDs) that currently have a given |
14 | //config: file open. fuser can also list all PIDs that have a given network | 14 | //config: file open. fuser can also list all PIDs that have a given network |
15 | //config: (TCP or UDP) port open. | 15 | //config: (TCP or UDP) port open. |
16 | 16 | ||
17 | //applet:IF_FUSER(APPLET(fuser, BB_DIR_USR_BIN, BB_SUID_DROP)) | 17 | //applet:IF_FUSER(APPLET(fuser, BB_DIR_USR_BIN, BB_SUID_DROP)) |
18 | 18 | ||
diff --git a/procps/iostat.c b/procps/iostat.c index 2db343f69..6a39c324f 100644 --- a/procps/iostat.c +++ b/procps/iostat.c | |||
@@ -8,10 +8,10 @@ | |||
8 | */ | 8 | */ |
9 | 9 | ||
10 | //config:config IOSTAT | 10 | //config:config IOSTAT |
11 | //config: bool "iostat" | 11 | //config: bool "iostat (7.4 kb)" |
12 | //config: default y | 12 | //config: default y |
13 | //config: help | 13 | //config: help |
14 | //config: Report CPU and I/O statistics | 14 | //config: Report CPU and I/O statistics |
15 | 15 | ||
16 | //applet:IF_IOSTAT(APPLET(iostat, BB_DIR_BIN, BB_SUID_DROP)) | 16 | //applet:IF_IOSTAT(APPLET(iostat, BB_DIR_BIN, BB_SUID_DROP)) |
17 | 17 | ||
diff --git a/procps/kill.c b/procps/kill.c index 975a3e8c5..5cff24475 100644 --- a/procps/kill.c +++ b/procps/kill.c | |||
@@ -8,29 +8,29 @@ | |||
8 | * Licensed under GPLv2 or later, see file LICENSE in this source tree. | 8 | * Licensed under GPLv2 or later, see file LICENSE in this source tree. |
9 | */ | 9 | */ |
10 | //config:config KILL | 10 | //config:config KILL |
11 | //config: bool "kill" | 11 | //config: bool "kill (2.6 kb)" |
12 | //config: default y | 12 | //config: default y |
13 | //config: help | 13 | //config: help |
14 | //config: The command kill sends the specified signal to the specified | 14 | //config: The command kill sends the specified signal to the specified |
15 | //config: process or process group. If no signal is specified, the TERM | 15 | //config: process or process group. If no signal is specified, the TERM |
16 | //config: signal is sent. | 16 | //config: signal is sent. |
17 | //config: | 17 | //config: |
18 | //config:config KILLALL | 18 | //config:config KILLALL |
19 | //config: bool "killall" | 19 | //config: bool "killall (5.6 kb)" |
20 | //config: default y | 20 | //config: default y |
21 | //config: help | 21 | //config: help |
22 | //config: killall sends a signal to all processes running any of the | 22 | //config: killall sends a signal to all processes running any of the |
23 | //config: specified commands. If no signal name is specified, SIGTERM is | 23 | //config: specified commands. If no signal name is specified, SIGTERM is |
24 | //config: sent. | 24 | //config: sent. |
25 | //config: | 25 | //config: |
26 | //config:config KILLALL5 | 26 | //config:config KILLALL5 |
27 | //config: bool "killall5" | 27 | //config: bool "killall5 (5.3 kb)" |
28 | //config: default y | 28 | //config: default y |
29 | //config: help | 29 | //config: help |
30 | //config: The SystemV killall command. killall5 sends a signal | 30 | //config: The SystemV killall command. killall5 sends a signal |
31 | //config: to all processes except kernel threads and the processes | 31 | //config: to all processes except kernel threads and the processes |
32 | //config: in its own session, so it won't kill the shell that is running | 32 | //config: in its own session, so it won't kill the shell that is running |
33 | //config: the script it was called from. | 33 | //config: the script it was called from. |
34 | 34 | ||
35 | //applet:IF_KILL(APPLET(kill, BB_DIR_BIN, BB_SUID_DROP)) | 35 | //applet:IF_KILL(APPLET(kill, BB_DIR_BIN, BB_SUID_DROP)) |
36 | // APPLET_ODDNAME:name main location suid_type help | 36 | // APPLET_ODDNAME:name main location suid_type help |
diff --git a/procps/lsof.c b/procps/lsof.c index b0156a538..8d3a23cc8 100644 --- a/procps/lsof.c +++ b/procps/lsof.c | |||
@@ -8,11 +8,11 @@ | |||
8 | */ | 8 | */ |
9 | 9 | ||
10 | //config:config LSOF | 10 | //config:config LSOF |
11 | //config: bool "lsof" | 11 | //config: bool "lsof (3.6 kb)" |
12 | //config: default y | 12 | //config: default y |
13 | //config: help | 13 | //config: help |
14 | //config: Show open files in the format of: | 14 | //config: Show open files in the format of: |
15 | //config: PID <TAB> /path/to/executable <TAB> /path/to/opened/file | 15 | //config: PID <TAB> /path/to/executable <TAB> /path/to/opened/file |
16 | 16 | ||
17 | //applet:IF_LSOF(APPLET(lsof, BB_DIR_USR_BIN, BB_SUID_DROP)) | 17 | //applet:IF_LSOF(APPLET(lsof, BB_DIR_USR_BIN, BB_SUID_DROP)) |
18 | 18 | ||
diff --git a/procps/mpstat.c b/procps/mpstat.c index 8a79fd8ba..05a3f3ff3 100644 --- a/procps/mpstat.c +++ b/procps/mpstat.c | |||
@@ -12,10 +12,10 @@ | |||
12 | //kbuild:lib-$(CONFIG_MPSTAT) += mpstat.o | 12 | //kbuild:lib-$(CONFIG_MPSTAT) += mpstat.o |
13 | 13 | ||
14 | //config:config MPSTAT | 14 | //config:config MPSTAT |
15 | //config: bool "mpstat" | 15 | //config: bool "mpstat (10 kb)" |
16 | //config: default y | 16 | //config: default y |
17 | //config: help | 17 | //config: help |
18 | //config: Per-processor statistics | 18 | //config: Per-processor statistics |
19 | 19 | ||
20 | #include "libbb.h" | 20 | #include "libbb.h" |
21 | #include <sys/utsname.h> /* struct utsname */ | 21 | #include <sys/utsname.h> /* struct utsname */ |
diff --git a/procps/nmeter.c b/procps/nmeter.c index 05bf0a08c..9463f94dc 100644 --- a/procps/nmeter.c +++ b/procps/nmeter.c | |||
@@ -7,10 +7,10 @@ | |||
7 | */ | 7 | */ |
8 | 8 | ||
9 | //config:config NMETER | 9 | //config:config NMETER |
10 | //config: bool "nmeter" | 10 | //config: bool "nmeter (10 kb)" |
11 | //config: default y | 11 | //config: default y |
12 | //config: help | 12 | //config: help |
13 | //config: Prints selected system stats continuously, one line per update. | 13 | //config: Prints selected system stats continuously, one line per update. |
14 | 14 | ||
15 | //applet:IF_NMETER(APPLET(nmeter, BB_DIR_USR_BIN, BB_SUID_DROP)) | 15 | //applet:IF_NMETER(APPLET(nmeter, BB_DIR_USR_BIN, BB_SUID_DROP)) |
16 | 16 | ||
diff --git a/procps/pgrep.c b/procps/pgrep.c index 3d01c6cff..a3ca9e295 100644 --- a/procps/pgrep.c +++ b/procps/pgrep.c | |||
@@ -7,16 +7,16 @@ | |||
7 | * Licensed under GPLv2 or later, see file LICENSE in this source tree. | 7 | * Licensed under GPLv2 or later, see file LICENSE in this source tree. |
8 | */ | 8 | */ |
9 | //config:config PGREP | 9 | //config:config PGREP |
10 | //config: bool "pgrep" | 10 | //config: bool "pgrep (6.8 kb)" |
11 | //config: default y | 11 | //config: default y |
12 | //config: help | 12 | //config: help |
13 | //config: Look for processes by name. | 13 | //config: Look for processes by name. |
14 | //config: | 14 | //config: |
15 | //config:config PKILL | 15 | //config:config PKILL |
16 | //config: bool "pkill" | 16 | //config: bool "pkill (7.6 kb)" |
17 | //config: default y | 17 | //config: default y |
18 | //config: help | 18 | //config: help |
19 | //config: Send signals to processes by name. | 19 | //config: Send signals to processes by name. |
20 | 20 | ||
21 | //applet:IF_PGREP(APPLET(pgrep, BB_DIR_USR_BIN, BB_SUID_DROP)) | 21 | //applet:IF_PGREP(APPLET(pgrep, BB_DIR_USR_BIN, BB_SUID_DROP)) |
22 | // APPLET_ODDNAME:name main location suid_type help | 22 | // APPLET_ODDNAME:name main location suid_type help |
@@ -155,15 +155,18 @@ int pgrep_main(int argc UNUSED_PARAM, char **argv) | |||
155 | proc = NULL; | 155 | proc = NULL; |
156 | while ((proc = procps_scan(proc, scan_mask)) != NULL) { | 156 | while ((proc = procps_scan(proc, scan_mask)) != NULL) { |
157 | char *cmd; | 157 | char *cmd; |
158 | int cmdlen; | 158 | int cmdlen, match; |
159 | 159 | ||
160 | if (proc->pid == pid) | 160 | if (proc->pid == pid) |
161 | continue; | 161 | continue; |
162 | 162 | ||
163 | if (ppid2match >= 0 && ppid2match != proc->ppid) | 163 | if (!OPT_INVERT) { |
164 | continue; | 164 | /* Quickly reject -sN -PN mismatches... unless -v */ |
165 | if (sid2match >= 0 && sid2match != proc->sid) | 165 | if (ppid2match >= 0 && ppid2match != proc->ppid) |
166 | continue; | 166 | continue; |
167 | if (sid2match >= 0 && sid2match != proc->sid) | ||
168 | continue; | ||
169 | } | ||
167 | 170 | ||
168 | cmdlen = -1; | 171 | cmdlen = -1; |
169 | cmd = proc->argv0; | 172 | cmd = proc->argv0; |
@@ -186,12 +189,36 @@ int pgrep_main(int argc UNUSED_PARAM, char **argv) | |||
186 | } | 189 | } |
187 | } | 190 | } |
188 | 191 | ||
192 | if (OPT_INVERT) { | ||
193 | /* "pgrep -v -P1 firefox" means "not (ppid=1 AND name=firefox)" | ||
194 | * or equivalently "ppid!=1 OR name!=firefox". | ||
195 | * Check the first condition and if true, skip matching. | ||
196 | */ | ||
197 | if (ppid2match >= 0 && ppid2match != proc->ppid) | ||
198 | goto got_it; | ||
199 | if (sid2match >= 0 && sid2match != proc->sid) | ||
200 | goto got_it; | ||
201 | } | ||
202 | |||
203 | match = !argv[0]; /* if no PATTERN, then it's a match, else... */ | ||
204 | if (!match) { | ||
205 | again: | ||
206 | match = (regexec(&re_buffer, cmd, 1, re_match, 0) == 0); | ||
207 | if (!match && cmd != proc->comm) { | ||
208 | /* if argv[] did not match, try comm */ | ||
209 | cmdlen = -1; | ||
210 | cmd = proc->comm; | ||
211 | goto again; | ||
212 | } | ||
213 | if (match && OPT_ANCHOR) { | ||
214 | /* -x requires full string match */ | ||
215 | match = (re_match[0].rm_so == 0 && cmd[re_match[0].rm_eo] == '\0'); | ||
216 | } | ||
217 | } | ||
218 | |||
189 | /* NB: OPT_INVERT is always 0 or 1 */ | 219 | /* NB: OPT_INVERT is always 0 or 1 */ |
190 | if (!argv[0] | 220 | if (match ^ OPT_INVERT) { |
191 | || (regexec(&re_buffer, cmd, 1, re_match, 0) == 0 /* match found */ | 221 | got_it: |
192 | && (!OPT_ANCHOR || (re_match[0].rm_so == 0 && re_match[0].rm_eo == (regoff_t)strlen(cmd))) | ||
193 | ) ^ OPT_INVERT | ||
194 | ) { | ||
195 | matched_pid = proc->pid; | 222 | matched_pid = proc->pid; |
196 | if (OPT_LAST) { | 223 | if (OPT_LAST) { |
197 | free(cmd_last); | 224 | free(cmd_last); |
diff --git a/procps/pidof.c b/procps/pidof.c index b64f0cbd6..41247a02c 100644 --- a/procps/pidof.c +++ b/procps/pidof.c | |||
@@ -7,27 +7,27 @@ | |||
7 | * Licensed under GPLv2, see file LICENSE in this source tree. | 7 | * Licensed under GPLv2, see file LICENSE in this source tree. |
8 | */ | 8 | */ |
9 | //config:config PIDOF | 9 | //config:config PIDOF |
10 | //config: bool "pidof" | 10 | //config: bool "pidof (6.6 kb)" |
11 | //config: default y | 11 | //config: default y |
12 | //config: help | 12 | //config: help |
13 | //config: Pidof finds the process id's (pids) of the named programs. It prints | 13 | //config: Pidof finds the process id's (pids) of the named programs. It prints |
14 | //config: those id's on the standard output. | 14 | //config: those id's on the standard output. |
15 | //config: | 15 | //config: |
16 | //config:config FEATURE_PIDOF_SINGLE | 16 | //config:config FEATURE_PIDOF_SINGLE |
17 | //config: bool "Enable single shot (-s)" | 17 | //config: bool "Enable single shot (-s)" |
18 | //config: default y | 18 | //config: default y |
19 | //config: depends on PIDOF | 19 | //config: depends on PIDOF |
20 | //config: help | 20 | //config: help |
21 | //config: Support '-s' for returning only the first pid found. | 21 | //config: Support '-s' for returning only the first pid found. |
22 | //config: | 22 | //config: |
23 | //config:config FEATURE_PIDOF_OMIT | 23 | //config:config FEATURE_PIDOF_OMIT |
24 | //config: bool "Enable omitting pids (-o PID)" | 24 | //config: bool "Enable omitting pids (-o PID)" |
25 | //config: default y | 25 | //config: default y |
26 | //config: depends on PIDOF | 26 | //config: depends on PIDOF |
27 | //config: help | 27 | //config: help |
28 | //config: Support '-o PID' for omitting the given pid(s) in output. | 28 | //config: Support '-o PID' for omitting the given pid(s) in output. |
29 | //config: The special pid %PPID can be used to name the parent process | 29 | //config: The special pid %PPID can be used to name the parent process |
30 | //config: of the pidof, in other words the calling shell or shell script. | 30 | //config: of the pidof, in other words the calling shell or shell script. |
31 | 31 | ||
32 | //applet:IF_PIDOF(APPLET(pidof, BB_DIR_BIN, BB_SUID_DROP)) | 32 | //applet:IF_PIDOF(APPLET(pidof, BB_DIR_BIN, BB_SUID_DROP)) |
33 | 33 | ||
diff --git a/procps/pmap.c b/procps/pmap.c index aa221cfb8..c8f728897 100644 --- a/procps/pmap.c +++ b/procps/pmap.c | |||
@@ -9,10 +9,10 @@ | |||
9 | */ | 9 | */ |
10 | 10 | ||
11 | //config:config PMAP | 11 | //config:config PMAP |
12 | //config: bool "pmap" | 12 | //config: bool "pmap (6 kb)" |
13 | //config: default y | 13 | //config: default y |
14 | //config: help | 14 | //config: help |
15 | //config: Display processes' memory mappings. | 15 | //config: Display processes' memory mappings. |
16 | 16 | ||
17 | //applet:IF_PMAP(APPLET(pmap, BB_DIR_USR_BIN, BB_SUID_DROP)) | 17 | //applet:IF_PMAP(APPLET(pmap, BB_DIR_USR_BIN, BB_SUID_DROP)) |
18 | //kbuild:lib-$(CONFIG_PMAP) += pmap.o | 18 | //kbuild:lib-$(CONFIG_PMAP) += pmap.o |
diff --git a/procps/powertop.c b/procps/powertop.c index 413806836..ebd659bdb 100644 --- a/procps/powertop.c +++ b/procps/powertop.c | |||
@@ -14,18 +14,18 @@ | |||
14 | //kbuild:lib-$(CONFIG_POWERTOP) += powertop.o | 14 | //kbuild:lib-$(CONFIG_POWERTOP) += powertop.o |
15 | 15 | ||
16 | //config:config POWERTOP | 16 | //config:config POWERTOP |
17 | //config: bool "powertop" | 17 | //config: bool "powertop (9.1 kb)" |
18 | //config: default y | 18 | //config: default y |
19 | //config: help | 19 | //config: help |
20 | //config: Analyze power consumption on Intel-based laptops | 20 | //config: Analyze power consumption on Intel-based laptops |
21 | //config: | 21 | //config: |
22 | //config:config FEATURE_POWERTOP_INTERACTIVE | 22 | //config:config FEATURE_POWERTOP_INTERACTIVE |
23 | //config: bool "Accept keyboard commands" | 23 | //config: bool "Accept keyboard commands" |
24 | //config: default y | 24 | //config: default y |
25 | //config: depends on POWERTOP | 25 | //config: depends on POWERTOP |
26 | //config: help | 26 | //config: help |
27 | //config: Without this, powertop will only refresh display every 10 seconds. | 27 | //config: Without this, powertop will only refresh display every 10 seconds. |
28 | //config: No keyboard commands will work, only ^C to terminate. | 28 | //config: No keyboard commands will work, only ^C to terminate. |
29 | 29 | ||
30 | // XXX This should be configurable | 30 | // XXX This should be configurable |
31 | #define ENABLE_FEATURE_POWERTOP_PROCIRQ 1 | 31 | #define ENABLE_FEATURE_POWERTOP_PROCIRQ 1 |
diff --git a/procps/ps.c b/procps/ps.c index f7242f2d5..c1da921bd 100644 --- a/procps/ps.c +++ b/procps/ps.c | |||
@@ -9,27 +9,27 @@ | |||
9 | * Licensed under GPLv2, see file LICENSE in this source tree. | 9 | * Licensed under GPLv2, see file LICENSE in this source tree. |
10 | */ | 10 | */ |
11 | //config:config PS | 11 | //config:config PS |
12 | //config: bool "ps" | 12 | //config: bool "ps (11 kb)" |
13 | //config: default y | 13 | //config: default y |
14 | //config: help | 14 | //config: help |
15 | //config: ps gives a snapshot of the current processes. | 15 | //config: ps gives a snapshot of the current processes. |
16 | //config: | 16 | //config: |
17 | //config:config FEATURE_PS_WIDE | 17 | //config:config FEATURE_PS_WIDE |
18 | //config: bool "Enable wide output option (-w)" | 18 | //config: bool "Enable wide output option (-w)" |
19 | //config: default y | 19 | //config: default y |
20 | //config: depends on PS && !DESKTOP | 20 | //config: depends on PS && !DESKTOP |
21 | //config: help | 21 | //config: help |
22 | //config: Support argument 'w' for wide output. | 22 | //config: Support argument 'w' for wide output. |
23 | //config: If given once, 132 chars are printed, and if given more | 23 | //config: If given once, 132 chars are printed, and if given more |
24 | //config: than once, the length is unlimited. | 24 | //config: than once, the length is unlimited. |
25 | //config: | 25 | //config: |
26 | //config:config FEATURE_PS_LONG | 26 | //config:config FEATURE_PS_LONG |
27 | //config: bool "Enable long output option (-l)" | 27 | //config: bool "Enable long output option (-l)" |
28 | //config: default y | 28 | //config: default y |
29 | //config: depends on PS && !DESKTOP | 29 | //config: depends on PS && !DESKTOP |
30 | //config: help | 30 | //config: help |
31 | //config: Support argument 'l' for long output. | 31 | //config: Support argument 'l' for long output. |
32 | //config: Adds fields PPID, RSS, START, TIME & TTY | 32 | //config: Adds fields PPID, RSS, START, TIME & TTY |
33 | //config: | 33 | //config: |
34 | //config:config FEATURE_PS_TIME | 34 | //config:config FEATURE_PS_TIME |
35 | //config: bool "Support -o time and -o etime output specifiers" | 35 | //config: bool "Support -o time and -o etime output specifiers" |
@@ -42,8 +42,8 @@ | |||
42 | //config: default n | 42 | //config: default n |
43 | //config: depends on FEATURE_PS_TIME | 43 | //config: depends on FEATURE_PS_TIME |
44 | //config: help | 44 | //config: help |
45 | //config: Include support for measuring HZ on old kernels and non-ELF systems | 45 | //config: Include support for measuring HZ on old kernels and non-ELF systems |
46 | //config: (if you are on Linux 2.4.0+ and use ELF, you don't need this) | 46 | //config: (if you are on Linux 2.4.0+ and use ELF, you don't need this) |
47 | //config: | 47 | //config: |
48 | //config:config FEATURE_PS_ADDITIONAL_COLUMNS | 48 | //config:config FEATURE_PS_ADDITIONAL_COLUMNS |
49 | //config: bool "Support -o rgroup, -o ruser, -o nice specifiers" | 49 | //config: bool "Support -o rgroup, -o ruser, -o nice specifiers" |
diff --git a/procps/pstree.c b/procps/pstree.c index bc9f0c927..212cda23c 100644 --- a/procps/pstree.c +++ b/procps/pstree.c | |||
@@ -11,10 +11,10 @@ | |||
11 | */ | 11 | */ |
12 | 12 | ||
13 | //config:config PSTREE | 13 | //config:config PSTREE |
14 | //config: bool "pstree" | 14 | //config: bool "pstree (9.4 kb)" |
15 | //config: default y | 15 | //config: default y |
16 | //config: help | 16 | //config: help |
17 | //config: Display a tree of processes. | 17 | //config: Display a tree of processes. |
18 | 18 | ||
19 | //applet:IF_PSTREE(APPLET(pstree, BB_DIR_USR_BIN, BB_SUID_DROP)) | 19 | //applet:IF_PSTREE(APPLET(pstree, BB_DIR_USR_BIN, BB_SUID_DROP)) |
20 | 20 | ||
diff --git a/procps/pwdx.c b/procps/pwdx.c index 4e34149ed..dac238950 100644 --- a/procps/pwdx.c +++ b/procps/pwdx.c | |||
@@ -9,10 +9,10 @@ | |||
9 | */ | 9 | */ |
10 | 10 | ||
11 | //config:config PWDX | 11 | //config:config PWDX |
12 | //config: bool "pwdx" | 12 | //config: bool "pwdx (3.5 kb)" |
13 | //config: default y | 13 | //config: default y |
14 | //config: help | 14 | //config: help |
15 | //config: Report current working directory of a process | 15 | //config: Report current working directory of a process |
16 | 16 | ||
17 | //applet:IF_PWDX(APPLET(pwdx, BB_DIR_USR_BIN, BB_SUID_DROP)) | 17 | //applet:IF_PWDX(APPLET(pwdx, BB_DIR_USR_BIN, BB_SUID_DROP)) |
18 | 18 | ||
diff --git a/procps/smemcap.c b/procps/smemcap.c index b2b32198f..17aeccd53 100644 --- a/procps/smemcap.c +++ b/procps/smemcap.c | |||
@@ -13,11 +13,11 @@ | |||
13 | //kbuild:lib-$(CONFIG_SMEMCAP) += smemcap.o | 13 | //kbuild:lib-$(CONFIG_SMEMCAP) += smemcap.o |
14 | 14 | ||
15 | //config:config SMEMCAP | 15 | //config:config SMEMCAP |
16 | //config: bool "smemcap" | 16 | //config: bool "smemcap (2.5 kb)" |
17 | //config: default y | 17 | //config: default y |
18 | //config: help | 18 | //config: help |
19 | //config: smemcap is a tool for capturing process data for smem, | 19 | //config: smemcap is a tool for capturing process data for smem, |
20 | //config: a memory usage statistic tool. | 20 | //config: a memory usage statistic tool. |
21 | 21 | ||
22 | #include "libbb.h" | 22 | #include "libbb.h" |
23 | #define BB_ARCHIVE_PUBLIC | 23 | #define BB_ARCHIVE_PUBLIC |
diff --git a/procps/sysctl.c b/procps/sysctl.c index 93d7c3418..b17f5e896 100644 --- a/procps/sysctl.c +++ b/procps/sysctl.c | |||
@@ -11,10 +11,10 @@ | |||
11 | * v1.01.1 - busybox applet aware by <solar@gentoo.org> | 11 | * v1.01.1 - busybox applet aware by <solar@gentoo.org> |
12 | */ | 12 | */ |
13 | //config:config BB_SYSCTL | 13 | //config:config BB_SYSCTL |
14 | //config: bool "sysctl" | 14 | //config: bool "sysctl (6.9 kb)" |
15 | //config: default y | 15 | //config: default y |
16 | //config: help | 16 | //config: help |
17 | //config: Configure kernel parameters at runtime. | 17 | //config: Configure kernel parameters at runtime. |
18 | 18 | ||
19 | //applet:IF_BB_SYSCTL(APPLET(sysctl, BB_DIR_SBIN, BB_SUID_DROP)) | 19 | //applet:IF_BB_SYSCTL(APPLET(sysctl, BB_DIR_SBIN, BB_SUID_DROP)) |
20 | 20 | ||
diff --git a/procps/top.c b/procps/top.c index ff2fddeea..015d1ab74 100644 --- a/procps/top.c +++ b/procps/top.c | |||
@@ -50,66 +50,66 @@ | |||
50 | * chroot . ./top -bn1 >top1.out | 50 | * chroot . ./top -bn1 >top1.out |
51 | */ | 51 | */ |
52 | //config:config TOP | 52 | //config:config TOP |
53 | //config: bool "top" | 53 | //config: bool "top (17 kb)" |
54 | //config: default y | 54 | //config: default y |
55 | //config: help | 55 | //config: help |
56 | //config: The top program provides a dynamic real-time view of a running | 56 | //config: The top program provides a dynamic real-time view of a running |
57 | //config: system. | 57 | //config: system. |
58 | //config: | 58 | //config: |
59 | //config:config FEATURE_TOP_INTERACTIVE | 59 | //config:config FEATURE_TOP_INTERACTIVE |
60 | //config: bool "Accept keyboard commands" | 60 | //config: bool "Accept keyboard commands" |
61 | //config: default y | 61 | //config: default y |
62 | //config: depends on TOP | 62 | //config: depends on TOP |
63 | //config: help | 63 | //config: help |
64 | //config: Without this, top will only refresh display every 5 seconds. | 64 | //config: Without this, top will only refresh display every 5 seconds. |
65 | //config: No keyboard commands will work, only ^C to terminate. | 65 | //config: No keyboard commands will work, only ^C to terminate. |
66 | //config: | 66 | //config: |
67 | //config:config FEATURE_TOP_CPU_USAGE_PERCENTAGE | 67 | //config:config FEATURE_TOP_CPU_USAGE_PERCENTAGE |
68 | //config: bool "Show CPU per-process usage percentage" | 68 | //config: bool "Show CPU per-process usage percentage" |
69 | //config: default y | 69 | //config: default y |
70 | //config: depends on TOP | 70 | //config: depends on TOP |
71 | //config: help | 71 | //config: help |
72 | //config: Make top display CPU usage for each process. | 72 | //config: Make top display CPU usage for each process. |
73 | //config: This adds about 2k. | 73 | //config: This adds about 2k. |
74 | //config: | 74 | //config: |
75 | //config:config FEATURE_TOP_CPU_GLOBAL_PERCENTS | 75 | //config:config FEATURE_TOP_CPU_GLOBAL_PERCENTS |
76 | //config: bool "Show CPU global usage percentage" | 76 | //config: bool "Show CPU global usage percentage" |
77 | //config: default y | 77 | //config: default y |
78 | //config: depends on FEATURE_TOP_CPU_USAGE_PERCENTAGE | 78 | //config: depends on FEATURE_TOP_CPU_USAGE_PERCENTAGE |
79 | //config: help | 79 | //config: help |
80 | //config: Makes top display "CPU: NN% usr NN% sys..." line. | 80 | //config: Makes top display "CPU: NN% usr NN% sys..." line. |
81 | //config: This adds about 0.5k. | 81 | //config: This adds about 0.5k. |
82 | //config: | 82 | //config: |
83 | //config:config FEATURE_TOP_SMP_CPU | 83 | //config:config FEATURE_TOP_SMP_CPU |
84 | //config: bool "SMP CPU usage display ('c' key)" | 84 | //config: bool "SMP CPU usage display ('c' key)" |
85 | //config: default y | 85 | //config: default y |
86 | //config: depends on FEATURE_TOP_CPU_GLOBAL_PERCENTS | 86 | //config: depends on FEATURE_TOP_CPU_GLOBAL_PERCENTS |
87 | //config: help | 87 | //config: help |
88 | //config: Allow 'c' key to switch between individual/cumulative CPU stats | 88 | //config: Allow 'c' key to switch between individual/cumulative CPU stats |
89 | //config: This adds about 0.5k. | 89 | //config: This adds about 0.5k. |
90 | //config: | 90 | //config: |
91 | //config:config FEATURE_TOP_DECIMALS | 91 | //config:config FEATURE_TOP_DECIMALS |
92 | //config: bool "Show 1/10th of a percent in CPU/mem statistics" | 92 | //config: bool "Show 1/10th of a percent in CPU/mem statistics" |
93 | //config: default y | 93 | //config: default y |
94 | //config: depends on FEATURE_TOP_CPU_USAGE_PERCENTAGE | 94 | //config: depends on FEATURE_TOP_CPU_USAGE_PERCENTAGE |
95 | //config: help | 95 | //config: help |
96 | //config: Show 1/10th of a percent in CPU/mem statistics. | 96 | //config: Show 1/10th of a percent in CPU/mem statistics. |
97 | //config: This adds about 0.3k. | 97 | //config: This adds about 0.3k. |
98 | //config: | 98 | //config: |
99 | //config:config FEATURE_TOP_SMP_PROCESS | 99 | //config:config FEATURE_TOP_SMP_PROCESS |
100 | //config: bool "Show CPU process runs on ('j' field)" | 100 | //config: bool "Show CPU process runs on ('j' field)" |
101 | //config: default y | 101 | //config: default y |
102 | //config: depends on TOP | 102 | //config: depends on TOP |
103 | //config: help | 103 | //config: help |
104 | //config: Show CPU where process was last found running on. | 104 | //config: Show CPU where process was last found running on. |
105 | //config: This is the 'j' field. | 105 | //config: This is the 'j' field. |
106 | //config: | 106 | //config: |
107 | //config:config FEATURE_TOPMEM | 107 | //config:config FEATURE_TOPMEM |
108 | //config: bool "Topmem command ('s' key)" | 108 | //config: bool "Topmem command ('s' key)" |
109 | //config: default y | 109 | //config: default y |
110 | //config: depends on TOP | 110 | //config: depends on TOP |
111 | //config: help | 111 | //config: help |
112 | //config: Enable 's' in top (gives lots of memory info). | 112 | //config: Enable 's' in top (gives lots of memory info). |
113 | 113 | ||
114 | //applet:IF_TOP(APPLET(top, BB_DIR_USR_BIN, BB_SUID_DROP)) | 114 | //applet:IF_TOP(APPLET(top, BB_DIR_USR_BIN, BB_SUID_DROP)) |
115 | 115 | ||
diff --git a/procps/uptime.c b/procps/uptime.c index 8e8956c0f..24b2b39df 100644 --- a/procps/uptime.c +++ b/procps/uptime.c | |||
@@ -12,20 +12,20 @@ | |||
12 | * Added FEATURE_UPTIME_UTMP_SUPPORT flag. | 12 | * Added FEATURE_UPTIME_UTMP_SUPPORT flag. |
13 | */ | 13 | */ |
14 | //config:config UPTIME | 14 | //config:config UPTIME |
15 | //config: bool "uptime" | 15 | //config: bool "uptime (632 bytes)" |
16 | //config: default y | 16 | //config: default y |
17 | //config: select PLATFORM_LINUX #sysinfo() | 17 | //config: select PLATFORM_LINUX #sysinfo() |
18 | //config: help | 18 | //config: help |
19 | //config: uptime gives a one line display of the current time, how long | 19 | //config: uptime gives a one line display of the current time, how long |
20 | //config: the system has been running, how many users are currently logged | 20 | //config: the system has been running, how many users are currently logged |
21 | //config: on, and the system load averages for the past 1, 5, and 15 minutes. | 21 | //config: on, and the system load averages for the past 1, 5, and 15 minutes. |
22 | //config: | 22 | //config: |
23 | //config:config FEATURE_UPTIME_UTMP_SUPPORT | 23 | //config:config FEATURE_UPTIME_UTMP_SUPPORT |
24 | //config: bool "Show the number of users" | 24 | //config: bool "Show the number of users" |
25 | //config: default y | 25 | //config: default y |
26 | //config: depends on UPTIME && FEATURE_UTMP | 26 | //config: depends on UPTIME && FEATURE_UTMP |
27 | //config: help | 27 | //config: help |
28 | //config: Display the number of users currently logged on. | 28 | //config: Display the number of users currently logged on. |
29 | 29 | ||
30 | //applet:IF_UPTIME(APPLET(uptime, BB_DIR_USR_BIN, BB_SUID_DROP)) | 30 | //applet:IF_UPTIME(APPLET(uptime, BB_DIR_USR_BIN, BB_SUID_DROP)) |
31 | 31 | ||
diff --git a/procps/watch.c b/procps/watch.c index bb34124c0..2bb7cca90 100644 --- a/procps/watch.c +++ b/procps/watch.c | |||
@@ -12,11 +12,11 @@ | |||
12 | /* BB_AUDIT GNU defects -- only option -n is supported. */ | 12 | /* BB_AUDIT GNU defects -- only option -n is supported. */ |
13 | 13 | ||
14 | //config:config WATCH | 14 | //config:config WATCH |
15 | //config: bool "watch" | 15 | //config: bool "watch (4.1 kb)" |
16 | //config: default y | 16 | //config: default y |
17 | //config: help | 17 | //config: help |
18 | //config: watch is used to execute a program periodically, showing | 18 | //config: watch is used to execute a program periodically, showing |
19 | //config: output to the screen. | 19 | //config: output to the screen. |
20 | 20 | ||
21 | //applet:IF_WATCH(APPLET(watch, BB_DIR_BIN, BB_SUID_DROP)) | 21 | //applet:IF_WATCH(APPLET(watch, BB_DIR_BIN, BB_SUID_DROP)) |
22 | 22 | ||