mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-18 17:54:13 +08:00
ffd602eb46
- do not generate unneeded top-level built-in.a - let git ignore O= directory entirely - optimize scripts/kallsyms slightly - exclude DWARF info from *.s regardless of config options - fix GCC toolchain search path for Clang to prepare ld.lld support - do not generate modules.order when CONFIG_MODULES is disabled - simplify single target rules and remove VPATH for external module build - allow to add optional flags to dpkg-buildpackage when building deb-pkg - move some compiler option tests from Makefile to Kconfig - various Makefile cleanups -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAABAgAGBQJcgxYUAAoJED2LAQed4NsGr7YQAJq4LmN/aZDI9Mt0YAQjEyyA PCpm8J2HI9HO1sMoY7J/ksWmV0BU25G+uspKD7dXAQo3l9fmahQM5e4dsyZ4Xqs8 DyyYSGtJJnMJaWmupIZNA4UKDCVtwPoVW8YeuK9rwADVokCux9avogof9O1OoA/E Pylo+I4UCM82kbpZSd+UxnCx6B0v8XGtW+d31Q4yZXCkw5nw14chrlaprcqB3UgB +7C3xOnDWCi7gyxaTqmD7dLay2DM8KCDlznEvBL733Y/cK3to1fywzEPzp0JQCLX BLgmmpW13NF++q5BCoTW6sFjZAhBVbiYZwesMrCi75Y32T8zt4G5l4pkvGkSuGF/ UQh5aoCxaMIp70VPj/loZ0lh78nwVGTok9zRb0rfztM0X4DbmiPi5MNiHRzRpIeE 1jjEa/GK1t0TDnXc/MuDFK8cWwdhttIqUL5yWfAxjXbtP27eLtsopQUdW7EPHs7d sMnfuSUuhOC28yByVxIkBcwawLyYrcWRphJ3ixCO70CoJWt2DT6aOKxcFJefoJix Pto6Oo3oQ4iypMM5M9/0Uo+AK2TKRejWIqtZdbo+ir70tNxVH3WDZq++fG0drXOB r2I/GY6nRjuzLOe2jzEqywFTFd2xpk4Qo84LGb1R3U6aU5qS2gA0W/q00JS5c2qU R8uReJ7bvmLmrVNZ/NI4 =y9YG -----END PGP SIGNATURE----- Merge tag 'kbuild-v5.1' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild Pull Kbuild updates from Masahiro Yamada: - do not generate unneeded top-level built-in.a - let git ignore O= directory entirely - optimize scripts/kallsyms slightly - exclude DWARF info from *.s regardless of config options - fix GCC toolchain search path for Clang to prepare ld.lld support - do not generate modules.order when CONFIG_MODULES is disabled - simplify single target rules and remove VPATH for external module build - allow to add optional flags to dpkg-buildpackage when building deb-pkg - move some compiler option tests from Makefile to Kconfig - various Makefile cleanups * tag 'kbuild-v5.1' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild: (40 commits) kbuild: remove scripts/basic/% build target kbuild: use -Werror=implicit-... instead of -Werror-implicit-... kbuild: clean up scripts/gcc-version.sh kbuild: remove cc-version macro kbuild: update comment block of scripts/clang-version.sh kbuild: remove commented-out INITRD_COMPRESS kbuild: move -gsplit-dwarf, -gdwarf-4 option tests to Kconfig kbuild: [bin]deb-pkg: add DPKG_FLAGS variable kbuild: move ".config not found!" message from Kconfig to Makefile kbuild: invoke syncconfig if include/config/auto.conf.cmd is missing kbuild: simplify single target rules kbuild: remove empty rules for makefiles kbuild: make -r/-R effective in top Makefile for old Make versions kbuild: move tools_silent to a more relevant place kbuild: compute false-positive -Wmaybe-uninitialized cases in Kconfig kbuild: refactor cc-cross-prefix implementation kbuild: hardcode genksyms path and remove GENKSYMS variable scripts/gdb: refactor rules for symlink creation kbuild: create symlink to vmlinux-gdb.py in scripts_gdb target scripts/gdb: do not descend into scripts/gdb from scripts ...
67 lines
1.5 KiB
Makefile
67 lines
1.5 KiB
Makefile
# SPDX-License-Identifier: GPL-2.0
|
|
#
|
|
# Kbuild for top-level directory of the kernel
|
|
|
|
#####
|
|
# Generate bounds.h
|
|
|
|
bounds-file := include/generated/bounds.h
|
|
|
|
always := $(bounds-file)
|
|
targets := kernel/bounds.s
|
|
|
|
$(bounds-file): kernel/bounds.s FORCE
|
|
$(call filechk,offsets,__LINUX_BOUNDS_H__)
|
|
|
|
#####
|
|
# Generate timeconst.h
|
|
|
|
timeconst-file := include/generated/timeconst.h
|
|
|
|
targets += $(timeconst-file)
|
|
|
|
filechk_gentimeconst = echo $(CONFIG_HZ) | bc -q $<
|
|
|
|
$(timeconst-file): kernel/time/timeconst.bc FORCE
|
|
$(call filechk,gentimeconst)
|
|
|
|
#####
|
|
# Generate asm-offsets.h
|
|
|
|
offsets-file := include/generated/asm-offsets.h
|
|
|
|
always += $(offsets-file)
|
|
targets += arch/$(SRCARCH)/kernel/asm-offsets.s
|
|
|
|
arch/$(SRCARCH)/kernel/asm-offsets.s: $(timeconst-file) $(bounds-file)
|
|
|
|
$(offsets-file): arch/$(SRCARCH)/kernel/asm-offsets.s FORCE
|
|
$(call filechk,offsets,__ASM_OFFSETS_H__)
|
|
|
|
#####
|
|
# Check for missing system calls
|
|
|
|
always += missing-syscalls
|
|
targets += missing-syscalls
|
|
|
|
quiet_cmd_syscalls = CALL $<
|
|
cmd_syscalls = $(CONFIG_SHELL) $< $(CC) $(c_flags) $(missing_syscalls_flags)
|
|
|
|
missing-syscalls: scripts/checksyscalls.sh $(offsets-file) FORCE
|
|
$(call cmd,syscalls)
|
|
|
|
#####
|
|
# Check atomic headers are up-to-date
|
|
|
|
always += old-atomics
|
|
targets += old-atomics
|
|
|
|
quiet_cmd_atomics = CALL $<
|
|
cmd_atomics = $(CONFIG_SHELL) $<
|
|
|
|
old-atomics: scripts/atomic/check-atomics.sh FORCE
|
|
$(call cmd,atomics)
|
|
|
|
# Keep these three files during make clean
|
|
no-clean-files := $(bounds-file) $(offsets-file) $(timeconst-file)
|