VirtualBox

Changeset 46021 in vbox for trunk/Config.kmk


Ignore:
Timestamp:
May 13, 2013 3:09:43 PM (12 years ago)
Author:
vboxsync
Message:

Additions/linux: add support for using cross-compiler tools to build the Additions.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Config.kmk

    r45923 r46021  
    47884788 TEMPLATE_VBOXGUESTR3EXE_LNK_DEPS.win.x86   = $(if $(eq $(tool_do),LINK_LIBRARY),,$(VBOX_PE_SET_VERSION))
    47894789else # the gcc guys
     4790 ifneq ($(VBOX_WITH_COMPATIBLE_LINUX_GUEST_PACKAGE),)
     4791  ifeq ($(KBUILD_TARGET),linux)
     4792   VBOX_WITH_COMPATIBLE_LINUX_GUEST_PACKAGE :=
     4793  endif
     4794 endif
    47904795 TEMPLATE_VBOXGUESTR3EXE_EXTENDS  = VBOXR3EXE
    47914796 TEMPLATE_VBOXGUESTR3EXE_TOOL    := $(subst GXX,GCC,$(TEMPLATE_VBOXR3EXE_TOOL))
    47924797 TEMPLATE_VBOXGUESTR3EXE_CXXFLAGS = $(TEMPLATE_VBOXR3EXE_CXXFLAGS) -fno-exceptions
     4798 TEMPLATE_VBOXGUESTR3EXE_LDFLAGS.linux = $(filter-out $(VBOX_GCC_ORIGIN_OPT),$(TEMPLATE_VBOXR3EXE_LDFLAGS.linux))
     4799 ifneq ($(VBOX_WITH_COMPATIBLE_LINUX_GUEST_PACKAGE),)
     4800  ifeq ($(KBUILD_TARGET_ARCH),x86)
     4801   TEMPLATE_VBOXGUESTR3EXE_TOOL          := XGCCX86REDHATLINUX
     4802  else ifeq ($(KBUILD_TARGET_ARCH),amd64)
     4803   TEMPLATE_VBOXGUESTR3EXE_TOOL          := XGCCAMD64LINUXGNU
     4804  endif
     4805  TEMPLATE_VBOXGUESTR3EXE_CXXFLAGS      := $(filter-out $(VBOX_GCC_pipe) $(VBOX_GCC_Wextra) $(VBOX_GCC_Wno-missing-field-initializers) $(VBOX_GCC_fdiagnostics-show-option) $(VBOX_GCC_Wno-delete-non-virtual-dtor) $(VBOX_GCC_Wno-variadic-macros) $(VBOX_GCC_fvisibility-hidden) $(VBOX_GCC_fvisibility-inlines-hidden),$(TEMPLATE_VBOXGUESTR3EXE_CXXFLAGS)) -pipe
     4806  TEMPLATE_VBOXGUESTR3EXE_CFLAGS        := $(TEMPLATE_VBOXGUESTR3EXE_CXXFLAGS)
     4807  TEMPLATE_VBOXGUESTR3EXE_LDFLAGS.linux := $(filter-out $(VBOX_GCC_ORIGIN_OPT) $(VBOX_LD_as_needed),$(TEMPLATE_VBOXGUESTR3EXE_LDFLAGS.linux))
     4808 endif
    47934809 TEMPLATE_VBOXGUESTR3EXE_LDFLAGS  = $(filter-out '$(VBOX_GCC_RPATH_OPT)%,$(TEMPLATE_VBOXR3EXE_LDFLAGS))
    4794  TEMPLATE_VBOXGUESTR3EXE_LDFLAGS.linux = $(filter-out $(VBOX_GCC_ORIGIN_OPT),$(TEMPLATE_VBOXR3EXE_LDFLAGS.linux))
    47954810endif
    47964811TEMPLATE_VBOXGUESTR3EXE_INST      = $(INST_ADDITIONS)
     
    48514866 TEMPLATE_VBoxGuestR3Dll_CXXFLAGS    += $(VBOX_VCC_WERR)
    48524867 TEMPLATE_VBoxGuestR3Dll_LDFLAGS     += $(VBOX_VCC_LD_WERR)
    4853 else
     4868else ifeq ($(VBOX_WITH_COMPATIBLE_LINUX_GUEST_PACKAGE),)
    48544869 TEMPLATE_VBoxGuestR3Dll_CFLAGS      += $(VBOX_GCC_WERR)
    48554870 TEMPLATE_VBoxGuestR3Dll_CXXFLAGS    += $(VBOX_GCC_WERR)
     
    48794894 TEMPLATE_VBoxGuestR3Lib_CXXFLAGS    += $(VBOX_VCC_WERR)
    48804895 TEMPLATE_VBoxGuestR3Lib_LDFLAGS     += $(VBOX_VCC_LD_WERR)
    4881 else
     4896else ifeq ($(VBOX_WITH_COMPATIBLE_LINUX_GUEST_PACKAGE),)
    48824897 TEMPLATE_VBoxGuestR3Lib_CFLAGS      += $(VBOX_GCC_WERR)
    48834898 TEMPLATE_VBoxGuestR3Lib_CXXFLAGS    += $(VBOX_GCC_WERR)
     
    49394954 TEMPLATE_VBOXGUESTR3XF86MOD_LDFLAGS.amd64   = -m elf_x86_64
    49404955endif
    4941 TEMPLATE_VBOXGUESTR3XF86MOD_CFLAGS  = $(TEMPLATE_VBOXGUESTR3EXE_CFLAGS)   -fno-merge-constants -std=c99 $(VBOX_GCC_fno-stack-protector) -ffreestanding
    4942 TEMPLATE_VBOXGUESTR3XF86MOD_CXXFLAGS= $(TEMPLATE_VBOXGUESTR3EXE_CXXFLAGS) -fno-merge-constants $(VBOX_GCC_fno-stack-protector) -ffreestanding
     4956TEMPLATE_VBOXGUESTR3XF86MOD_CFLAGS  = $(TEMPLATE_VBOXGUESTR3EXE_CFLAGS)   -fno-merge-constants -std=c99 -ffreestanding
     4957TEMPLATE_VBOXGUESTR3XF86MOD_CXXFLAGS= $(TEMPLATE_VBOXGUESTR3EXE_CXXFLAGS) -fno-merge-constants -ffreestanding
     4958ifeq ($(VBOX_WITH_COMPATIBLE_LINUX_GUEST_PACKAGE),)
     4959 TEMPLATE_VBOXGUESTR3XF86MOD_CFLAGS   += $(VBOX_GCC_fno-stack-protector)
     4960 TEMPLATE_VBOXGUESTR3XF86MOD_CXXFLAGS += $(VBOX_GCC_fno-stack-protector)
     4961endif
    49434962TEMPLATE_VBOXGUESTR3XF86MOD_SYSSUFF = .o
    49444963TEMPLATE_VBOXGUESTR3XF86MOD_LIBS  = \
     
    49634982TEMPLATE_VBOXGUESTR3XORGMOD_LIBS.$(KBUILD_TYPE)     = $(NO_SUCH_VARIABLE)
    49644983TEMPLATE_VBOXGUESTR3XORGMOD_LIBS.$(KBUILD_TARGET)   = $(NO_SUCH_VARIABLE)
    4965 TEMPLATE_VBOXGUESTR3XORGMOD_CFLAGS                  = $(TEMPLATE_VBOXGUESTR3DLL_CFLAGS) -std=c99
     4984if1of ($(KBUILD_TARGET), linux)
     4985 TEMPLATE_VBOXGUESTR3XORGMOD_CFLAGS                 = $(TEMPLATE_VBOXGUESTR3DLL_CFLAGS) -std=c99 -Wno-conversion -Wno-unused-parameter
     4986 ifeq ($(VBOX_WITH_COMPATIBLE_LINUX_GUEST_PACKAGE),)
     4987  TEMPLATE_VBOXGUESTR3XORGMOD_CFLAGS               += $(VBOX_GCC_Wno-variadic-macros)
     4988 endif
     4989endif
    49664990TEMPLATE_VBOXGUESTR3XORGMOD_DEFS = $(TEMPLATE_VBOXGUESTR3DLL_DEFS) LOG_TO_BACKDOOR VBOX_GUESTR3XORGMOD RTMEM_NO_WRAP_TO_EF_APIS
    49674991ifeq ($(KBUILD_TARGET_ARCH),amd64)
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