1 | # $Id: Makefile.kmk 47992 2013-08-22 14:38:19Z vboxsync $
|
---|
2 | ## @file
|
---|
3 | #
|
---|
4 |
|
---|
5 | #
|
---|
6 | # Copyright (C) 2006-2012 Oracle Corporation
|
---|
7 | #
|
---|
8 | # This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
9 | # available from http://www.virtualbox.org. This file is free software;
|
---|
10 | # you can redistribute it and/or modify it under the terms of the GNU
|
---|
11 | # General Public License (GPL) as published by the Free Software
|
---|
12 | # Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
13 | # VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
14 | # hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
15 | #
|
---|
16 |
|
---|
17 | SUB_DEPTH = ../../../..
|
---|
18 | include $(KBUILD_PATH)/subheader.kmk
|
---|
19 |
|
---|
20 | define def_vbox_nat_network_service_sources
|
---|
21 | $(1)_SOURCES += $2/$3
|
---|
22 | endef
|
---|
23 |
|
---|
24 | define def_vbox_nat_network_service_incs
|
---|
25 | $(1)_INCS += $2/$3
|
---|
26 | endef
|
---|
27 |
|
---|
28 | ifdef VBOX_WITH_LWIP_NAT
|
---|
29 |
|
---|
30 | ifdef VBOX_WITH_HARDENING
|
---|
31 | PROGRAMS += VBoxNetLwipNATHardened
|
---|
32 | DLLS += VBoxNetLwipNAT
|
---|
33 | else
|
---|
34 | PROGRAMS += VBoxNetLwipNAT
|
---|
35 | endif
|
---|
36 |
|
---|
37 | ifdef VBOX_WITH_HARDENING
|
---|
38 | VBoxNetLwipNATHardened_SOURCES += VBoxNetNATHardened.cpp
|
---|
39 | VBoxNetLwipNATHardened_DEFS += SERVICE_NAME=\"VBoxNetNAT\"
|
---|
40 | VBoxNetLwipNATHardened_TEMPLATE=VBOXR3HARDENEDEXE
|
---|
41 | VBoxNetLwipNATHardened_NAME = VBoxNetNAT
|
---|
42 | endif
|
---|
43 |
|
---|
44 | VBoxNetLwipNAT_TEMPLATE =
|
---|
45 | VBoxNetLwipNAT_TEMPLATE := VBOXMAIN$(if-expr defined(VBOX_WITH_HARDENING),DLL,CLIENTEXE)
|
---|
46 | VBoxNetLwipNAT_NAME = VBoxNetNAT
|
---|
47 | VBoxNetLwipNAT_INCS += ../../Devices/Network \
|
---|
48 | ../../Devices/Network/lwip-new/vbox # testproxy.h
|
---|
49 | VBoxNetLwipNAT_DEFS += ${LWIP_DEFS}
|
---|
50 | VBoxNetLwipNAT_DEFS.win += _WIN32_WINNT=0x501 # Windows XP
|
---|
51 | VBoxNetLwipNAT_SOURCES += VBoxNetLwipNAT.cpp \
|
---|
52 | ../NetLib/VBoxNetBaseService.cpp \
|
---|
53 | ../NetLib/VBoxNetPortForwardString.cpp
|
---|
54 | VBoxNetLwipNAT_LIBS = \
|
---|
55 | $(LIB_RUNTIME)
|
---|
56 | VBoxNetLwipNAT_LIBS.solaris += socket nsl
|
---|
57 | VBoxNetLwipNAT_LDFLAGS.win = /SUBSYSTEM:windows
|
---|
58 |
|
---|
59 | #
|
---|
60 | # Note: not spaces please in "Devices,$("
|
---|
61 | #
|
---|
62 | $(foreach file,$(LWIP_SOURCES) $(LWIP_NAT_SOURCES),$(eval $(call def_vbox_nat_network_service_sources, VBoxNetLwipNAT, ../../Devices,$(file))))
|
---|
63 |
|
---|
64 | $(foreach incs,$(LWIP_INCS),$(eval $(call def_vbox_nat_network_service_incs, VBoxNetLwipNAT, ../../Devices,$(incs))))
|
---|
65 |
|
---|
66 | endif
|
---|
67 |
|
---|
68 | ifdef VBOX_WITH_TESTCASES
|
---|
69 | PROGRAMS += tstNetPfAddressPortPairParse
|
---|
70 |
|
---|
71 | tstNetPfAddressPortPairParse_TEMPLATE = VBOXR3TSTEXE
|
---|
72 | #tstNetPfAddressPortPairParse_INSTTYPE = none
|
---|
73 | tstNetPfAddressPortPairParse_SOURCES = ../NetLib/testcase/tstNetPfAddressPortPairParse.cpp \
|
---|
74 | ../NetLib/VBoxNetPortForwardString.cpp
|
---|
75 | endif
|
---|
76 |
|
---|
77 | include $(FILE_KBUILD_SUB_FOOTER)
|
---|