Build issue if LWIP_DHCP is set to 0

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Build issue if LWIP_DHCP is set to 0

Axel Lin
LWIP_DHCP_DOES_ACD_CHECK is default set to 1.
So LWIP_ACD is also set to 1 by default. (#define LWIP_ACD (LWIP_AUTOIP || LWIP_DHCP_DOES_ACD_CHECK))
So When LWIP_DHCP && LWIP_AUTOIP are both 0, I hit below error
#error "If you want to use DHCP ACD checking, you have to define LWIP_DHCP=1, LWIP_ARP=1 and LWIP_ACD=1 in your lwipopts.h"

I'm wondering if it make sense with below change:

diff --git a/src/include/lwip/opt.h b/src/include/lwip/opt.h
index abecdb45..1ccd2a83 100644
--- a/src/include/lwip/opt.h
+++ b/src/include/lwip/opt.h
@@ -927,7 +927,7 @@
  * LWIP_DHCP_DOES_ACD_CHECK==1: Perform address conflict detection on the dhcp address.
  */
 #if !defined LWIP_DHCP_DOES_ACD_CHECK || defined __DOXYGEN__
-#define LWIP_DHCP_DOES_ACD_CHECK        1
+#define LWIP_DHCP_DOES_ACD_CHECK        LWIP_DHCP
 #endif

 /**


_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel
Reply | Threaded
Open this post in threaded view
|

Re: Build issue if LWIP_DHCP is set to 0

Dirk Ziegelmeier-2
Yes, applied your fix. Thanks for reporting!

Dirk


On Mon, Oct 8, 2018 at 9:34 AM Axel Lin <[hidden email]> wrote:
LWIP_DHCP_DOES_ACD_CHECK is default set to 1.
So LWIP_ACD is also set to 1 by default. (#define LWIP_ACD (LWIP_AUTOIP || LWIP_DHCP_DOES_ACD_CHECK))
So When LWIP_DHCP && LWIP_AUTOIP are both 0, I hit below error
#error "If you want to use DHCP ACD checking, you have to define LWIP_DHCP=1, LWIP_ARP=1 and LWIP_ACD=1 in your lwipopts.h"

I'm wondering if it make sense with below change:

diff --git a/src/include/lwip/opt.h b/src/include/lwip/opt.h
index abecdb45..1ccd2a83 100644
--- a/src/include/lwip/opt.h
+++ b/src/include/lwip/opt.h
@@ -927,7 +927,7 @@
  * LWIP_DHCP_DOES_ACD_CHECK==1: Perform address conflict detection on the dhcp address.
  */
 #if !defined LWIP_DHCP_DOES_ACD_CHECK || defined __DOXYGEN__
-#define LWIP_DHCP_DOES_ACD_CHECK        1
+#define LWIP_DHCP_DOES_ACD_CHECK        LWIP_DHCP
 #endif

 /**

_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel

_______________________________________________
lwip-devel mailing list
[hidden email]
https://lists.nongnu.org/mailman/listinfo/lwip-devel