diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/applets.h | 2 | ||||
-rw-r--r-- | include/libbb.h | 4 | ||||
-rw-r--r-- | include/usage.h | 24 |
3 files changed, 29 insertions, 1 deletions
diff --git a/include/applets.h b/include/applets.h index f162c5479..e88192d24 100644 --- a/include/applets.h +++ b/include/applets.h | |||
@@ -251,11 +251,13 @@ USE_OD(APPLET(od, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) | |||
251 | USE_OPENVT(APPLET(openvt, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) | 251 | USE_OPENVT(APPLET(openvt, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) |
252 | USE_PASSWD(APPLET(passwd, _BB_DIR_USR_BIN, _BB_SUID_ALWAYS)) | 252 | USE_PASSWD(APPLET(passwd, _BB_DIR_USR_BIN, _BB_SUID_ALWAYS)) |
253 | USE_PATCH(APPLET(patch, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) | 253 | USE_PATCH(APPLET(patch, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) |
254 | USE_PGREP(APPLET(pgrep, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) | ||
254 | USE_PIDOF(APPLET(pidof, _BB_DIR_BIN, _BB_SUID_NEVER)) | 255 | USE_PIDOF(APPLET(pidof, _BB_DIR_BIN, _BB_SUID_NEVER)) |
255 | USE_PING(APPLET(ping, _BB_DIR_BIN, _BB_SUID_MAYBE)) | 256 | USE_PING(APPLET(ping, _BB_DIR_BIN, _BB_SUID_MAYBE)) |
256 | USE_PING6(APPLET(ping6, _BB_DIR_BIN, _BB_SUID_NEVER)) | 257 | USE_PING6(APPLET(ping6, _BB_DIR_BIN, _BB_SUID_NEVER)) |
257 | USE_PIPE_PROGRESS(APPLET_NOUSAGE(pipe_progress, pipe_progress, _BB_DIR_BIN, _BB_SUID_NEVER)) | 258 | USE_PIPE_PROGRESS(APPLET_NOUSAGE(pipe_progress, pipe_progress, _BB_DIR_BIN, _BB_SUID_NEVER)) |
258 | USE_PIVOT_ROOT(APPLET(pivot_root, _BB_DIR_SBIN, _BB_SUID_NEVER)) | 259 | USE_PIVOT_ROOT(APPLET(pivot_root, _BB_DIR_SBIN, _BB_SUID_NEVER)) |
260 | USE_PKILL(APPLET_ODDNAME(pkill, pgrep, _BB_DIR_USR_BIN, _BB_SUID_NEVER, pkill)) | ||
259 | USE_HALT(APPLET_ODDNAME(poweroff, halt, _BB_DIR_SBIN, _BB_SUID_NEVER, poweroff)) | 261 | USE_HALT(APPLET_ODDNAME(poweroff, halt, _BB_DIR_SBIN, _BB_SUID_NEVER, poweroff)) |
260 | USE_PRINTENV(APPLET(printenv, _BB_DIR_BIN, _BB_SUID_NEVER)) | 262 | USE_PRINTENV(APPLET(printenv, _BB_DIR_BIN, _BB_SUID_NEVER)) |
261 | USE_PRINTF(APPLET(printf, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) | 263 | USE_PRINTF(APPLET(printf, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) |
diff --git a/include/libbb.h b/include/libbb.h index a6709c95d..34b978452 100644 --- a/include/libbb.h +++ b/include/libbb.h | |||
@@ -787,6 +787,7 @@ int bb_make_directory(char *path, long mode, int flags); | |||
787 | 787 | ||
788 | int get_signum(const char *name); | 788 | int get_signum(const char *name); |
789 | const char *get_signame(int number); | 789 | const char *get_signame(int number); |
790 | void print_signames_and_exit(void) ATTRIBUTE_NORETURN; | ||
790 | 791 | ||
791 | char *bb_simplify_path(const char *path); | 792 | char *bb_simplify_path(const char *path); |
792 | 793 | ||
@@ -973,7 +974,8 @@ enum { | |||
973 | PSSCAN_UTIME = 1 << 13, | 974 | PSSCAN_UTIME = 1 << 13, |
974 | PSSCAN_TTY = 1 << 14, | 975 | PSSCAN_TTY = 1 << 14, |
975 | PSSCAN_SMAPS = (1 << 15) * ENABLE_FEATURE_TOPMEM, | 976 | PSSCAN_SMAPS = (1 << 15) * ENABLE_FEATURE_TOPMEM, |
976 | USE_SELINUX(PSSCAN_CONTEXT = 1 << 16,) | 977 | PSSCAN_ARGVN = (1 << 16) * (ENABLE_PGREP | ENABLE_PKILL), |
978 | USE_SELINUX(PSSCAN_CONTEXT = 1 << 17,) | ||
977 | /* These are all retrieved from proc/NN/stat in one go: */ | 979 | /* These are all retrieved from proc/NN/stat in one go: */ |
978 | PSSCAN_STAT = PSSCAN_PPID | PSSCAN_PGID | PSSCAN_SID | 980 | PSSCAN_STAT = PSSCAN_PPID | PSSCAN_PGID | PSSCAN_SID |
979 | | PSSCAN_COMM | PSSCAN_STATE | 981 | | PSSCAN_COMM | PSSCAN_STATE |
diff --git a/include/usage.h b/include/usage.h index 4152fecd3..d7e1dd9f1 100644 --- a/include/usage.h +++ b/include/usage.h | |||
@@ -2558,6 +2558,18 @@ | |||
2558 | "$ patch -p1 < example.diff\n" \ | 2558 | "$ patch -p1 < example.diff\n" \ |
2559 | "$ patch -p0 -i example.diff" | 2559 | "$ patch -p0 -i example.diff" |
2560 | 2560 | ||
2561 | #define pgrep_trivial_usage \ | ||
2562 | "[-flnovx] pattern" | ||
2563 | #define pgrep_full_usage \ | ||
2564 | "Display process(es) selected by regex pattern" \ | ||
2565 | "\n\nOptions:\n" \ | ||
2566 | " -l Show command name too\n" \ | ||
2567 | " -f Match against entire command line\n" \ | ||
2568 | " -n Signal the newest process only\n" \ | ||
2569 | " -o Signal the oldest process only\n" \ | ||
2570 | " -v Negate the matching\n" \ | ||
2571 | " -x Match whole name (not substring)" | ||
2572 | |||
2561 | #if (ENABLE_FEATURE_PIDOF_SINGLE || ENABLE_FEATURE_PIDOF_OMIT) | 2573 | #if (ENABLE_FEATURE_PIDOF_SINGLE || ENABLE_FEATURE_PIDOF_OMIT) |
2562 | #define USAGE_PIDOF "Options:" | 2574 | #define USAGE_PIDOF "Options:" |
2563 | #else | 2575 | #else |
@@ -2640,6 +2652,18 @@ | |||
2640 | "Move the current root file system to PUT_OLD and make NEW_ROOT\n" \ | 2652 | "Move the current root file system to PUT_OLD and make NEW_ROOT\n" \ |
2641 | "the new root file system" | 2653 | "the new root file system" |
2642 | 2654 | ||
2655 | #define pkill_trivial_usage \ | ||
2656 | "[-l] | [-fnovx] [-signal] pattern" | ||
2657 | #define pkill_full_usage \ | ||
2658 | "Send a signal to process(es) selected by regex pattern" \ | ||
2659 | "\n\nOptions:\n" \ | ||
2660 | " -l List all signals\n" \ | ||
2661 | " -f Match against entire command line\n" \ | ||
2662 | " -n Signal the newest process only\n" \ | ||
2663 | " -o Signal the oldest process only\n" \ | ||
2664 | " -v Negate the matching\n" \ | ||
2665 | " -x Match whole name (not substring)" | ||
2666 | |||
2643 | #define poweroff_trivial_usage \ | 2667 | #define poweroff_trivial_usage \ |
2644 | "[-d delay] [-n] [-f]" | 2668 | "[-d delay] [-n] [-f]" |
2645 | #define poweroff_full_usage \ | 2669 | #define poweroff_full_usage \ |