Skip to content

Commit ea83a83

Browse files
authored
lwip-2.1.0 IPv6-enabled (#21)
update to lwIP-2.1.0 SACK-out: option IPv6: option fragmentation / reassembly: option
1 parent 163bb82 commit ea83a83

24 files changed

+10328
-295
lines changed

Makefile.arduino

Lines changed: 13 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,20 @@
11

2-
# stable MSS: 536..896
3-
# unstable: 1024 1460
4-
52
%:
6-
make -f makefiles/Makefile.build-lwip2 \
7-
target=arduino \
8-
SDK=../.. \
9-
LWIP_ESP=../../lwip/include \
10-
LWIP_LIB=liblwip2.a \
11-
LWIP_LIB_RELEASE=../../lib/liblwip2.a \
12-
LWIP_INCLUDES_RELEASE=../include \
13-
TOOLS=../../../xtensa-lx106-elf/bin/xtensa-lx106-elf- \
14-
TCP_MSS=536 BUILD=build-536 \
15-
$@
16-
17-
make -f makefiles/Makefile.build-lwip2 \
3+
for v6 in 0 1; do \
4+
for mss in 536 1460; do \
5+
for feat in 0 1; do \
6+
test \( $$feat = 0 \) -a \( $$v6 = 1 \) && continue; \
7+
featname= ;\
8+
test $$feat = 1 && featname=-feat ;\
9+
make -f makefiles/Makefile.build-lwip2 \
1810
target=arduino \
1911
SDK=../.. \
2012
LWIP_ESP=../../lwip/include \
21-
LWIP_LIB=liblwip2_1460.a \
22-
LWIP_LIB_RELEASE=../../lib/liblwip2_1460.a \
13+
LWIP_LIB=liblwip$$((2+4*v6))-$$mss$$featname.a \
14+
LWIP_LIB_RELEASE=../../lib/liblwip$$((2+4*v6))-$$mss$$featname.a \
2315
LWIP_INCLUDES_RELEASE=../include \
2416
TOOLS=../../../xtensa-lx106-elf/bin/xtensa-lx106-elf- \
25-
TCP_MSS=1460 BUILD=build-1460 \
26-
$@
17+
TCP_MSS=$$mss LWIP_FEATURES=$$feat LWIP_IPV6=$$v6 \
18+
BUILD=build-$$mss$$featname-v$$((4+2*v6)) \
19+
$@ ; \
20+
done; done; done

glue-lwip/arch/cc.h

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ typedef uint32_t sys_prot_t; // not really used
6262
#define SYS_ARCH_DECL_PROTECT(lev)
6363
#define SYS_ARCH_PROTECT(lev) os_intr_lock()
6464
#define SYS_ARCH_UNPROTECT(lev) os_intr_unlock()
65+
#define LWIP_NO_CTYPE_H 1
6566

6667
///////////////////////////////
6768
//// DEBUG
@@ -89,14 +90,14 @@ typedef uint32_t sys_prot_t; // not really used
8990
ip4_addr3_16(ipaddr), \
9091
ip4_addr4_16(ipaddr)
9192

92-
// ip_addr / ip_info: do not exist in lwip2 (only in lwip1.4)
93-
struct ip_addr {
93+
// ipv4_addr / ip_info: do not exist in lwip2 (only in lwip1.4)
94+
struct ipv4_addr {
9495
uint32_t addr;
9596
};
9697
struct ip_info {
97-
struct ip_addr ip;
98-
struct ip_addr netmask;
99-
struct ip_addr gw;
98+
struct ipv4_addr ip;
99+
struct ipv4_addr netmask;
100+
struct ipv4_addr gw;
100101
};
101102

102103
///////////////////////////////

0 commit comments

Comments
 (0)