# SPDX-License-Identifier: GPL-2.0
VERSION = 4
PATCHLEVEL = 14
-SUBLEVEL = 98
+SUBLEVEL = 113
EXTRAVERSION =
NAME = Petit Gorille
sub-make:
$(Q)$(MAKE) -C $(KBUILD_OUTPUT) KBUILD_SRC=$(CURDIR) \
-f $(CURDIR)/Makefile $(filter-out _all sub-make,$(MAKECMDGOALS))
+ @lib/libdss-build.sh $(KBUILD_OUTPUT)/
# Leave processing to above invocation of make
skip-makefile := 1
PYTHON = python
CHECK = sparse
+ifeq ($(CONFIG_EXYNOS_FMP_FIPS),)
+READELF = $(CROSS_COMPILE)readelf
+export READELF
+endif
+
CHECKFLAGS := -D__linux__ -Dlinux -D__STDC__ -Dunix -D__unix__ \
-Wbitwise -Wno-return-void $(CF)
NOSTDINC_FLAGS =
-fno-strict-aliasing -fno-common -fshort-wchar \
-Werror-implicit-function-declaration \
-Wno-format-security \
+ -Werror \
-std=gnu89
KBUILD_CPPFLAGS := -D__KERNEL__
KBUILD_AFLAGS_KERNEL :=
ifneq ($(CROSS_COMPILE),)
CLANG_TRIPLE ?= $(CROSS_COMPILE)
CLANG_FLAGS := --target=$(notdir $(CLANG_TRIPLE:%-=%))
-GCC_TOOLCHAIN_DIR := $(dir $(shell which $(LD)))
+GCC_TOOLCHAIN_DIR := $(dir $(shell which $(CROSS_COMPILE)elfedit))
CLANG_FLAGS += --prefix=$(GCC_TOOLCHAIN_DIR)
GCC_TOOLCHAIN := $(realpath $(GCC_TOOLCHAIN_DIR)/..)
endif
# command line.
# This allow a user to issue only 'make' to build a kernel including modules
# Defaults to vmlinux, but the arch makefile usually adds further targets
+ifneq ($(O),)
all: vmlinux
+else
+all: vmlinux
+ @lib/libdss-build.sh
+endif
KBUILD_CFLAGS += $(call cc-option,-fno-PIE)
KBUILD_AFLAGS += $(call cc-option,-fno-PIE)
# use GNU gold with LLVMgold for LTO linking, and LD for vmlinux_link
LDFINAL_vmlinux := $(LD)
LD := $(LDGOLD)
-LDFLAGS += -plugin LLVMgold.so
+LDFLAGS += -plugin $(LTO_LLVM_LIB_BASE)LLVMgold.so
# use llvm-ar for building symbol tables from IR files, and llvm-dis instead
# of objdump for processing symbol versions and exports
-LLVM_AR := llvm-ar
-LLVM_DIS := llvm-dis
+LLVM_AR ?= llvm-ar
+LLVM_DIS ?= llvm-dis
export LLVM_AR LLVM_DIS
endif