Changeset 38183 in vbox
- Timestamp:
- Jul 26, 2011 1:20:51 PM (13 years ago)
- Location:
- trunk
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
-
trunk/src/VBox/HostDrivers/Support/Makefile.kmk
r38082 r38183 5 5 6 6 # 7 # Copyright (C) 2006-201 0Oracle Corporation7 # Copyright (C) 2006-2011 Oracle Corporation 8 8 # 9 9 # This file is part of VirtualBox Open Source Edition (OSE), as … … 51 51 SYSMODS.solaris += vboxdrv 52 52 endif 53 INSTALLS.linux += vboxdrv-mod vboxdrv-sh vboxdrv-dkms54 INSTALLS.freebsd += vboxdrv-mod vboxdrv-sh53 INSTALLS.linux += vboxdrv-mod 54 INSTALLS.freebsd += vboxdrv-mod 55 55 56 56 # … … 185 185 endif 186 186 ifdef VBOX_WITH_VMMR0_DISABLE_PREEMPTION 187 VBoxDrv_DEFS+= VBOX_WITH_VMMR0_DISABLE_PREEMPTION187 VBoxDrv_DEFS += VBOX_WITH_VMMR0_DISABLE_PREEMPTION 188 188 endif 189 189 VBoxDrv_SDKS = W2K3DDK WINPSDKINCS … … 240 240 vboxdrv_DEFS = KBUILD_MODNAME=KBUILD_STR\(vboxdrv\) KBUILD_BASENAME=KBUILD_STR\(vboxdrv\) MODULE IN_RT_R0 IN_SUP_R0 CONFIG_VBOXDRV_AS_MISC 241 241 ifdef VBOX_LINUX_VERSION_2_4 242 vboxdrv_DEFS+= EXPORT_SYMTAB242 vboxdrv_DEFS += EXPORT_SYMTAB 243 243 endif 244 244 vboxdrv_INCS := \ … … 252 252 SUPDrvSem.c 253 253 ifndef VBOX_LINUX_VERSION_2_4 254 vboxdrv_SOURCES+= \255 $(KBUILD_TARGET)/SUPDrv-$(KBUILD_TARGET).mod.c254 vboxdrv_SOURCES += \ 255 $(KBUILD_TARGET)/SUPDrv-$(KBUILD_TARGET).mod.c 256 256 endif 257 257 … … 261 261 # 262 262 vboxdrv-mod_INST = bin/src/vboxdrv/ 263 vboxdrv-mod_MODE = a+r,u+w 264 vboxdrv-mod_SOURCES = $(subst ",,$(FILES_VBOXDRV_NOBIN)) #" 265 vboxdrv-mod_SOURCES += \ 263 vboxdrv-mod_SOURCES = \ 264 $(subst $(DQUOTE),,$(FILES_VBOXDRV_NOBIN)) \ 266 265 $(vboxdrv-mod_0_OUTDIR)/Makefile 266 vboxdrv-mod_EXEC_SOURCES = \ 267 $(subst $(DQUOTE),,$(FILES_VBOXDRV_BIN)) \ 268 $(vboxdrv-mod_0_OUTDIR)/build_in_tmp \ 269 $(PATH_ROOT)/src/VBox/HostDrivers/linux/do_Module.symvers 267 270 vboxdrv-mod_CLEAN = \ 268 $(vboxdrv-mod_0_OUTDIR)/Makefile 269 270 vboxdrv-sh_INST = bin/src/vboxdrv/ 271 vboxdrv-sh_MODE = a+rx,u+w 272 vboxdrv-sh_SOURCES = $(subst ",,$(FILES_VBOXDRV_BIN)) #" 273 vboxdrv-sh_SOURCES += \ 274 $(vboxdrv-sh_0_OUTDIR)/build_in_tmp \ 275 $(PATH_ROOT)/src/VBox/HostDrivers/linux/do_Module.symvers 276 vboxdrv-sh_CLEAN = \ 277 $(PATH_TARGET)/vboxdrv-sh-1.dep \ 278 $(vboxdrv-sh_0_OUTDIR)/build_in_tmp 271 $(vboxdrv-mod_0_OUTDIR)/Makefile \ 272 $(PATH_TARGET)/vboxdrv-mod-1.dep \ 273 $(vboxdrv-mod_0_OUTDIR)/build_in_tmp 279 274 280 275 # Scripts needed for building the kernel modules 281 276 282 $$(vboxdrv- sh_0_OUTDIR)/build_in_tmp: \277 $$(vboxdrv-mod_0_OUTDIR)/build_in_tmp: \ 283 278 $(PATH_ROOT)/src/VBox/HostDrivers/linux/build_in_tmp \ 284 279 $(VBOX_VERSION_STAMP) \ … … 291 286 $(QUIET)chmod 0755 $@ 292 287 293 includedep $(PATH_TARGET)/vboxdrv- sh-1.dep288 includedep $(PATH_TARGET)/vboxdrv-mod-1.dep 294 289 $$(vboxdrv-mod_0_OUTDIR)/Makefile: \ 295 290 $(PATH_SUB_CURRENT)/linux/Makefile \ … … 302 297 $(QUIET)$(CP) -f $< $@ 303 298 endif 304 %$(QUIET2)$(RM) -f -- $(PATH_TARGET)/vboxdrv-sh-1.dep 305 %$(QUIET2)$(APPEND) '$(PATH_TARGET)/vboxdrv-sh-1.dep' 'Support/linux/Makefile_VBOX_HARDENED=$(VBOX_WITH_HARDENING)' 299 %$(QUIET2)$(APPEND) -t '$(PATH_TARGET)/vboxdrv-mod-1.dep' 'Support/linux/Makefile_VBOX_HARDENED=$(VBOX_WITH_HARDENING)' 306 300 307 301 endif # real linux … … 360 354 # Common manual loader script. 361 355 INSTALLS += Scripts 362 Scripts_INST 363 Scripts_ SOURCES = \356 Scripts_INST = $(INST_DIST) 357 Scripts_EXEC_SOURCES = \ 364 358 darwin/load.sh 365 359 … … 417 411 # 418 412 vboxdrv-mod_INST = bin/src/vboxdrv/ 419 vboxdrv-mod_MODE = a+r,u+w 420 vboxdrv-mod_SOURCES = $(subst ",,$(FILES_VBOXDRV_NOBIN)) #" 421 vboxdrv-mod_SOURCES += \ 413 vboxdrv-mod_SOURCES = \ 414 $(subst $(DQUOTE),,$(FILES_VBOXDRV_NOBIN)) \ 422 415 $(vboxdrv-mod_0_OUTDIR)/Makefile 423 416 vboxdrv-mod_CLEAN = \ … … 429 422 | $$(dir $$@) 430 423 $(call MSG_TOOL,Creating,,$@) 424 $(QUIET)$(RM) -f -- $@ 431 425 ifndef VBOX_WITH_HARDENING 432 426 $(QUIET)$(SED) -e "s;-DVBOX_WITH_HARDENING;;g" --output $@ $< -
trunk/src/VBox/HostDrivers/VBoxNetAdp/Makefile.kmk
r38136 r38183 20 20 21 21 if1of ($(KBUILD_TARGET), solaris darwin linux freebsd) 22 #23 # VBoxNetAdp - Virtual Network Adapter24 # Note! On Solaris the name has to be <= 8 chars long.25 #22 # 23 # VBoxNetAdp - Virtual Network Adapter 24 # Note! On Solaris the name has to be <= 8 chars long. 25 # 26 26 ifdef VBOX_WITH_VBOXDRV 27 SYSMODS += VBoxNetAdp28 VBoxNetAdp_TEMPLATE = VBOXR0DRV29 VBoxNetAdp_INST = $(INST_VBOXNETADP)$(if $(eq $(KBUILD_TARGET),darwin),Contents/MacOS/)30 VBoxNetAdp_NAME.solaris = vboxnet31 VBoxNetAdp_NAME.linux = vboxnetadp32 VBoxNetAdp_NAME.freebsd = vboxnetadp33 VBoxNetAdp_NOINST.linux = true34 VBoxNetAdp_DEPS.solaris += $(VBOX_SVN_REV_KMK)35 VBoxNetAdp_DEFS = IN_RT_R0 VBOX_SVN_REV=$(VBOX_SVN_REV) IN_SUP_STATIC36 VBoxNetAdp_DEFS.linux = KBUILD_MODNAME=KBUILD_STR\(vboxnetadp\) KBUILD_BASENAME=KBUILD_STR\(vboxnetadp\) MODULE37 #VBoxNetAdp_LDFLAGS.darwin = -v -Wl,-whyload -Wl,-v -Wl,-whatsloaded38 VBoxNetAdp_LDFLAGS.solaris += -N misc/gld -N drv/vboxdrv39 VBoxNetAdp_INCS.linux := \40 $(PATH_ROOT)/src/VBox/Runtime/r0drv/linux41 VBoxNetAdp_INCS = \42 .43 VBoxNetAdp_SOURCES.darwin = \44 darwin/VBoxNetAdp-darwin.cpp \45 VBoxNetAdp.c46 VBoxNetAdp_SOURCES.solaris = \47 solaris/VBoxNetAdp-solaris.c48 VBoxNetAdp_SOURCES.linux = \49 linux/VBoxNetAdp-linux.c \50 VBoxNetAdp.c51 VBoxNetAdp_SOURCES.freebsd = \52 freebsd/VBoxNetAdp-freebsd.c \53 VBoxNetAdp.c54 VBoxNetAdp_SOURCES =55 #VBoxNetAdp_SOURCES = \56 # VBoxNetAdp.c57 VBoxNetAdp_LIBS += \58 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB)27 SYSMODS += VBoxNetAdp 28 VBoxNetAdp_TEMPLATE = VBOXR0DRV 29 VBoxNetAdp_INST = $(INST_VBOXNETADP)$(if $(eq $(KBUILD_TARGET),darwin),Contents/MacOS/) 30 VBoxNetAdp_NAME.solaris = vboxnet 31 VBoxNetAdp_NAME.linux = vboxnetadp 32 VBoxNetAdp_NAME.freebsd = vboxnetadp 33 VBoxNetAdp_NOINST.linux = true 34 VBoxNetAdp_DEPS.solaris += $(VBOX_SVN_REV_KMK) 35 VBoxNetAdp_DEFS = IN_RT_R0 VBOX_SVN_REV=$(VBOX_SVN_REV) IN_SUP_STATIC 36 VBoxNetAdp_DEFS.linux = KBUILD_MODNAME=KBUILD_STR\(vboxnetadp\) KBUILD_BASENAME=KBUILD_STR\(vboxnetadp\) MODULE 37 #VBoxNetAdp_LDFLAGS.darwin = -v -Wl,-whyload -Wl,-v -Wl,-whatsloaded 38 VBoxNetAdp_LDFLAGS.solaris += -N misc/gld -N drv/vboxdrv 39 VBoxNetAdp_INCS.linux := \ 40 $(PATH_ROOT)/src/VBox/Runtime/r0drv/linux 41 VBoxNetAdp_INCS = \ 42 . 43 VBoxNetAdp_SOURCES.darwin = \ 44 darwin/VBoxNetAdp-darwin.cpp \ 45 VBoxNetAdp.c 46 VBoxNetAdp_SOURCES.solaris = \ 47 solaris/VBoxNetAdp-solaris.c 48 VBoxNetAdp_SOURCES.linux = \ 49 linux/VBoxNetAdp-linux.c \ 50 VBoxNetAdp.c 51 VBoxNetAdp_SOURCES.freebsd = \ 52 freebsd/VBoxNetAdp-freebsd.c \ 53 VBoxNetAdp.c 54 VBoxNetAdp_SOURCES = 55 #VBoxNetAdp_SOURCES = \ 56 # VBoxNetAdp.c 57 VBoxNetAdp_LIBS += \ 58 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB) 59 59 endif 60 60 endif … … 64 64 # 65 65 ifeq ($(KBUILD_TARGET),darwin) 66 INSTALLS += VBoxNetAdp.kext67 VBoxNetAdp.kext_INST = $(INST_VBOXNETADP)Contents/68 VBoxNetAdp.kext_SOURCES = \69 $(VBoxNetAdp.kext_0_OUTDIR)/Info.plist70 VBoxNetAdp.kext_CLEAN = \71 $(VBoxNetAdp.kext_0_OUTDIR)/Info.plist66 INSTALLS += VBoxNetAdp.kext 67 VBoxNetAdp.kext_INST = $(INST_VBOXNETADP)Contents/ 68 VBoxNetAdp.kext_SOURCES = \ 69 $(VBoxNetAdp.kext_0_OUTDIR)/Info.plist 70 VBoxNetAdp.kext_CLEAN = \ 71 $(VBoxNetAdp.kext_0_OUTDIR)/Info.plist 72 72 73 73 $$(VBoxNetAdp.kext_0_OUTDIR)/Info.plist: $(PATH_SUB_CURRENT)/darwin/Info.plist $(VBOX_VERSION_MK) | $$(dir $$@) … … 85 85 $< 86 86 87 INSTALLS.darwin += Scripts-darwin-adp88 Scripts-darwin-adp_INST = $(INST_DIST)89 Scripts-darwin-adp_SOURCES = \90 darwin/loadnetadp.sh87 INSTALLS.darwin += Scripts-darwin-adp 88 Scripts-darwin-adp_INST = $(INST_DIST) 89 Scripts-darwin-adp_EXEC_SOURCES = \ 90 darwin/loadnetadp.sh 91 91 endif # darwin 92 92 … … 96 96 # files_vboxnetadp defines VBOX_VBOXNETADP_SOURCES. 97 97 # 98 INSTALLS += VBoxNetAdp-src 98 99 include $(PATH_SUB_CURRENT)/linux/files_vboxnetadp 99 INSTALLS += VBoxNetAdp-src VBoxNetAdp-sh100 100 VBoxNetAdp-src_INST = bin/src/vboxnetadp/ 101 VBoxNetAdp-src_MODE = a+r,u+w 102 VBoxNetAdp-src_SOURCES = $(subst ",,$(VBOX_VBOXNETADP_SOURCES)) #" 103 VBoxNetAdp-src_SOURCES+= \ 101 VBoxNetAdp-src_SOURCES = \ 102 $(subst $(DQUOTE),,$(VBOX_VBOXNETADP_SOURCES)) \ 104 103 $(VBoxNetAdp-src_0_OUTDIR)/Makefile 105 VBoxNetAdp-src_CLEAN = \ 106 $(VBoxNetAdp-src_0_OUTDIR)/Makefile \ 107 $(PATH_TARGET)/VBoxNetAdp-src-1.dep 104 VBoxNetAdp-src_EXEC_SOURCES = \ 105 $(VBoxNetAdp-src_0_OUTDIR)/build_in_tmp \ 106 $(PATH_ROOT)/src/VBox/HostDrivers/linux/do_Module.symvers 107 VBoxNetAdp-src_CLEAN = \ 108 $(VBoxNetAdp-src_0_OUTDIR)/Makefile \ 109 $(PATH_TARGET)/VBoxNetAdp-src-1.dep \ 110 $(VBoxNetAdp-src_0_OUTDIR)/build_in_tmp 108 111 109 VBoxNetAdp-sh_INST = bin/src/vboxnetadp/ 110 VBoxNetAdp-sh_MODE = a+rx,u+w 111 VBoxNetAdp-sh_SOURCES = \ 112 $(VBoxNetAdp-sh_0_OUTDIR)/build_in_tmp \ 113 $(PATH_ROOT)/src/VBox/HostDrivers/linux/do_Module.symvers 114 VBoxNetAdp-sh_CLEAN = $(VBoxNetAdp-sh_0_OUTDIR)/build_in_tmp 115 116 117 includedep $(PATH_TARGET)/VBoxNetAdp-src-1.dep 112 # Scripts needed for building the kernel modules 113 includedep $(PATH_TARGET)/VBoxNetAdp-src-1.dep 118 114 $$(VBoxNetAdp-src_0_OUTDIR)/Makefile: \ 119 115 $(PATH_SUB_CURRENT)/linux/Makefile \ 120 116 $$(if $$(eq $$(VBoxNetAdp/linux/Makefile_VBOX_HARDENED),$$(VBOX_WITH_HARDENING)),,FORCE) \ 121 117 | $$(dir $$@) 122 ifndef VBOX_WITH_HARDENING 118 $(QUIET)$(RM) -f -- $@ 119 ifndef VBOX_WITH_HARDENING 123 120 $(QUIET)$(SED) -e "s;-DVBOX_WITH_HARDENING;;g" --output $@ $< 124 else121 else 125 122 $(QUIET)$(CP) -f $< $@ 126 endif 127 %$(QUIET2)$(RM) -f -- $(PATH_TARGET)/VBoxNetAdp-src-1.dep 128 %$(QUIET2)$(APPEND) '$(PATH_TARGET)/VBoxNetAdp-src-1.dep' 'VBoxNetAdp/linux/Makefile_VBOX_HARDENED=$(VBOX_WITH_HARDENING)' 123 endif 124 %$(QUIET2)$(APPEND) -t '$(PATH_TARGET)/VBoxNetAdp-src-1.dep' 'VBoxNetAdp/linux/Makefile_VBOX_HARDENED=$(VBOX_WITH_HARDENING)' 129 125 130 ## Scripts needed for building the kernel modules131 126 132 $$(VBoxNetAdp-s h_0_OUTDIR)/build_in_tmp: \127 $$(VBoxNetAdp-src_0_OUTDIR)/build_in_tmp: \ 133 128 $(PATH_ROOT)/src/VBox/HostDrivers/linux/build_in_tmp \ 134 129 $(VBOX_VERSION_STAMP) \ 135 130 | $$(dir $$@) 136 131 $(call MSG_TOOL,Creating,,$@) 132 $(QUIET)$(RM) -f -- $@ 137 133 $(QUIET)$(SED) -e "s;_VERSION_;${VBOX_VERSION_STRING};g; s;_MODULE_;vboxnetadp;g; s;_BUILDTYPE_;${KBUILD_TYPE};g" --output $@ $< 138 134 $(QUIET)chmod 0755 $@ … … 145 141 # files_vboxnetadp defines VBOX_VBOXNETADP_SOURCES. 146 142 # 143 INSTALLS += VBoxNetAdp-src 147 144 include $(PATH_SUB_CURRENT)/freebsd/files_vboxnetadp 148 INSTALLS += VBoxNetAdp-src 149 VBoxNetAdp-src_INST = bin/src/vboxnetadp/ 150 VBoxNetAdp-src_MODE = a+r,u+w 151 VBoxNetAdp-src_SOURCES = $(subst ",,$(VBOX_VBOXNETADP_SOURCES)) #" 152 VBoxNetAdp-src_SOURCES+= \ 145 VBoxNetAdp-src_INST = bin/src/vboxnetadp/ 146 VBoxNetAdp-src_SOURCES = \ 147 $(subst $(DQUOTE),,$(VBOX_VBOXNETADP_SOURCES)) \ 153 148 $(VBoxNetAdp-src_0_OUTDIR)/Makefile 154 VBoxNetAdp-src_CLEAN 149 VBoxNetAdp-src_CLEAN = \ 155 150 $(VBoxNetAdp-src_0_OUTDIR)/Makefile \ 156 151 … … 159 154 $$(if $$(eq $$(VBoxNetAdp/freebsd/Makefile_VBOX_HARDENED),$$(VBOX_WITH_HARDENING)),,FORCE) \ 160 155 | $$(dir $$@) 161 ifndef VBOX_WITH_HARDENING 156 $(QUIET)$(RM) -f -- $@ 157 ifndef VBOX_WITH_HARDENING 162 158 $(QUIET)$(SED) -e "s;-DVBOX_WITH_HARDENING;;g" --output $@ $< 163 else159 else 164 160 $(QUIET)$(CP) -f $< $@ 165 endif161 endif 166 162 167 163 endif # freebsd -
trunk/src/VBox/HostDrivers/VBoxNetFlt/Makefile.kmk
r38082 r38183 21 21 22 22 if1of ($(KBUILD_TARGET), darwin win) # this ifeq must go, see @todo around elif 23 # 24 # VBoxNetFlt.sys - The mixed case driver. 25 # 26 SYSMODS += VBoxNetFlt 27 VBoxNetFlt_TEMPLATE = VBOXR0DRV 28 VBoxNetFlt_INST = $(INST_VBOXNETFLT)$(if $(eq $(KBUILD_TARGET),darwin),Contents/MacOS/) 29 if defined(VBOX_SIGNING_MODE) && "$(KBUILD_TARGET)" == "win" 30 VBoxNetFlt_NOINST = true 31 endif 32 VBoxNetFlt_DEFS = IN_RT_R0 IN_SUP_STATIC 33 VBoxNetFlt_INCS = . 34 VBoxNetFlt_SOURCES.darwin = \ 35 darwin/VBoxNetFlt-darwin.cpp 36 #VBoxNetFlt_SOURCES.darwin += \ 37 # darwin/VBoxNetAdapter-darwin.cpp 38 VBoxNetFlt_SDKS.win = WINDDKWLH WINPSDKINCS 39 VBoxNetFlt_SOURCES.win = \ 40 win/drv/VBoxNetFltP-win.cpp \ 41 win/drv/VBoxNetFltM-win.cpp \ 42 win/drv/VBoxNetFltRt-win.cpp \ 43 win/drv/VBoxNetFlt-win.rc 44 # with WINDDKWLH the WIN9X_COMPAT_SPINLOCK is needed to avoid inline declaration of KeInitializeSpinLock 45 # otherwise the linker would complain about dumplicate _KeInitializeSpinLock@4 definition 46 # in ntoskrnl.lib and our object files 47 VBoxNetFlt_DEFS.win += WIN9X_COMPAT_SPINLOCK=1 48 VBoxNetFlt_DEFS.win += VBOXNETFLT_STATIC_CONFIG 49 VBoxNetFlt_DEFS.win += VBOXNETFLT_NO_PACKET_QUEUE 50 VBoxNetFlt_DEFS.win += NDIS_MINIPORT_DRIVER NDIS_WDM=1 BINARY_COMPATIBLE=0 51 VBoxNetFlt_DEFS.win += NDIS50_MINIPORT=1 NDIS50=1 52 ifdef VBOX_LOOPBACK_USEFLAGS 53 VBoxNetFlt_DEFS.win += VBOX_LOOPBACK_USEFLAGS 54 endif 55 VBoxNetFlt_SOURCES = VBoxNetFlt.c 56 #VBoxNetFlt_LDFLAGS.darwin = -v -Wl,-whyload -Wl,-v -Wl,-whatsloaded 57 VBoxNetFlt_LDFLAGS.win.x86 = -Entry:DriverEntry@8 58 VBoxNetFlt_LDFLAGS.win.amd64 = -Entry:DriverEntry 59 VBoxNetFlt_LIBS.win = \ 60 $(PATH_SDK_WINDDKWLH_LIB)/ntoskrnl.lib \ 61 $(PATH_SDK_WINDDKWLH_LIB)/hal.lib \ 62 $(PATH_SDK_WINDDKWLH_LIB)/ndis.lib \ 63 $(PATH_STAGE_LIB)/RuntimeR0Drv$(VBOX_SUFF_LIB) 64 VBoxNetFlt_LIBS = \ 65 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB) 66 67 darwin/VBoxNetFlt-darwin.cpp_DEFS = VBOX_SVN_REV=$(VBOX_SVN_REV) 23 # 24 # VBoxNetFlt.sys - The mixed case driver. 25 # 26 SYSMODS += VBoxNetFlt 27 VBoxNetFlt_TEMPLATE = VBOXR0DRV 28 VBoxNetFlt_INST = $(INST_VBOXNETFLT)$(if $(eq $(KBUILD_TARGET),darwin),Contents/MacOS/) 29 if defined(VBOX_SIGNING_MODE) && "$(KBUILD_TARGET)" == "win" 30 VBoxNetFlt_NOINST = true 31 endif 32 VBoxNetFlt_DEFS = IN_RT_R0 IN_SUP_STATIC 33 VBoxNetFlt_INCS = . 34 VBoxNetFlt_SOURCES.darwin = \ 35 darwin/VBoxNetFlt-darwin.cpp 36 VBoxNetFlt_SDKS.win = WINDDKWLH WINPSDKINCS 37 VBoxNetFlt_SOURCES.win = \ 38 win/drv/VBoxNetFltP-win.cpp \ 39 win/drv/VBoxNetFltM-win.cpp \ 40 win/drv/VBoxNetFltRt-win.cpp \ 41 win/drv/VBoxNetFlt-win.rc 42 # with WINDDKWLH the WIN9X_COMPAT_SPINLOCK is needed to avoid inline declaration of KeInitializeSpinLock 43 # otherwise the linker would complain about dumplicate _KeInitializeSpinLock@4 definition 44 # in ntoskrnl.lib and our object files 45 VBoxNetFlt_DEFS.win += WIN9X_COMPAT_SPINLOCK=1 46 VBoxNetFlt_DEFS.win += VBOXNETFLT_STATIC_CONFIG 47 VBoxNetFlt_DEFS.win += VBOXNETFLT_NO_PACKET_QUEUE 48 VBoxNetFlt_DEFS.win += NDIS_MINIPORT_DRIVER NDIS_WDM=1 BINARY_COMPATIBLE=0 49 VBoxNetFlt_DEFS.win += NDIS50_MINIPORT=1 NDIS50=1 50 ifdef VBOX_LOOPBACK_USEFLAGS 51 VBoxNetFlt_DEFS.win += VBOX_LOOPBACK_USEFLAGS 52 endif 53 VBoxNetFlt_SOURCES = VBoxNetFlt.c 54 #VBoxNetFlt_LDFLAGS.darwin = -v -Wl,-whyload -Wl,-v -Wl,-whatsloaded 55 VBoxNetFlt_LDFLAGS.win.x86 = -Entry:DriverEntry@8 56 VBoxNetFlt_LDFLAGS.win.amd64 = -Entry:DriverEntry 57 VBoxNetFlt_LIBS.win = \ 58 $(PATH_SDK_WINDDKWLH_LIB)/ntoskrnl.lib \ 59 $(PATH_SDK_WINDDKWLH_LIB)/hal.lib \ 60 $(PATH_SDK_WINDDKWLH_LIB)/ndis.lib \ 61 $(PATH_STAGE_LIB)/RuntimeR0Drv$(VBOX_SUFF_LIB) 62 VBoxNetFlt_LIBS = \ 63 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB) 64 65 darwin/VBoxNetFlt-darwin.cpp_DEFS = VBOX_SVN_REV=$(VBOX_SVN_REV) 68 66 69 67 70 68 # Darwin extras. 71 69 ifeq ($(KBUILD_TARGET),darwin) 72 INSTALLS += VBoxNetFlt.kext73 VBoxNetFlt.kext_INST = $(INST_VBOXNETFLT)Contents/74 VBoxNetFlt.kext_SOURCES = \75 $(VBoxNetFlt.kext_0_OUTDIR)/Info.plist76 VBoxNetFlt.kext_CLEAN = \77 $(VBoxNetFlt.kext_0_OUTDIR)/Info.plist70 INSTALLS += VBoxNetFlt.kext 71 VBoxNetFlt.kext_INST = $(INST_VBOXNETFLT)Contents/ 72 VBoxNetFlt.kext_SOURCES = \ 73 $(VBoxNetFlt.kext_0_OUTDIR)/Info.plist 74 VBoxNetFlt.kext_CLEAN = \ 75 $(VBoxNetFlt.kext_0_OUTDIR)/Info.plist 78 76 79 77 $$(VBoxNetFlt.kext_0_OUTDIR)/Info.plist: $(PATH_SUB_CURRENT)/darwin/Info.plist $(VBOX_VERSION_MK) | $$(dir $$@) … … 91 89 $< 92 90 93 INSTALLS.darwin += Scripts-darwin94 Scripts-darwin_INST = $(INST_DIST)95 Scripts-darwin_SOURCES = \96 darwin/loadnetflt.sh91 INSTALLS.darwin += Scripts-darwin 92 Scripts-darwin_INST = $(INST_DIST) 93 Scripts-darwin_EXEC_SOURCES = \ 94 darwin/loadnetflt.sh 97 95 endif # darwin 98 96 99 97 100 98 ifeq ($(KBUILD_TARGET),win) 101 # 102 # Windows extras. 103 # 104 INSTALLS.win += VBoxNetFlt-inf 105 VBoxNetFlt-inf_INST = $(INST_BIN) 106 VBoxNetFlt-inf_MODE = a+r,u+w 107 VBoxNetFlt-inf_SOURCES = \ 108 $(PATH_TARGET)/VBoxNetFltCat.dir/VBoxNetFlt.inf \ 109 $(PATH_TARGET)/VBoxNetFltCat.dir/VBoxNetFltM.inf 110 VBoxNetFlt-inf_CLEAN = $(VBoxNetFlt-inf_SOURCES) 111 VBoxNetFlt-inf_BLDDIRS = $(PATH_TARGET)/VBoxNetFltCat.dir 99 # 100 # Windows extras. 101 # 102 INSTALLS.win += VBoxNetFlt-inf 103 VBoxNetFlt-inf_INST = $(INST_BIN) 104 VBoxNetFlt-inf_SOURCES = \ 105 $(PATH_TARGET)/VBoxNetFltCat.dir/VBoxNetFlt.inf \ 106 $(PATH_TARGET)/VBoxNetFltCat.dir/VBoxNetFltM.inf 107 VBoxNetFlt-inf_CLEAN = $(VBoxNetFlt-inf_SOURCES) 108 VBoxNetFlt-inf_BLDDIRS = $(PATH_TARGET)/VBoxNetFltCat.dir 112 109 113 110 $(PATH_TARGET)/VBoxNetFltCat.dir/VBoxNetFlt.inf: $(PATH_SUB_CURRENT)/win/drv/VBoxNetFlt.inf $(MAKEFILE_CURRENT) | $$(dir $$@) … … 141 138 endif # signing 142 139 143 #144 # WinNetConfig - static library with host network interface config API145 #146 LIBRARIES.win += WinNetConfig147 WinNetConfig_TEMPLATE = VBOXR3STATIC148 WinNetConfig_DEFS = _WIN32_WINNT=0x0501 _UNICODE UNICODE149 WinNetConfig_SDKS = WINPSDK W2K3DDK150 WinNetConfig_SOURCES = \151 win/cfg/VBoxNetCfg.cpp152 WinNetConfig_INCS.win += $(PATH_TOOL_$(VBOX_VCC_TOOL)_INC)153 154 #155 # NetFltInstall156 #157 PROGRAMS.win += NetFltInstall158 NetFltInstall_TEMPLATE = VBOXR3STATIC159 NetFltInstall_SDKS = WINPSDK W2K3DDK VBOX_NTDLL160 NetFltInstall_SOURCES = win/tools/VBoxNetFltInstall.cpp161 NetFltInstall_LIBS = \162 $(WinNetConfig_1_TARGET) \163 $(VBoxDrvCfg_1_TARGET) \164 $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/comsupp.lib \165 $(PATH_SDK_WINPSDK_LIB)/WbemUuid.Lib166 167 168 #169 # NetFltUninstall170 #171 PROGRAMS.win += NetFltUninstall172 NetFltUninstall_TEMPLATE = VBOXR3STATIC173 NetFltUninstall_SDKS = WINPSDK W2K3DDK VBOX_NTDLL174 NetFltUninstall_SOURCES = win/tools/VBoxNetFltUninstall.cpp175 NetFltUninstall_LIBS = \176 $(WinNetConfig_1_TARGET) \177 $(VBoxDrvCfg_1_TARGET) \178 $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/comsupp.lib \179 $(PATH_SDK_WINPSDK_LIB)/WbemUuid.Lib180 181 #182 # NetAdpInstall183 #184 PROGRAMS.win += NetAdpInstall185 NetAdpInstall_TEMPLATE = VBOXR3STATIC186 NetAdpInstall_SDKS = WINPSDK W2K3DDK VBOX_NTDLL187 NetAdpInstall_SOURCES = win/tools/VBoxNetAdpInstall.cpp188 NetAdpInstall_LIBS = \189 $(WinNetConfig_1_TARGET) \190 $(VBoxDrvCfg_1_TARGET) \191 $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/comsupp.lib \192 $(PATH_SDK_WINPSDK_LIB)/WbemUuid.Lib193 194 195 #196 # NetAdpUninstall197 #198 PROGRAMS.win += NetAdpUninstall199 NetAdpUninstall_TEMPLATE = VBOXR3STATIC200 NetAdpUninstall_SDKS = WINPSDK W2K3DDK VBOX_NTDLL201 NetAdpUninstall_SOURCES = win/tools/VBoxNetAdpUninstall.cpp202 NetAdpUninstall_LIBS = \203 $(WinNetConfig_1_TARGET) \204 $(VBoxDrvCfg_1_TARGET) \205 $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/comsupp.lib \206 $(PATH_SDK_WINPSDK_LIB)/WbemUuid.Lib207 208 #209 # VBoxNetFltNobj210 #211 DLLS.win += VBoxNetFltNobj212 if defined(VBOX_SIGNING_MODE) 213 VBoxNetFltNobj_NOINST = true 214 endif 215 VBoxNetFltNobj_TEMPLATE = VBOXR3STATIC 216 VBoxNetFltNobj_SDKS = WINPSDK W2K3DDK VBOX_NTDLL217 VBoxNetFltNobj_DEFS = _WIN32_WINNT=0x0500 WIN32 _ATL_STATIC_REGISTRY218 VBoxNetFltNobj_INCS = \219 $(VBoxNetFltNobj_0_OUTDIR)220 VBoxNetFltNobj_SOURCES = \221 win/nobj/VBoxNetFltNobj.cpp \222 win/nobj/VBoxNetFltNobj.def \223 win/nobj/VBoxNetFltNobj.rc224 VBoxNetFltNobj_LIBS = \225 $(PATH_TOOL_$(VBOX_VCC_TOOL)_ATLMFC_LIB)/atls$(VBOX_VCC_CRT_TYPE).lib226 #VBoxNetFltNobj_INTERMEDIATES =227 VBoxNetFltNobj_DEPS = \228 $(VBoxNetFltNobj_0_OUTDIR)/VBoxNetFltNobjT_i.c \229 $(VBoxNetFltNobj_0_OUTDIR)/VBoxNetFltNobjT_p.c \230 $(VBoxNetFltNobj_0_OUTDIR)/VBoxNetFltNobjT.h \231 $(VBoxNetFltNobj_0_OUTDIR)/dlldata.c \232 $(VBoxNetFltNobj_0_OUTDIR)/VBoxNetFltNobjT.tlb233 VBoxNetFltNobj_CLEAN = $(VBoxNetFltNobj_DEPS)234 235 VBOXNETFLT_NOBJ_IDL ?= $(EXEC_X86_WIN32) $(call VBOX_FN_MAKE_WIN_PATH,$(firstword $(wildcard \236 $(PATH_SDK_WINPSDK_BIN)/Midl.Exe\237 $(PATH_SDK_WINPSDK)/Bin/Midl.Exe\238 $(PATH_DEVTOOLS)/win.x86/bin/midl.exe\239 ) Sorry_Cannot_Find_The_Midl_Compiler_In_The_PSDK))140 # 141 # WinNetConfig - static library with host network interface config API 142 # 143 LIBRARIES.win += WinNetConfig 144 WinNetConfig_TEMPLATE = VBOXR3STATIC 145 WinNetConfig_DEFS = _WIN32_WINNT=0x0501 _UNICODE UNICODE 146 WinNetConfig_SDKS = WINPSDK W2K3DDK 147 WinNetConfig_SOURCES = \ 148 win/cfg/VBoxNetCfg.cpp 149 WinNetConfig_INCS.win += $(PATH_TOOL_$(VBOX_VCC_TOOL)_INC) 150 151 # 152 # NetFltInstall 153 # 154 PROGRAMS.win += NetFltInstall 155 NetFltInstall_TEMPLATE = VBOXR3STATIC 156 NetFltInstall_SDKS = WINPSDK W2K3DDK VBOX_NTDLL 157 NetFltInstall_SOURCES = win/tools/VBoxNetFltInstall.cpp 158 NetFltInstall_LIBS = \ 159 $(WinNetConfig_1_TARGET) \ 160 $(VBoxDrvCfg_1_TARGET) \ 161 $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/comsupp.lib \ 162 $(PATH_SDK_WINPSDK_LIB)/WbemUuid.Lib 163 164 165 # 166 # NetFltUninstall 167 # 168 PROGRAMS.win += NetFltUninstall 169 NetFltUninstall_TEMPLATE = VBOXR3STATIC 170 NetFltUninstall_SDKS = WINPSDK W2K3DDK VBOX_NTDLL 171 NetFltUninstall_SOURCES = win/tools/VBoxNetFltUninstall.cpp 172 NetFltUninstall_LIBS = \ 173 $(WinNetConfig_1_TARGET) \ 174 $(VBoxDrvCfg_1_TARGET) \ 175 $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/comsupp.lib \ 176 $(PATH_SDK_WINPSDK_LIB)/WbemUuid.Lib 177 178 # 179 # NetAdpInstall 180 # 181 PROGRAMS.win += NetAdpInstall 182 NetAdpInstall_TEMPLATE = VBOXR3STATIC 183 NetAdpInstall_SDKS = WINPSDK W2K3DDK VBOX_NTDLL 184 NetAdpInstall_SOURCES = win/tools/VBoxNetAdpInstall.cpp 185 NetAdpInstall_LIBS = \ 186 $(WinNetConfig_1_TARGET) \ 187 $(VBoxDrvCfg_1_TARGET) \ 188 $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/comsupp.lib \ 189 $(PATH_SDK_WINPSDK_LIB)/WbemUuid.Lib 190 191 192 # 193 # NetAdpUninstall 194 # 195 PROGRAMS.win += NetAdpUninstall 196 NetAdpUninstall_TEMPLATE = VBOXR3STATIC 197 NetAdpUninstall_SDKS = WINPSDK W2K3DDK VBOX_NTDLL 198 NetAdpUninstall_SOURCES = win/tools/VBoxNetAdpUninstall.cpp 199 NetAdpUninstall_LIBS = \ 200 $(WinNetConfig_1_TARGET) \ 201 $(VBoxDrvCfg_1_TARGET) \ 202 $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/comsupp.lib \ 203 $(PATH_SDK_WINPSDK_LIB)/WbemUuid.Lib 204 205 # 206 # VBoxNetFltNobj 207 # 208 DLLS.win += VBoxNetFltNobj 209 VBoxNetFltNobj_TEMPLATE = VBOXR3STATIC 210 if defined(VBOX_SIGNING_MODE) 211 VBoxNetFltNobj_NOINST = true 212 endif 213 VBoxNetFltNobj_SDKS = WINPSDK W2K3DDK VBOX_NTDLL 214 VBoxNetFltNobj_DEFS = _WIN32_WINNT=0x0500 WIN32 _ATL_STATIC_REGISTRY 215 VBoxNetFltNobj_INCS = \ 216 $(VBoxNetFltNobj_0_OUTDIR) 217 VBoxNetFltNobj_SOURCES = \ 218 win/nobj/VBoxNetFltNobj.cpp \ 219 win/nobj/VBoxNetFltNobj.def \ 220 win/nobj/VBoxNetFltNobj.rc 221 VBoxNetFltNobj_LIBS = \ 222 $(PATH_TOOL_$(VBOX_VCC_TOOL)_ATLMFC_LIB)/atls$(VBOX_VCC_CRT_TYPE).lib 223 #VBoxNetFltNobj_INTERMEDIATES = 224 VBoxNetFltNobj_DEPS = \ 225 $(VBoxNetFltNobj_0_OUTDIR)/VBoxNetFltNobjT_i.c \ 226 $(VBoxNetFltNobj_0_OUTDIR)/VBoxNetFltNobjT_p.c \ 227 $(VBoxNetFltNobj_0_OUTDIR)/VBoxNetFltNobjT.h \ 228 $(VBoxNetFltNobj_0_OUTDIR)/dlldata.c \ 229 $(VBoxNetFltNobj_0_OUTDIR)/VBoxNetFltNobjT.tlb 230 VBoxNetFltNobj_CLEAN = $(VBoxNetFltNobj_DEPS) 231 232 VBOXNETFLT_NOBJ_IDL ?= $(EXEC_X86_WIN32) $(call VBOX_FN_MAKE_WIN_PATH,$(firstword $(wildcard \ 233 $(PATH_SDK_WINPSDK_BIN)/Midl.Exe\ 234 $(PATH_SDK_WINPSDK)/Bin/Midl.Exe\ 235 $(PATH_DEVTOOLS)/win.x86/bin/midl.exe\ 236 ) Sorry_Cannot_Find_The_Midl_Compiler_In_The_PSDK)) 240 237 241 238 $$(VBoxNetFltNobj_0_OUTDIR)/VBoxNetFltNobjT_i.c \ … … 252 249 $(call VBOX_FN_MAKE_WIN_PATH,$<) 253 250 254 #255 # VBoxNetAdp.sys - The VirtualBox Adapter miniport driver.256 #257 SYSMODS.win += VBoxNetAdp258 VBoxNetAdp_TEMPLATE = VBOXR0DRV259 #VBoxNetAdp_INST = $(INST_VBOXNETADP)251 # 252 # VBoxNetAdp.sys - The VirtualBox Adapter miniport driver. 253 # 254 SYSMODS.win += VBoxNetAdp 255 VBoxNetAdp_TEMPLATE = VBOXR0DRV 256 #VBoxNetAdp_INST = $(INST_VBOXNETADP) 260 257 if defined(VBOX_SIGNING_MODE) 261 VBoxNetAdp_NOINST = true262 endif 263 VBoxNetAdp_DEFS = IN_RT_R0 IN_SUP_STATIC264 VBoxNetAdp_INCS := $(PATH_SUB_CURRENT)265 VBoxNetAdp_SDKS = WINDDKWLH WINPSDKINCS266 VBoxNetAdp_SOURCES = \267 VBoxNetFlt.c \268 win/drv/VBoxNetFltM-win.cpp \269 win/drv/VBoxNetFltRt-win.cpp \270 win/drv/VBoxNetFlt-win.rc271 VBoxNetAdp_DEFS += VBOXNETFLT_STATIC_CONFIG VBOXNETADP272 VBoxNetAdp_DEFS.win += VBOXNETFLT_NO_PACKET_QUEUE273 VBoxNetAdp_DEFS += NDIS_MINIPORT_DRIVER NDIS_WDM=1 BINARY_COMPATIBLE=0274 VBoxNetAdp_DEFS += NDIS50_MINIPORT=1 NDIS50=1275 VBoxNetAdp_LDFLAGS.win.x86 = -Entry:DriverEntry@8276 VBoxNetAdp_LDFLAGS.win.amd64 = -Entry:DriverEntry277 VBoxNetAdp_LIBS.win = \278 $(PATH_SDK_W2K3DDK_LIB)/ntoskrnl.lib \279 $(PATH_SDK_W2K3DDK_LIB)/hal.lib \280 $(PATH_SDK_W2K3DDK_LIB)/ndis.lib \281 $(PATH_STAGE_LIB)/RuntimeR0Drv$(VBOX_SUFF_LIB)282 VBoxNetAdp_LIBS = \283 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB)284 285 286 INSTALLS.win += VBoxNetAdp-inf287 VBoxNetAdp-inf_INST = $(INST_BIN)288 VBoxNetAdp-inf_MODE = a+r,u+w289 VBoxNetAdp-inf_SOURCES = \290 $(PATH_TARGET)/VBoxNetAdpCat.dir/VBoxNetAdp.inf291 VBoxNetAdp-inf_CLEAN = $(VBoxNetAdp-inf_SOURCES)292 VBoxNetAdp-inf_BLDDIRS = $(PATH_TARGET)/VBoxNetAdpCat.dir258 VBoxNetAdp_NOINST = true 259 endif 260 VBoxNetAdp_DEFS = IN_RT_R0 IN_SUP_STATIC 261 VBoxNetAdp_INCS := $(PATH_SUB_CURRENT) 262 VBoxNetAdp_SDKS = WINDDKWLH WINPSDKINCS 263 VBoxNetAdp_SOURCES = \ 264 VBoxNetFlt.c \ 265 win/drv/VBoxNetFltM-win.cpp \ 266 win/drv/VBoxNetFltRt-win.cpp \ 267 win/drv/VBoxNetFlt-win.rc 268 VBoxNetAdp_DEFS += VBOXNETFLT_STATIC_CONFIG VBOXNETADP 269 VBoxNetAdp_DEFS.win += VBOXNETFLT_NO_PACKET_QUEUE 270 VBoxNetAdp_DEFS += NDIS_MINIPORT_DRIVER NDIS_WDM=1 BINARY_COMPATIBLE=0 271 VBoxNetAdp_DEFS += NDIS50_MINIPORT=1 NDIS50=1 272 VBoxNetAdp_LDFLAGS.win.x86 = -Entry:DriverEntry@8 273 VBoxNetAdp_LDFLAGS.win.amd64 = -Entry:DriverEntry 274 VBoxNetAdp_LIBS.win = \ 275 $(PATH_SDK_W2K3DDK_LIB)/ntoskrnl.lib \ 276 $(PATH_SDK_W2K3DDK_LIB)/hal.lib \ 277 $(PATH_SDK_W2K3DDK_LIB)/ndis.lib \ 278 $(PATH_STAGE_LIB)/RuntimeR0Drv$(VBOX_SUFF_LIB) 279 VBoxNetAdp_LIBS = \ 280 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB) 281 282 283 INSTALLS.win += VBoxNetAdp-inf 284 VBoxNetAdp-inf_INST = $(INST_BIN) 285 VBoxNetAdp-inf_MODE = a+r,u+w 286 VBoxNetAdp-inf_SOURCES = \ 287 $(PATH_TARGET)/VBoxNetAdpCat.dir/VBoxNetAdp.inf 288 VBoxNetAdp-inf_CLEAN = $(VBoxNetAdp-inf_SOURCES) 289 VBoxNetAdp-inf_BLDDIRS = $(PATH_TARGET)/VBoxNetAdpCat.dir 293 290 294 291 $(PATH_TARGET)/VBoxNetAdpCat.dir/VBoxNetAdp.inf: $(PATH_SUB_CURRENT)/win/drv/VBoxNetAdp.inf $(MAKEFILE_CURRENT) | $$(dir $$@) … … 320 317 # 321 318 ifdef VBOX_WITH_VBOXDRV 322 SYSMODS += vboxnetflt 323 vboxnetflt_TEMPLATE = VBOXR0DRV 324 vboxnetflt_NAME.solaris = vboxflt 325 vboxnetflt_DEFS.linux = KBUILD_MODNAME=KBUILD_STR\(vboxnetflt\) KBUILD_BASENAME=KBUILD_STR\(vboxnetflt\) MODULE 326 vboxnetflt_DEFS = IN_RT_R0 327 vboxnetflt_DEPS.solaris += $(VBOX_SVN_REV_KMK) 328 vboxnetflt_NOINST.linux = true 329 vboxnetflt_INCS.linux := \ 330 $(PATH_ROOT)/src/VBox/Runtime/r0drv/linux 331 vboxnetflt_INCS := \ 332 $(PATH_SUB_CURRENT) 333 vboxnetflt_LDFLAGS.solaris += -N drv/vboxdrv -N misc/ctf 334 vboxnetflt_LIBS = \ 335 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB) 336 ## @todo vboxflt should resolves all the IPRT bits from vboxdrv. 337 #vboxnetflt_LIBS += \ 338 # $(PATH_STAGE_LIB)/RuntimeR0Drv$(VBOX_SUFF_LIB) 339 vboxnetflt_SOURCES.linux = linux/VBoxNetFlt-linux.c 340 vboxnetflt_SOURCES.solaris = solaris/VBoxNetFlt-solaris.c 341 vboxnetflt_SOURCES.freebsd = freebsd/VBoxNetFlt-freebsd.c 342 vboxnetflt_SOURCES = VBoxNetFlt.c 343 solaris/VBoxNetFlt-solaris.c_DEFS = VBOX_SVN_REV=$(VBOX_SVN_REV) 319 SYSMODS += vboxnetflt 320 vboxnetflt_TEMPLATE = VBOXR0DRV 321 vboxnetflt_NAME.solaris = vboxflt 322 vboxnetflt_DEFS.linux = KBUILD_MODNAME=KBUILD_STR\(vboxnetflt\) KBUILD_BASENAME=KBUILD_STR\(vboxnetflt\) MODULE 323 vboxnetflt_DEFS = IN_RT_R0 324 vboxnetflt_DEPS.solaris += $(VBOX_SVN_REV_KMK) 325 vboxnetflt_NOINST.linux = true 326 vboxnetflt_INCS.linux := \ 327 $(PATH_ROOT)/src/VBox/Runtime/r0drv/linux 328 vboxnetflt_INCS := \ 329 $(PATH_SUB_CURRENT) 330 vboxnetflt_LDFLAGS.solaris += -N drv/vboxdrv -N misc/ctf 331 vboxnetflt_LIBS = \ 332 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB) 333 ## @todo vboxflt should resolves all the IPRT bits from vboxdrv. 334 #vboxnetflt_LIBS += \ 335 # $(PATH_STAGE_LIB)/RuntimeR0Drv$(VBOX_SUFF_LIB) 336 vboxnetflt_SOURCES.linux = linux/VBoxNetFlt-linux.c 337 vboxnetflt_SOURCES.solaris = solaris/VBoxNetFlt-solaris.c 338 vboxnetflt_SOURCES.freebsd = freebsd/VBoxNetFlt-freebsd.c 339 vboxnetflt_SOURCES = VBoxNetFlt.c 340 solaris/VBoxNetFlt-solaris.c_DEFS = VBOX_SVN_REV=$(VBOX_SVN_REV) 341 344 342 ifdef VBOX_WITH_NETFLT_CROSSBOW 345 SYSMODS += vboxnetbow 346 vboxnetbow_TEMPLATE = VBOXR0DRV 347 vboxnetbow_NAME = vboxbow 348 vboxnetbow_DEFS = vboxnetflt_DEFS VBOX_WITH_NETFLT_CROSSBOW 349 vboxnetbow_DEPS += $(VBOX_SVN_REV_KMK) 350 vboxnetbow_INCS := $(PATH_SUB_CURRENT) 351 vboxnetbow_LDFLAGS += -N drv/vboxdrv -N drv/vnic -N misc/mac -N misc/dls 352 vboxnetbow_LIBS = \ 353 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB) 354 vboxnetbow_SOURCES.solaris = solaris/VBoxNetFltBow-solaris.c 355 vboxnetbow_SOURCES = VBoxNetFlt.c 356 solaris/VBoxNetFltBow-solaris.c_DEFS = VBOX_SVN_REV=$(VBOX_SVN_REV) 343 SYSMODS += vboxnetbow 344 vboxnetbow_TEMPLATE = VBOXR0DRV 345 vboxnetbow_NAME = vboxbow 346 vboxnetbow_DEFS = vboxnetflt_DEFS VBOX_WITH_NETFLT_CROSSBOW 347 vboxnetbow_INCS := $(PATH_SUB_CURRENT) 348 vboxnetbow_LDFLAGS += -N drv/vboxdrv -N drv/vnic -N misc/mac -N misc/dls 349 vboxnetbow_LIBS = \ 350 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB) 351 vboxnetbow_SOURCES.solaris = solaris/VBoxNetFltBow-solaris.c 352 vboxnetbow_SOURCES = VBoxNetFlt.c 353 solaris/VBoxNetFltBow-solaris.c_DEFS = VBOX_SVN_REV=$(VBOX_SVN_REV) 357 354 endif # VBOX_WITH_NETFLT_CROSSBOW 358 355 endif # VBOX_WITH_VBOXDRV … … 368 365 INSTALLS += VBoxNetFlt-src VBoxNetFlt-sh 369 366 VBoxNetFlt-src_INST = bin/src/vboxnetflt/ 370 VBoxNetFlt-src_MODE = a+r,u+w 371 VBoxNetFlt-src_SOURCES = $(subst ",,$(VBOX_VBOXNETFLT_SOURCES)) #" 372 VBoxNetFlt-src_SOURCES+= \ 367 VBoxNetFlt-src_SOURCES = \ 368 $(subst $(DQUOTE),,$(VBOX_VBOXNETFLT_SOURCES)) \ 373 369 $(VBoxNetFlt-src_0_OUTDIR)/Makefile 370 VBoxNetFlt-src_EXEC_SOURCES = \ 371 $(VBoxNetFlt-src_0_OUTDIR)/build_in_tmp \ 372 $(PATH_ROOT)/src/VBox/HostDrivers/linux/do_Module.symvers 374 373 VBoxNetFlt-src_CLEAN = \ 375 $(VBoxNetFlt-src_0_OUTDIR)/Makefile \ 376 $(PATH_TARGET)/VBoxNetFlt-src-1.dep 377 378 VBoxNetFlt-sh_INST = bin/src/vboxnetflt/ 379 VBoxNetFlt-sh_MODE = a+rx,u+w 380 VBoxNetFlt-sh_SOURCES = \ 381 $(VBoxNetFlt-sh_0_OUTDIR)/build_in_tmp \ 382 $(PATH_ROOT)/src/VBox/HostDrivers/linux/do_Module.symvers 383 VBoxNetFlt-sh_CLEAN = $(VBoxNetFlt-sh_0_OUTDIR)/build_in_tmp 384 374 $(VBoxNetFlt-src_0_OUTDIR)/Makefile \ 375 $(PATH_TARGET)/VBoxNetFlt-src-1.dep \ 376 $(VBoxNetFlt-src_0_OUTDIR)/build_in_tmp 377 378 # Scripts needed for building the kernel module. 385 379 386 380 includedep $(PATH_TARGET)/VBoxNetFlt-src-1.dep … … 389 383 $$(if $$(eq $$(VBoxNetFlt/linux/Makefile_VBOX_HARDENED),$$(VBOX_WITH_HARDENING)),,FORCE) \ 390 384 | $$(dir $$@) 385 $(QUIET)$(RM) -f -- $@ 391 386 ifndef VBOX_WITH_HARDENING 392 387 $(QUIET)$(SED) -e "s;-DVBOX_WITH_HARDENING;;g" --output $@ $< … … 397 392 %$(QUIET2)$(APPEND) '$(PATH_TARGET)/VBoxNetFlt-src-1.dep' 'VBoxNetFlt/linux/Makefile_VBOX_HARDENED=$(VBOX_WITH_HARDENING)' 398 393 399 # Script needed for building the kernel module 400 $$(VBoxNetFlt-sh_0_OUTDIR)/build_in_tmp: \ 394 $$(VBoxNetFlt-src_0_OUTDIR)/build_in_tmp: \ 401 395 $(PATH_ROOT)/src/VBox/HostDrivers/linux/build_in_tmp \ 402 396 $(VBOX_VERSION_STAMP) \ 403 397 | $$(dir $$@) 404 398 $(call MSG_TOOL,Creating,,$@) 399 $(QUIET)$(RM) -f -- $@ 405 400 $(QUIET)$(SED) -e "s;_VERSION_;${VBOX_VERSION_STRING};g; s;_MODULE_;vboxnetflt;g; s;_BUILDTYPE_;${KBUILD_TYPE};g" --output $@ $< 406 $(QUIET) chmod0755 $@401 $(QUIET)$(CHMOD) 0755 $@ 407 402 408 403 endif # linux … … 411 406 ## @todo Properly generate opt_netgraph.h 412 407 ifeq ($(KBUILD_TARGET),freebsd) 413 vboxnetflt_DEPS.freebsd += $(PATH_OUT)/opt_netgraph.h408 vboxnetflt_DEPS.freebsd += $(PATH_OUT)/opt_netgraph.h 414 409 $(PATH_OUT)/opt_netgraph.h: 415 410 echo > $(PATH_OUT)/opt_netgraph.h … … 422 417 INSTALLS += VBoxNetFlt-src 423 418 VBoxNetFlt-src_INST = bin/src/vboxnetflt/ 424 VBoxNetFlt-src_MODE = a+r,u+w 425 VBoxNetFlt-src_SOURCES = $(subst ",,$(VBOX_VBOXNETFLT_SOURCES)) #" 426 VBoxNetFlt-src_SOURCES+= \ 427 $(VBoxNetFlt-src_0_OUTDIR)/Makefile 419 VBoxNetFlt-src_SOURCES = \ 420 $(subst $(DQUOTE),,$(VBOX_VBOXNETFLT_SOURCES)) \ 421 $(VBoxNetFlt-src_0_OUTDIR)/Makefile 428 422 VBoxNetFlt-src_CLEAN = \ 429 $(VBoxNetFlt-src_0_OUTDIR)/Makefile \423 $(VBoxNetFlt-src_0_OUTDIR)/Makefile \ 430 424 431 425 $$(VBoxNetFlt-src_0_OUTDIR)/Makefile: \ … … 433 427 $$(if $$(eq $$(VBoxNetFlt/freebsd/Makefile_VBOX_HARDENED),$$(VBOX_WITH_HARDENING)),,FORCE) \ 434 428 | $$(dir $$@) 429 $(QUIET)$(RM) -f -- $@ 435 430 $(QUIET)$(CP) -f $< $@ 436 431 ifndef VBOX_WITH_HARDENING -
trunk/src/VBox/HostDrivers/VBoxPci/Makefile.kmk
r38082 r38183 1 # $Id$ 2 ## @file 3 # Sub-Makefile for the PCI passthru driver (VBoxPci). 4 # 5 6 # 7 # Copyright (C) 2011 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 1 18 SUB_DEPTH = ../../../.. 2 19 include $(KBUILD_PATH)/subheader.kmk 3 4 ifeq (1,1)5 6 20 if1of ($(KBUILD_TARGET), linux) 7 21 8 SYSMODS += VBoxPci 9 VBoxPci_TEMPLATE = VBOXR0DRV 10 VBoxPci_INST = $(INST_VBOXPCI)$(if $(eq $(KBUILD_TARGET),darwin),Contents/MacOS/) 11 VBoxPci_NAME.linux = vboxpci 12 VBoxPci_NOINST.linux = true 13 VBoxPci_DEFS = IN_RT_R0 VBOX_SVN_REV=$(VBOX_SVN_REV) IN_SUP_STATIC 14 VBoxPci_DEFS.linux = KBUILD_MODNAME=KBUILD_STR\(vboxpci\) KBUILD_BASENAME=KBUILD_STR\(vboxpci\) MODULE 15 VBoxPci_INCS.linux := \ 16 $(PATH_ROOT)/src/VBox/Runtime/r0drv/linux 17 VBoxPci_INCS = \ 18 . 19 VBoxPci_SOURCES.linux = \ 20 linux/VBoxPci-linux.c \ 21 VBoxPci.c 22 VBoxPci_SOURCES = 23 VBoxPci_LIBS += \ 24 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB) 25 26 endif 22 # 23 # The driver. 24 # Note! For Linux, this is just a compile test. Don't use the binary! 25 # 26 SYSMODS += VBoxPci 27 VBoxPci_TEMPLATE = VBOXR0DRV 28 VBoxPci_INST = $(INST_VBOXPCI)$(if $(eq $(KBUILD_TARGET),darwin),Contents/MacOS/) 29 VBoxPci_NAME.linux = vboxpci 30 VBoxPci_NOINST.linux = true 31 VBoxPci_DEFS = IN_RT_R0 VBOX_SVN_REV=$(VBOX_SVN_REV) IN_SUP_STATIC 32 VBoxPci_DEFS.linux = KBUILD_MODNAME=KBUILD_STR\(vboxpci\) KBUILD_BASENAME=KBUILD_STR\(vboxpci\) MODULE 33 VBoxPci_INCS.linux := \ 34 $(PATH_ROOT)/src/VBox/Runtime/r0drv/linux 35 VBoxPci_INCS = \ 36 . 37 VBoxPci_SOURCES.linux = \ 38 linux/VBoxPci-linux.c 39 VBoxPci_SOURCES = \ 40 VBoxPci.c 41 VBoxPci_LIBS += \ 42 $(PATH_STAGE_LIB)/SUPR0IdcClient$(VBOX_SUFF_LIB) 27 43 28 44 29 ifeq ($(KBUILD_TARGET),linux) 45 # 46 # Install the sources. 47 # 48 include $(PATH_SUB_CURRENT)/linux/files_vboxpci 49 INSTALLS += VBoxPci-src 50 VBoxPci-src_INST = bin/src/vboxpci/ 51 VBoxPci-src_SOURCES = \ 52 $(subst $(DQUOTE),,$(VBOX_VBOXPCI_SOURCES)) \ 53 $(VBoxPci-src_0_OUTDIR)/Makefile 54 VBoxPci-src_EXEC_SOURCES = \ 55 $(VBoxPci-src_0_OUTDIR)/build_in_tmp \ 56 $(PATH_ROOT)/src/VBox/HostDrivers/linux/do_Module.symvers 57 VBoxPci-src_CLEAN = \ 58 $(VBoxPci-src_0_OUTDIR)/Makefile \ 59 $(PATH_TARGET)/VBoxPciSrc-src-1.dep \ 60 $(VBoxPci-src_0_OUTDIR)/build_in_tmp 30 61 31 include $(PATH_SUB_CURRENT)/linux/files_vboxpci62 # Generate the scripts needed for building the kernel module. 32 63 33 INSTALLS += VBoxPci-src VBoxPci-sh 34 35 VBoxPci-src_INST = bin/src/vboxpci/ 36 VBoxPci-src_MODE = a+r,u+w 37 VBoxPci-src_SOURCES = $(subst ",,$(VBOX_VBOXPCI_SOURCES)) #" 38 VBoxPci-src_SOURCES+= \ 39 $(VBoxPci-src_0_OUTDIR)/Makefile 40 VBoxPci-src_CLEAN = \ 41 $(VBoxPci-src_0_OUTDIR)/Makefile \ 42 $(PATH_TARGET)/VBoxPciSrc-src-1.dep 43 44 VBoxPci-sh_INST = bin/src/vboxpci/ 45 VBoxPci-sh_MODE = a+rx,u+w 46 VBoxPci-sh_SOURCES = \ 47 $(VBoxPci-sh_0_OUTDIR)/build_in_tmp \ 48 $(PATH_ROOT)/src/VBox/HostDrivers/linux/do_Module.symvers 49 VBoxPci-sh_CLEAN = $(VBoxPci-sh_0_OUTDIR)/build_in_tmp 50 51 52 includedep $(PATH_TARGET)/VBoxPci-src-1.dep 64 includedep $(PATH_TARGET)/VBoxPci-src-1.dep 53 65 $$(VBoxPci-src_0_OUTDIR)/Makefile: \ 54 66 $(PATH_SUB_CURRENT)/linux/Makefile \ 55 67 $$(if $$(eq $$(VBoxPci/linux/Makefile_VBOX_HARDENED),$$(VBOX_WITH_HARDENING)),,FORCE) \ 56 68 | $$(dir $$@) 57 ifndef VBOX_WITH_HARDENING 69 $(QUIET)$(RM) -f -- $@ 70 ifndef VBOX_WITH_HARDENING 58 71 $(QUIET)$(SED) -e "s;-DVBOX_WITH_HARDENING;;g" --output $@ $< 59 else72 else 60 73 $(QUIET)$(CP) -f $< $@ 61 endif 62 %$(QUIET2)$(RM) -f -- $(PATH_TARGET)/VBoxPci-src-1.dep 63 %$(QUIET2)$(APPEND) '$(PATH_TARGET)/VBoxPci-src-1.dep' 'VBoxPci/linux/Makefile_VBOX_HARDENED=$(VBOX_WITH_HARDENING)' 74 endif 75 %$(QUIET2)$(APPEND) -t '$(PATH_TARGET)/VBoxPci-src-1.dep' 'VBoxPci/linux/Makefile_VBOX_HARDENED=$(VBOX_WITH_HARDENING)' 64 76 65 ## Scripts needed for building the kernel modules 66 67 $$(VBoxPci-sh_0_OUTDIR)/build_in_tmp: \ 77 $$(VBoxPci-src_0_OUTDIR)/build_in_tmp: \ 68 78 $(PATH_ROOT)/src/VBox/HostDrivers/linux/build_in_tmp \ 69 79 $(VBOX_VERSION_STAMP) \ 70 80 | $$(dir $$@) 71 81 $(call MSG_TOOL,Creating,,$@) 82 $(QUIET)$(RM) -f -- $@ 72 83 $(QUIET)$(SED) -e "s;_VERSION_;${VBOX_VERSION_STRING};g; s;_MODULE_;vboxpci;g; s;_BUILDTYPE_;${KBUILD_TYPE};g" --output $@ $< 73 $(QUIET)chmod 0755 $@ 74 endif 84 $(QUIET)$(CHMOD) 0755 $@ 75 85 76 endif 86 endif # Supported platform. 87 include $(KBUILD_PATH)/subfooter.kmk 77 88 78 include $(KBUILD_PATH)/subfooter.kmk -
trunk/src/VBox/HostDrivers/VBoxUSB/Makefile.kmk
r37423 r38183 5 5 6 6 # 7 # Copyright (C) 2006-20 07Oracle Corporation7 # Copyright (C) 2006-2011 Oracle Corporation 8 8 # 9 9 # This file is part of VirtualBox Open Source Edition (OSE), as … … 50 50 win/lib/VBoxUsbLib-win.cpp 51 51 52 #53 # USBFilter testcase.54 #55 52 ifdef VBOX_WITH_TESTCASES 56 PROGRAMS += tstUSBFilter 57 tstUSBFilter_TEMPLATE = VBOXR3TSTEXE 58 tstUSBFilter_DEFS = IN_USBLIB 59 tstUSBFilter_SOURCES = \ 60 testcase/tstUSBFilter.cpp 61 tstUSBFilter_LIBS = \ 62 $(USBLib_1_TARGET) 63 endif 53 # 54 # USBFilter testcase. 55 # 56 PROGRAMS += tstUSBFilter 57 tstUSBFilter_TEMPLATE = VBOXR3TSTEXE 58 tstUSBFilter_DEFS = IN_USBLIB 59 tstUSBFilter_SOURCES = \ 60 testcase/tstUSBFilter.cpp 61 tstUSBFilter_LIBS = \ 62 $(USBLib_1_TARGET) 63 endif # VBOX_WITH_TESTCASES 64 64 65 65 -
trunk/src/VBox/HostDrivers/darwin/Makefile.kmk
r28800 r38183 20 20 21 21 INSTALLS += HostDrivers-darwin-sh 22 HostDrivers-darwin-sh_INST 23 HostDrivers-darwin-sh_ MODE = a+rx,u+w24 HostDrivers-darwin-sh_ SOURCES = \22 HostDrivers-darwin-sh_INST = $(INST_DIST) 23 HostDrivers-darwin-sh_INSTTYPE = stage 24 HostDrivers-darwin-sh_EXEC_SOURCES = \ 25 25 loadall.sh 26 26
Note:
See TracChangeset
for help on using the changeset viewer.