Makefile (4f9786035f9e519db41375818e1d0b5f20da2f10) Makefile (a45728fd4120011c78af1d056e571b84d47dfcc1)
1# SPDX-License-Identifier: GPL-2.0
2#
3# The stub may be linked into the kernel proper or into a separate boot binary,
4# but in either case, it executes before the kernel does (with MMU disabled) so
5# things like ftrace and stack-protector are likely to cause trouble if left
6# enabled, even if doing so doesn't break the build.
7#
8

--- 17 unchanged lines hidden (view full) ---

26 -fno-unwind-tables -fno-asynchronous-unwind-tables
27cflags-$(CONFIG_ARM) += -DEFI_HAVE_STRLEN -DEFI_HAVE_STRNLEN \
28 -DEFI_HAVE_MEMCHR -DEFI_HAVE_STRRCHR \
29 -DEFI_HAVE_STRCMP -fno-builtin -fpic \
30 $(call cc-option,-mno-single-pic-base) \
31 $(DISABLE_STACKLEAK_PLUGIN)
32cflags-$(CONFIG_RISCV) += -fpic -DNO_ALTERNATIVE -mno-relax \
33 $(DISABLE_STACKLEAK_PLUGIN)
1# SPDX-License-Identifier: GPL-2.0
2#
3# The stub may be linked into the kernel proper or into a separate boot binary,
4# but in either case, it executes before the kernel does (with MMU disabled) so
5# things like ftrace and stack-protector are likely to cause trouble if left
6# enabled, even if doing so doesn't break the build.
7#
8

--- 17 unchanged lines hidden (view full) ---

26 -fno-unwind-tables -fno-asynchronous-unwind-tables
27cflags-$(CONFIG_ARM) += -DEFI_HAVE_STRLEN -DEFI_HAVE_STRNLEN \
28 -DEFI_HAVE_MEMCHR -DEFI_HAVE_STRRCHR \
29 -DEFI_HAVE_STRCMP -fno-builtin -fpic \
30 $(call cc-option,-mno-single-pic-base) \
31 $(DISABLE_STACKLEAK_PLUGIN)
32cflags-$(CONFIG_RISCV) += -fpic -DNO_ALTERNATIVE -mno-relax \
33 $(DISABLE_STACKLEAK_PLUGIN)
34cflags-$(CONFIG_LOONGARCH) += -fpie
34cflags-$(CONFIG_LOONGARCH) += -fpie $(DISABLE_STACKLEAK_PLUGIN)
35
36cflags-$(CONFIG_EFI_PARAMS_FROM_FDT) += -I$(srctree)/scripts/dtc/libfdt
37
38KBUILD_CFLAGS := $(subst $(CC_FLAGS_FTRACE),,$(cflags-y)) \
39 -Os -DDISABLE_BRANCH_PROFILING \
40 -include $(srctree)/include/linux/hidden.h \
41 -D__NO_FORTIFY \
42 -ffreestanding \

--- 131 unchanged lines hidden ---
35
36cflags-$(CONFIG_EFI_PARAMS_FROM_FDT) += -I$(srctree)/scripts/dtc/libfdt
37
38KBUILD_CFLAGS := $(subst $(CC_FLAGS_FTRACE),,$(cflags-y)) \
39 -Os -DDISABLE_BRANCH_PROFILING \
40 -include $(srctree)/include/linux/hidden.h \
41 -D__NO_FORTIFY \
42 -ffreestanding \

--- 131 unchanged lines hidden ---