Makefile (cb54b53adae70701bdd77d848cea4b9b39b61cf9) | Makefile (a02150610776f66b40257624822a879311592bb2) |
---|---|
1# Unified Makefile for i386 and x86_64 2 3# select defconfig based on actual architecture 4ifeq ($(ARCH),x86) 5 ifeq ($(shell uname -m),x86_64) 6 KBUILD_DEFCONFIG := x86_64_defconfig 7 else 8 KBUILD_DEFCONFIG := i386_defconfig 9 endif 10else 11 KBUILD_DEFCONFIG := $(ARCH)_defconfig 12endif 13 14# BITS is used as extension for files which are available in a 32 bit 15# and a 64 bit version to simplify shared Makefiles. 16# e.g.: obj-y += foo_$(BITS).o 17export BITS 18 | 1# Unified Makefile for i386 and x86_64 2 3# select defconfig based on actual architecture 4ifeq ($(ARCH),x86) 5 ifeq ($(shell uname -m),x86_64) 6 KBUILD_DEFCONFIG := x86_64_defconfig 7 else 8 KBUILD_DEFCONFIG := i386_defconfig 9 endif 10else 11 KBUILD_DEFCONFIG := $(ARCH)_defconfig 12endif 13 14# BITS is used as extension for files which are available in a 32 bit 15# and a 64 bit version to simplify shared Makefiles. 16# e.g.: obj-y += foo_$(BITS).o 17export BITS 18 |
19ifdef CONFIG_X86_NEED_RELOCS 20 LDFLAGS_vmlinux := --emit-relocs 21endif 22 |
|
19ifeq ($(CONFIG_X86_32),y) 20 BITS := 32 21 UTS_MACHINE := i386 22 CHECKFLAGS += -D__i386__ 23 24 biarch := $(call cc-option,-m32) 25 KBUILD_AFLAGS += $(biarch) 26 KBUILD_CFLAGS += $(biarch) 27 | 23ifeq ($(CONFIG_X86_32),y) 24 BITS := 32 25 UTS_MACHINE := i386 26 CHECKFLAGS += -D__i386__ 27 28 biarch := $(call cc-option,-m32) 29 KBUILD_AFLAGS += $(biarch) 30 KBUILD_CFLAGS += $(biarch) 31 |
28 ifdef CONFIG_RELOCATABLE 29 LDFLAGS_vmlinux := --emit-relocs 30 endif 31 | |
32 KBUILD_CFLAGS += -msoft-float -mregparm=3 -freg-struct-return 33 34 # Never want PIC in a 32-bit kernel, prevent breakage with GCC built 35 # with nonstandard options 36 KBUILD_CFLAGS += -fno-pic 37 38 # prevent gcc from keeping the stack 16 byte aligned 39 KBUILD_CFLAGS += $(call cc-option,-mpreferred-stack-boundary=2) --- 204 unchanged lines hidden --- | 32 KBUILD_CFLAGS += -msoft-float -mregparm=3 -freg-struct-return 33 34 # Never want PIC in a 32-bit kernel, prevent breakage with GCC built 35 # with nonstandard options 36 KBUILD_CFLAGS += -fno-pic 37 38 # prevent gcc from keeping the stack 16 byte aligned 39 KBUILD_CFLAGS += $(call cc-option,-mpreferred-stack-boundary=2) --- 204 unchanged lines hidden --- |