Changeset 84947 in vbox for trunk/src/VBox/Installer
- Timestamp:
- Jun 25, 2020 11:52:07 AM (4 years ago)
- Location:
- trunk/src/VBox/Installer/linux
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Installer/linux/Makefile-footer.gmk
r82968 r84947 27 27 # 28 28 VBOXMOD_0_KFLAGS := -D__KERNEL__ -DMODULE -DRT_WITHOUT_PRAGMA_ONCE $(addprefix -D,$(VBOXMOD_DEFS)) 29 ifeq ($( BUILD_TARGET_ARCH),amd64)29 ifeq ($(VBOX_KBUILD_TARGET_ARCH),amd64) 30 30 VBOXMOD_0_KFLAGS += -DRT_ARCH_AMD64 31 31 else … … 33 33 endif 34 34 35 ifeq ($( BUILD_TYPE),debug)35 ifeq ($(VBOX_KBUILD_TYPE),debug) 36 36 # The -Wno-array-bounds is because of a bug in gcc 4.something, see 37 37 # https://sourceware.org/bugzilla/show_bug.cgi?id=10001 … … 53 53 VBOXMOD_EXT := o 54 54 55 ifeq ($( BUILD_TARGET_ARCH),amd64)55 ifeq ($(VBOX_KBUILD_TARGET_ARCH),amd64) 56 56 VBOXMOD_0_KFLAGS += -mcmodel=kernel 57 57 endif -
trunk/src/VBox/Installer/linux/Makefile-header.gmk
r82968 r84947 37 37 # include $(obj)/Makefile-footer.gmk 38 38 # 39 # The kmk kBuild define KBUILD_TARGET_ARCH is available. 39 # To avoid potential confusion between kmk/kBuild and linux/kbuild, 40 # we use VBOX_KBUILD_TARGET_ARCH instead of KBUILD_TARGET_ARCH and 41 # VBOX_KBUILD_TYPE instead of KBUILD_TYPE. The VBOX_KBUILD_ variable 42 # variant takes percedence over the kmk/kBuild ones. 40 43 # 41 44 … … 44 47 # First, figure out which architecture we're targeting and the build type. 45 48 # (We have to support basic cross building (ARCH=i386|x86_64).) 46 # While at it, warn about BUILD_* vars found to help with user problems. 47 # 49 # While at it, warn about *BUILD_* vars found to help with user problems. 50 # 51 52 # VBOX_KBUILD_TARGET_ARCH = amd64|x86 48 53 ifeq ($(filter-out x86_64 amd64 AMD64,$(shell uname -m)),) 49 BUILD_TARGET_ARCH_DEF := amd64 50 else 51 BUILD_TARGET_ARCH_DEF := x86 52 endif 53 ifneq ($(filter-out amd64 x86,$(BUILD_TARGET_ARCH)),) 54 $(warning Ignoring unknown BUILD_TARGET_ARCH value '$(BUILD_TARGET_ARCH)'.) 55 BUILD_TARGET_ARCH := 56 endif 57 ifeq ($(BUILD_TARGET_ARCH),) 54 VBOX_KBUILD_TARGET_ARCH_DEFAULT := amd64 55 else 56 VBOX_KBUILD_TARGET_ARCH_DEFAULT := x86 57 endif 58 ifdef VBOX_KBUILD_TARGET_ARCH 59 ifneq ($(filter-out amd64 x86,$(VBOX_KBUILD_TARGET_ARCH)),) 60 $(warning Ignoring unknown VBOX_KBUILD_TARGET_ARCH value '$(VBOX_KBUILD_TARGET_ARCH)'.) 61 VBOX_KBUILD_TARGET_ARCH := 62 endif 63 else 64 ifdef KBUILD_TARGET_ARCH 65 ifneq ($(filter-out amd64 x86,$(KBUILD_TARGET_ARCH)),) 66 $(warning Ignoring unknown KBUILD_TARGET_ARCH value '$(KBUILD_TARGET_ARCH)'.) 67 VBOX_KBUILD_TARGET_ARCH := 68 endif 69 else 70 ifdef BUILD_TARGET_ARCH 71 $(warning BUILD_TARGET_ARCH is deprecated, use VBOX_KBUILD_TARGET_ARCH instead.) 72 ifneq ($(filter-out amd64 x86,$(BUILD_TARGET_ARCH)),) 73 $(warning Ignoring unknown BUILD_TARGET_ARCH value '$(BUILD_TARGET_ARCH)'.) 74 VBOX_KBUILD_TARGET_ARCH := 75 endif 76 endif 77 endif 78 endif 79 ifeq ($(VBOX_KBUILD_TARGET_ARCH),) 58 80 ifeq ($(ARCH),x86_64) 59 BUILD_TARGET_ARCH := amd6481 VBOX_KBUILD_TARGET_ARCH := amd64 60 82 else 61 83 ifeq ($(ARCH),i386) 62 BUILD_TARGET_ARCH := x8684 VBOX_KBUILD_TARGET_ARCH := x86 63 85 else 64 BUILD_TARGET_ARCH := $(BUILD_TARGET_ARCH_DEF) 65 endif 66 endif 67 else 68 ifneq ($(BUILD_TARGET_ARCH),$(BUILD_TARGET_ARCH_DEF)) 69 $(warning Using BUILD_TARGET_ARCH='$(BUILD_TARGET_ARCH)' from the $(origin BUILD_TARGET_ARCH).) 70 endif 71 endif 72 73 ifneq ($(filter-out release profile debug strict,$(BUILD_TYPE)),) 74 $(warning Ignoring unknown BUILD_TYPE value '$(BUILD_TYPE)'.) 75 BUILD_TYPE := 76 endif 77 ifeq ($(BUILD_TYPE),) 78 BUILD_TYPE := release 79 else 80 ifneq ($(BUILD_TYPE),release) 86 VBOX_KBUILD_TARGET_ARCH := $(VBOX_KBUILD_TARGET_ARCH_DEFAULT) 87 endif 88 endif 89 else 90 ifneq ($(VBOX_KBUILD_TARGET_ARCH),$(VBOX_KBUILD_TARGET_ARCH_DEFAULT)) 91 $(warning Using VBOX_KBUILD_TARGET_ARCH='$(VBOX_KBUILD_TARGET_ARCH)' from the $(origin VBOX_KBUILD_TARGET_ARCH).) 92 endif 93 endif 94 95 # VBOX_KBUILD_TYPE = release|debug|profile|strict 96 ifdef VBOX_KBUILD_TYPE 97 VBOX_KBUILD_TYPE_VAR := VBOX_KBUILD_TYPE 98 ifneq ($(filter-out release profile debug strict,$(VBOX_KBUILD_TYPE)),) 99 $(warning Ignoring unknown VBOX_KBUILD_TYPE value '$(VBOX_KBUILD_TYPE)'.) 100 VBOX_KBUILD_TYPE := 101 endif 102 else 103 ifdef KBUILD_TYPE 104 VBOX_KBUILD_TYPE_VAR := KBUILD_TYPE 105 VBOX_KBUILD_TYPE := $(KBUILD_TYPE) 106 ifneq ($(filter-out release profile debug strict,$(KBUILD_TYPE)),) 107 $(warning Ignoring unknown KBUILD_TYPE value '$(KBUILD_TYPE)'.) 108 VBOX_KBUILD_TYPE := 109 endif 110 else 111 ifdef BUILD_TYPE 112 $(warning BUILD_TYPE is deprecated, use VBOX_KBUILD_TYPE instead.) 113 VBOX_KBUILD_TYPE_VAR := BUILD_TYPE 114 VBOX_KBUILD_TYPE := $(BUILD_TYPE) 115 ifneq ($(filter-out release profile debug strict,$(BUILD_TYPE)),) 116 $(warning Ignoring unknown BUILD_TYPE value '$(BUILD_TYPE)'.) 117 VBOX_KBUILD_TYPE := 118 endif 119 endif 120 endif 121 endif 122 ifeq ($(VBOX_KBUILD_TYPE),) 123 VBOX_KBUILD_TYPE_VAR = VBOX_KBUILD_TYPE 124 VBOX_KBUILD_TYPE := release 125 else 126 ifneq ($(VBOX_KBUILD_TYPE),release) 81 127 ifndef VBOX_KERN_QUIET 82 $(warning Using BUILD_TYPE='$(BUILD_TYPE)' from the $(origin BUILD_TYPE).) 83 endif 84 endif 85 endif 128 $(warning Using VBOX_KBUILD_TYPE='$(VBOX_KBUILD_TYPE)' from the $(origin $(VBOX_KBUILD_TYPE_VAR)) ($(VBOX_KBUILD_TYPE_VAR)).) 129 endif 130 endif 131 endif 132 86 133 ifeq ($(USERNAME),) 87 134 USERNAME := noname -
trunk/src/VBox/Installer/linux/install.sh
r82968 r84947 36 36 # The "BUILD_" prefixes prevent the variables from being overwritten when we 37 37 # read the configuration from the previous installation. 38 BUILD_ BUILDTYPE="_BUILDTYPE_"38 BUILD_VBOX_KBUILD_TYPE="_BUILDTYPE_" 39 39 BUILD_USERNAME="_USERNAME_" 40 40 CONFIG_DIR="/etc/vbox" … … 308 308 echo "INSTALL_REV='$SVNREV'" >> $CONFIG_DIR/$CONFIG 309 309 echo "# Build type and user name for logging purposes" >> $CONFIG_DIR/$CONFIG 310 echo " BUILD_TYPE='$BUILD_BUILDTYPE'" >> $CONFIG_DIR/$CONFIG310 echo "VBOX_KBUILD_TYPE='$BUILD_VBOX_KBUILD_TYPE'" >> $CONFIG_DIR/$CONFIG 311 311 echo "USERNAME='$BUILD_USERNAME'" >> $CONFIG_DIR/$CONFIG 312 312 -
trunk/src/VBox/Installer/linux/vboxdrv.sh
r82968 r84947 58 58 59 59 [ -f /etc/vbox/vbox.cfg ] && . /etc/vbox/vbox.cfg 60 export BUILD_TYPE60 export VBOX_KBUILD_TYPE 61 61 export USERNAME 62 62 export USER=$USERNAME
Note:
See TracChangeset
for help on using the changeset viewer.