VirtualBox

Ignore:
Timestamp:
Feb 1, 2023 4:25:48 PM (2 years ago)
Author:
vboxsync
Message:

NetworkServices/*.kmk: Automatic scm cleanups. bugref:10348

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/NetworkServices/NAT/Makefile.kmk

    r98187 r98417  
    3434 endif
    3535
    36 #
    37 # Globals
    38 #
    39 VBOX_PATH_NAT_SRC := $(PATH_SUB_CURRENT)
     36 #
     37 # Globals
     38 #
     39 VBOX_PATH_NAT_SRC := $(PATH_SUB_CURRENT)
    4040
    4141
    42 #
    43 # Hardened stub exe for VBoxNetNAT.
    44 #
     42 #
     43 # Hardened stub exe for VBoxNetNAT.
     44 #
    4545 ifdef VBOX_WITH_HARDENING
    46 PROGRAMS += VBoxNetNATHardened
    47 VBoxNetNATHardened_TEMPLATE = VBoxR3HardenedExe
    48 VBoxNetNATHardened_NAME     = VBoxNetNAT
     46  PROGRAMS += VBoxNetNATHardened
     47  VBoxNetNATHardened_TEMPLATE = VBoxR3HardenedExe
     48  VBoxNetNATHardened_NAME   = VBoxNetNAT
    4949  ifdef VBOX_WITH_AUTOMATIC_DEFS_QUOTING
    50 VBoxNetNATHardened_DEFS     = SERVICE_NAME="VBoxNetNAT"
     50   VBoxNetNATHardened_DEFS  = SERVICE_NAME="VBoxNetNAT"
    5151  else
    52 VBoxNetNATHardened_DEFS     = SERVICE_NAME=\"VBoxNetNAT\"
     52   VBoxNetNATHardened_DEFS  = SERVICE_NAME=\"VBoxNetNAT\"
    5353  endif
    54 VBoxNetNATHardened_SOURCES = VBoxNetNATHardened.cpp
    55 VBoxNetNATHardened_LDFLAGS.win = /SUBSYSTEM:windows
    56 $(call VBOX_SET_VER_INFO_EXE,VBoxNetNATHardened,VirtualBox NAT Engine,$(VBOX_WINDOWS_ICON_FILE)) # Version info / description.
     54  VBoxNetNATHardened_SOURCES = VBoxNetNATHardened.cpp
     55  VBoxNetNATHardened_LDFLAGS.win = /SUBSYSTEM:windows
     56  $(call VBOX_SET_VER_INFO_EXE,VBoxNetNATHardened,VirtualBox NAT Engine,$(VBOX_WINDOWS_ICON_FILE)) # Version info / description.
    5757 endif
    5858
    5959
    60 #
    61 # VBoxNetNAT.
    62 #
     60 #
     61 # VBoxNetNAT.
     62 #
    6363 ifdef VBOX_WITH_HARDENING
    64 DLLS     += VBoxNetNAT
     64  DLLS   += VBoxNetNAT
    6565 else
    66 PROGRAMS += VBoxNetNAT
     66  PROGRAMS += VBoxNetNAT
    6767 endif
    68 VBoxNetNAT_TEMPLATE := $(if-expr defined(VBOX_WITH_HARDENING),VBoxMainDll,VBoxMainClientExe)
    69 VBoxNetNAT_NAME     := VBoxNetNAT
    70 VBoxNetNAT_DEFS      = \
     68 VBoxNetNAT_TEMPLATE := $(if-expr defined(VBOX_WITH_HARDENING),VBoxMainDll,VBoxMainClientExe)
     69 VBoxNetNAT_NAME    := VBoxNetNAT
     70 VBoxNetNAT_DEFS     = \
    7171        IPv6 \
    7272        $(if $(VBOX_WITH_INTNET_SERVICE_IN_R3),VBOX_WITH_INTNET_SERVICE_IN_R3,)
    73 # VBoxNetNAT_DEFS.linux = WITH_VALGRIND # instrument lwip memp.c
    74 VBoxNetNAT_DEFS.win = VBOX_COM_OUTOFPROC_MODULE _WIN32_WINNT=0x501 # Windows XP
    75 # Convince Solaris headers to expose socket stuff we need.
    76 #
    77 # Setting _XOPEN_SOURCE to either 500 or 600 would always work, but
    78 # <sys/feature_tests.h> insists that 600 requires C99 and so it
    79 # explodes for older g++.  It also insists that 500 is NOT to be used
    80 # with C99.
    81 #
    82 # Newer g++ in C++11 mode (formerly known as C++0x) needs 600, so it
    83 # employs sleight of hand to pretend it's C99 to keep feature test
    84 # happy.
    85 #
    86 # Compile the C code with settings that match g++.  This probably
    87 # should be centralized so that whole codebase uses consistent
    88 # settings.
     73 # VBoxNetNAT_DEFS.linux = WITH_VALGRIND # instrument lwip memp.c
     74 VBoxNetNAT_DEFS.win = VBOX_COM_OUTOFPROC_MODULE _WIN32_WINNT=0x501 # Windows XP
     75 # Convince Solaris headers to expose socket stuff we need.
     76 #
     77 # Setting _XOPEN_SOURCE to either 500 or 600 would always work, but
     78 # <sys/feature_tests.h> insists that 600 requires C99 and so it
     79 # explodes for older g++.  It also insists that 500 is NOT to be used
     80 # with C99.
     81 #
     82 # Newer g++ in C++11 mode (formerly known as C++0x) needs 600, so it
     83 # employs sleight of hand to pretend it's C99 to keep feature test
     84 # happy.
     85 #
     86 # Compile the C code with settings that match g++.  This probably
     87 # should be centralized so that whole codebase uses consistent
     88 # settings.
    8989 ifeq ($(KBUILD_TARGET),solaris)
    9090  ifneq ($(VBOX_GCC_VERSION_CXX),)
    9191   if $(VBOX_GCC_VERSION_CXX) >= 40600
    92 # we compile C++ code with -std=c++0x / -std=c++11
    93 VBoxNetNAT_CFLAGS.solaris += -std=c99
    94 VBoxNetNAT_DEFS.solaris += _XOPEN_SOURCE=600
     92    # we compile C++ code with -std=c++0x / -std=c++11
     93    VBoxNetNAT_CFLAGS.solaris += -std=c99
     94    VBoxNetNAT_DEFS.solaris += _XOPEN_SOURCE=600
    9595   else
    96 VBoxNetNAT_DEFS.solaris += _XOPEN_SOURCE=500
     96    VBoxNetNAT_DEFS.solaris += _XOPEN_SOURCE=500
    9797   endif
    9898  endif
    99 VBoxNetNAT_DEFS.solaris += __EXTENSIONS__=1
     99  VBoxNetNAT_DEFS.solaris += __EXTENSIONS__=1
    100100 endif
    101101
    102 # (current dir is for for lwipopts.h)
    103 VBoxNetNAT_INCS += . $(addprefix ../../Devices/Network/lwip-new/,$(LWIP_INCS))
     102 # (current dir is for for lwipopts.h)
     103 VBoxNetNAT_INCS += . $(addprefix ../../Devices/Network/lwip-new/,$(LWIP_INCS))
    104104
    105 VBoxNetNAT_SOURCES = \
    106         VBoxNetLwipNAT.cpp \
    107         ../NetLib/IntNetIf.cpp \
    108         ../NetLib/VBoxNetPortForwardString.cpp \
    109         $(addprefix ../../Devices/Network/lwip-new/,$(LWIP_SOURCES)) \
    110         proxy_pollmgr.c \
    111         proxy_rtadvd.c \
    112         proxy.c \
    113         pxremap.c \
    114         pxtcp.c \
    115         pxudp.c \
    116         pxdns.c \
    117         fwtcp.c \
    118         fwudp.c \
    119         portfwd.c \
    120         proxy_dhcp6ds.c \
    121         proxy_tftpd.c
     105 VBoxNetNAT_SOURCES = \
     106        VBoxNetLwipNAT.cpp \
     107        ../NetLib/IntNetIf.cpp \
     108        ../NetLib/VBoxNetPortForwardString.cpp \
     109        $(addprefix ../../Devices/Network/lwip-new/,$(LWIP_SOURCES)) \
     110        proxy_pollmgr.c \
     111        proxy_rtadvd.c \
     112        proxy.c \
     113        pxremap.c \
     114        pxtcp.c \
     115        pxudp.c \
     116        pxdns.c \
     117        fwtcp.c \
     118        fwudp.c \
     119        portfwd.c \
     120        proxy_dhcp6ds.c \
     121        proxy_tftpd.c
    122122
    123123 ifeq ($(KBUILD_TARGET),win)
    124 VBoxNetNAT_SOURCES += pxping_win.c # unprivileged Icmp API
     124  VBoxNetNAT_SOURCES += pxping_win.c # unprivileged Icmp API
    125125 else
    126 VBoxNetNAT_SOURCES        += pxping.c     # raw sockets
    127 VBoxNetNAT_CFLAGS.linux  += -Wno-address-of-packed-member # Needed for GCC 9.
     126  VBoxNetNAT_SOURCES      += pxping.c     # raw sockets
     127  VBoxNetNAT_CFLAGS.linux += -Wno-address-of-packed-member # Needed for GCC 9.
    128128 endif
    129129
    130 VBoxNetNAT_SOURCES.darwin += rtmon_bsd.c
    131 VBoxNetNAT_SOURCES.freebsd += rtmon_bsd.c
    132 VBoxNetNAT_SOURCES.linux   += rtmon_linux.c
    133 VBoxNetNAT_SOURCES.solaris += rtmon_bsd.c
    134 VBoxNetNAT_SOURCES.win     += \
    135         rtmon_win.c \
    136         RTWinPoll.cpp \
    137         RTWinSocketPair.cpp
     130 VBoxNetNAT_SOURCES.darwin += rtmon_bsd.c
     131 VBoxNetNAT_SOURCES.freebsd += rtmon_bsd.c
     132 VBoxNetNAT_SOURCES.linux  += rtmon_linux.c
     133 VBoxNetNAT_SOURCES.solaris += rtmon_bsd.c
     134 VBoxNetNAT_SOURCES.win    += \
     135        rtmon_win.c \
     136        RTWinPoll.cpp \
     137        RTWinSocketPair.cpp
    138138
    139 VBoxNetNAT_LIBS = \
     139 VBoxNetNAT_LIBS = \
    140140        $(LIB_RUNTIME)
    141 VBoxNetNAT_LIBS.solaris += socket nsl
     141 VBoxNetNAT_LIBS.solaris += socket nsl
    142142
    143 VBoxNetNAT_LDFLAGS.win = /SUBSYSTEM:windows
     143 VBoxNetNAT_LDFLAGS.win = /SUBSYSTEM:windows
    144144
    145 # ifeq ($(VBOX_WITH_HARDENING),)
    146 #  ifn1of ($(KBUILD_TARGET), darwin win)
    147 #   # helper for debugging unprivileged
    148 #   VBoxNetNAT_DEFS += VBOX_RAWSOCK_DEBUG_HELPER
    149 #   VBoxNetNAT_SOURCES += getrawsock.c
    150 #  endif
    151 # endif
     145 # ifeq ($(VBOX_WITH_HARDENING),)
     146 #  ifn1of ($(KBUILD_TARGET), darwin win)
     147 #   # helper for debugging unprivileged
     148 #   VBoxNetNAT_DEFS += VBOX_RAWSOCK_DEBUG_HELPER
     149 #   VBoxNetNAT_SOURCES += getrawsock.c
     150 #  endif
     151 # endif
    152152
    153153
    154154 ifdef VBOX_WITH_HARDENING
    155 $(call VBOX_SET_VER_INFO_DLL,VBoxNetNAT,VirtualBox NAT Engine (dll),$(VBOX_WINDOWS_ICON_FILE)) # Version info / description.
     155  $(call VBOX_SET_VER_INFO_DLL,VBoxNetNAT,VirtualBox NAT Engine (dll),$(VBOX_WINDOWS_ICON_FILE)) # Version info / description.
    156156 else
    157 $(call VBOX_SET_VER_INFO_EXE,VBoxNetNAT,VirtualBox NAT Engine,$(VBOX_WINDOWS_ICON_FILE)) # Version info / description.
     157  $(call VBOX_SET_VER_INFO_EXE,VBoxNetNAT,VirtualBox NAT Engine,$(VBOX_WINDOWS_ICON_FILE)) # Version info / description.
    158158 endif
    159159
Note: See TracChangeset for help on using the changeset viewer.

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