From 812450ebe60d9236ebdd3fde5172260a6cc824a4 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Sun, 12 Jul 2015 09:25:39 -0600 Subject: [PATCH] If NSH or Webclient is selected, make sure that CONFIG_LIBC_NETDB is enabled; reanem dnsclient.h to dns.h --- examples/bridge/bridge_main.c | 2 +- examples/discover/discover_main.c | 2 +- examples/tcpecho/tcpecho_main.c | 2 +- examples/webserver/webserver_main.c | 2 +- examples/wget/wget_main.c | 2 +- examples/xmlrpc/xmlrpc_main.c | 2 +- netutils/webclient/Kconfig | 1 + nshlib/Kconfig | 1 + nshlib/nsh_netinit.c | 2 +- 9 files changed, 9 insertions(+), 7 deletions(-) diff --git a/examples/bridge/bridge_main.c b/examples/bridge/bridge_main.c index 38cecf633..26b8fcb8b 100644 --- a/examples/bridge/bridge_main.c +++ b/examples/bridge/bridge_main.c @@ -55,7 +55,7 @@ #if defined(CONFIG_EXAMPLES_BRIDGE_NET1_DHCPC) || \ defined(CONFIG_EXAMPLES_BRIDGE_NET2_DHCPC) # include -# include +# include # include #endif diff --git a/examples/discover/discover_main.c b/examples/discover/discover_main.c index 1384ec8b5..5a32d02fc 100644 --- a/examples/discover/discover_main.c +++ b/examples/discover/discover_main.c @@ -65,7 +65,7 @@ /* DHCPC may be used in conjunction with any other feature (or not) */ #ifdef CONFIG_EXAMPLES_DISCOVER_DHCPC -# include +# include # include #endif diff --git a/examples/tcpecho/tcpecho_main.c b/examples/tcpecho/tcpecho_main.c index d27e96588..7bc6c566f 100644 --- a/examples/tcpecho/tcpecho_main.c +++ b/examples/tcpecho/tcpecho_main.c @@ -71,7 +71,7 @@ /* DHCPC may be used in conjunction with any other feature (or not) */ #ifdef CONFIG_EXAMPLES_TCPECHO_DHCPC -# include +# include # include #endif diff --git a/examples/webserver/webserver_main.c b/examples/webserver/webserver_main.c index 512c79bda..6fc8e5f47 100644 --- a/examples/webserver/webserver_main.c +++ b/examples/webserver/webserver_main.c @@ -70,7 +70,7 @@ /* DHCPC may be used in conjunction with any other feature (or not) */ #ifdef CONFIG_EXAMPLES_WEBSERVER_DHCPC -# include +# include # include #endif diff --git a/examples/wget/wget_main.c b/examples/wget/wget_main.c index 6459db6c8..9993a0786 100644 --- a/examples/wget/wget_main.c +++ b/examples/wget/wget_main.c @@ -47,7 +47,7 @@ #include #include -#include +#include #include /**************************************************************************** diff --git a/examples/xmlrpc/xmlrpc_main.c b/examples/xmlrpc/xmlrpc_main.c index 184b00484..0cda419d3 100644 --- a/examples/xmlrpc/xmlrpc_main.c +++ b/examples/xmlrpc/xmlrpc_main.c @@ -80,7 +80,7 @@ /* DHCPC may be used in conjunction with any other feature (or not) */ #ifdef CONFIG_EXAMPLES_XMLRPC_DHCPC -# include +# include # include #endif diff --git a/netutils/webclient/Kconfig b/netutils/webclient/Kconfig index d468d63df..e2d5e4855 100644 --- a/netutils/webclient/Kconfig +++ b/netutils/webclient/Kconfig @@ -7,6 +7,7 @@ config NETUTILS_WEBCLIENT bool "uIP web client" default n depends on NET_TCP + select LIBC_NETDB ---help--- Enable support for the uIP web client. diff --git a/nshlib/Kconfig b/nshlib/Kconfig index 886a6012c..41ddc479f 100644 --- a/nshlib/Kconfig +++ b/nshlib/Kconfig @@ -7,6 +7,7 @@ config NSH_LIBRARY bool "NSH Library" default n select NETUTILS_NETLIB if NET + select LIBC_NETDB if NET ---help--- Build the NSH support library. This is used, for example, by examples/nsh in order to implement the full NuttShell (NSH). diff --git a/nshlib/nsh_netinit.c b/nshlib/nsh_netinit.c index 17ef4abb4..fee2175d6 100644 --- a/nshlib/nsh_netinit.c +++ b/nshlib/nsh_netinit.c @@ -69,7 +69,7 @@ #include #if defined(CONFIG_NSH_DHCPC) || defined(CONFIG_NSH_DNS) -# include +# include # include #endif