VirtualBox

source: vbox/trunk/src/VBox/NetworkServices/NAT/Makefile.kmk@ 50065

Last change on this file since 50065 was 50065, checked in by vboxsync, 11 years ago

Add commented out snippet to use debug helper for raw ICMP sockets.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 3.0 KB
Line 
1# $Id: Makefile.kmk 50065 2014-01-14 01:42:41Z 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
17SUB_DEPTH = ../../../..
18include $(KBUILD_PATH)/subheader.kmk
19
20ifdef VBOX_WITH_LWIP_NAT
21# XXX: do not depend on order
22ifndef LWIP_SOURCES
23 include ../../Devices/Network/lwip-new/Makefile.kmk
24endif
25
26ifdef VBOX_WITH_HARDENING
27 PROGRAMS += VBoxNetLwipNATHardened
28 DLLS += VBoxNetLwipNAT
29else
30 PROGRAMS += VBoxNetLwipNAT
31endif
32
33ifdef VBOX_WITH_HARDENING
34 VBoxNetLwipNATHardened_SOURCES += VBoxNetNATHardened.cpp
35 VBoxNetLwipNATHardened_DEFS += SERVICE_NAME=\"VBoxNetNAT\"
36 VBoxNetLwipNATHardened_TEMPLATE=VBOXR3HARDENEDEXE
37 VBoxNetLwipNATHardened_NAME = VBoxNetNAT
38endif
39
40VBoxNetLwipNAT_TEMPLATE =
41VBoxNetLwipNAT_TEMPLATE := VBOXMAIN$(if-expr defined(VBOX_WITH_HARDENING),DLL,CLIENTEXE)
42VBoxNetLwipNAT_NAME = VBoxNetNAT
43VBoxNetLwipNAT_DEFS += ${LWIP_DEFS} IPv6
44VBoxNetLwipNAT_DEFS.win += VBOX_COM_OUTOFPROC_MODULE _WIN32_WINNT=0x501 # Windows XP
45VBoxNetLwipNAT_SOURCES += VBoxNetLwipNAT.cpp \
46 ../NetLib/VBoxNetBaseService.cpp \
47 ../NetLib/VBoxNetPortForwardString.cpp \
48 ../NetLib/VBoxNetIntIf.cpp \
49 ../NetLib/VBoxNetUDP.cpp \
50 ../NetLib/VBoxNetARP.cpp \
51 ../NetLib/ComHostUtils.cpp
52
53VBoxNetLwipNAT_LIBS = \
54 $(LIB_RUNTIME)
55VBoxNetLwipNAT_LIBS.solaris += socket nsl
56VBoxNetLwipNAT_LDFLAGS.win = /SUBSYSTEM:windows
57
58# Convince Solaris headers to expose socket stuff we need. 600 would
59# also work, but <sys/feature_tests.h> insists on C99 for it and so
60# explodes for C++. Note that for 500 it insists on NOT using C99, so
61# when some day we decide to use -std=c99 we are in for some fun.
62VBoxNetLwipNAT_DEFS.solaris += _XOPEN_SOURCE=500 __EXTENSIONS__=1
63
64VBoxNetLwipNAT_SOURCES += \
65 proxy_pollmgr.c \
66 proxy_rtadvd.c \
67 proxy.c \
68 pxremap.c \
69 pxtcp.c \
70 pxudp.c \
71 pxdns.c \
72 fwtcp.c \
73 fwudp.c \
74 portfwd.c \
75 proxy_dhcp6ds.c \
76 proxy_tftpd.c
77
78ifeq ($(KBUILD_TARGET),win)
79 # unprivileged Icmp API
80 VBoxNetLwipNAT_SOURCES += pxping_win.c
81else
82 # raw sockets
83 VBoxNetLwipNAT_SOURCES += pxping.c
84endif
85
86# ifeq ($(VBOX_WITH_HARDENING),)
87# ifn1of ($(KBUILD_TARGET), darwin win)
88# # helper for debugging unprivileged
89# VBoxNetLwipNAT_SOURCES += getrawsock.c
90# endif
91# endif
92
93VBoxNetLwipNAT_SOURCES.darwin += rtmon_bsd.c
94VBoxNetLwipNAT_SOURCES.freebsd += rtmon_bsd.c
95VBoxNetLwipNAT_SOURCES.linux += rtmon_linux.c
96VBoxNetLwipNAT_SOURCES.solaris += rtmon_bsd.c
97VBoxNetLwipNAT_SOURCES.win += rtmon_win.c
98
99VBoxNetLwipNAT_SOURCES.win += \
100 RTWinPoll.cpp \
101 RTWinSocketPair.cpp
102
103$(eval $(call def_vbox_lwip_public, \
104 VBoxNetLwipNAT, ../../Devices/Network/lwip-new))
105endif
106
107include $(FILE_KBUILD_SUB_FOOTER)
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