VirtualBox

source: vbox/trunk/src/VBox/Devices/Network/lwip-new/Makefile.kmk@ 63005

Last change on this file since 63005 was 63005, checked in by vboxsync, 8 years ago

lwip,nat: Try figure LWIP_NOASSERT in the two lwipopts.h files, linking it to VBOX_ASSERT.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 4.5 KB
Line 
1# $Id: Makefile.kmk 63005 2016-08-04 20:19:20Z vboxsync $
2## @file
3# Adds sources list and defines required to LWIP pre-1.5.0 compilation
4#
5
6#
7# Copyright (C) 2006-2016 Oracle Corporation
8#
9# This file is part of VirtualBox Open Source Edition (OSE), as
10# available from http://www.virtualbox.org. This file is free software;
11# you can redistribute it and/or modify it under the terms of the GNU
12# General Public License (GPL) as published by the Free Software
13# Foundation, in version 2 as it comes in the "COPYING" file of the
14# VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15# hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16#
17
18LWIP_INCS += \
19 src/include \
20 src/include/ipv4 \
21 src/include/ipv6 \
22 vbox/include \
23 vbox
24
25LWIP_SOURCES += \
26 src/api/api_lib.c \
27 src/api/api_msg.c \
28 src/api/err.c \
29 src/api/netbuf.c \
30 src/api/netdb.c \
31 src/api/netifapi.c \
32 src/api/sockets.c \
33 src/api/tcpip.c \
34 src/core/def.c \
35 src/core/dhcp.c \
36 src/core/dns.c \
37 src/core/inet_chksum.c \
38 src/core/init.c \
39 src/core/ipv4/autoip.c \
40 src/core/ipv4/icmp.c \
41 src/core/ipv4/igmp.c \
42 src/core/ipv4/ip4.c \
43 src/core/ipv4/ip4_addr.c \
44 src/core/ipv4/ip_frag.c \
45 src/core/ipv6/dhcp6.c \
46 src/core/ipv6/ethip6.c \
47 src/core/ipv6/icmp6.c \
48 src/core/ipv6/inet6.c \
49 src/core/ipv6/ip6.c \
50 src/core/ipv6/ip6_addr.c \
51 src/core/ipv6/ip6_frag.c \
52 src/core/ipv6/mld6.c \
53 src/core/ipv6/nd6.c \
54 src/core/mem.c \
55 src/core/memp.c \
56 src/core/netif.c \
57 src/core/pbuf.c \
58 src/core/raw.c \
59 src/core/stats.c \
60 src/core/sys.c \
61 src/core/tcp.c \
62 src/core/tcp_in.c \
63 src/core/tcp_out.c \
64 src/core/timers.c \
65 src/core/udp.c \
66 src/netif/etharp.c \
67 vbox/sys_arch.c \
68 vbox/VBoxLwipCore.cpp
69
70# LWIP_SOURCES += \
71# src/core/snmp/asn1_dec.c \
72# src/core/snmp/asn1_enc.c \
73# src/core/snmp/mib2.c \
74# src/core/snmp/mib_structs.c \
75# src/core/snmp/msg_in.c \
76# src/core/snmp/msg_out.c \
77
78# LWIP_SOURCES += \
79# src/netif/slipif.c \
80
81# LWIP_SOURCES += \
82# src/netif/ppp/auth.c \
83# src/netif/ppp/chap.c \
84# src/netif/ppp/chpms.c \
85# src/netif/ppp/fsm.c \
86# src/netif/ppp/ipcp.c \
87# src/netif/ppp/lcp.c \
88# src/netif/ppp/magic.c \
89# src/netif/ppp/md5.c \
90# src/netif/ppp/pap.c \
91# src/netif/ppp/ppp.c \
92# src/netif/ppp/ppp_oe.c \
93# src/netif/ppp/randm.c \
94# src/netif/ppp/vj.c
95
96
97
98define _def_vbox_lwip_use # VAR_BaseName, path/to/lwip/dir
99 $(strip $1)_SOURCES += \
100 $(foreach file, $(LWIP_SOURCES), $(strip $2)/$(file))
101
102 # if individual lwip files need special settings, add them here:
103 # $(strip $2)/src/foo/bar.c_CFLAGS += -magic
104endef
105
106
107define def_vbox_lwip_flags # PROTO_BaseName, VAR_BaseName, path/to/lwip/dir
108 # add anything configured for the component via PROTO_BaseName
109 $(foreach suffix, INCS DEFS,
110 $(if $(value $(strip $1)_LWIP_$(suffix)),
111 $(eval #
112 $(strip $2)_$(suffix) += $(value $(strip $1)_LWIP_$(suffix))
113 )))
114
115 # add lwip's own includes
116 $(strip $2)_INCS += $(foreach incdir, $(LWIP_INCS), $(strip $3)/$(incdir))
117endef
118
119
120###
121### Call this if you want to expose lwip to your component as a whole.
122### In this case individual lwip files (added to _SOURCES of your
123### component) will pick up lwip includes etc from your component
124### settings.
125###
126### This is, for example, how NetworkServices/NAT uses it.
127###
128define def_vbox_lwip_public # VAR_BaseName, path/to/lwip/dir
129 $(eval $(call _def_vbox_lwip_use, $1, $2))
130 $(eval $(call def_vbox_lwip_flags, $1, $1, $2))
131endef
132
133
134###
135### Call this if you want to expose lwip only to a few selected files.
136### In this case each lwip file is configured with lwip includes etc
137### separately and you are supposed to call def_vbox_lwip_flags
138### yourself for those of your files that use lwip.
139###
140### This is, for example, how Devices uses it.
141###
142define def_vbox_lwip_private # VAR_BaseName, path/to/lwip/dir
143 $(eval $(call _def_vbox_lwip_use, $1, $2))
144 $(foreach file, $(LWIP_SOURCES), \
145 $(eval $(call def_vbox_lwip_flags, $1, $(strip $2)/$(file), $2)))
146endef
147
148
149ifeq ($(USERNAME), vvl)
150$(foreach lwip_file, $(LWIP_SOURCES), $(eval $(lwip_file)_DEFS=RTMEM_WRAP_TO_EF_APIS))
151
152LWIPTEST_SOURCES= Network/lwip-new/test/unit/core/test_mem.c \
153 Network/lwip-new/test/unit/etharp/test_etharp.c \
154 Network/lwip-new/test/unit/lwip_unittests.c \
155 Network/lwip-new/test/unit/tcp/tcp_helper.c \
156 Network/lwip-new/test/unit/tcp/test_tcp.c \
157 Network/lwip-new/test/unit/tcp/test_tcp_oos.c \
158 Network/lwip-new/test/unit/udp/test_udp.c
159endif
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette