aboutsummaryrefslogtreecommitdiff
path: root/networking/udhcp
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2006-11-29 11:09:43 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2006-11-29 11:09:43 +0000
commitc61852a02bd2d61682235ba3185173f527313827 (patch)
tree6af2895da70dda926317fac31cd4db6a4b20200c /networking/udhcp
parent601ae1378ba7bb59e9c1a19fcc4ddd7bf9fb2e1b (diff)
downloadbusybox-c61852a02bd2d61682235ba3185173f527313827.tar.gz
fix support for globally disabling --long-options.
(disabling them saves ~4K on fully configured bbox)
Diffstat (limited to 'networking/udhcp')
-rw-r--r--networking/udhcp/dhcpc.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/networking/udhcp/dhcpc.c b/networking/udhcp/dhcpc.c
index f69b687b2..71315ff0a 100644
--- a/networking/udhcp/dhcpc.c
+++ b/networking/udhcp/dhcpc.c
@@ -160,6 +160,7 @@ int udhcpc_main(int argc, char *argv[])
OPT_t = 1 << 16,
OPT_v = 1 << 17,
};
+#if ENABLE_GETOPT_LONG
static const struct option arg_options[] = {
{ "clientid", required_argument, 0, 'c' },
{ "clientid-none", no_argument, 0, 'C' },
@@ -181,7 +182,7 @@ int udhcpc_main(int argc, char *argv[])
{ "retries", required_argument, 0, 't' },
{ 0, 0, 0, 0 }
};
-
+#endif
/* Default options. */
client_config.interface = "eth0";
client_config.script = DEFAULT_SCRIPT;
@@ -191,7 +192,9 @@ int udhcpc_main(int argc, char *argv[])
/* Parse command line */
opt_complementary = "?:c--C:C--c" // mutually exclusive
":hH:Hh"; // -h and -H are the same
+#if ENABLE_GETOPT_LONG
applet_long_options = arg_options;
+#endif
opt = getopt32(argc, argv, "c:CV:fbH:h:F:i:np:qRr:s:T:t:v",
&str_c, &str_V, &str_h, &str_h, &str_F,
&client_config.interface, &client_config.pidfile, &str_r,