diff options
| author | John Beppu <beppu@lbox.org> | 2000-04-17 17:49:44 +0000 |
|---|---|---|
| committer | John Beppu <beppu@lbox.org> | 2000-04-17 17:49:44 +0000 |
| commit | 91e581fa0438b39ceb0ffb4ddcb90ee4d260ae81 (patch) | |
| tree | 821da011406dde39fac4076ae8b50feca17783b8 | |
| parent | 5a50def0f4f7265f74a51995852e95851f06f2a1 (diff) | |
| download | busybox-w32-91e581fa0438b39ceb0ffb4ddcb90ee4d260ae81.tar.gz busybox-w32-91e581fa0438b39ceb0ffb4ddcb90ee4d260ae81.tar.bz2 busybox-w32-91e581fa0438b39ceb0ffb4ddcb90ee4d260ae81.zip | |
- grep -v ^\.PHONY < Makefile
+ busybox.def.h
BB_FEATURE_TRIVIAL_HELP
+ uname.c has an example of how BB_FEATURE_TRIVIAL_HELP
is to be applied.
| -rw-r--r-- | Makefile | 6 | ||||
| -rw-r--r-- | busybox.def.h | 3 | ||||
| -rw-r--r-- | coreutils/uname.c | 5 | ||||
| -rw-r--r-- | uname.c | 5 |
4 files changed, 11 insertions, 8 deletions
| @@ -96,7 +96,6 @@ ifdef BB_INIT_SCRIPT | |||
| 96 | endif | 96 | endif |
| 97 | 97 | ||
| 98 | all: busybox busybox.links docs | 98 | all: busybox busybox.links docs |
| 99 | .PHONY: all | ||
| 100 | 99 | ||
| 101 | busybox: $(OBJECTS) | 100 | busybox: $(OBJECTS) |
| 102 | $(CC) $(LDFLAGS) -o $@ $^ $(LIBRARIES) | 101 | $(CC) $(LDFLAGS) -o $@ $^ $(LIBRARIES) |
| @@ -111,26 +110,21 @@ busybox.links: busybox.def.h | |||
| 111 | regexp.o nfsmount.o: %.o: %.h | 110 | regexp.o nfsmount.o: %.o: %.h |
| 112 | $(OBJECTS): %.o: busybox.def.h internal.h %.c | 111 | $(OBJECTS): %.o: busybox.def.h internal.h %.c |
| 113 | 112 | ||
| 114 | .PHONY: test tests | ||
| 115 | test tests: | 113 | test tests: |
| 116 | cd tests && $(MAKE) all | 114 | cd tests && $(MAKE) all |
| 117 | 115 | ||
| 118 | .PHONY: clean | ||
| 119 | clean: | 116 | clean: |
| 120 | - rm -f busybox.links *~ *.o core | 117 | - rm -f busybox.links *~ *.o core |
| 121 | - rm -rf _install | 118 | - rm -rf _install |
| 122 | - cd tests && $(MAKE) clean | 119 | - cd tests && $(MAKE) clean |
| 123 | 120 | ||
| 124 | .PHONY: distclean | ||
| 125 | distclean: clean | 121 | distclean: clean |
| 126 | - rm -f busybox | 122 | - rm -f busybox |
| 127 | - cd tests && $(MAKE) distclean | 123 | - cd tests && $(MAKE) distclean |
| 128 | 124 | ||
| 129 | .PHONY: install | ||
| 130 | install: busybox busybox.links | 125 | install: busybox busybox.links |
| 131 | ./install.sh $(PREFIX) | 126 | ./install.sh $(PREFIX) |
| 132 | 127 | ||
| 133 | .PHONY: dist release | ||
| 134 | dist release: distclean | 128 | dist release: distclean |
| 135 | $(MAKE) -C docs clean all | 129 | $(MAKE) -C docs clean all |
| 136 | cd ..; \ | 130 | cd ..; \ |
diff --git a/busybox.def.h b/busybox.def.h index 1880884f9..79eef1d12 100644 --- a/busybox.def.h +++ b/busybox.def.h | |||
| @@ -130,6 +130,9 @@ | |||
| 130 | // normal strings. | 130 | // normal strings. |
| 131 | #define BB_FEATURE_FULL_REGULAR_EXPRESSIONS | 131 | #define BB_FEATURE_FULL_REGULAR_EXPRESSIONS |
| 132 | // | 132 | // |
| 133 | // Use only simple command help | ||
| 134 | #define BB_FEATURE_TRIVIAL_HELP | ||
| 135 | // | ||
| 133 | // Use termios to manipulate the screen ('more' is prettier with this on) | 136 | // Use termios to manipulate the screen ('more' is prettier with this on) |
| 134 | #define BB_FEATURE_USE_TERMIOS | 137 | #define BB_FEATURE_USE_TERMIOS |
| 135 | // | 138 | // |
diff --git a/coreutils/uname.c b/coreutils/uname.c index 9a1cb808a..f1304925d 100644 --- a/coreutils/uname.c +++ b/coreutils/uname.c | |||
| @@ -43,6 +43,7 @@ | |||
| 43 | 43 | ||
| 44 | static const char uname_usage[] = | 44 | static const char uname_usage[] = |
| 45 | "uname [OPTION]...\n\n" | 45 | "uname [OPTION]...\n\n" |
| 46 | #ifndef BB_FEATURE_TRIVIAL_HELP | ||
| 46 | "Print certain system information. With no OPTION, same as -s.\n\n" | 47 | "Print certain system information. With no OPTION, same as -s.\n\n" |
| 47 | "Options:\n" | 48 | "Options:\n" |
| 48 | "\t-a\tprint all information\n" | 49 | "\t-a\tprint all information\n" |
| @@ -52,7 +53,9 @@ static const char uname_usage[] = | |||
| 52 | "\t-s\tprint the operating system name\n" | 53 | "\t-s\tprint the operating system name\n" |
| 53 | 54 | ||
| 54 | "\t-p\tprint the host processor type\n" | 55 | "\t-p\tprint the host processor type\n" |
| 55 | "\t-v\tprint the operating system version\n"; | 56 | "\t-v\tprint the operating system version\n" |
| 57 | #endif | ||
| 58 | ; | ||
| 56 | 59 | ||
| 57 | 60 | ||
| 58 | static void print_element(unsigned int mask, char *element); | 61 | static void print_element(unsigned int mask, char *element); |
| @@ -43,6 +43,7 @@ | |||
| 43 | 43 | ||
| 44 | static const char uname_usage[] = | 44 | static const char uname_usage[] = |
| 45 | "uname [OPTION]...\n\n" | 45 | "uname [OPTION]...\n\n" |
| 46 | #ifndef BB_FEATURE_TRIVIAL_HELP | ||
| 46 | "Print certain system information. With no OPTION, same as -s.\n\n" | 47 | "Print certain system information. With no OPTION, same as -s.\n\n" |
| 47 | "Options:\n" | 48 | "Options:\n" |
| 48 | "\t-a\tprint all information\n" | 49 | "\t-a\tprint all information\n" |
| @@ -52,7 +53,9 @@ static const char uname_usage[] = | |||
| 52 | "\t-s\tprint the operating system name\n" | 53 | "\t-s\tprint the operating system name\n" |
| 53 | 54 | ||
| 54 | "\t-p\tprint the host processor type\n" | 55 | "\t-p\tprint the host processor type\n" |
| 55 | "\t-v\tprint the operating system version\n"; | 56 | "\t-v\tprint the operating system version\n" |
| 57 | #endif | ||
| 58 | ; | ||
| 56 | 59 | ||
| 57 | 60 | ||
| 58 | static void print_element(unsigned int mask, char *element); | 61 | static void print_element(unsigned int mask, char *element); |
