Changeset 36462 in vbox for trunk/src/VBox/Additions
- Timestamp:
- Mar 29, 2011 3:19:19 PM (14 years ago)
- svn:sync-xref-src-repo-rev:
- 70846
- Location:
- trunk/src/VBox/Additions/linux/installer
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/linux/installer/Makefile.include.footer
r28998 r36462 4 4 # (For 2.6.x, the main file must be called 'Makefile'!) 5 5 # 6 # Copyright (C) 2006-20 07Oracle Corporation6 # Copyright (C) 2006-2011 Oracle Corporation 7 7 # 8 8 # This file is part of VirtualBox Open Source Edition (OSE), as … … 23 23 # MOD_NAME = <name of the module to be built, without extension> 24 24 # MOD_OBJS = <list of object files which should be included> 25 # MOD_DEFS = <any additional defines which this module needs> 26 # MOD_INCL = <any additional include paths which this module needs> 25 27 # MOD_FLAGS = <any additional CFLAGS which this module needs> 28 # MOD_CLEAN = <list of directories that the clean target should look at> 26 29 # 27 30 # The kmk kBuild define KBUILD_TARGET_ARCH is available. … … 121 124 122 125 # guess kernel version (24 or 26) 123 ifeq ($(shell if echo "$(VERSION).$(PATCHLEVEL)." | grep '2\.4\.' > /dev/null; then echo yes; fi),yes) 126 # MOD_OBJS = <list of object files which should be included> 127 ifeq ($(shell if echo "$(VERSION).$(PATCHLEVEL)." | grep '2\.4\.' > /dev/null; then echo yes; fi),yes) 124 128 KERN_VERSION := 24 125 129 else … … 147 151 KBUILD_EXTMOD := $(shell pwd) 148 152 endif 149 INCL += $( addprefix -I$(KBUILD_EXTMOD),/ /include /r0drv/linux)153 INCL += $(MOD_INCL) 150 154 export INCL 151 155 endif 152 KFLAGS := -D__KERNEL__ -DMODULE -DRT_OS_LINUX -DIN_RING0\153 -DIN_RT_R0 -DIN_SUP_R0 -DVBOX -DVBGL_VBOXGUEST -DVBOX_WITH_HGCM\154 -DLOG_TO_BACKDOOR -DRT_WITH_VBOX -DIN_MODULE -DIN_GUEST_R0156 KFLAGS := -D__KERNEL__ -DMODULE \ 157 -DVBOX -DRT_OS_LINUX -DIN_RING0 -DIN_RT_R0 -DIN_MODULE \ 158 -DRT_WITH_VBOX $(MOD_DEFS) 155 159 ifeq ($(BUILD_TARGET_ARCH),amd64) 156 160 KFLAGS += -DRT_ARCH_AMD64 -DVBOX_WITH_64_BITS_GUESTS … … 167 171 # 168 172 169 CFLAGS := -O2 -DVBOX_LINUX_2_4 -DEXPORT_SYMTAB $(INCL) $(KFLAGS) $(KDEBUG) 173 ifeq ($(BUILD_TARGET_ARCH),amd64) 174 KFLAGS += -mcmodel=kernel 175 endif 176 177 CFLAGS := -O2 -DVBOX_LINUX_2_4 -DEXPORT_SYMTAB $(INCL) $(KFLAGS) $(KDEBUG) \ 178 $(MOD_CFLAGS) 170 179 MODULE_EXT := o 171 180 … … 188 197 189 198 # build defs 190 EXTRA_CFLAGS += $(INCL) $(KFLAGS) $(KDEBUG) 199 EXTRA_CFLAGS += $(INCL) $(KFLAGS) $(KDEBUG) $(MOD_CFLAGS) 191 200 192 201 all: $(MODULE) … … 207 216 208 217 clean: 209 for f in . linux r0drv r0drv/linux; do rm -f $$f/*.o $$f/.*.cmd $$f/.*.flags; done218 for f in $(MOD_CLEAN); do rm -f $$f/*.o $$f/.*.cmd $$f/.*.flags; done 210 219 rm -rf .$(MOD_NAME)* .tmp_ver* $(MOD_NAME).* Module.symvers Modules.symvers modules.order -
trunk/src/VBox/Additions/linux/installer/Makefile.include.header
r28998 r36462 4 4 # (For 2.6.x, the main file must be called 'Makefile'!) 5 5 # 6 # Copyright (C) 2006-20 07Oracle Corporation6 # Copyright (C) 2006-2011 Oracle Corporation 7 7 # 8 8 # This file is part of VirtualBox Open Source Edition (OSE), as … … 26 26 # MOD_NAME = <name of the module to be built, without extension> 27 27 # MOD_OBJS = <list of object files which should be included> 28 # MOD_DEFS = <any additional defines which this module needs> 29 # MOD_INCL = <any additional include paths which this module needs> 28 30 # MOD_FLAGS = <any additional CFLAGS which this module needs> 31 # MOD_CLEAN = <list of directories that the clean target should look at> 29 32 # include $(obj)/Makefile.include.footer 30 33 # … … 62 65 # While at it, warn about BUILD_* vars found to help with user problems. 63 66 # 67 ifeq ($(filter-out x86_64 amd64 AMD64,$(shell uname -m)),) 68 BUILD_TARGET_ARCH_DEF := amd64 69 else 70 BUILD_TARGET_ARCH_DEF := x86 71 endif 64 72 ifneq ($(filter-out amd64 x86,$(BUILD_TARGET_ARCH)),) 65 73 $(warning Ignoring unknown BUILD_TARGET_ARCH value '$(BUILD_TARGET_ARCH)'.) … … 73 81 BUILD_TARGET_ARCH := x86 74 82 else 75 ifeq ($(filter-out x86_64 amd64 AMD64,$(shell uname -m)),) 76 BUILD_TARGET_ARCH := amd64 77 else 78 BUILD_TARGET_ARCH := x86 79 endif 83 BUILD_TARGET_ARCH := $(BUILD_TARGET_ARCH_DEF) 80 84 endif 81 85 endif 82 86 else 83 $(warning Using BUILD_TARGET_ARCH='$(BUILD_TARGET_ARCH)' from the $(origin BUILD_TARGET_ARCH).) 87 ifneq ($(BUILD_TARGET_ARCH),$(BUILD_TARGET_ARCH_DEF)) 88 $(warning Using BUILD_TARGET_ARCH='$(BUILD_TARGET_ARCH)' from the $(origin BUILD_TARGET_ARCH).) 89 endif 84 90 endif 85 91 … … 91 97 BUILD_TYPE := release 92 98 else 93 $(warning Using BUILD_TYPE='$(BUILD_TYPE)' from the $(origin BUILD_TYPE).) 99 ifneq ($(BUILD_TYPE),release) 100 $(warning Using BUILD_TYPE='$(BUILD_TYPE)' from the $(origin BUILD_TYPE).) 101 endif 94 102 endif -
trunk/src/VBox/Additions/linux/installer/Makefile.test.drm
r32394 r36462 17 17 MOD_NAME = vboxadd_test_drm 18 18 MOD_OBJS = test_drm.o 19 MOD_INCL = $(addprefix -I$(KBUILD_EXTMOD),/ /include /r0drv/linux) 20 MOD_CLEAN = . linux r0drv r0drv/linux 19 21 # These are present in the shared folders Makefile but not the main one. 20 22 # MOD_FLAGS = -DEXPORT_SYMTAB -DVBGL_VBOXGUEST -DRT_WITH_VBOX
Note:
See TracChangeset
for help on using the changeset viewer.