VirtualBox

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

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

Convince Solaris headers to expose socket stuff we need with
-D_XOPEN_SOURCE=500 -DEXTENSIONS=1

-D_XOPEN_SOURCE=600 would also work, but <sys/feature_tests.h> insists
on C99 for it and so explodes for C++. Note that for 500 it insists
on NOT using C99, so when some day we decide to use -std=c99 we are in
for some fun.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.6 KB
Line 
1# $Id: Makefile.kmk 49663 2013-11-26 15:44:59Z 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
48VBoxNetLwipNAT_LIBS = \
49 $(LIB_RUNTIME)
50VBoxNetLwipNAT_LIBS.solaris += socket nsl
51VBoxNetLwipNAT_LDFLAGS.win = /SUBSYSTEM:windows
52
53# Convince Solaris headers to expose socket stuff we need. 600 would
54# also work, but <sys/feature_tests.h> insists on C99 for it and so
55# explodes for C++. Note that for 500 it insists on NOT using C99, so
56# when some day we decide to use -std=c99 we are in for some fun.
57VBoxNetLwipNAT_DEFS.solaris += _XOPEN_SOURCE=500 __EXTENSIONS__=1
58
59VBoxNetLwipNAT_SOURCES += \
60 proxy_pollmgr.c \
61 proxy_rtadvd.c \
62 proxy.c \
63 pxremap.c \
64 pxtcp.c \
65 pxudp.c \
66 pxdns.c \
67 fwtcp.c \
68 fwudp.c \
69 portfwd.c \
70 proxy_dhcp6ds.c \
71 proxy_tftpd.c
72
73VBoxNetLwipNAT_SOURCES.darwin += rtmon_bsd.c
74VBoxNetLwipNAT_SOURCES.freebsd += rtmon_bsd.c
75VBoxNetLwipNAT_SOURCES.linux += rtmon_linux.c
76VBoxNetLwipNAT_SOURCES.solaris += rtmon_bsd.c
77VBoxNetLwipNAT_SOURCES.win += rtmon_win.c
78
79VBoxNetLwipNAT_SOURCES.win += \
80 RTWinPoll.cpp \
81 RTWinSocketPair.cpp
82
83$(eval $(call def_vbox_lwip_public, \
84 VBoxNetLwipNAT, ../../Devices/Network/lwip-new))
85endif
86
87include $(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