Extract usage information into a separate file.
diff --git a/networking/hostname.c b/networking/hostname.c
index 60f66c0..77b545d 100644
--- a/networking/hostname.c
+++ b/networking/hostname.c
@@ -1,6 +1,6 @@
/* vi: set sw=4 ts=4: */
/*
- * $Id: hostname.c,v 1.11 2000/07/14 01:51:25 kraai Exp $
+ * $Id: hostname.c,v 1.12 2000/07/16 20:57:15 kraai Exp $
* Mini hostname implementation for busybox
*
* Copyright (C) 1999 by Randolph Chung <tausq@debian.org>
@@ -30,21 +30,6 @@
#include <unistd.h>
#include <stdio.h>
-static const char *hostname_usage =
- "hostname [OPTION] {hostname | -F file}\n"
-#ifndef BB_FEATURE_TRIVIAL_HELP
- "\nGet or set the hostname or DNS domain name. If a hostname is given\n"
- "(or a file with the -F parameter), the host name will be set.\n\n"
- "Options:\n"
- "\t-s\t\tShort\n"
-
- "\t-i\t\tAddresses for the hostname\n"
- "\t-d\t\tDNS domain name\n"
- "\t-F FILE\t\tUse the contents of FILE to specify the hostname\n"
-#endif
- ;
-
-
void do_sethostname(char *s, int isfile)
{
FILE *f;
diff --git a/networking/nc.c b/networking/nc.c
index b6afe6f..a544f32 100644
--- a/networking/nc.c
+++ b/networking/nc.c
@@ -40,12 +40,6 @@
#define BUFSIZE 100
-static const char nc_usage[] = "nc [IP] [port]\n"
-#ifndef BB_FEATURE_TRIVIAL_HELP
- "\nNetcat opens a pipe to IP:port\n"
-#endif
- ;
-
int nc_main(int argc, char **argv)
{
int sfd;
diff --git a/networking/nslookup.c b/networking/nslookup.c
index 54f37c8..10d36b2 100644
--- a/networking/nslookup.c
+++ b/networking/nslookup.c
@@ -41,13 +41,6 @@
| + find out how the real nslookup gets the default name server
*/
-static const char nslookup_usage[] = "nslookup [HOST]\n"
-#ifndef BB_FEATURE_TRIVIAL_HELP
- "\nQueries the nameserver for the IP address of the given HOST\n"
-#endif
-;
-
-
/* I have to see how the real nslookup does this.
* I could dig through /etc/resolv.conf, but is there a
* better (programatic) way?
@@ -177,4 +170,4 @@
return( TRUE);
}
-/* $Id: nslookup.c,v 1.10 2000/06/19 17:25:40 andersen Exp $ */
+/* $Id: nslookup.c,v 1.11 2000/07/16 20:57:15 kraai Exp $ */
diff --git a/networking/ping.c b/networking/ping.c
index b2b4880..5f44a68 100644
--- a/networking/ping.c
+++ b/networking/ping.c
@@ -1,6 +1,6 @@
/* vi: set sw=4 ts=4: */
/*
- * $Id: ping.c,v 1.22 2000/07/14 06:49:52 andersen Exp $
+ * $Id: ping.c,v 1.23 2000/07/16 20:57:15 kraai Exp $
* Mini ping implementation for busybox
*
* Copyright (C) 1999 by Randolph Chung <tausq@debian.org>
@@ -174,12 +174,6 @@
/* simple version */
#ifdef BB_FEATURE_SIMPLE_PING
-static const char *ping_usage = "ping host\n"
-#ifndef BB_FEATURE_TRIVIAL_HELP
- "\nSend ICMP ECHO_REQUEST packets to network hosts\n"
-#endif
- ;
-
static char *hostname = NULL;
static void noresp(int ign)
@@ -267,17 +261,6 @@
#else /* ! BB_FEATURE_SIMPLE_PING */
/* full(er) version */
-static const char *ping_usage = "ping [OPTION]... host\n"
-#ifndef BB_FEATURE_TRIVIAL_HELP
- "\nSend ICMP ECHO_REQUEST packets to network hosts.\n\n"
- "Options:\n"
- "\t-c COUNT\tSend only COUNT pings.\n"
- "\t-s SIZE\t\tSend SIZE data bytes in packets (default=56).\n"
- "\t-q\t\tQuiet mode, only displays output at start\n"
- "\t\t\tand when finished.\n"
-#endif
- ;
-
static char *hostname = NULL;
static struct sockaddr_in pingaddr;
static int pingsock = -1;
diff --git a/networking/telnet.c b/networking/telnet.c
index f276035..3e43c4a 100644
--- a/networking/telnet.c
+++ b/networking/telnet.c
@@ -134,14 +134,6 @@
/* Some globals */
static int one = 1;
-static const char telnet_usage[] =
- "telnet host [port]\n"
-#ifndef BB_FEATURE_TRIVIAL_HELP
- "\nTelnet is used to establish interactive communication with another\n"
- "computer over a network using the TELNET protocol.\n"
-#endif
- ;
-
static void doexit(int ev)
{