VirtualBox

Changeset 9499

Show
Ignore:
Timestamp:
06/08/08 02:44:31 (3 months ago)
Author:
vboxsync
Message:

Preparing 64-bit guest additions building (focusing on windows atm.)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/Config.kmk

    r9489 r9499  
    300300else 
    301301# VBOX_WITH_64_BITS_GUESTS = 1 
     302endif 
     303# Enable building 64-bit additions (actually KBUILD_TARGET_ARCH decides). 
     304ifeq ($(USERNAME),bird) # precaution 
     305VBOX_WITH_64BIT_ADDITIONS = 1 
    302306endif 
    303307 
     
    817821 
    818822ifdef VBOX_WITH_64_BITS_GUESTS 
    819  GCARCH_BITS_DEFS := GC_ARCH_BITS=64 
    820 else 
    821  GCARCH_BITS_DEFS := GC_ARCH_BITS=32 
    822 endif 
    823 ARCH_BITS_DEFS += $(GCARCH_BITS_DEFS) 
     823 VBOX_GC_ARCH_BITS_DEFS := GC_ARCH_BITS=64 
     824else 
     825 VBOX_GC_ARCH_BITS_DEFS := GC_ARCH_BITS=32 
     826endif 
     827ARCH_BITS_DEFS += $(VBOX_GC_ARCH_BITS_DEFS) 
    824828 
    825829# 
     
    25872591TEMPLATE_VBOXW32GUESTR3_BLD_TRG_ARCH        = x86 
    25882592TEMPLATE_VBOXW32GUESTR3_BLD_TRG_CPU         = i386 
    2589 TEMPLATE_VBOXW32GUESTR3_DEFS                = IN_GUEST IN_GUEST_R3 IN_RING3 IN_RT_R3 __WIN32__ __WIN__ HC_ARCH_BITS=32 $(GCARCH_BITS_DEFS) 
     2593TEMPLATE_VBOXW32GUESTR3_DEFS                = IN_GUEST IN_GUEST_R3 IN_RING3 IN_RT_R3 __WIN32__ __WIN__ HC_ARCH_BITS=32 $(VBOX_GC_ARCH_BITS_DEFS) 
    25902594TEMPLATE_VBOXW32GUESTR3_RCDEFS              = \ 
    25912595        VBOX_VERSION_MAJOR=\"$(VBOX_VERSION_MAJOR)\" \ 
     
    26602664TEMPLATE_VBOXW32GUESTR0_BLD_TRG_ARCH        = x86 
    26612665TEMPLATE_VBOXW32GUESTR0_BLD_TRG_CPU         = i386 
    2662 TEMPLATE_VBOXW32GUESTR0_DEFS                = _X86_ IN_GUEST IN_GUEST_R0 IN_RING0 IN_RT_R0 __WIN32__ __WIN__ HC_ARCH_BITS=32 $(GCARCH_BITS_DEFS) 
     2666TEMPLATE_VBOXW32GUESTR0_DEFS                = _X86_ IN_GUEST IN_GUEST_R0 IN_RING0 IN_RT_R0 __WIN32__ __WIN__ HC_ARCH_BITS=32 $(VBOX_GC_ARCH_BITS_DEFS) 
    26632667TEMPLATE_VBOXW32GUESTR0_RCDEFS              = \ 
    26642668        VBOX_VERSION_MAJOR=\"$(VBOX_VERSION_MAJOR)\" \ 
     
    27662770# 
    27672771TEMPLATE_VBOXGUESTR3EXE           = VBox Guest Program 
    2768 ifeq ($(KBUILD_TARGET),win) # quick hack 
    2769  TEMPLATE_VBOXGUESTR3EXE_EXTENDS  = VBOXW32GUESTR3 
    2770 else 
     2772ifeq ($(KBUILD_TARGET),win) 
     2773 ifdef VBOX_WITH_64BIT_ADDITIONS 
     2774  TEMPLATE_VBOXGUESTR3EXE_EXTENDS  = VBOXR3EXE 
     2775 else 
     2776  TEMPLATE_VBOXGUESTR3EXE_EXTENDS  = VBOXW32GUESTR3 
     2777 endif 
     2778else # the gcc guys 
    27712779 TEMPLATE_VBOXGUESTR3EXE_EXTENDS  = VBOXR3EXE 
    27722780 #TEMPLATE_VBOXGUESTR3EXE_TOOL   := $(subst GXX,GCC,$(TEMPLATE_VBOXR3EXE_TOOL)) 
     
    27752783endif 
    27762784TEMPLATE_VBOXGUESTR3EXE_INST      = $(INST_ADDITIONS) 
    2777 TEMPLATE_VBOXGUESTR3EXE_ASFLAGS   = $(VBOX_ASFLAGS32) 
    2778 TEMPLATE_VBOXGUESTR3EXE_BLD_TRG_ARCH  = x86 
    2779 TEMPLATE_VBOXGUESTR3EXE_BLD_TRG_CPU   = blend 
    2780 TEMPLATE_VBOXGUESTR3EXE_DEFS     := IN_GUEST IN_GUEST_R3 IN_RT_R3 \ 
     2785ifdef VBOX_WITH_64BIT_ADDITIONS 
     2786 TEMPLATE_VBOXGUESTR3EXE_DEFS    := $(TEMPLATE_VBOXR3EXE_DEFS) IN_GUEST IN_GUEST_R3 IN_RT_R3 
     2787else 
     2788 TEMPLATE_VBOXGUESTR3EXE_ASFLAGS  = $(VBOX_ASFLAGS32) 
     2789 TEMPLATE_VBOXGUESTR3EXE_BLD_TRG_ARCH  = x86 
     2790 TEMPLATE_VBOXGUESTR3EXE_BLD_TRG_CPU   = blend 
     2791 TEMPLATE_VBOXGUESTR3EXE_DEFS    := IN_GUEST IN_GUEST_R3 IN_RT_R3 \ 
    27812792                                    $(filter-out $(ARCH_BITS_DEFS),$(TEMPLATE_VBOXR3EXE_DEFS)) \ 
    2782                                     HC_ARCH_BITS=32 $(GCARCH_BITS_DEFS) 
     2793                                    HC_ARCH_BITS=32 $(VBOX_GC_ARCH_BITS_DEFS) 
     2794endif 
    27832795if1of ($(KBUILD_TARGET),l4 linux) # As few libs as possible on linux. 
    27842796 TEMPLATE_VBOXGUESTR3EXE_LIBS     = pthread rt m 
     
    28852897TEMPLATE_VBOXGUESTR0_SDKS.win.x86   = WIN32SDK W2K3DDKX86 
    28862898TEMPLATE_VBOXGUESTR0_SDKS.win.amd64 = W2K3DDK WINPSDKINCS 
    2887 ifn1of ($(KBUILD_TARGET),l4 linux) # must be same as the host. 
    2888  TEMPLATE_VBOXGUESTR0_DEFS      = $(filter-out $(ARCH_BITS_DEFS),$(TEMPLATE_VBOXR0DRV_DEFS)) IN_GUEST IN_GUEST_R0 HC_ARCH_BITS=32 $(GCARCH_BITS_DEFS) 
    2889  TEMPLATE_VBOXGUESTR0_BLD_TRG_ARCH = x86 
    2890  TEMPLATE_VBOXGUESTR0_BLD_TRG_CPU = blend 
    2891 else 
    2892  TEMPLATE_VBOXGUESTR0_DEFS      = $(TEMPLATE_VBOXR0DRV_DEFS) IN_GUEST IN_GUEST_R0 
     2899ifdef VBOX_WITH_64BIT_ADDITIONS 
     2900 TEMPLATE_VBOXGUESTR0_DEFS      = $(TEMPLATE_VBOXR0DRV_DEFS) IN_GUEST IN_GUEST_R0 $(VBOX_GC_ARCH_BITS_DEFS) 
     2901else 
     2902 ifn1of ($(KBUILD_TARGET),l4 linux) # must be same as the host. 
     2903  TEMPLATE_VBOXGUESTR0_DEFS     = $(filter-out $(ARCH_BITS_DEFS),$(TEMPLATE_VBOXR0DRV_DEFS)) IN_GUEST IN_GUEST_R0 HC_ARCH_BITS=32 $(VBOX_GC_ARCH_BITS_DEFS) 
     2904  TEMPLATE_VBOXGUESTR0_BLD_TRG_ARCH = x86 
     2905  TEMPLATE_VBOXGUESTR0_BLD_TRG_CPU = blend 
     2906 else 
     2907  TEMPLATE_VBOXGUESTR0_DEFS     = $(TEMPLATE_VBOXR0DRV_DEFS) IN_GUEST IN_GUEST_R0 
     2908 endif 
    28932909endif 
    28942910ifeq ($(KBUILD_TARGET),l4) # cross building linux on l4. 
     
    29152931VBOX_LIB_IPRT_GUEST_R3_MINI     = $(VBOX_PATH_ADDITIONS_LIB)/RuntimeGuestR3Mini$(VBOX_SUFF_LIB) 
    29162932VBOX_LIB_IPRT_GUEST_R0          = $(VBOX_PATH_ADDITIONS_LIB)/RuntimeGuestR0$(VBOX_SUFF_LIB) 
     2933VBOX_LIB_IPRT_GUEST_R0_NT4      = $(VBOX_PATH_ADDITIONS_LIB)/RuntimeGuestR0NT4$(VBOX_SUFF_LIB) 
    29172934VBOX_LIB_VBGL_R3                = $(VBOX_PATH_ADDITIONS_LIB)/VBoxGuestR3Lib$(VBOX_SUFF_LIB) 
    29182935VBOX_LIB_VBGL_R3_XFREE86        = $(VBOX_PATH_ADDITIONS_LIB)/VBoxGuestR3LibXFree86$(VBOX_SUFF_LIB) 
  • trunk/src/VBox/Runtime/Makefile.kmk

    r9429 r9499  
    3838 # Only build the additions, sort out the legacy names first. 
    3939 # 
    40  ifeq ($(KBUILD_TARGET),win) 
     40 ifeq ($(KBUILD_TARGET)$(VBOX_WITH_64BIT_ADDITIONS),win) 
    4141  LIBRARIES = RuntimeW32GuestR0 RuntimeW32GuestR3 RuntimeW32NT4GuestR0 
    4242 else 
    4343  LIBRARIES = RuntimeGuestR0 RuntimeGuestR3 RuntimeGuestR3Mini 
    44   #LIBRARIES.os2 = RuntimeOS2Warp3GuestR0 
    45   #LIBRARIES.win = RuntimeW32NT4GuestR0 
     44  #LIBRARIES.os2 = RuntimeGuestR0OS2Warp3 
     45  LIBRARIES.win.x86 = RuntimeGuestR0NT4 
    4646  ifndef VBOX_WITH_ADDITION_DRIVERS 
    4747   if1of ($(KBUILD_TARGET), linux l4) # All drivers are optional, can skip RuntimeGuestR0. 
     
    6565 ifdef VBOX_WITH_ADDITIONS 
    6666  ifdef VBOX_WITH_WIN32_ADDITIONS 
    67    LIBRARIES += RuntimeW32GuestR0 RuntimeW32GuestR3 RuntimeW32NT4GuestR0 
     67   ifndef VBOX_WITH_64BIT_ADDITIONS 
     68    LIBRARIES += RuntimeW32GuestR0 RuntimeW32GuestR3 RuntimeW32NT4GuestR0 
     69   endif 
    6870  endif 
    69   ifneq ($(KBUILD_TARGET),win) 
     71  ifneq ($(KBUILD_TARGET)$(VBOX_WITH_64BIT_ADDITIONS),win) 
    7072   LIBRARIES += RuntimeGuestR0 RuntimeGuestR3 RuntimeGuestR3Mini 
    71    #LIBRARIES.os2 = RuntimeOS2Warp3GuestR0 
    72    #LIBRARIES.win = RuntimeW32NT4GuestR0 
     73   #LIBRARIES.os2 = RuntimeGuestR0OS2Warp3 
     74   LIBRARIES.win.x86 = RuntimeGuestR0NT4 
    7375   ifndef VBOX_WITH_ADDITION_DRIVERS 
    7476    if1of ($(KBUILD_TARGET), linux l4) # All drivers are optional, can skip RuntimeGuestR0. 
     
    545547# 
    546548RuntimeGuestR3_TEMPLATE                 := VBOXGUESTR3LIB 
     549## @todo change this to EXTEND the RuntimeR3 target. 
    547550RuntimeGuestR3_SDKS.win                 := $(RuntimeR3_SDKS.win) 
    548551RuntimeGuestR3_DEFS                     := $(filter-out RTCRITSECT_STRICT, $(RuntimeR3_DEFS)) 
     
    565568RuntimeGuestR3_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) := $(RuntimeR3_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)) 
    566569RuntimeGuestR3_SOURCES.$(KBUILD_HOST).$(KBUILD_TARGET_ARCH)   := $(RuntimeR3_SOURCES.$(KBUILD_HOST).$(KBUILD_TARGET_ARCH)) 
     570ifndef VBOX_WITH_64BIT_ADDITIONS 
    567571RuntimeGuestR3_SOURCES.$(KBUILD_TARGET).x86 := $(RuntimeR3_SOURCES.$(KBUILD_TARGET).x86) 
    568572RuntimeGuestR3_SOURCES.$(KBUILD_HOST).x86   := $(RuntimeR3_SOURCES.$(KBUILD_HOST).x86) 
     573endif 
    569574 
    570575 
     
    575580# 
    576581RuntimeGuestR3Mini_TEMPLATE                 := VBOXGUESTR3DLL 
     582## @todo change this to EXTEND the RuntimeGuestR3 target. 
    577583RuntimeGuestR3Mini_INST                     := $(INST_ADDITIONS_LIB) 
    578584RuntimeGuestR3Mini_SDKS.win                 := $(RuntimeR3_SDKS.win) 
    579585RuntimeGuestR3Mini_DEFS                     := $(filter-out RTCRITSECT_STRICT, $(RuntimeR3_DEFS)) RT_MINI 
    580 RuntimeGuestR3Mini_DEFS.$(KBUILD_TARGET)    := $(RuntimeR3_DEFS.$(KBUILD_TARGET)) 
    581 RuntimeGuestR3Mini_DEFS.$(KBUILD_HOST)   := $(RuntimeR3_DEFS.$(KBUILD_HOST)) 
     586RuntimeGuestR3Mini_DEFS.$(KBUILD_TARGET)    := $(RuntimeR3_DEFS.$(KBUILD_TARGET)) 
     587RuntimeGuestR3Mini_DEFS.$(KBUILD_HOST)      := $(RuntimeR3_DEFS.$(KBUILD_HOST)) 
    582588RuntimeGuestR3Mini_INCS                     := $(RuntimeR3_INCS) 
    583 RuntimeGuestR3Mini_INCS.$(KBUILD_TARGET)    := $(RuntimeR3_INCS.$(KBUILD_TARGET)) 
    584 RuntimeGuestR3Mini_INCS.$(KBUILD_HOST)   := $(RuntimeR3_INCS.$(KBUILD_HOST)) 
     589RuntimeGuestR3Mini_INCS.$(KBUILD_TARGET)    := $(RuntimeR3_INCS.$(KBUILD_TARGET)) 
     590RuntimeGuestR3Mini_INCS.$(KBUILD_HOST)      := $(RuntimeR3_INCS.$(KBUILD_HOST)) 
    585591RuntimeGuestR3Mini_SOURCES = \ 
    586592        common/err/errmsg.cpp \ 
     
    11571163#                  This is almost the same as the RuntimeR0Drv, the main difference 
    11581164#                  is in the backdoor logging and the lack of sup.h (which should be 
    1159 #                  made irrelevant even for RuntimeR0Rdrv). 
    1160 
    1161 # TODO: RuntimeGuestR0_EXTENDS = RuntimeR0Drv (kBuild) 
     1165#                  made irrelevant even for RuntimeR0Drv). 
    11621166# 
    11631167RuntimeGuestR0_TEMPLATE                := VBOXGUESTR0LIB 
    1164 RuntimeGuestR0_SDKS.win                := W2K3DDKX86 WINPSDKINCS 
    1165 RuntimeGuestR0_DEFS                    := $(RuntimeR0Drv_DEFS) 
    1166 RuntimeGuestR0_DEFS.$(KBUILD_TARGET)    := $(RuntimeR0Drv_DEFS.$(KBUILD_TARGET)) 
    1167 RuntimeGuestR0_INCS                    := $(PATH_SUB_CURRENT) include 
    1168 RuntimeGuestR0_INCS.$(KBUILD_TARGET)    := $(RuntimeR0Drv_INCS.$(KBUILD_TARGET)) 
    11691168RuntimeGuestR0_SOURCES                 := $(filter-out generic/RTLogWriteUser-generic.cpp, $(RuntimeR0Drv_SOURCES)) 
    11701169RuntimeGuestR0_SOURCES                 += VBox/logbackdoor.cpp 
    1171 RuntimeGuestR0_SOURCES.$(KBUILD_TARGET) := $(RuntimeR0Drv_SOURCES.$(KBUILD_TARGET)) 
    1172 RuntimeGuestR0_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) := $(RuntimeR0Drv_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)) 
    1173 ifdef VBOX_USE_VCC80 
    1174 RuntimeGuestR0_SOURCES.win += \ 
    1175         common/string/memchr.cpp \ 
    1176         common/string/memcpy.cpp \ 
    1177         common/string/memset.cpp \ 
    1178         common/string/memmove.asm \ 
    1179         common/string/strlen.cpp 
    1180 endif 
    1181 RuntimeGuestR0_SOURCES.freebsd += \ 
    1182         common/string/memset.cpp \ 
    1183         common/string/memcmp.cpp \ 
    1184         common/string/strchr.asm 
     1170ifdef VBOX_WITH_64BIT_ADDITIONS 
     1171 RuntimeGuestR0_EXTENDS                 = RuntimeR0Drv 
     1172else 
     1173 RuntimeGuestR0_SDKS.win               := W2K3DDKX86 WINPSDKINCS 
     1174 RuntimeGuestR0_DEFS                   := $(RuntimeR0Drv_DEFS) 
     1175 RuntimeGuestR0_DEFS.$(KBUILD_TARGET)  := $(RuntimeR0Drv_DEFS.$(KBUILD_TARGET)) 
     1176 RuntimeGuestR0_INCS                   := $(PATH_SUB_CURRENT) include 
     1177 RuntimeGuestR0_INCS.$(KBUILD_TARGET)  := $(RuntimeR0Drv_INCS.$(KBUILD_TARGET)) 
     1178 RuntimeGuestR0_SOURCES.$(KBUILD_TARGET) := $(RuntimeR0Drv_SOURCES.$(KBUILD_TARGET)) 
     1179 RuntimeGuestR0_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH) := $(RuntimeR0Drv_SOURCES.$(KBUILD_TARGET).$(KBUILD_TARGET_ARCH)) 
     1180 ifdef VBOX_USE_VCC80 
     1181  RuntimeGuestR0_SOURCES.win += \ 
     1182        common/string/memchr.cpp \ 
     1183        common/string/memcpy.cpp \ 
     1184        common/string/memset.cpp \ 
     1185        common/string/memmove.asm \ 
     1186        common/string/strlen.cpp 
     1187 endif 
     1188 RuntimeGuestR0_SOURCES.freebsd += \ 
     1189        common/string/memset.cpp \ 
     1190        common/string/memcmp.cpp \ 
     1191        common/string/strchr.asm 
     1192endif 
    11851193 
    11861194# HACK: no vbi for the solaris guest additions - yet. 
     
    12191227        r0drv/solaris/timer-r0drv-solaris.c 
    12201228 
     1229# 
     1230# RuntimeGuestR0NT4 - Win32 NT4 guest driver runtime. 
     1231# 
     1232RuntimeGuestR0NT4_EXTENDS = RuntimeGuestR0 
     1233RuntimeGuestR0NT4_EXTENDS_BY = appending 
     1234RuntimeGuestR0NT4_DEFS = IPRT_TARGET_NT4 
     1235 
     1236 
     1237## @todo remove this 
    12211238RuntimeOS2GuestR0_TEMPLATE      = VBOXOS2GUESTR0LIB 
    12221239RuntimeOS2GuestR0_SOURCES       = \ 

© 2008 Sun Microsystems, Inc.
ContactPrivacy policy