diff options
author | Erik Andersen <andersen@codepoet.org> | 2000-05-12 19:41:47 +0000 |
---|---|---|
committer | Erik Andersen <andersen@codepoet.org> | 2000-05-12 19:41:47 +0000 |
commit | 7ab9c7ee52db8759d457819f5480378fa3aa97cc (patch) | |
tree | 37ef0fb8b142a4925b866c7caa5207b71b4ecae6 /coreutils/test.c | |
parent | 3d427ac5efd249dc25dd03deb30520335f68911a (diff) | |
download | busybox-w32-7ab9c7ee52db8759d457819f5480378fa3aa97cc.tar.gz busybox-w32-7ab9c7ee52db8759d457819f5480378fa3aa97cc.tar.bz2 busybox-w32-7ab9c7ee52db8759d457819f5480378fa3aa97cc.zip |
Lots of updates. Finished implementing BB_FEATURE_TRIVIAL_HELP
which lets you compile out most of the "--help" output, saving
up to 17k.
Renamed mnc to nc.
-Erik
Diffstat (limited to 'coreutils/test.c')
-rw-r--r-- | coreutils/test.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/coreutils/test.c b/coreutils/test.c index 0ed777194..9b541e33e 100644 --- a/coreutils/test.c +++ b/coreutils/test.c | |||
@@ -39,6 +39,9 @@ | |||
39 | #include <errno.h> | 39 | #include <errno.h> |
40 | #include <stdlib.h> | 40 | #include <stdlib.h> |
41 | #include <string.h> | 41 | #include <string.h> |
42 | #define BB_DECLARE_EXTERN | ||
43 | #define bb_need_help | ||
44 | #include "messages.c" | ||
42 | 45 | ||
43 | /* test(1) accepts the following grammar: | 46 | /* test(1) accepts the following grammar: |
44 | oexpr ::= aexpr | aexpr "-o" oexpr ; | 47 | oexpr ::= aexpr | aexpr "-o" oexpr ; |
@@ -185,11 +188,14 @@ test_main(int argc, char** argv) | |||
185 | fatalError("missing ]"); | 188 | fatalError("missing ]"); |
186 | argv[argc] = NULL; | 189 | argv[argc] = NULL; |
187 | } | 190 | } |
188 | if (strcmp(argv[1], "--help") == 0) { | 191 | if (strcmp(argv[1], dash_dash_help) == 0) { |
189 | usage("test EXPRESSION\n" | 192 | usage("test EXPRESSION\n" |
190 | "or [ EXPRESSION ]\n\n" | 193 | "or [ EXPRESSION ]\n" |
191 | "Checks file types and compares values returning an exit\n" | 194 | #ifndef BB_FEATURE_TRIVIAL_HELP |
192 | "code determined by the value of EXPRESSION.\n"); | 195 | "\nChecks file types and compares values returning an exit\n" |
196 | "code determined by the value of EXPRESSION.\n" | ||
197 | #endif | ||
198 | ); | ||
193 | } | 199 | } |
194 | 200 | ||
195 | /* Implement special cases from POSIX.2, section 4.62.4 */ | 201 | /* Implement special cases from POSIX.2, section 4.62.4 */ |