Adding trailing slash to $(srctree)
Subsystems (152)
cover Adding trailing slash to $(srctree)
The subject states exactly what I'm suggesting.
The reason is the fallback value for $(srctree) of "." doesn't work properly in several places under some conditions. In particular in several places a pattern of "$(srctree)/$(src)" is used. If $(srctree) ends up with the value "." and $(src) ends up with the value pwd, the build breaks. This can be triggered via in-tree/out-of-tree build mechanisms.
As such, assuming $(srctree) includes the trailing slash and setting the fallback for $(srctree) to "" fixes things. This is untested, I'm proposing this since I wanted to use a build approach which triggers this. This is really a single patch, but it has been split into 3 to emphasize where the real work is done.
I'm suspicious of the fallback settings of $(srctree) found in several Makefiles. This might be a distinct workaround for the same situation. I was wondering about adjusting some of those comments too. I think $(src) needs similar treatment, but that is rather messier.
Note, this is basically untested. I'm hopeful this actually works, but if it breaks then this was mostly to alert the maintainers of this troublesome condition.
Elliott Mitchell (3):
build: add trailing slash to $(srctree)
build: modify uses of $(srctree) to assume trailing slash
build: change $(srctree) to empty for current directory
Documentation/Makefile | 48 +++--- Documentation/devicetree/bindings/Makefile | 18 +-- Documentation/userspace-api/media/Makefile | 10 +- Makefile | 152 +++++++++--------- arch/alpha/boot/Makefile | 2 +- arch/alpha/kernel/syscalls/Makefile | 4 +- arch/arc/Makefile | 2 +- arch/arc/boot/dts/Makefile | 2 +- arch/arm/Makefile | 4 +- arch/arm/boot/Makefile | 2 +- arch/arm/boot/compressed/Makefile | 2 +- arch/arm/mach-dove/Makefile | 2 +- arch/arm/mach-mv78xx0/Makefile | 2 +- arch/arm/mach-mvebu/Makefile | 2 +- arch/arm/mach-orion5x/Makefile | 2 +- arch/arm/mach-s3c/Makefile | 2 +- arch/arm/plat-orion/Makefile | 2 +- arch/arm/tools/Makefile | 6 +- arch/arm/vdso/Makefile | 2 +- arch/arm64/Makefile | 2 +- arch/arm64/boot/Makefile | 2 +- arch/arm64/kernel/pi/Makefile | 6 +- arch/arm64/kernel/vdso/Makefile | 4 +- arch/arm64/kernel/vdso32/Makefile | 2 +- arch/arm64/kvm/Makefile | 6 +- arch/arm64/kvm/hyp/Makefile | 2 +- arch/csky/Makefile | 2 +- arch/csky/boot/dts/Makefile | 2 +- arch/csky/kernel/vdso/Makefile | 4 +- arch/loongarch/boot/Makefile | 2 +- arch/loongarch/kvm/Makefile | 4 +- arch/loongarch/vdso/Makefile | 4 +- arch/m68k/kernel/syscalls/Makefile | 4 +- arch/microblaze/kernel/syscalls/Makefile | 4 +- arch/mips/Makefile | 18 +-- arch/mips/Makefile.postlink | 2 +- arch/mips/boot/Makefile | 2 +- arch/mips/boot/compressed/Makefile | 4 +- arch/mips/kernel/syscalls/Makefile | 6 +- arch/mips/kvm/Makefile | 2 +- arch/mips/vdso/Makefile | 6 +- arch/nios2/boot/dts/Makefile | 2 +- arch/parisc/Makefile | 4 +- arch/parisc/kernel/syscalls/Makefile | 4 +- arch/parisc/kernel/vdso32/Makefile | 2 +- arch/parisc/kernel/vdso64/Makefile | 2 +- arch/powerpc/Makefile | 30 ++-- arch/powerpc/Makefile.postlink | 10 +- arch/powerpc/boot/Makefile | 32 ++-- arch/powerpc/boot/dts/Makefile | 2 +- arch/powerpc/boot/dts/fsl/Makefile | 2 +- arch/powerpc/kernel/syscalls/Makefile | 4 +- arch/powerpc/kernel/vdso/Makefile | 6 +- arch/powerpc/kvm/Makefile | 2 +- arch/powerpc/platforms/cell/spufs/Makefile | 4 +- arch/riscv/Makefile | 12 +- arch/riscv/Makefile.postlink | 4 +- arch/riscv/boot/Makefile | 2 +- arch/riscv/kernel/compat_vdso/Makefile | 2 +- arch/riscv/kernel/pi/Makefile | 8 +- arch/riscv/kernel/vdso/Makefile | 4 +- arch/riscv/kvm/Makefile | 4 +- arch/riscv/purgatory/Makefile | 16 +- arch/s390/Makefile | 2 +- arch/s390/boot/Makefile | 2 +- arch/s390/kernel/syscalls/Makefile | 4 +- arch/s390/kernel/vdso32/Makefile | 4 +- arch/s390/kernel/vdso64/Makefile | 4 +- arch/s390/kvm/Makefile | 2 +- arch/s390/purgatory/Makefile | 4 +- arch/s390/tools/Makefile | 2 +- arch/sh/Makefile | 2 +- arch/sh/kernel/syscalls/Makefile | 4 +- arch/sparc/kernel/syscalls/Makefile | 4 +- arch/sparc/vdso/Makefile | 4 +- arch/um/Makefile | 22 +-- arch/um/drivers/Makefile | 2 +- arch/um/kernel/Makefile | 4 +- arch/um/kernel/skas/Makefile | 2 +- arch/um/os-Linux/Makefile | 2 +- arch/um/os-Linux/drivers/Makefile | 2 +- arch/um/os-Linux/skas/Makefile | 2 +- arch/um/scripts/Makefile.rules | 2 +- arch/x86/Makefile | 6 +- arch/x86/Makefile.postlink | 2 +- arch/x86/Makefile.um | 2 +- arch/x86/boot/Makefile | 6 +- arch/x86/boot/compressed/Makefile | 6 +- arch/x86/entry/syscalls/Makefile | 8 +- arch/x86/entry/vdso/Makefile | 6 +- arch/x86/kernel/Makefile | 2 +- arch/x86/kernel/cpu/Makefile | 2 +- arch/x86/kvm/Makefile | 4 +- arch/x86/lib/Makefile | 4 +- arch/x86/mm/Makefile | 2 +- arch/x86/purgatory/Makefile | 4 +- arch/x86/realmode/rm/Makefile | 2 +- arch/x86/tools/Makefile | 14 +- arch/x86/um/Makefile | 2 +- arch/x86/um/os-Linux/Makefile | 2 +- arch/x86/um/vdso/Makefile | 2 +- arch/xtensa/Makefile | 2 +- arch/xtensa/boot/boot-redboot/Makefile | 2 +- arch/xtensa/boot/dts/Makefile | 2 +- arch/xtensa/boot/lib/Makefile | 4 +- arch/xtensa/kernel/syscalls/Makefile | 4 +- certs/Makefile | 4 +- drivers/Makefile | 2 +- drivers/accessibility/speakup/Makefile | 2 +- drivers/base/firmware_loader/builtin/Makefile | 2 +- drivers/block/rnbd/Makefile | 2 +- drivers/crypto/chelsio/Makefile | 2 +- drivers/crypto/intel/iaa/Makefile | 2 +- drivers/crypto/intel/qat/qat_420xx/Makefile | 2 +- drivers/crypto/intel/qat/qat_4xxx/Makefile | 2 +- drivers/crypto/intel/qat/qat_c3xxx/Makefile | 2 +- drivers/crypto/intel/qat/qat_c3xxxvf/Makefile | 2 +- drivers/crypto/intel/qat/qat_c62x/Makefile | 2 +- drivers/crypto/intel/qat/qat_c62xvf/Makefile | 2 +- .../crypto/intel/qat/qat_dh895xcc/Makefile | 2 +- .../crypto/intel/qat/qat_dh895xccvf/Makefile | 2 +- drivers/crypto/marvell/octeontx2/Makefile | 2 +- drivers/cxl/core/Makefile | 2 +- drivers/firmware/efi/libstub/Makefile | 6 +- drivers/firmware/efi/libstub/Makefile.zboot | 4 +- drivers/gpu/drm/amd/amdgpu/Makefile | 2 +- drivers/gpu/drm/arm/display/komeda/Makefile | 4 +- drivers/gpu/drm/i915/Makefile | 8 +- drivers/gpu/drm/imagination/Makefile | 2 +- drivers/gpu/drm/msm/Makefile | 8 +- drivers/gpu/drm/xe/Makefile | 18 +-- drivers/hid/amd-sfh-hid/Makefile | 2 +- drivers/hid/bpf/Makefile | 2 +- drivers/hid/intel-ish-hid/Makefile | 2 +- drivers/iio/humidity/Makefile | 2 +- drivers/infiniband/hw/bnxt_re/Makefile | 2 +- drivers/infiniband/hw/cxgb4/Makefile | 4 +- drivers/infiniband/hw/hns/Makefile | 2 +- drivers/infiniband/hw/ocrdma/Makefile | 2 +- drivers/infiniband/hw/usnic/Makefile | 2 +- drivers/media/common/b2c2/Makefile | 4 +- drivers/media/dvb-frontends/Makefile | 4 +- drivers/media/dvb-frontends/drx39xyj/Makefile | 2 +- drivers/media/i2c/ccs/Makefile | 2 +- drivers/media/mmc/siano/Makefile | 2 +- drivers/media/pci/b2c2/Makefile | 2 +- drivers/media/pci/bt8xx/Makefile | 4 +- drivers/media/pci/cx18/Makefile | 4 +- drivers/media/pci/cx23885/Makefile | 4 +- drivers/media/pci/cx88/Makefile | 4 +- drivers/media/pci/ddbridge/Makefile | 4 +- drivers/media/pci/dm1105/Makefile | 2 +- drivers/media/pci/ivtv/Makefile | 4 +- drivers/media/pci/mantis/Makefile | 2 +- drivers/media/pci/netup_unidvb/Makefile | 2 +- drivers/media/pci/ngene/Makefile | 4 +- drivers/media/pci/pluto2/Makefile | 2 +- drivers/media/pci/pt1/Makefile | 4 +- drivers/media/pci/pt3/Makefile | 4 +- drivers/media/pci/saa7134/Makefile | 6 +- drivers/media/pci/saa7146/Makefile | 2 +- drivers/media/pci/saa7164/Makefile | 4 +- drivers/media/pci/smipcie/Makefile | 4 +- drivers/media/pci/ttpci/Makefile | 6 +- drivers/media/platform/mediatek/mdp/Makefile | 2 +- .../media/platform/st/sti/c8sectpfe/Makefile | 4 +- drivers/media/spi/Makefile | 2 +- drivers/media/tuners/Makefile | 2 +- drivers/media/usb/as102/Makefile | 2 +- drivers/media/usb/au0828/Makefile | 4 +- drivers/media/usb/b2c2/Makefile | 2 +- drivers/media/usb/cx231xx/Makefile | 4 +- drivers/media/usb/dvb-usb-v2/Makefile | 6 +- drivers/media/usb/dvb-usb/Makefile | 6 +- drivers/media/usb/em28xx/Makefile | 4 +- drivers/media/usb/go7007/Makefile | 2 +- drivers/media/usb/gspca/gl860/Makefile | 2 +- drivers/media/usb/gspca/m5602/Makefile | 2 +- drivers/media/usb/gspca/stv06xx/Makefile | 2 +- drivers/media/usb/pvrusb2/Makefile | 4 +- drivers/media/usb/siano/Makefile | 2 +- drivers/media/usb/ttusb-budget/Makefile | 2 +- drivers/media/v4l2-core/Makefile | 4 +- .../net/ethernet/aquantia/atlantic/Makefile | 2 +- .../chelsio/inline_crypto/ch_ipsec/Makefile | 4 +- .../chelsio/inline_crypto/ch_ktls/Makefile | 2 +- .../chelsio/inline_crypto/chtls/Makefile | 4 +- drivers/net/ethernet/chelsio/libcxgb/Makefile | 2 +- drivers/net/ethernet/freescale/dpaa/Makefile | 2 +- drivers/net/ethernet/freescale/fman/Makefile | 2 +- drivers/net/ethernet/fungible/funeth/Makefile | 2 +- drivers/net/ethernet/hisilicon/hns3/Makefile | 8 +- .../ethernet/marvell/octeontx2/nic/Makefile | 2 +- .../net/ethernet/microchip/lan966x/Makefile | 2 +- .../net/ethernet/microchip/sparx5/Makefile | 2 +- drivers/net/wan/Makefile | 2 +- .../broadcom/brcm80211/brcmfmac/Makefile | 4 +- .../broadcom/brcm80211/brcmfmac/bca/Makefile | 6 +- .../broadcom/brcm80211/brcmfmac/cyw/Makefile | 6 +- .../broadcom/brcm80211/brcmfmac/wcc/Makefile | 6 +- .../broadcom/brcm80211/brcmsmac/Makefile | 6 +- .../broadcom/brcm80211/brcmutil/Makefile | 2 +- .../net/wireless/intel/iwlwifi/dvm/Makefile | 2 +- .../net/wireless/intel/iwlwifi/mei/Makefile | 2 +- .../net/wireless/intel/iwlwifi/mvm/Makefile | 2 +- .../wireless/realtek/rtl818x/rtl8180/Makefile | 2 +- .../wireless/realtek/rtl818x/rtl8187/Makefile | 2 +- drivers/pinctrl/renesas/Makefile | 24 +-- drivers/scsi/aic7xxx/Makefile | 12 +- drivers/scsi/csiostor/Makefile | 2 +- drivers/scsi/cxgbi/Makefile | 2 +- drivers/scsi/libsas/Makefile | 2 +- drivers/scsi/pcmcia/Makefile | 2 +- drivers/staging/media/atomisp/Makefile | 2 +- drivers/staging/media/av7110/Makefile | 8 +- drivers/staging/rtl8723bs/Makefile | 2 +- drivers/target/iscsi/cxgbit/Makefile | 6 +- drivers/tty/serial/8250/Makefile | 2 +- drivers/usb/gadget/function/Makefile | 4 +- drivers/usb/gadget/legacy/Makefile | 6 +- drivers/usb/storage/Makefile | 2 +- drivers/vdpa/mlx5/Makefile | 2 +- fs/hostfs/Makefile | 2 +- fs/iomap/Makefile | 2 +- fs/unicode/Makefile | 14 +- fs/xfs/Makefile | 4 +- init/Makefile | 2 +- kernel/Makefile | 2 +- kernel/bpf/Makefile | 2 +- kernel/bpf/preload/Makefile | 2 +- kernel/gcov/Makefile | 2 +- lib/Makefile | 16 +- lib/raid6/Makefile | 2 +- net/wireless/Makefile | 2 +- rust/Makefile | 14 +- samples/bpf/Makefile | 24 +-- samples/coresight/Makefile | 2 +- samples/hid/Makefile | 16 +- scripts/Makefile | 6 +- scripts/Makefile.asm-generic | 8 +- scripts/Makefile.build | 22 +-- scripts/Makefile.clean | 2 +- scripts/Makefile.defconf | 16 +- scripts/Makefile.dtbinst | 2 +- scripts/Makefile.headersinst | 10 +- scripts/Makefile.lib | 22 +-- scripts/Makefile.modfinal | 4 +- scripts/Makefile.modinst | 6 +- scripts/Makefile.modpost | 4 +- scripts/Makefile.package | 22 +-- scripts/Makefile.vdsoinst | 2 +- scripts/Makefile.vmlinux | 6 +- scripts/Makefile.vmlinux_o | 8 +- scripts/basic/Makefile | 2 +- scripts/dtc/Makefile | 6 +- scripts/gcc-plugins/Makefile | 2 +- scripts/gdb/linux/Makefile | 2 +- scripts/genksyms/Makefile | 4 +- scripts/kconfig/Makefile | 22 +-- scripts/selinux/genheaders/Makefile | 4 +- scripts/selinux/mdp/Makefile | 4 +- security/apparmor/Makefile | 8 +- security/selinux/Makefile | 2 +- security/tomoyo/Makefile | 2 +- tools/bootconfig/Makefile | 6 +- tools/bpf/Makefile | 16 +- tools/bpf/bpftool/Makefile | 24 +-- tools/bpf/resolve_btfids/Makefile | 12 +- tools/build/Makefile | 8 +- tools/build/Makefile.build | 2 +- tools/build/Makefile.feature | 2 +- tools/build/Makefile.include | 6 +- tools/build/tests/ex/Makefile | 4 +- tools/counter/Makefile | 8 +- tools/gpio/Makefile | 6 +- tools/hv/Makefile | 6 +- tools/iio/Makefile | 6 +- tools/include/nolibc/Makefile | 4 +- tools/lib/api/Makefile | 14 +- tools/lib/bpf/Makefile | 22 +-- tools/lib/perf/Makefile | 26 +-- tools/lib/subcmd/Makefile | 10 +- tools/lib/symbol/Makefile | 14 +- tools/lib/thermal/Makefile | 26 +-- tools/objtool/Makefile | 18 +-- tools/pci/Makefile | 6 +- tools/perf/Makefile.config | 22 +-- tools/perf/Makefile.perf | 136 ++++++++-------- tools/perf/arch/arm64/Makefile | 6 +- tools/perf/arch/loongarch/Makefile | 6 +- tools/perf/arch/mips/Makefile | 2 +- tools/perf/arch/powerpc/Makefile | 2 +- tools/perf/arch/s390/Makefile | 2 +- tools/perf/arch/x86/Makefile | 2 +- tools/power/acpi/Makefile.config | 10 +- tools/power/acpi/Makefile.rules | 2 +- tools/power/acpi/tools/acpidump/Makefile | 2 +- tools/power/acpi/tools/pfrut/Makefile | 2 +- tools/power/x86/intel-speed-select/Makefile | 10 +- tools/spi/Makefile | 6 +- tools/testing/selftests/nolibc/Makefile | 14 +- tools/thermal/lib/Makefile | 24 +-- tools/thermal/thermal-engine/Makefile | 14 +- tools/thermal/thermometer/Makefile | 10 +- tools/usb/Makefile | 8 +- usr/Makefile | 2 +- usr/include/Makefile | 4 +- 307 files changed, 960 insertions(+), 960 deletions(-)
Signature · 1 line
2.39.2
RFC PATCH 1/3 build: add trailing slash to $(srctree)
This better handles the case of $(srctree) being the current directory and $(src) being an absolute path. Instead of being ".", $(srctree) ends up empty, and $(src) can be directly appended.
---
I suspect the Makefile sections besides the top-level are attempting to solve the *exact* *same* issue. Problem is that workaround requires changes in every Makefile, whereas this looks closer to the root cause.
I'm less than 100% sure I've avoided all spacing changes. I forget where, but I seem to recall running into a space which was instead a tab.
--- Makefile | 8 ++++---- tools/bootconfig/Makefile | 4 ++-- tools/bpf/Makefile | 4 ++-- tools/bpf/bpftool/Makefile | 6 +++--- tools/build/Makefile | 4 ++-- tools/counter/Makefile | 4 ++-- tools/gpio/Makefile | 4 ++-- tools/hv/Makefile | 4 ++-- tools/iio/Makefile | 4 ++-- tools/include/nolibc/Makefile | 2 +- tools/lib/api/Makefile | 6 +++--- tools/lib/bpf/Makefile | 6 +++--- tools/lib/perf/Makefile | 6 +++--- tools/lib/subcmd/Makefile | 6 +++--- tools/lib/symbol/Makefile | 6 +++--- tools/lib/thermal/Makefile | 6 +++--- tools/objtool/Makefile | 4 ++-- tools/pci/Makefile | 4 ++-- tools/perf/Makefile.perf | 4 ++-- tools/power/acpi/Makefile.config | 4 ++-- tools/power/x86/intel-speed-select/Makefile | 8 ++++---- tools/spi/Makefile | 4 ++-- tools/testing/selftests/nolibc/Makefile | 2 +- tools/thermal/lib/Makefile | 6 +++--- tools/thermal/thermal-engine/Makefile | 6 +++--- tools/thermal/thermometer/Makefile | 6 +++--- tools/usb/Makefile | 4 ++-- 27 files changed, 66 insertions(+), 66 deletions(-)
Makefile +4 -4
@@ -246,20 +246,20 @@ else # need-sub-make ifeq ($(abs_srctree),$(abs_objtree)) # building in the source tree - srctree := . + srctree := ./ building_out_of_srctree := else ifeq ($(abs_srctree)/,$(dir $(abs_objtree))) # building in a subdirectory of the source tree - srctree := .. + srctree := ../ else - srctree := $(abs_srctree) + srctree := $(abs_srctree)/ endif building_out_of_srctree := 1 endif ifneq ($(KBUILD_ABS_SRCTREE),) -srctree := $(abs_srctree) +srctree := $(abs_srctree)/ endif objtree := .
tools/bootconfig/Makefile +2 -2
@@ -5,8 +5,8 @@ include ../scripts/Makefile.include bindir ?= /usr/bin ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) endif LIBSRC = $(srctree)/lib/bootconfig.c $(srctree)/include/linux/bootconfig.h
tools/bpf/Makefile +2 -2
@@ -23,8 +23,8 @@ ifndef building_out_of_srctree update_srctree := 1 endif ifeq ($(update_srctree),1) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) endif ifeq ($(V),1)
tools/bpf/bpftool/Makefile +3 -3
@@ -2,9 +2,9 @@ include ../../scripts/Makefile.include ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) endif ifeq ($(V),1)
tools/build/Makefile +2 -2
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) endif include $(srctree)/tools//scripts/Makefile.include
tools/counter/Makefile +2 -2
@@ -4,8 +4,8 @@ include ../scripts/Makefile.include bindir ?= /usr/bin ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) endif # Do not use make's built-in rules
tools/gpio/Makefile +2 -2
@@ -8,8 +8,8 @@ bindir ?= /usr/bin # is set to ".". building_out_of_srctree is undefined for in srctree # builds ifndef building_out_of_srctree -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) endif # Do not use make's built-in rules
tools/hv/Makefile +2 -2
@@ -7,8 +7,8 @@ libexecdir ?= /usr/libexec sharedstatedir ?= /var/lib ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) endif # Do not use make's built-in rules
tools/iio/Makefile +2 -2
@@ -4,8 +4,8 @@ include ../scripts/Makefile.include bindir ?= /usr/bin ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) endif # Do not use make's built-in rules
tools/include/nolibc/Makefile +1 -1
@@ -4,7 +4,7 @@ include ../../scripts/Makefile.include # we're in ".../tools/include/nolibc" ifeq ($(srctree),) -srctree := $(patsubst %/tools/include/,%,$(dir $(CURDIR))) +srctree := $(patsubst %tools/include/,%,$(dir $(CURDIR))) endif # when run as make -C tools/ nolibc_<foo> the arch is not set
tools/lib/api/Makefile +3 -3
@@ -3,9 +3,9 @@ include ../../scripts/Makefile.include include ../../scripts/utilities.mak # QUIET_CLEAN ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) #$(info Determined 'srctree' to be $(srctree)) endif
tools/lib/bpf/Makefile +3 -3
@@ -18,9 +18,9 @@ MAKEFLAGS += --no-print-directory # is a ".". building_out_of_srctree is undefined for in srctree # builds ifndef building_out_of_srctree -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) #$(info Determined 'srctree' to be $(srctree)) endif
tools/lib/perf/Makefile +3 -3
@@ -8,9 +8,9 @@ LIBPERF_EXTRAVERSION = 1 MAKEFLAGS += --no-print-directory ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) #$(info Determined 'srctree' to be $(srctree)) endif
tools/lib/subcmd/Makefile +3 -3
@@ -3,9 +3,9 @@ include ../../scripts/Makefile.include include ../../scripts/utilities.mak # QUIET_CLEAN ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) #$(info Determined 'srctree' to be $(srctree)) endif
tools/lib/symbol/Makefile +3 -3
@@ -3,9 +3,9 @@ include ../../scripts/Makefile.include include ../../scripts/utilities.mak # QUIET_CLEAN ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) #$(info Determined 'srctree' to be $(srctree)) endif
tools/lib/thermal/Makefile +3 -3
@@ -8,9 +8,9 @@ LIBTHERMAL_EXTRAVERSION = 1 MAKEFLAGS += --no-print-directory ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) # $(info Determined 'srctree' to be $(srctree)) endif
tools/objtool/Makefile +2 -2
@@ -3,8 +3,8 @@ include ../scripts/Makefile.include include ../scripts/Makefile.arch ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) endif LIBSUBCMD_DIR = $(srctree)/tools/lib/subcmd/
tools/pci/Makefile +2 -2
@@ -4,8 +4,8 @@ include ../scripts/Makefile.include bindir ?= /usr/bin ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) endif # Do not use make's built-in rules
tools/perf/Makefile.perf +2 -2
@@ -144,8 +144,8 @@ LC_NUMERIC=C export LC_COLLATE LC_NUMERIC ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) #$(info Determined 'srctree' to be $(srctree)) endif
tools/power/acpi/Makefile.config +2 -2
@@ -6,8 +6,8 @@ # ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(shell pwd))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) #$(info Determined 'srctree' to be $(srctree)) endif
tools/power/x86/intel-speed-select/Makefile +4 -4
@@ -4,10 +4,10 @@ include ../../../scripts/Makefile.include bindir ?= /usr/bin ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) endif # Do not use make's built-in rules
tools/spi/Makefile +2 -2
@@ -4,8 +4,8 @@ include ../scripts/Makefile.include bindir ?= /usr/bin ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) endif # Do not use make's built-in rules
tools/testing/selftests/nolibc/Makefile +1 -1
@@ -13,7 +13,7 @@ endif # we're in ".../tools/testing/selftests/nolibc" ifeq ($(srctree),) -srctree := $(patsubst %/tools/testing/selftests/,%,$(dir $(CURDIR))) +srctree := $(patsubst %tools/testing/selftests/,%,$(dir $(CURDIR))) endif ifeq ($(ARCH),)
tools/thermal/lib/Makefile +3 -3
@@ -8,9 +8,9 @@ LIBTHERMAL_TOOLS_EXTRAVERSION = 1 MAKEFLAGS += --no-print-directory ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) # $(info Determined 'srctree' to be $(srctree)) endif
tools/thermal/thermal-engine/Makefile +3 -3
@@ -2,9 +2,9 @@ # Makefile for thermal tools ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) # $(info Determined 'srctree' to be $(srctree)) endif
tools/thermal/thermometer/Makefile +3 -3
@@ -2,9 +2,9 @@ # Makefile for cgroup tools ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=%)) +srctree := $(dir $(srctree:%/=%)) # $(info Determined 'srctree' to be $(srctree)) endif
tools/usb/Makefile +2 -2
@@ -5,8 +5,8 @@ include ../scripts/Makefile.include bindir ?= /usr/bin ifeq ($(srctree),) -srctree := $(patsubst %/,%,$(dir $(CURDIR))) -srctree := $(patsubst %/,%,$(dir $(srctree))) +srctree := $(dir $(CURDIR)) +srctree := $(dir $(srctree:%/=$)) endif # Do not use make's built-in rules
Signature · 1 line
2.39.2
RFC PATCH 2/3 build: modify uses of $(srctree) to assume trailing slash
In reply to Elliott MitchellThis isn't much more than find | sed to adjust all uses of $(srctree). This is split into a separate commit to highlight the actual changes to the build machinery.
---grep was also used to locate things which needed other actions (notably the non-toplevel Makefile adjustments), but this is roughly:
find . -name Makefile\* -print0 | xargs -0 sed -i -es',$(srctree)/,$(srctree),g'
There could be goofs in here or missed bits. I hope not, but...
--- Documentation/Makefile | 48 +++--- Documentation/devicetree/bindings/Makefile | 18 +-- Documentation/userspace-api/media/Makefile | 10 +- Makefile | 144 +++++++++--------- arch/alpha/boot/Makefile | 2 +- arch/alpha/kernel/syscalls/Makefile | 4 +- arch/arc/Makefile | 2 +- arch/arc/boot/dts/Makefile | 2 +- arch/arm/Makefile | 4 +- arch/arm/boot/Makefile | 2 +- arch/arm/boot/compressed/Makefile | 2 +- arch/arm/mach-dove/Makefile | 2 +- arch/arm/mach-mv78xx0/Makefile | 2 +- arch/arm/mach-mvebu/Makefile | 2 +- arch/arm/mach-orion5x/Makefile | 2 +- arch/arm/mach-s3c/Makefile | 2 +- arch/arm/plat-orion/Makefile | 2 +- arch/arm/tools/Makefile | 6 +- arch/arm/vdso/Makefile | 2 +- arch/arm64/Makefile | 2 +- arch/arm64/boot/Makefile | 2 +- arch/arm64/kernel/pi/Makefile | 6 +- arch/arm64/kernel/vdso/Makefile | 4 +- arch/arm64/kernel/vdso32/Makefile | 2 +- arch/arm64/kvm/Makefile | 6 +- arch/arm64/kvm/hyp/Makefile | 2 +- arch/csky/Makefile | 2 +- arch/csky/boot/dts/Makefile | 2 +- arch/csky/kernel/vdso/Makefile | 4 +- arch/loongarch/boot/Makefile | 2 +- arch/loongarch/kvm/Makefile | 4 +- arch/loongarch/vdso/Makefile | 4 +- arch/m68k/kernel/syscalls/Makefile | 4 +- arch/microblaze/kernel/syscalls/Makefile | 4 +- arch/mips/Makefile | 18 +-- arch/mips/Makefile.postlink | 2 +- arch/mips/boot/Makefile | 2 +- arch/mips/boot/compressed/Makefile | 4 +- arch/mips/kernel/syscalls/Makefile | 6 +- arch/mips/kvm/Makefile | 2 +- arch/mips/vdso/Makefile | 6 +- arch/nios2/boot/dts/Makefile | 2 +- arch/parisc/Makefile | 4 +- arch/parisc/kernel/syscalls/Makefile | 4 +- arch/parisc/kernel/vdso32/Makefile | 2 +- arch/parisc/kernel/vdso64/Makefile | 2 +- arch/powerpc/Makefile | 30 ++-- arch/powerpc/Makefile.postlink | 10 +- arch/powerpc/boot/Makefile | 32 ++-- arch/powerpc/boot/dts/Makefile | 2 +- arch/powerpc/boot/dts/fsl/Makefile | 2 +- arch/powerpc/kernel/syscalls/Makefile | 4 +- arch/powerpc/kernel/vdso/Makefile | 6 +- arch/powerpc/kvm/Makefile | 2 +- arch/powerpc/platforms/cell/spufs/Makefile | 4 +- arch/riscv/Makefile | 12 +- arch/riscv/Makefile.postlink | 4 +- arch/riscv/boot/Makefile | 2 +- arch/riscv/kernel/compat_vdso/Makefile | 2 +- arch/riscv/kernel/pi/Makefile | 8 +- arch/riscv/kernel/vdso/Makefile | 4 +- arch/riscv/kvm/Makefile | 4 +- arch/riscv/purgatory/Makefile | 16 +- arch/s390/Makefile | 2 +- arch/s390/boot/Makefile | 2 +- arch/s390/kernel/syscalls/Makefile | 4 +- arch/s390/kernel/vdso32/Makefile | 4 +- arch/s390/kernel/vdso64/Makefile | 4 +- arch/s390/kvm/Makefile | 2 +- arch/s390/purgatory/Makefile | 4 +- arch/s390/tools/Makefile | 2 +- arch/sh/Makefile | 2 +- arch/sh/kernel/syscalls/Makefile | 4 +- arch/sparc/kernel/syscalls/Makefile | 4 +- arch/sparc/vdso/Makefile | 4 +- arch/um/Makefile | 22 +-- arch/um/drivers/Makefile | 2 +- arch/um/kernel/Makefile | 4 +- arch/um/kernel/skas/Makefile | 2 +- arch/um/os-Linux/Makefile | 2 +- arch/um/os-Linux/drivers/Makefile | 2 +- arch/um/os-Linux/skas/Makefile | 2 +- arch/um/scripts/Makefile.rules | 2 +- arch/x86/Makefile | 6 +- arch/x86/Makefile.postlink | 2 +- arch/x86/Makefile.um | 2 +- arch/x86/boot/Makefile | 6 +- arch/x86/boot/compressed/Makefile | 6 +- arch/x86/entry/syscalls/Makefile | 8 +- arch/x86/entry/vdso/Makefile | 6 +- arch/x86/kernel/Makefile | 2 +- arch/x86/kernel/cpu/Makefile | 2 +- arch/x86/kvm/Makefile | 4 +- arch/x86/lib/Makefile | 4 +- arch/x86/mm/Makefile | 2 +- arch/x86/purgatory/Makefile | 4 +- arch/x86/realmode/rm/Makefile | 2 +- arch/x86/tools/Makefile | 14 +- arch/x86/um/Makefile | 2 +- arch/x86/um/os-Linux/Makefile | 2 +- arch/x86/um/vdso/Makefile | 2 +- arch/xtensa/Makefile | 2 +- arch/xtensa/boot/boot-redboot/Makefile | 2 +- arch/xtensa/boot/dts/Makefile | 2 +- arch/xtensa/boot/lib/Makefile | 4 +- arch/xtensa/kernel/syscalls/Makefile | 4 +- certs/Makefile | 4 +- drivers/Makefile | 2 +- drivers/accessibility/speakup/Makefile | 2 +- drivers/base/firmware_loader/builtin/Makefile | 2 +- drivers/block/rnbd/Makefile | 2 +- drivers/crypto/chelsio/Makefile | 2 +- drivers/crypto/intel/iaa/Makefile | 2 +- drivers/crypto/intel/qat/qat_420xx/Makefile | 2 +- drivers/crypto/intel/qat/qat_4xxx/Makefile | 2 +- drivers/crypto/intel/qat/qat_c3xxx/Makefile | 2 +- drivers/crypto/intel/qat/qat_c3xxxvf/Makefile | 2 +- drivers/crypto/intel/qat/qat_c62x/Makefile | 2 +- drivers/crypto/intel/qat/qat_c62xvf/Makefile | 2 +- .../crypto/intel/qat/qat_dh895xcc/Makefile | 2 +- .../crypto/intel/qat/qat_dh895xccvf/Makefile | 2 +- drivers/crypto/marvell/octeontx2/Makefile | 2 +- drivers/cxl/core/Makefile | 2 +- drivers/firmware/efi/libstub/Makefile | 6 +- drivers/firmware/efi/libstub/Makefile.zboot | 4 +- drivers/gpu/drm/amd/amdgpu/Makefile | 2 +- drivers/gpu/drm/arm/display/komeda/Makefile | 4 +- drivers/gpu/drm/i915/Makefile | 8 +- drivers/gpu/drm/imagination/Makefile | 2 +- drivers/gpu/drm/msm/Makefile | 8 +- drivers/gpu/drm/xe/Makefile | 18 +-- drivers/hid/amd-sfh-hid/Makefile | 2 +- drivers/hid/bpf/Makefile | 2 +- drivers/hid/intel-ish-hid/Makefile | 2 +- drivers/iio/humidity/Makefile | 2 +- drivers/infiniband/hw/bnxt_re/Makefile | 2 +- drivers/infiniband/hw/cxgb4/Makefile | 4 +- drivers/infiniband/hw/hns/Makefile | 2 +- drivers/infiniband/hw/ocrdma/Makefile | 2 +- drivers/infiniband/hw/usnic/Makefile | 2 +- drivers/media/common/b2c2/Makefile | 4 +- drivers/media/dvb-frontends/Makefile | 4 +- drivers/media/dvb-frontends/drx39xyj/Makefile | 2 +- drivers/media/i2c/ccs/Makefile | 2 +- drivers/media/mmc/siano/Makefile | 2 +- drivers/media/pci/b2c2/Makefile | 2 +- drivers/media/pci/bt8xx/Makefile | 4 +- drivers/media/pci/cx18/Makefile | 4 +- drivers/media/pci/cx23885/Makefile | 4 +- drivers/media/pci/cx88/Makefile | 4 +- drivers/media/pci/ddbridge/Makefile | 4 +- drivers/media/pci/dm1105/Makefile | 2 +- drivers/media/pci/ivtv/Makefile | 4 +- drivers/media/pci/mantis/Makefile | 2 +- drivers/media/pci/netup_unidvb/Makefile | 2 +- drivers/media/pci/ngene/Makefile | 4 +- drivers/media/pci/pluto2/Makefile | 2 +- drivers/media/pci/pt1/Makefile | 4 +- drivers/media/pci/pt3/Makefile | 4 +- drivers/media/pci/saa7134/Makefile | 6 +- drivers/media/pci/saa7146/Makefile | 2 +- drivers/media/pci/saa7164/Makefile | 4 +- drivers/media/pci/smipcie/Makefile | 4 +- drivers/media/pci/ttpci/Makefile | 6 +- drivers/media/platform/mediatek/mdp/Makefile | 2 +- .../media/platform/st/sti/c8sectpfe/Makefile | 4 +- drivers/media/spi/Makefile | 2 +- drivers/media/tuners/Makefile | 2 +- drivers/media/usb/as102/Makefile | 2 +- drivers/media/usb/au0828/Makefile | 4 +- drivers/media/usb/b2c2/Makefile | 2 +- drivers/media/usb/cx231xx/Makefile | 4 +- drivers/media/usb/dvb-usb-v2/Makefile | 6 +- drivers/media/usb/dvb-usb/Makefile | 6 +- drivers/media/usb/em28xx/Makefile | 4 +- drivers/media/usb/go7007/Makefile | 2 +- drivers/media/usb/gspca/gl860/Makefile | 2 +- drivers/media/usb/gspca/m5602/Makefile | 2 +- drivers/media/usb/gspca/stv06xx/Makefile | 2 +- drivers/media/usb/pvrusb2/Makefile | 4 +- drivers/media/usb/siano/Makefile | 2 +- drivers/media/usb/ttusb-budget/Makefile | 2 +- drivers/media/v4l2-core/Makefile | 4 +- .../net/ethernet/aquantia/atlantic/Makefile | 2 +- .../chelsio/inline_crypto/ch_ipsec/Makefile | 4 +- .../chelsio/inline_crypto/ch_ktls/Makefile | 2 +- .../chelsio/inline_crypto/chtls/Makefile | 4 +- drivers/net/ethernet/chelsio/libcxgb/Makefile | 2 +- drivers/net/ethernet/freescale/dpaa/Makefile | 2 +- drivers/net/ethernet/freescale/fman/Makefile | 2 +- drivers/net/ethernet/fungible/funeth/Makefile | 2 +- drivers/net/ethernet/hisilicon/hns3/Makefile | 8 +- .../ethernet/marvell/octeontx2/nic/Makefile | 2 +- .../net/ethernet/microchip/lan966x/Makefile | 2 +- .../net/ethernet/microchip/sparx5/Makefile | 2 +- drivers/net/wan/Makefile | 2 +- .../broadcom/brcm80211/brcmfmac/Makefile | 4 +- .../broadcom/brcm80211/brcmfmac/bca/Makefile | 6 +- .../broadcom/brcm80211/brcmfmac/cyw/Makefile | 6 +- .../broadcom/brcm80211/brcmfmac/wcc/Makefile | 6 +- .../broadcom/brcm80211/brcmsmac/Makefile | 6 +- .../broadcom/brcm80211/brcmutil/Makefile | 2 +- .../net/wireless/intel/iwlwifi/dvm/Makefile | 2 +- .../net/wireless/intel/iwlwifi/mei/Makefile | 2 +- .../net/wireless/intel/iwlwifi/mvm/Makefile | 2 +- .../wireless/realtek/rtl818x/rtl8180/Makefile | 2 +- .../wireless/realtek/rtl818x/rtl8187/Makefile | 2 +- drivers/pinctrl/renesas/Makefile | 24 +-- drivers/scsi/aic7xxx/Makefile | 12 +- drivers/scsi/csiostor/Makefile | 2 +- drivers/scsi/cxgbi/Makefile | 2 +- drivers/scsi/libsas/Makefile | 2 +- drivers/scsi/pcmcia/Makefile | 2 +- drivers/staging/media/atomisp/Makefile | 2 +- drivers/staging/media/av7110/Makefile | 8 +- drivers/staging/rtl8723bs/Makefile | 2 +- drivers/target/iscsi/cxgbit/Makefile | 6 +- drivers/tty/serial/8250/Makefile | 2 +- drivers/usb/gadget/function/Makefile | 4 +- drivers/usb/gadget/legacy/Makefile | 6 +- drivers/usb/storage/Makefile | 2 +- drivers/vdpa/mlx5/Makefile | 2 +- fs/hostfs/Makefile | 2 +- fs/iomap/Makefile | 2 +- fs/unicode/Makefile | 14 +- fs/xfs/Makefile | 4 +- init/Makefile | 2 +- kernel/Makefile | 2 +- kernel/bpf/Makefile | 2 +- kernel/bpf/preload/Makefile | 2 +- kernel/gcov/Makefile | 2 +- lib/Makefile | 16 +- lib/raid6/Makefile | 2 +- net/wireless/Makefile | 2 +- rust/Makefile | 14 +- samples/bpf/Makefile | 24 +-- samples/coresight/Makefile | 2 +- samples/hid/Makefile | 16 +- scripts/Makefile | 6 +- scripts/Makefile.asm-generic | 8 +- scripts/Makefile.build | 22 +-- scripts/Makefile.clean | 2 +- scripts/Makefile.defconf | 16 +- scripts/Makefile.dtbinst | 2 +- scripts/Makefile.headersinst | 10 +- scripts/Makefile.lib | 22 +-- scripts/Makefile.modfinal | 4 +- scripts/Makefile.modinst | 6 +- scripts/Makefile.modpost | 4 +- scripts/Makefile.package | 22 +-- scripts/Makefile.vdsoinst | 2 +- scripts/Makefile.vmlinux | 6 +- scripts/Makefile.vmlinux_o | 8 +- scripts/basic/Makefile | 2 +- scripts/dtc/Makefile | 6 +- scripts/gcc-plugins/Makefile | 2 +- scripts/gdb/linux/Makefile | 2 +- scripts/genksyms/Makefile | 4 +- scripts/kconfig/Makefile | 22 +-- scripts/selinux/genheaders/Makefile | 4 +- scripts/selinux/mdp/Makefile | 4 +- security/apparmor/Makefile | 8 +- security/selinux/Makefile | 2 +- security/tomoyo/Makefile | 2 +- tools/bootconfig/Makefile | 2 +- tools/bpf/Makefile | 12 +- tools/bpf/bpftool/Makefile | 18 +-- tools/bpf/resolve_btfids/Makefile | 12 +- tools/build/Makefile | 4 +- tools/build/Makefile.build | 2 +- tools/build/Makefile.feature | 2 +- tools/build/Makefile.include | 6 +- tools/build/tests/ex/Makefile | 4 +- tools/counter/Makefile | 4 +- tools/gpio/Makefile | 2 +- tools/hv/Makefile | 2 +- tools/iio/Makefile | 2 +- tools/include/nolibc/Makefile | 2 +- tools/lib/api/Makefile | 8 +- tools/lib/bpf/Makefile | 16 +- tools/lib/perf/Makefile | 20 +-- tools/lib/subcmd/Makefile | 4 +- tools/lib/symbol/Makefile | 8 +- tools/lib/thermal/Makefile | 20 +-- tools/objtool/Makefile | 14 +- tools/pci/Makefile | 2 +- tools/perf/Makefile.config | 22 +-- tools/perf/Makefile.perf | 132 ++++++++-------- tools/perf/arch/arm64/Makefile | 6 +- tools/perf/arch/loongarch/Makefile | 6 +- tools/perf/arch/mips/Makefile | 2 +- tools/perf/arch/powerpc/Makefile | 2 +- tools/perf/arch/s390/Makefile | 2 +- tools/perf/arch/x86/Makefile | 2 +- tools/power/acpi/Makefile.config | 6 +- tools/power/acpi/Makefile.rules | 2 +- tools/power/acpi/tools/acpidump/Makefile | 2 +- tools/power/acpi/tools/pfrut/Makefile | 2 +- tools/power/x86/intel-speed-select/Makefile | 2 +- tools/spi/Makefile | 2 +- tools/testing/selftests/nolibc/Makefile | 12 +- tools/thermal/lib/Makefile | 18 +-- tools/thermal/thermal-engine/Makefile | 8 +- tools/thermal/thermometer/Makefile | 4 +- tools/usb/Makefile | 4 +- usr/Makefile | 2 +- usr/include/Makefile | 4 +- 307 files changed, 894 insertions(+), 894 deletions(-)
Documentation/Makefile +24 -24
@@ -7,12 +7,12 @@ subdir- := devicetree/bindings # Check for broken documentation file references ifeq ($(CONFIG_WARN_MISSING_DOCUMENTS),y) -$(shell $(srctree)/scripts/documentation-file-ref-check --warn) +$(shell $(srctree)scripts/documentation-file-ref-check --warn) endif # Check for broken ABI files ifeq ($(CONFIG_WARN_ABI_ERRORS),y) -$(shell $(srctree)/scripts/get_abi.pl validate --dir $(srctree)/Documentation/ABI) +$(shell $(srctree)scripts/get_abi.pl validate --dir $(srctree)Documentation/ABI) endif # You can set these variables from the command line.
@@ -21,7 +21,7 @@ SPHINXOPTS = SPHINXDIRS = . DOCS_THEME = DOCS_CSS = -_SPHINXDIRS = $(sort $(patsubst $(srctree)/Documentation/%/index.rst,%,$(wildcard $(srctree)/Documentation/*/index.rst))) +_SPHINXDIRS = $(sort $(patsubst $(srctree)Documentation/%/index.rst,%,$(wildcard $(srctree)Documentation/*/index.rst))) SPHINX_CONF = conf.py PAPER = BUILDDIR = $(obj)/output
@@ -40,7 +40,7 @@ ifeq ($(HAVE_SPHINX),0) .DEFAULT: $(warning The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed and in PATH, or set the SPHINXBUILD make variable to point to the full path of the '$(SPHINXBUILD)' executable.) @echo - @$(srctree)/scripts/sphinx-pre-install + @$(srctree)scripts/sphinx-pre-install @echo " SKIP Sphinx $@ target." else # HAVE_SPHINX
@@ -56,10 +56,10 @@ endif #HAVE_LATEXMK # Internal variables. PAPEROPT_a4 = -D latex_paper_size=a4 PAPEROPT_letter = -D latex_paper_size=letter -KERNELDOC = $(srctree)/scripts/kernel-doc +KERNELDOC = $(srctree)scripts/kernel-doc KERNELDOC_CONF = -D kerneldoc_srctree=$(srctree) -D kerneldoc_bin=$(KERNELDOC) ALLSPHINXOPTS = $(KERNELDOC_CONF) $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) -ifneq ($(wildcard $(srctree)/.config),) +ifneq ($(wildcard $(srctree).config),) ifeq ($(CONFIG_RUST),y) # Let Sphinx know we will include rustdoc ALLSPHINXOPTS += -t rustdoc
@@ -76,31 +76,31 @@ loop_cmd = $(echo-cmd) $(cmd_$(1)) || exit; # * dest folder relative to $(BUILDDIR) and # * cache folder relative to $(BUILDDIR)/.doctrees # $4 dest subfolder e.g. "man" for man pages at userspace-api/media/man -# $5 reST source folder relative to $(srctree)/$(src), +# $5 reST source folder relative to $(srctree)$(src), # e.g. "userspace-api/media" for the linux-tv book-set at ./Documentation/userspace-api/media quiet_cmd_sphinx = SPHINX $@ --> file://$(abspath $(BUILDDIR)/$3/$4) cmd_sphinx = $(MAKE) BUILDDIR=$(abspath $(BUILDDIR)) $(build)=Documentation/userspace-api/media $2 && \ PYTHONDONTWRITEBYTECODE=1 \ - BUILDDIR=$(abspath $(BUILDDIR)) SPHINX_CONF=$(abspath $(srctree)/$(src)/$5/$(SPHINX_CONF)) \ - $(PYTHON3) $(srctree)/scripts/jobserver-exec \ - $(CONFIG_SHELL) $(srctree)/Documentation/sphinx/parallel-wrapper.sh \ + BUILDDIR=$(abspath $(BUILDDIR)) SPHINX_CONF=$(abspath $(srctree)$(src)/$5/$(SPHINX_CONF)) \ + $(PYTHON3) $(srctree)scripts/jobserver-exec \ + $(CONFIG_SHELL) $(srctree)Documentation/sphinx/parallel-wrapper.sh \ $(SPHINXBUILD) \ -b $2 \ - -c $(abspath $(srctree)/$(src)) \ + -c $(abspath $(srctree)$(src)) \ -d $(abspath $(BUILDDIR)/.doctrees/$3) \ -D version=$(KERNELVERSION) -D release=$(KERNELRELEASE) \ $(ALLSPHINXOPTS) \ - $(abspath $(srctree)/$(src)/$5) \ + $(abspath $(srctree)$(src)/$5) \ $(abspath $(BUILDDIR)/$3/$4) && \ if [ "x$(DOCS_CSS)" != "x" ]; then \ - cp $(if $(patsubst /%,,$(DOCS_CSS)),$(abspath $(srctree)/$(DOCS_CSS)),$(DOCS_CSS)) $(BUILDDIR)/$3/_static/; \ + cp $(if $(patsubst /%,,$(DOCS_CSS)),$(abspath $(srctree)$(DOCS_CSS)),$(DOCS_CSS)) $(BUILDDIR)/$3/_static/; \ fi -YNL_INDEX:=$(srctree)/Documentation/networking/netlink_spec/index.rst -YNL_RST_DIR:=$(srctree)/Documentation/networking/netlink_spec -YNL_YAML_DIR:=$(srctree)/Documentation/netlink/specs -YNL_TOOL:=$(srctree)/tools/net/ynl/ynl-gen-rst.py +YNL_INDEX:=$(srctree)Documentation/networking/netlink_spec/index.rst +YNL_RST_DIR:=$(srctree)Documentation/networking/netlink_spec +YNL_YAML_DIR:=$(srctree)Documentation/netlink/specs +YNL_TOOL:=$(srctree)tools/net/ynl/ynl-gen-rst.py YNL_RST_FILES_TMP := $(patsubst %.yaml,%.rst,$(wildcard $(YNL_YAML_DIR)/*.yaml)) YNL_RST_FILES := $(patsubst $(YNL_YAML_DIR)%,$(YNL_RST_DIR)%, $(YNL_RST_FILES_TMP))
@@ -112,21 +112,21 @@ $(YNL_RST_DIR)/%.rst: $(YNL_YAML_DIR)/%.yaml $(YNL_TOOL) $(Q)$(YNL_TOOL) -i $< -o $@ htmldocs: $(YNL_INDEX) - @$(srctree)/scripts/sphinx-pre-install --version-check + @$(srctree)scripts/sphinx-pre-install --version-check @+$(foreach var,$(SPHINXDIRS),$(call loop_cmd,sphinx,html,$(var),,$(var))) # If Rust support is available and .config exists, add rustdoc generated contents. # If there are any, the errors from this make rustdoc will be displayed but # won't stop the execution of htmldocs -ifneq ($(wildcard $(srctree)/.config),) +ifneq ($(wildcard $(srctree).config),) ifeq ($(CONFIG_RUST),y) $(Q)$(MAKE) rustdoc || true endif endif texinfodocs: - @$(srctree)/scripts/sphinx-pre-install --version-check + @$(srctree)scripts/sphinx-pre-install --version-check @+$(foreach var,$(SPHINXDIRS),$(call loop_cmd,sphinx,texinfo,$(var),texinfo,$(var))) # Note: the 'info' Make target is generated by sphinx itself when
@@ -138,7 +138,7 @@ linkcheckdocs: @$(foreach var,$(SPHINXDIRS),$(call loop_cmd,sphinx,linkcheck,$(var),,$(var))) latexdocs: - @$(srctree)/scripts/sphinx-pre-install --version-check + @$(srctree)scripts/sphinx-pre-install --version-check @+$(foreach var,$(SPHINXDIRS),$(call loop_cmd,sphinx,latex,$(var),latex,$(var))) ifeq ($(HAVE_PDFLATEX),0)
@@ -150,7 +150,7 @@ pdfdocs: else # HAVE_PDFLATEX pdfdocs: latexdocs - @$(srctree)/scripts/sphinx-pre-install --version-check + @$(srctree)scripts/sphinx-pre-install --version-check $(foreach var,$(SPHINXDIRS), \ $(MAKE) PDFLATEX="$(PDFLATEX)" LATEXOPTS="$(LATEXOPTS)" -C $(BUILDDIR)/$(var)/latex || exit; \ mkdir -p $(BUILDDIR)/$(var)/pdf; \
@@ -160,11 +160,11 @@ pdfdocs: latexdocs endif # HAVE_PDFLATEX epubdocs: - @$(srctree)/scripts/sphinx-pre-install --version-check + @$(srctree)scripts/sphinx-pre-install --version-check @+$(foreach var,$(SPHINXDIRS),$(call loop_cmd,sphinx,epub,$(var),epub,$(var))) xmldocs: - @$(srctree)/scripts/sphinx-pre-install --version-check + @$(srctree)scripts/sphinx-pre-install --version-check @+$(foreach var,$(SPHINXDIRS),$(call loop_cmd,sphinx,xml,$(var),xml,$(var))) endif # HAVE_SPHINX
Documentation/devicetree/bindings/Makefile +9 -9
@@ -25,23 +25,23 @@ quiet_cmd_extract_ex = DTEX $@ $(obj)/%.example.dts: $(src)/%.yaml check_dtschema_version FORCE $(call if_changed,extract_ex) -find_all_cmd = find $(srctree)/$(src) \( -name '*.yaml' ! \ +find_all_cmd = find $(srctree)$(src) \( -name '*.yaml' ! \ -name 'processed-schema*' \) find_cmd = $(find_all_cmd) | \ - sed 's|^$(srctree)/||' | \ + sed 's|^$(srctree)||' | \ grep -F -e "$(subst :," -e ",$(DT_SCHEMA_FILES))" | \ - sed 's|^|$(srctree)/|' + sed 's|^|$(srctree)|' CHK_DT_DOCS := $(shell $(find_cmd)) quiet_cmd_yamllint = LINT $(src) cmd_yamllint = ($(find_cmd) | \ xargs -n200 -P$$(nproc) \ - $(DT_SCHEMA_LINT) -f parsable -c $(srctree)/$(src)/.yamllint >&2) || true + $(DT_SCHEMA_LINT) -f parsable -c $(srctree)$(src)/.yamllint >&2) || true quiet_cmd_chk_bindings = CHKDT $@ cmd_chk_bindings = ($(find_cmd) | \ - xargs -n200 -P$$(nproc) $(DT_DOC_CHECKER) -u $(srctree)/$(src)) || true + xargs -n200 -P$$(nproc) $(DT_DOC_CHECKER) -u $(srctree)$(src)) || true quiet_cmd_mk_schema = SCHEMA $@ cmd_mk_schema = f=$$(mktemp) ; \
@@ -55,7 +55,7 @@ define rule_chkdt $(call cmd,mk_schema) endef -DT_DOCS = $(patsubst $(srctree)/%,%,$(shell $(find_all_cmd))) +DT_DOCS = $(patsubst $(srctree)%,%,$(shell $(find_all_cmd))) override DTC_FLAGS := \ -Wno-avoid_unnecessary_addr_size \
@@ -71,8 +71,8 @@ $(obj)/processed-schema.json: $(DT_DOCS) $(src)/.yamllint check_dtschema_version $(call if_changed_rule,chkdt) always-y += processed-schema.json -always-$(CHECK_DT_BINDING) += $(patsubst $(srctree)/$(src)/%.yaml,%.example.dts, $(CHK_DT_DOCS)) -always-$(CHECK_DT_BINDING) += $(patsubst $(srctree)/$(src)/%.yaml,%.example.dtb, $(CHK_DT_DOCS)) +always-$(CHECK_DT_BINDING) += $(patsubst $(srctree)$(src)/%.yaml,%.example.dts, $(CHK_DT_DOCS)) +always-$(CHECK_DT_BINDING) += $(patsubst $(srctree)$(src)/%.yaml,%.example.dtb, $(CHK_DT_DOCS)) # Hack: avoid 'Argument list too long' error for 'make clean'. Remove most of # build artifacts here before they are processed by scripts/Makefile.clean
@@ -80,4 +80,4 @@ clean-files = $(shell find $(obj) \( -name '*.example.dts' -o \ -name '*.example.dtb' \) -delete 2>/dev/null) dt_compatible_check: $(obj)/processed-schema.json - $(Q)$(srctree)/scripts/dtc/dt-extract-compatibles $(srctree) | xargs dt-check-compatible -v -s $< + $(Q)$(srctree)scripts/dtc/dt-extract-compatibles $(srctree) | xargs dt-check-compatible -v -s $<
Documentation/userspace-api/media/Makefile +5 -5
@@ -2,10 +2,10 @@ # Rules to convert a .h file to inline RST documentation -SRC_DIR=$(srctree)/Documentation/userspace-api/media -PARSER = $(srctree)/Documentation/sphinx/parse-headers.pl -UAPI = $(srctree)/include/uapi/linux -KAPI = $(srctree)/include/linux +SRC_DIR=$(srctree)Documentation/userspace-api/media +PARSER = $(srctree)Documentation/sphinx/parse-headers.pl +UAPI = $(srctree)include/uapi/linux +KAPI = $(srctree)include/linux FILES = ca.h.rst dmx.h.rst frontend.h.rst net.h.rst \ videodev2.h.rst media.h.rst cec.h.rst lirc.h.rst
@@ -16,7 +16,7 @@ gen_rst = \ echo ${PARSER} $< $@ $(SRC_DIR)/$(notdir $@).exceptions; \ ${PARSER} $< $@ $(SRC_DIR)/$(notdir $@).exceptions -quiet_gen_rst = echo ' PARSE $(patsubst $(srctree)/%,%,$<)'; \ +quiet_gen_rst = echo ' PARSE $(patsubst $(srctree)%,%,$<)'; \ ${PARSER} $< $@ $(SRC_DIR)/$(notdir $@).exceptions silent_gen_rst = ${gen_rst}
Makefile +72 -72
450 lines not on this page · raw message
arch/alpha/boot/Makefile +1 -1
@@ -15,7 +15,7 @@ targets := vmlinux.gz vmlinux \ OBJSTRIP := $(obj)/tools/objstrip KBUILD_HOSTCFLAGS := -Wall -I$(objtree)/usr/include -BOOTCFLAGS += -I$(objtree)/$(obj) -I$(srctree)/$(obj) +BOOTCFLAGS += -I$(objtree)/$(obj) -I$(srctree)$(obj) # SRM bootable image. Copy to offset 512 of a partition. $(obj)/bootimage: $(addprefix $(obj)/tools/,mkbb lxboot bootlx) $(obj)/vmlinux.nh
arch/alpha/kernel/syscalls/Makefile +2 -2
@@ -5,8 +5,8 @@ uapi := arch/$(SRCARCH)/include/generated/uapi/asm $(shell mkdir -p $(uapi) $(kapi)) syscall := $(src)/syscall.tbl -syshdr := $(srctree)/scripts/syscallhdr.sh -systbl := $(srctree)/scripts/syscalltbl.sh +syshdr := $(srctree)scripts/syscallhdr.sh +systbl := $(srctree)scripts/syscalltbl.sh quiet_cmd_syshdr = SYSHDR $@ cmd_syshdr = $(CONFIG_SHELL) $(syshdr) --emit-nr $< $@
arch/arc/Makefile +1 -1
@@ -34,7 +34,7 @@ ifdef CONFIG_ARC_CURR_IN_REG # any kernel headers, and missing the global register # Can't do unconditionally because of recursive include issues # due to <linux/thread_info.h> -LINUXINCLUDE += -include $(srctree)/arch/arc/include/asm/current.h +LINUXINCLUDE += -include $(srctree)arch/arc/include/asm/current.h cflags-y += -ffixed-gp endif
arch/arc/boot/dts/Makefile +1 -1
@@ -10,7 +10,7 @@ obj-y += $(builtindtb-y).dtb.o dtb-y := $(builtindtb-y).dtb # for CONFIG_OF_ALL_DTBS test -dtstree := $(srctree)/$(src) +dtstree := $(srctree)$(src) dtb- := $(patsubst $(dtstree)/%.dts,%.dtb, $(wildcard $(dtstree)/*.dts)) # board-specific dtc flags
arch/arm/Makefile +2 -2
@@ -228,7 +228,7 @@ machine-$(CONFIG_PLAT_SPEAR) += spear machdirs-$(CONFIG_ARCH_FOOTBRIDGE) += arch/arm/mach-footbridge machdirs-$(CONFIG_ARCH_RPC) += arch/arm/mach-rpc machdirs-$(CONFIG_ARCH_SA1100) += arch/arm/mach-sa1100 -KBUILD_CPPFLAGS += $(patsubst %,-I$(srctree)/%/include,$(machdirs-y)) +KBUILD_CPPFLAGS += $(patsubst %,-I$(srctree)%/include,$(machdirs-y)) # The byte offset of the kernel image in RAM from the start of RAM. TEXT_OFFSET := $(textofs-y)
@@ -305,7 +305,7 @@ vdso-install-$(CONFIG_VDSO) += arch/arm/vdso/vdso.so.dbg # My testing targets (bypasses dependencies) bp:; $(Q)$(MAKE) $(build)=$(boot) $(boot)/bootpImage -include $(srctree)/scripts/Makefile.defconf +include $(srctree)scripts/Makefile.defconf PHONY += multi_v7_lpae_defconfig multi_v7_lpae_defconfig: $(call merge_into_defconfig,multi_v7_defconfig,lpae)
arch/arm/boot/Makefile +1 -1
@@ -26,7 +26,7 @@ targets := Image zImage xipImage bootpImage uImage ifeq ($(CONFIG_XIP_KERNEL),y) cmd_deflate_xip_data = $(CONFIG_SHELL) -c \ - '$(srctree)/$(src)/deflate_xip_data.sh $< $@' + '$(srctree)$(src)/deflate_xip_data.sh $< $@' ifeq ($(CONFIG_XIP_DEFLATED_DATA),y) quiet_cmd_mkxip = XIPZ $@
arch/arm/boot/compressed/Makefile +1 -1
@@ -101,7 +101,7 @@ targets := vmlinux vmlinux.lds piggy_data piggy.o \ KBUILD_CFLAGS += -DDISABLE_BRANCH_PROFILING ccflags-y := -fpic $(call cc-option,-mno-single-pic-base,) -fno-builtin \ - -I$(srctree)/scripts/dtc/libfdt -fno-stack-protector \ + -I$(srctree)scripts/dtc/libfdt -fno-stack-protector \ -I$(obj) $(DISABLE_ARM_SSP_PER_TASK_PLUGIN) ccflags-remove-$(CONFIG_FUNCTION_TRACER) += -pg asflags-y := -DZIMAGE
arch/arm/mach-dove/Makefile +1 -1
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-y := -I$(srctree)/arch/arm/plat-orion/include +ccflags-y := -I$(srctree)arch/arm/plat-orion/include obj-y += common.o obj-$(CONFIG_DOVE_LEGACY) += irq.o mpp.o
arch/arm/mach-mv78xx0/Makefile +1 -1
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-y := -I$(srctree)/arch/arm/plat-orion/include +ccflags-y := -I$(srctree)arch/arm/plat-orion/include obj-y += common.o mpp.o irq.o pcie.o obj-$(CONFIG_MACH_TERASTATION_WXL) += buffalo-wxl-setup.o
arch/arm/mach-mvebu/Makefile +1 -1
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-y := -I$(srctree)/arch/arm/plat-orion/include +ccflags-y := -I$(srctree)arch/arm/plat-orion/include obj-$(CONFIG_MACH_MVEBU_ANY) += system-controller.o mvebu-soc-id.o
arch/arm/mach-orion5x/Makefile +1 -1
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-y := -I$(srctree)/arch/arm/plat-orion/include +ccflags-y := -I$(srctree)arch/arm/plat-orion/include obj-y += common.o pci.o irq.o mpp.o obj-$(CONFIG_MACH_KUROBOX_PRO) += kurobox_pro-setup.o
arch/arm/mach-s3c/Makefile +1 -1
@@ -2,7 +2,7 @@ # # Copyright 2009 Simtec Electronics -include $(srctree)/$(src)/Makefile.s3c64xx +include $(srctree)$(src)/Makefile.s3c64xx # Objects we always build independent of SoC choice
arch/arm/plat-orion/Makefile +1 -1
@@ -2,7 +2,7 @@ # # Makefile for the linux kernel. # -ccflags-y := -I$(srctree)/$(src)/include +ccflags-y := -I$(srctree)$(src)/include orion-gpio-$(CONFIG_GPIOLIB) += gpio.o obj-$(CONFIG_PLAT_ORION_LEGACY) += irq.o pcie.o time.o common.o mpp.o
arch/arm/tools/Makefile +3 -3
@@ -8,9 +8,9 @@ gen := arch/$(ARCH)/include/generated kapi := $(gen)/asm uapi := $(gen)/uapi/asm -syshdr := $(srctree)/scripts/syscallhdr.sh -sysnr := $(srctree)/$(src)/syscallnr.sh -systbl := $(srctree)/scripts/syscalltbl.sh +syshdr := $(srctree)scripts/syscallhdr.sh +sysnr := $(srctree)$(src)/syscallnr.sh +systbl := $(srctree)scripts/syscalltbl.sh syscall := $(src)/syscall.tbl gen-y := $(gen)/calls-oabi.S
arch/arm/vdso/Makefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 # Include the generic Makefile to check the built vdso. -include $(srctree)/lib/vdso/Makefile +include $(srctree)lib/vdso/Makefile hostprogs := vdsomunge
arch/arm64/Makefile +1 -1
@@ -202,7 +202,7 @@ endif vdso-install-y += arch/arm64/kernel/vdso/vdso.so.dbg vdso-install-$(CONFIG_COMPAT_VDSO) += arch/arm64/kernel/vdso32/vdso32.so.dbg -include $(srctree)/scripts/Makefile.defconf +include $(srctree)scripts/Makefile.defconf PHONY += virtconfig virtconfig:
arch/arm64/boot/Makefile +1 -1
@@ -47,4 +47,4 @@ EFI_ZBOOT_FORWARD_CFI := $(CONFIG_ARM64_BTI_KERNEL) EFI_ZBOOT_OBJCOPY_FLAGS = --add-symbol zboot_code_size=0x$$( \ $(NM) vmlinux|grep _kernel_codesize|cut -d' ' -f1) -include $(srctree)/drivers/firmware/efi/libstub/Makefile.zboot +include $(srctree)drivers/firmware/efi/libstub/Makefile.zboot
arch/arm64/kernel/pi/Makefile +3 -3
@@ -5,8 +5,8 @@ KBUILD_CFLAGS := $(subst $(CC_FLAGS_FTRACE),,$(KBUILD_CFLAGS)) -fpie \ -Os -DDISABLE_BRANCH_PROFILING $(DISABLE_STACKLEAK_PLUGIN) \ $(DISABLE_LATENT_ENTROPY_PLUGIN) \ $(call cc-option,-mbranch-protection=none) \ - -I$(srctree)/scripts/dtc/libfdt -fno-stack-protector \ - -include $(srctree)/include/linux/hidden.h \ + -I$(srctree)scripts/dtc/libfdt -fno-stack-protector \ + -include $(srctree)include/linux/hidden.h \ -D__DISABLE_EXPORTS -ffreestanding -D__NO_FORTIFY \ -fno-asynchronous-unwind-tables -fno-unwind-tables \ $(call cc-option,-fno-addrsig)
@@ -28,7 +28,7 @@ $(obj)/%.pi.o: OBJCOPYFLAGS := --prefix-symbols=__pi_ \ $(obj)/%.pi.o: $(obj)/%.o FORCE $(call if_changed,objcopy) -$(obj)/lib-%.o: $(srctree)/lib/%.c FORCE +$(obj)/lib-%.o: $(srctree)lib/%.c FORCE $(call if_changed_rule,cc_o_c) obj-y := kaslr_early.pi.o lib-fdt.pi.o lib-fdt_ro.pi.o
arch/arm64/kernel/vdso/Makefile +2 -2
@@ -7,7 +7,7 @@ # # Include the generic Makefile to check the built vdso. -include $(srctree)/lib/vdso/Makefile +include $(srctree)lib/vdso/Makefile obj-vdso := vgettimeofday.o note.o sigreturn.o
@@ -68,7 +68,7 @@ $(obj)/%.so: $(obj)/%.so.dbg FORCE $(call if_changed,objcopy) # Generate VDSO offsets using helper script -gen-vdsosym := $(srctree)/$(src)/gen_vdso_offsets.sh +gen-vdsosym := $(srctree)$(src)/gen_vdso_offsets.sh quiet_cmd_vdsosym = VDSOSYM $@ cmd_vdsosym = $(NM) $< | $(gen-vdsosym) | LC_ALL=C sort > $@
arch/arm64/kernel/vdso32/Makefile +1 -1
@@ -3,7 +3,7 @@ # Makefile for vdso32 # -include $(srctree)/lib/vdso/Makefile +include $(srctree)lib/vdso/Makefile # Same as cc-*option, but using CC_COMPAT instead of CC ifeq ($(CONFIG_CC_IS_CLANG), y)
arch/arm64/kvm/Makefile +3 -3
@@ -3,9 +3,9 @@ # Makefile for Kernel-based Virtual Machine module # -ccflags-y += -I $(srctree)/$(src) +ccflags-y += -I $(srctree)$(src) -include $(srctree)/virt/kvm/Makefile.kvm +include $(srctree)virt/kvm/Makefile.kvm obj-$(CONFIG_KVM) += kvm.o obj-$(CONFIG_KVM) += hyp/
@@ -30,7 +30,7 @@ define rule_gen_hyp_constants $(call filechk,offsets,__HYP_CONSTANTS_H__) endef -CFLAGS_hyp-constants.o = -I $(srctree)/$(src)/hyp/include +CFLAGS_hyp-constants.o = -I $(srctree)$(src)/hyp/include $(obj)/hyp-constants.s: $(src)/hyp/hyp-constants.c FORCE $(call if_changed_dep,cc_s_c)
arch/arm64/kvm/hyp/Makefile +1 -1
@@ -3,7 +3,7 @@ # Makefile for Kernel-based Virtual Machine module, HYP part # -incdir := $(srctree)/$(src)/include +incdir := $(srctree)$(src)/include subdir-asflags-y := -I$(incdir) subdir-ccflags-y := -I$(incdir)
arch/csky/Makefile +1 -1
@@ -52,7 +52,7 @@ KBUILD_CFLAGS += -mbacktrace endif abidirs := $(patsubst %,arch/csky/%/,$(CSKYABI)) -KBUILD_CFLAGS += $(patsubst %,-I$(srctree)/%inc,$(abidirs)) +KBUILD_CFLAGS += $(patsubst %,-I$(srctree)%inc,$(abidirs)) KBUILD_CPPFLAGS += -mlittle-endian LDFLAGS += -EL
arch/csky/boot/dts/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only -dtstree := $(srctree)/$(src) +dtstree := $(srctree)$(src) dtb-y := $(patsubst $(dtstree)/%.dts,%.dtb, $(wildcard $(dtstree)/*.dts))
arch/csky/kernel/vdso/Makefile +2 -2
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0-only # Include the generic Makefile to check the built vdso. -include $(srctree)/lib/vdso/Makefile +include $(srctree)lib/vdso/Makefile # Symbols present in the vdso vdso-syms += rt_sigreturn
@@ -57,4 +57,4 @@ quiet_cmd_vdsold = VDSOLD $@ # Extracts symbol offsets from the VDSO, converting them into an assembly file # that contains the same symbols at the same offsets. quiet_cmd_so2s = SO2S $@ - cmd_so2s = $(NM) -D $< | $(srctree)/$(src)/so2s.sh > $@ + cmd_so2s = $(NM) -D $< | $(srctree)$(src)/so2s.sh > $@
arch/loongarch/boot/Makefile +1 -1
@@ -23,4 +23,4 @@ EFI_ZBOOT_PAYLOAD := vmlinux.efi EFI_ZBOOT_BFD_TARGET := elf64-loongarch EFI_ZBOOT_MACH_TYPE := LOONGARCH64 -include $(srctree)/drivers/firmware/efi/libstub/Makefile.zboot +include $(srctree)drivers/firmware/efi/libstub/Makefile.zboot
arch/loongarch/kvm/Makefile +2 -2
@@ -3,9 +3,9 @@ # Makefile for LoongArch KVM support # -ccflags-y += -I $(srctree)/$(src) +ccflags-y += -I $(srctree)$(src) -include $(srctree)/virt/kvm/Makefile.kvm +include $(srctree)virt/kvm/Makefile.kvm obj-$(CONFIG_KVM) += kvm.o
arch/loongarch/vdso/Makefile +2 -2
@@ -6,7 +6,7 @@ UBSAN_SANITIZE := n KCOV_INSTRUMENT := n # Include the generic Makefile to check the built vdso. -include $(srctree)/lib/vdso/Makefile +include $(srctree)lib/vdso/Makefile obj-vdso-y := elf.o vgetcpu.o vgettimeofday.o sigreturn.o
@@ -51,7 +51,7 @@ quiet_cmd_vdsoas_o_S = AS $@ cmd_vdsoas_o_S = $(CC) $(a_flags) -c -o $@ $< # Generate VDSO offsets using helper script -gen-vdsosym := $(srctree)/$(src)/gen_vdso_offsets.sh +gen-vdsosym := $(srctree)$(src)/gen_vdso_offsets.sh quiet_cmd_vdsosym = VDSOSYM $@ cmd_vdsosym = $(NM) $< | $(gen-vdsosym) | LC_ALL=C sort > $@
arch/m68k/kernel/syscalls/Makefile +2 -2
@@ -5,8 +5,8 @@ uapi := arch/$(SRCARCH)/include/generated/uapi/asm $(shell mkdir -p $(uapi) $(kapi)) syscall := $(src)/syscall.tbl -syshdr := $(srctree)/scripts/syscallhdr.sh -systbl := $(srctree)/scripts/syscalltbl.sh +syshdr := $(srctree)scripts/syscallhdr.sh +systbl := $(srctree)scripts/syscalltbl.sh quiet_cmd_syshdr = SYSHDR $@ cmd_syshdr = $(CONFIG_SHELL) $(syshdr) --emit-nr $< $@
arch/microblaze/kernel/syscalls/Makefile +2 -2
@@ -5,8 +5,8 @@ uapi := arch/$(SRCARCH)/include/generated/uapi/asm $(shell mkdir -p $(uapi) $(kapi)) syscall := $(src)/syscall.tbl -syshdr := $(srctree)/scripts/syscallhdr.sh -systbl := $(srctree)/scripts/syscalltbl.sh +syshdr := $(srctree)scripts/syscallhdr.sh +systbl := $(srctree)scripts/syscalltbl.sh quiet_cmd_syshdr = SYSHDR $@ cmd_syshdr = $(CONFIG_SHELL) $(syshdr) --emit-nr $< $@
arch/mips/Makefile +9 -9
@@ -280,14 +280,14 @@ endif # # Board-dependent options and extra files # -include $(srctree)/arch/mips/Kbuild.platforms +include $(srctree)arch/mips/Kbuild.platforms ifdef CONFIG_PHYSICAL_START load-y = $(CONFIG_PHYSICAL_START) endif entry-y = $(shell $(objtree)/arch/mips/tools/elf-entry vmlinux) -cflags-y += -I$(srctree)/arch/mips/include/asm/mach-generic +cflags-y += -I$(srctree)arch/mips/include/asm/mach-generic drivers-$(CONFIG_PCI) += arch/mips/pci/ #
@@ -492,7 +492,7 @@ define archhelp echo ' Otherwise, the following default configurations are available:' endef -generic_config_dir = $(srctree)/arch/$(ARCH)/configs/generic +generic_config_dir = $(srctree)arch/$(ARCH)/configs/generic generic_defconfigs := #
@@ -529,16 +529,16 @@ endef .PHONY: $(generic_defconfigs) $(generic_defconfigs): - $(Q)$(CONFIG_SHELL) $(srctree)/scripts/kconfig/merge_config.sh \ - -m -O $(objtree) $(srctree)/arch/$(ARCH)/configs/generic_defconfig $^ | \ + $(Q)$(CONFIG_SHELL) $(srctree)scripts/kconfig/merge_config.sh \ + -m -O $(objtree) $(srctree)arch/$(ARCH)/configs/generic_defconfig $^ | \ grep -Ev '^#' $(Q)cp $(KCONFIG_CONFIG) $(objtree)/.config.$@ - $(Q)$(MAKE) -f $(srctree)/Makefile olddefconfig \ + $(Q)$(MAKE) -f $(srctree)Makefile olddefconfig \ KCONFIG_CONFIG=$(objtree)/.config.$@ >/dev/null - $(Q)$(CONFIG_SHELL) $(srctree)/arch/$(ARCH)/tools/generic-board-config.sh \ + $(Q)$(CONFIG_SHELL) $(srctree)arch/$(ARCH)/tools/generic-board-config.sh \ $(srctree) $(objtree) $(objtree)/.config.$@ $(KCONFIG_CONFIG) \ "$(origin BOARDS)" $(BOARDS) - $(Q)$(MAKE) -f $(srctree)/Makefile olddefconfig + $(Q)$(MAKE) -f $(srctree)Makefile olddefconfig # # Prevent generic merge_config rules attempting to merge single fragments
@@ -580,4 +580,4 @@ pistachio_defconfig-y := 32r2el_defconfig BOARDS=marduk .PHONY: $(legacy_defconfigs) $(legacy_defconfigs): - $(Q)$(MAKE) -f $(srctree)/Makefile $($@-y) + $(Q)$(MAKE) -f $(srctree)Makefile $($@-y)
arch/mips/Makefile.postlink +1 -1
@@ -10,7 +10,7 @@ PHONY := __archpost __archpost: -include include/config/auto.conf -include $(srctree)/scripts/Kbuild.include +include $(srctree)scripts/Kbuild.include CMD_LS3_LLSC = arch/mips/tools/loongson3-llsc-check quiet_cmd_ls3_llsc = LLSCCHK $@
arch/mips/boot/Makefile +1 -1
@@ -117,7 +117,7 @@ targets += vmlinux.its.S quiet_cmd_its_cat = CAT $@ cmd_its_cat = cat $(real-prereqs) >$@ -$(obj)/vmlinux.its.S: $(addprefix $(srctree)/arch/mips/$(PLATFORM)/,$(ITS_INPUTS)) FORCE +$(obj)/vmlinux.its.S: $(addprefix $(srctree)arch/mips/$(PLATFORM)/,$(ITS_INPUTS)) FORCE $(call if_changed,its_cat) targets += vmlinux.its
arch/mips/boot/compressed/Makefile +2 -2
@@ -12,7 +12,7 @@ # Author: Wu Zhangjin <[email protected]> # -include $(srctree)/arch/mips/Kbuild.platforms +include $(srctree)arch/mips/Kbuild.platforms # set the default size of the mallocing area for decompressing BOOT_HEAP_SIZE := 0x400000
@@ -186,7 +186,7 @@ targets += ../vmlinuz.its.S quiet_cmd_its_cat = CAT $@ cmd_its_cat = cat $(real-prereqs) >$@ -$(objboot)/vmlinuz.its.S: $(addprefix $(srctree)/arch/mips/$(PLATFORM)/,$(ITS_INPUTS)) FORCE +$(objboot)/vmlinuz.its.S: $(addprefix $(srctree)arch/mips/$(PLATFORM)/,$(ITS_INPUTS)) FORCE $(call if_changed,its_cat) targets += ../vmlinuz.its
arch/mips/kernel/syscalls/Makefile +3 -3
@@ -4,9 +4,9 @@ uapi := arch/$(SRCARCH)/include/generated/uapi/asm $(shell mkdir -p $(uapi) $(kapi)) -syshdr := $(srctree)/scripts/syscallhdr.sh -sysnr := $(srctree)/$(src)/syscallnr.sh -systbl := $(srctree)/scripts/syscalltbl.sh +syshdr := $(srctree)scripts/syscallhdr.sh +sysnr := $(srctree)$(src)/syscallnr.sh +systbl := $(srctree)scripts/syscalltbl.sh quiet_cmd_syshdr = SYSHDR $@ cmd_syshdr = $(CONFIG_SHELL) $(syshdr) --offset __NR_Linux $< $@
arch/mips/kvm/Makefile +1 -1
@@ -2,7 +2,7 @@ # Makefile for KVM support for MIPS # -include $(srctree)/virt/kvm/Makefile.kvm +include $(srctree)virt/kvm/Makefile.kvm ccflags-y += -Ivirt/kvm -Iarch/mips/kvm
arch/mips/vdso/Makefile +3 -3
@@ -5,7 +5,7 @@ KCSAN_SANITIZE := n # Include the generic Makefile to check the built vdso. -include $(srctree)/lib/vdso/Makefile +include $(srctree)lib/vdso/Makefile obj-vdso-y := elf.o vgettimeofday.o sigreturn.o
@@ -43,8 +43,8 @@ CFLAGS_vgettimeofday.o = -include $(c-gettimeofday-y) # config-n32-o32-env.c prepares the environment to build a 32bit vDSO # library on a 64bit kernel. # Note: Needs to be included before than the generic library. -CFLAGS_vgettimeofday-o32.o = -include $(srctree)/$(src)/config-n32-o32-env.c -include $(c-gettimeofday-y) -CFLAGS_vgettimeofday-n32.o = -include $(srctree)/$(src)/config-n32-o32-env.c -include $(c-gettimeofday-y) +CFLAGS_vgettimeofday-o32.o = -include $(srctree)$(src)/config-n32-o32-env.c -include $(c-gettimeofday-y) +CFLAGS_vgettimeofday-n32.o = -include $(srctree)$(src)/config-n32-o32-env.c -include $(c-gettimeofday-y) endif CFLAGS_REMOVE_vgettimeofday.o = $(CC_FLAGS_FTRACE)
arch/nios2/boot/dts/Makefile +1 -1
@@ -2,5 +2,5 @@ obj-y := $(patsubst %.dts,%.dtb.o,$(CONFIG_NIOS2_DTB_SOURCE)) -dtstree := $(srctree)/$(src) +dtstree := $(srctree)$(src) dtb-$(CONFIG_OF_ALL_DTBS) := $(patsubst $(dtstree)/%.dts,%.dtb, $(wildcard $(dtstree)/*.dts))
arch/parisc/Makefile +2 -2
@@ -127,7 +127,7 @@ PALO := $(shell if (which palo 2>&1); then : ; \ elif [ -x /sbin/palo ]; then echo /sbin/palo; \ fi) -PALOCONF := $(shell if [ -f $(srctree)/palo.conf ]; then echo $(srctree)/palo.conf; \ +PALOCONF := $(shell if [ -f $(srctree)palo.conf ]; then echo $(srctree)palo.conf; \ else echo $(objtree)/palo.conf; \ fi)
@@ -138,7 +138,7 @@ palo lifimage: vmlinuz false; \ fi @if test ! -f "$(PALOCONF)"; then \ - cp $(srctree)/arch/parisc/defpalo.conf $(objtree)/palo.conf; \ + cp $(srctree)arch/parisc/defpalo.conf $(objtree)/palo.conf; \ echo 'A generic palo config file ($(objree)/palo.conf) has been created for you.'; \ echo 'You should check it and re-run "make palo".'; \ echo 'WARNING: the "lifimage" file is now placed in this directory by default!'; \
arch/parisc/kernel/syscalls/Makefile +2 -2
@@ -5,8 +5,8 @@ uapi := arch/$(SRCARCH)/include/generated/uapi/asm $(shell mkdir -p $(uapi) $(kapi)) syscall := $(src)/syscall.tbl -syshdr := $(srctree)/scripts/syscallhdr.sh -systbl := $(srctree)/scripts/syscalltbl.sh +syshdr := $(srctree)scripts/syscallhdr.sh +systbl := $(srctree)scripts/syscalltbl.sh quiet_cmd_syshdr = SYSHDR $@ cmd_syshdr = $(CONFIG_SHELL) $(syshdr) --emit-nr --abis common,$* $< $@
arch/parisc/kernel/vdso32/Makefile +1 -1
@@ -45,7 +45,7 @@ quiet_cmd_vdso32cc = VDSO32C $@ cmd_vdso32cc = $(CROSS32CC) $(c_flags) -c -fPIC -mno-fast-indirect-calls -o $@ $< # Generate VDSO offsets using helper script -gen-vdsosym := $(srctree)/$(src)/gen_vdso_offsets.sh +gen-vdsosym := $(srctree)$(src)/gen_vdso_offsets.sh quiet_cmd_vdsosym = VDSOSYM $@ cmd_vdsosym = $(NM) $< | $(gen-vdsosym) | LC_ALL=C sort > $@
arch/parisc/kernel/vdso64/Makefile +1 -1
@@ -40,7 +40,7 @@ quiet_cmd_vdso64as = VDSO64A $@ cmd_vdso64as = $(CC) $(a_flags) -c -o $@ $< # Generate VDSO offsets using helper script -gen-vdsosym := $(srctree)/$(src)/gen_vdso_offsets.sh +gen-vdsosym := $(srctree)$(src)/gen_vdso_offsets.sh quiet_cmd_vdsosym = VDSOSYM $@ cmd_vdsosym = $(NM) $< | $(gen-vdsosym) | LC_ALL=C sort > $@
arch/powerpc/Makefile +15 -15
@@ -172,7 +172,7 @@ CFLAGS-y += $(CONFIG_TUNE_CPU) asinstr := $(call as-instr,lis 9$(comma)foo@high,-DHAVE_AS_ATHIGH=1) -KBUILD_CPPFLAGS += -I $(srctree)/arch/powerpc $(asinstr) +KBUILD_CPPFLAGS += -I $(srctree)arch/powerpc $(asinstr) KBUILD_AFLAGS += $(AFLAGS-y) KBUILD_CFLAGS += $(call cc-option,-msoft-float) KBUILD_CFLAGS += $(CFLAGS-y)
@@ -187,7 +187,7 @@ endif ifdef CONFIG_476FPE_ERR46 KBUILD_LDFLAGS_MODULE += --ppc476-workaround \ - -T $(srctree)/arch/powerpc/platforms/44x/ppc476_modules.lds + -T $(srctree)arch/powerpc/platforms/44x/ppc476_modules.lds endif # No prefix or pcrel
@@ -255,7 +255,7 @@ PHONY += bootwrapper_install bootwrapper_install: $(Q)$(MAKE) $(build)=$(boot) $(patsubst %,$(boot)/%,$@) -include $(srctree)/scripts/Makefile.defconf +include $(srctree)scripts/Makefile.defconf generated_configs += ppc64le_defconfig ppc64le_defconfig:
@@ -311,8 +311,8 @@ mpc86xx_smp_defconfig: generated_configs += ppc32_allmodconfig ppc32_allmodconfig: - $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)/arch/powerpc/configs/book3s_32.config \ - -f $(srctree)/Makefile allmodconfig + $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)arch/powerpc/configs/book3s_32.config \ + -f $(srctree)Makefile allmodconfig generated_configs += ppc_defconfig ppc_defconfig:
@@ -320,28 +320,28 @@ ppc_defconfig: generated_configs += ppc64le_allmodconfig ppc64le_allmodconfig: - $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)/arch/powerpc/configs/le.config \ - -f $(srctree)/Makefile allmodconfig + $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)arch/powerpc/configs/le.config \ + -f $(srctree)Makefile allmodconfig generated_configs += ppc64le_allnoconfig ppc64le_allnoconfig: - $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)/arch/powerpc/configs/ppc64le.config \ - -f $(srctree)/Makefile allnoconfig + $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)arch/powerpc/configs/ppc64le.config \ + -f $(srctree)Makefile allnoconfig generated_configs += ppc64_book3e_allmodconfig ppc64_book3e_allmodconfig: - $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)/arch/powerpc/configs/85xx-64bit.config \ - -f $(srctree)/Makefile allmodconfig + $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)arch/powerpc/configs/85xx-64bit.config \ + -f $(srctree)Makefile allmodconfig generated_configs += ppc32_randconfig ppc32_randconfig: - $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)/arch/powerpc/configs/32-bit.config \ - -f $(srctree)/Makefile randconfig + $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)arch/powerpc/configs/32-bit.config \ + -f $(srctree)Makefile randconfig generated_configs += ppc64_randconfig ppc64_randconfig: - $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)/arch/powerpc/configs/64-bit.config \ - -f $(srctree)/Makefile randconfig + $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)arch/powerpc/configs/64-bit.config \ + -f $(srctree)Makefile randconfig PHONY += $(generated_configs)
arch/powerpc/Makefile.postlink +5 -5
@@ -9,19 +9,19 @@ PHONY := __archpost __archpost: -include include/config/auto.conf -include $(srctree)/scripts/Kbuild.include +include $(srctree)scripts/Kbuild.include quiet_cmd_head_check = CHKHEAD $@ - cmd_head_check = $(CONFIG_SHELL) $(srctree)/arch/powerpc/tools/head_check.sh "$(NM)" "$@" + cmd_head_check = $(CONFIG_SHELL) $(srctree)arch/powerpc/tools/head_check.sh "$(NM)" "$@" quiet_cmd_relocs_check = CHKREL $@ ifdef CONFIG_PPC_BOOK3S_64 cmd_relocs_check = \ - $(CONFIG_SHELL) $(srctree)/arch/powerpc/tools/relocs_check.sh "$(OBJDUMP)" "$(NM)" "$@" ; \ - $(BASH) $(srctree)/arch/powerpc/tools/unrel_branch_check.sh "$(OBJDUMP)" "$(NM)" "$@" + $(CONFIG_SHELL) $(srctree)arch/powerpc/tools/relocs_check.sh "$(OBJDUMP)" "$(NM)" "$@" ; \ + $(BASH) $(srctree)arch/powerpc/tools/unrel_branch_check.sh "$(OBJDUMP)" "$(NM)" "$@" else cmd_relocs_check = \ - $(CONFIG_SHELL) $(srctree)/arch/powerpc/tools/relocs_check.sh "$(OBJDUMP)" "$(NM)" "$@" + $(CONFIG_SHELL) $(srctree)arch/powerpc/tools/relocs_check.sh "$(OBJDUMP)" "$(NM)" "$@" endif # `@true` prevents complaint when there is nothing to be done
arch/powerpc/boot/Makefile +16 -16
@@ -98,8 +98,8 @@ ifeq ($(call cc-option-yn, -fstack-protector),y) BOOTCFLAGS += -fno-stack-protector endif -BOOTCFLAGS += -include $(srctree)/include/linux/compiler_attributes.h -BOOTCFLAGS += -I$(objtree)/$(obj) -I$(srctree)/$(obj) +BOOTCFLAGS += -include $(srctree)include/linux/compiler_attributes.h +BOOTCFLAGS += -I$(objtree)/$(obj) -I$(srctree)$(obj) DTC_FLAGS ?= -p 1024
@@ -195,30 +195,30 @@ obj-plat := $(addsuffix .o, $(basename $(addprefix $(obj)/, $(src-plat)))) obj-plat: $(libfdt) quiet_cmd_copy_kern_src = COPY $@ - cmd_copy_kern_src = sed -f $(srctree)/arch/powerpc/boot/fixup-headers.sed $< > $@ + cmd_copy_kern_src = sed -f $(srctree)arch/powerpc/boot/fixup-headers.sed $< > $@ -$(addprefix $(obj)/,$(zlib-y)): $(obj)/%: $(srctree)/lib/zlib_inflate/% +$(addprefix $(obj)/,$(zlib-y)): $(obj)/%: $(srctree)lib/zlib_inflate/% $(call cmd,copy_kern_src) -$(addprefix $(obj)/,$(zlibheader-y)): $(obj)/%: $(srctree)/lib/zlib_inflate/% +$(addprefix $(obj)/,$(zlibheader-y)): $(obj)/%: $(srctree)lib/zlib_inflate/% $(call cmd,copy_kern_src) -$(addprefix $(obj)/,$(zliblinuxheader-y)): $(obj)/%: $(srctree)/include/linux/% +$(addprefix $(obj)/,$(zliblinuxheader-y)): $(obj)/%: $(srctree)include/linux/% $(call cmd,copy_kern_src) -$(addprefix $(obj)/,$(zlib-decomp-y)): $(obj)/%: $(srctree)/lib/% +$(addprefix $(obj)/,$(zlib-decomp-y)): $(obj)/%: $(srctree)lib/% $(call cmd,copy_kern_src) quiet_cmd_copy_libfdt = COPY $@ cmd_copy_libfdt = cp $< $@ -$(addprefix $(obj)/,$(libfdt) $(libfdtheader)): $(obj)/%: $(srctree)/scripts/dtc/libfdt/% +$(addprefix $(obj)/,$(libfdt) $(libfdtheader)): $(obj)/%: $(srctree)scripts/dtc/libfdt/% $(call cmd,copy_libfdt) $(obj)/empty.c: $(Q)touch $@ -$(obj)/zImage.coff.lds $(obj)/zImage.ps3.lds : $(obj)/%: $(srctree)/$(src)/%.S +$(obj)/zImage.coff.lds $(obj)/zImage.ps3.lds : $(obj)/%: $(srctree)$(src)/%.S $(Q)cp $< $@ clean-files := $(zlib-) $(zlibheader-) $(zliblinuxheader-) \
@@ -234,7 +234,7 @@ quiet_cmd_bootas = BOOTAS $@ quiet_cmd_bootar = BOOTAR $@ cmd_bootar = $(BOOTAR) $(BOOTARFLAGS) $@.$$$$ $(real-prereqs); mv $@.$$$$ $@ -$(obj-libfdt): $(obj)/%.o: $(srctree)/scripts/dtc/libfdt/%.c FORCE +$(obj-libfdt): $(obj)/%.o: $(srctree)scripts/dtc/libfdt/%.c FORCE $(call if_changed_dep,bootcc) $(patsubst %.c,%.o, $(filter %.c, $(src-boot))): %.o: %.c FORCE $(Q)mkdir -p $(dir $@)
@@ -252,9 +252,9 @@ targets += $(patsubst $(obj)/%,%,$(obj-boot) wrapper.a) zImage.lds extra-y := $(obj)/wrapper.a $(obj-plat) $(obj)/empty.o \ $(obj)/zImage.lds $(obj)/zImage.coff.lds $(obj)/zImage.ps3.lds -dtstree := $(srctree)/$(src)/dts +dtstree := $(srctree)$(src)/dts -wrapper :=$(srctree)/$(src)/wrapper +wrapper :=$(srctree)$(src)/wrapper wrapperbits := $(extra-y) $(addprefix $(obj)/,addnote hack-coff mktree) \ $(wrapper) FORCE
@@ -483,13 +483,13 @@ quiet_cmd_install = INSTALL $(patsubst $(DESTDIR)$(WRAPPER_OBJDIR)/%,%,$@) cmd_install = $(INSTALL) -m0644 $(patsubst $(DESTDIR)$(WRAPPER_OBJDIR)/%,$(obj)/%,$@) $@ quiet_cmd_install_dts = INSTALL $(patsubst $(DESTDIR)$(WRAPPER_DTSDIR)/%,dts/%,$@) - cmd_install_dts = $(INSTALL) -m0644 $(patsubst $(DESTDIR)$(WRAPPER_DTSDIR)/%,$(srctree)/$(obj)/dts/%,$@) $@ + cmd_install_dts = $(INSTALL) -m0644 $(patsubst $(DESTDIR)$(WRAPPER_DTSDIR)/%,$(srctree)$(obj)/dts/%,$@) $@ quiet_cmd_install_exe = INSTALL $(patsubst $(DESTDIR)$(WRAPPER_BINDIR)/%,%,$@) cmd_install_exe = $(INSTALL) -m0755 $(patsubst $(DESTDIR)$(WRAPPER_BINDIR)/%,$(obj)/%,$@) $@ quiet_cmd_install_wrapper = INSTALL $(patsubst $(DESTDIR)$(WRAPPER_BINDIR)/%,%,$@) - cmd_install_wrapper = $(INSTALL) -m0755 $(patsubst $(DESTDIR)$(WRAPPER_BINDIR)/%,$(srctree)/$(obj)/%,$@) $@ ;\ + cmd_install_wrapper = $(INSTALL) -m0755 $(patsubst $(DESTDIR)$(WRAPPER_BINDIR)/%,$(srctree)$(obj)/%,$@) $@ ;\ sed -i $@ -e 's%^object=.*%object=$(WRAPPER_OBJDIR)%' \ -e 's%^objbin=.*%objbin=$(WRAPPER_BINDIR)%' \
@@ -503,10 +503,10 @@ $(extra-installed) : $(DESTDIR)$(WRAPPER_OBJDIR)/% : $(obj)/% | $(DESTDIR)$(WRAP $(hostprogs-installed) : $(DESTDIR)$(WRAPPER_BINDIR)/% : $(obj)/% | $(DESTDIR)$(WRAPPER_BINDIR) $(call cmd,install_exe) -$(dts-installed) : $(DESTDIR)$(WRAPPER_DTSDIR)/% : $(srctree)/$(obj)/dts/% | $(DESTDIR)$(WRAPPER_DTSDIR) +$(dts-installed) : $(DESTDIR)$(WRAPPER_DTSDIR)/% : $(srctree)$(obj)/dts/% | $(DESTDIR)$(WRAPPER_DTSDIR) $(call cmd,install_dts) -$(wrapper-installed): $(DESTDIR)$(WRAPPER_BINDIR) $(srctree)/$(obj)/wrapper | $(DESTDIR)$(WRAPPER_BINDIR) +$(wrapper-installed): $(DESTDIR)$(WRAPPER_BINDIR) $(srctree)$(obj)/wrapper | $(DESTDIR)$(WRAPPER_BINDIR) $(call cmd,install_wrapper) $(obj)/bootwrapper_install: $(all-installed)
arch/powerpc/boot/dts/Makefile +1 -1
@@ -2,5 +2,5 @@ subdir-y += fsl -dtstree := $(srctree)/$(src) +dtstree := $(srctree)$(src) dtb-$(CONFIG_OF_ALL_DTBS) := $(patsubst $(dtstree)/%.dts,%.dtb, $(wildcard $(dtstree)/*.dts))
arch/powerpc/boot/dts/fsl/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0 -dtstree := $(srctree)/$(src) +dtstree := $(srctree)$(src) dtb-$(CONFIG_OF_ALL_DTBS) := $(patsubst $(dtstree)/%.dts,%.dtb, $(wildcard $(dtstree)/*.dts))
arch/powerpc/kernel/syscalls/Makefile +2 -2
@@ -5,8 +5,8 @@ uapi := arch/$(SRCARCH)/include/generated/uapi/asm $(shell mkdir -p $(uapi) $(kapi)) syscall := $(src)/syscall.tbl -syshdr := $(srctree)/scripts/syscallhdr.sh -systbl := $(srctree)/scripts/syscalltbl.sh +syshdr := $(srctree)scripts/syscallhdr.sh +systbl := $(srctree)scripts/syscalltbl.sh quiet_cmd_syshdr = SYSHDR $@ cmd_syshdr = $(CONFIG_SHELL) $(syshdr) --emit-nr --abis $(abis) $< $@
arch/powerpc/kernel/vdso/Makefile +3 -3
@@ -3,7 +3,7 @@ # List of files in the vdso, has to be asm only for now # Include the generic Makefile to check the built vdso. -include $(srctree)/lib/vdso/Makefile +include $(srctree)lib/vdso/Makefile obj-vdso32 = sigtramp32-32.o gettimeofday-32.o datapage-32.o cacheflush-32.o note-32.o getcpu-32.o obj-vdso64 = sigtramp64-64.o gettimeofday-64.o datapage-64.o cacheflush-64.o note-64.o getcpu-64.o
@@ -90,10 +90,10 @@ $(obj)/vgettimeofday-64.o: %-64.o: %.c FORCE $(call if_changed_dep,cc_o_c) # Generate VDSO offsets using helper script -gen-vdso32sym := $(srctree)/$(src)/gen_vdso32_offsets.sh +gen-vdso32sym := $(srctree)$(src)/gen_vdso32_offsets.sh quiet_cmd_vdso32sym = VDSO32SYM $@ cmd_vdso32sym = $(NM) $< | $(gen-vdso32sym) | LC_ALL=C sort > $@ -gen-vdso64sym := $(srctree)/$(src)/gen_vdso64_offsets.sh +gen-vdso64sym := $(srctree)$(src)/gen_vdso64_offsets.sh quiet_cmd_vdso64sym = VDSO64SYM $@ cmd_vdso64sym = $(NM) $< | $(gen-vdso64sym) | LC_ALL=C sort > $@
arch/powerpc/kvm/Makefile +1 -1
@@ -5,7 +5,7 @@ ccflags-y := -Ivirt/kvm -Iarch/powerpc/kvm -include $(srctree)/virt/kvm/Makefile.kvm +include $(srctree)virt/kvm/Makefile.kvm common-objs-y += powerpc.o emulate_loadstore.o obj-$(CONFIG_KVM_EXIT_TIMING) += timing.o
arch/powerpc/platforms/cell/spufs/Makefile +2 -2
@@ -15,8 +15,8 @@ SPU_CC := $(SPU_CROSS)gcc SPU_AS := $(SPU_CROSS)gcc SPU_LD := $(SPU_CROSS)ld SPU_OBJCOPY := $(SPU_CROSS)objcopy -SPU_CFLAGS := -O2 -Wall -I$(srctree)/include -D__KERNEL__ -SPU_AFLAGS := -c -D__ASSEMBLY__ -I$(srctree)/include -D__KERNEL__ +SPU_CFLAGS := -O2 -Wall -I$(srctree)include -D__KERNEL__ +SPU_AFLAGS := -c -D__ASSEMBLY__ -I$(srctree)include -D__KERNEL__ SPU_LDFLAGS := -N -Ttext=0x0 $(obj)/switch.o: $(obj)/spu_save_dump.h $(obj)/spu_restore_dump.h
arch/riscv/Makefile +6 -6
@@ -179,18 +179,18 @@ install zinstall: PHONY += rv32_randconfig rv32_randconfig: - $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)/arch/riscv/configs/32-bit.config \ - -f $(srctree)/Makefile randconfig + $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)arch/riscv/configs/32-bit.config \ + -f $(srctree)Makefile randconfig PHONY += rv64_randconfig rv64_randconfig: - $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)/arch/riscv/configs/64-bit.config \ - -f $(srctree)/Makefile randconfig + $(Q)$(MAKE) KCONFIG_ALLCONFIG=$(srctree)arch/riscv/configs/64-bit.config \ + -f $(srctree)Makefile randconfig PHONY += rv32_defconfig rv32_defconfig: - $(Q)$(MAKE) -f $(srctree)/Makefile defconfig 32-bit.config + $(Q)$(MAKE) -f $(srctree)Makefile defconfig 32-bit.config PHONY += rv32_nommu_virt_defconfig rv32_nommu_virt_defconfig: - $(Q)$(MAKE) -f $(srctree)/Makefile nommu_virt_defconfig 32-bit.config + $(Q)$(MAKE) -f $(srctree)Makefile nommu_virt_defconfig 32-bit.config
arch/riscv/Makefile.postlink +2 -2
@@ -9,11 +9,11 @@ PHONY := __archpost __archpost: -include include/config/auto.conf -include $(srctree)/scripts/Kbuild.include +include $(srctree)scripts/Kbuild.include quiet_cmd_relocs_check = CHKREL $@ cmd_relocs_check = \ - $(CONFIG_SHELL) $(srctree)/arch/riscv/tools/relocs_check.sh "$(OBJDUMP)" "$(NM)" "$@" + $(CONFIG_SHELL) $(srctree)arch/riscv/tools/relocs_check.sh "$(OBJDUMP)" "$(NM)" "$@" ifdef CONFIG_RELOCATABLE quiet_cmd_cp_vmlinux_relocs = CPREL vmlinux.relocs
arch/riscv/boot/Makefile +1 -1
@@ -74,4 +74,4 @@ EFI_ZBOOT_PAYLOAD := Image EFI_ZBOOT_BFD_TARGET := elf$(BITS)-littleriscv EFI_ZBOOT_MACH_TYPE := RISCV$(BITS) -include $(srctree)/drivers/firmware/efi/libstub/Makefile.zboot +include $(srctree)drivers/firmware/efi/libstub/Makefile.zboot
arch/riscv/kernel/compat_vdso/Makefile +1 -1
@@ -58,7 +58,7 @@ $(obj)/%.so: $(obj)/%.so.dbg FORCE $(call if_changed,objcopy) # Generate VDSO offsets using helper script -gen-compat_vdsosym := $(srctree)/$(src)/gen_compat_vdso_offsets.sh +gen-compat_vdsosym := $(srctree)$(src)/gen_compat_vdso_offsets.sh quiet_cmd_compat_vdsosym = VDSOSYM $@ cmd_compat_vdsosym = $(NM) $< | $(gen-compat_vdsosym) | LC_ALL=C sort > $@
arch/riscv/kernel/pi/Makefile +4 -4
@@ -4,7 +4,7 @@ KBUILD_CFLAGS := $(subst $(CC_FLAGS_FTRACE),,$(KBUILD_CFLAGS)) -fpie \ -Os -DDISABLE_BRANCH_PROFILING $(DISABLE_STACKLEAK_PLUGIN) \ $(call cc-option,-mbranch-protection=none) \ - -I$(srctree)/scripts/dtc/libfdt -fno-stack-protector \ + -I$(srctree)scripts/dtc/libfdt -fno-stack-protector \ -D__DISABLE_EXPORTS -ffreestanding \ -fno-asynchronous-unwind-tables -fno-unwind-tables \ $(call cc-option,-fno-addrsig)
@@ -26,13 +26,13 @@ $(obj)/%.pi.o: OBJCOPYFLAGS := --prefix-symbols=__pi_ \ $(obj)/%.pi.o: $(obj)/%.o FORCE $(call if_changed,objcopy) -$(obj)/lib-%.o: $(srctree)/lib/%.c FORCE +$(obj)/lib-%.o: $(srctree)lib/%.c FORCE $(call if_changed_rule,cc_o_c) -$(obj)/string.o: $(srctree)/lib/string.c FORCE +$(obj)/string.o: $(srctree)lib/string.c FORCE $(call if_changed_rule,cc_o_c) -$(obj)/ctype.o: $(srctree)/lib/ctype.c FORCE +$(obj)/ctype.o: $(srctree)lib/ctype.c FORCE $(call if_changed_rule,cc_o_c) obj-y := cmdline_early.pi.o fdt_early.pi.o string.pi.o ctype.pi.o lib-fdt.pi.o lib-fdt_ro.pi.o
arch/riscv/kernel/vdso/Makefile +2 -2
@@ -2,7 +2,7 @@ # Copied from arch/tile/kernel/vdso/Makefile # Include the generic Makefile to check the built vdso. -include $(srctree)/lib/vdso/Makefile +include $(srctree)lib/vdso/Makefile # Symbols present in the vdso vdso-syms = rt_sigreturn ifdef CONFIG_64BIT
@@ -59,7 +59,7 @@ $(obj)/%.so: $(obj)/%.so.dbg FORCE $(call if_changed,objcopy) # Generate VDSO offsets using helper script -gen-vdsosym := $(srctree)/$(src)/gen_vdso_offsets.sh +gen-vdsosym := $(srctree)$(src)/gen_vdso_offsets.sh quiet_cmd_vdsosym = VDSOSYM $@ cmd_vdsosym = $(NM) $< | $(gen-vdsosym) | LC_ALL=C sort > $@
arch/riscv/kvm/Makefile +2 -2
@@ -3,9 +3,9 @@ # Makefile for RISC-V KVM support # -ccflags-y += -I $(srctree)/$(src) +ccflags-y += -I $(srctree)$(src) -include $(srctree)/virt/kvm/Makefile.kvm +include $(srctree)virt/kvm/Makefile.kvm obj-$(CONFIG_KVM) += kvm.o
arch/riscv/purgatory/Makefile +8 -8
@@ -7,28 +7,28 @@ purgatory-y += strcmp.o strlen.o strncmp.o targets += $(purgatory-y) PURGATORY_OBJS = $(addprefix $(obj)/,$(purgatory-y)) -$(obj)/string.o: $(srctree)/lib/string.c FORCE +$(obj)/string.o: $(srctree)lib/string.c FORCE $(call if_changed_rule,cc_o_c) -$(obj)/ctype.o: $(srctree)/lib/ctype.c FORCE +$(obj)/ctype.o: $(srctree)lib/ctype.c FORCE $(call if_changed_rule,cc_o_c) -$(obj)/memcpy.o: $(srctree)/arch/riscv/lib/memcpy.S FORCE +$(obj)/memcpy.o: $(srctree)arch/riscv/lib/memcpy.S FORCE $(call if_changed_rule,as_o_S) -$(obj)/memset.o: $(srctree)/arch/riscv/lib/memset.S FORCE +$(obj)/memset.o: $(srctree)arch/riscv/lib/memset.S FORCE $(call if_changed_rule,as_o_S) -$(obj)/strcmp.o: $(srctree)/arch/riscv/lib/strcmp.S FORCE +$(obj)/strcmp.o: $(srctree)arch/riscv/lib/strcmp.S FORCE $(call if_changed_rule,as_o_S) -$(obj)/strlen.o: $(srctree)/arch/riscv/lib/strlen.S FORCE +$(obj)/strlen.o: $(srctree)arch/riscv/lib/strlen.S FORCE $(call if_changed_rule,as_o_S) -$(obj)/strncmp.o: $(srctree)/arch/riscv/lib/strncmp.S FORCE +$(obj)/strncmp.o: $(srctree)arch/riscv/lib/strncmp.S FORCE $(call if_changed_rule,as_o_S) -$(obj)/sha256.o: $(srctree)/lib/crypto/sha256.c FORCE +$(obj)/sha256.o: $(srctree)lib/crypto/sha256.c FORCE $(call if_changed_rule,cc_o_c) CFLAGS_sha256.o := -D__DISABLE_EXPORTS -D__NO_FORTIFY
arch/s390/Makefile +1 -1
@@ -60,7 +60,7 @@ cflags-$(CONFIG_MARCH_Z14_TUNE) += -mtune=z14 cflags-$(CONFIG_MARCH_Z15_TUNE) += -mtune=z15 cflags-$(CONFIG_MARCH_Z16_TUNE) += -mtune=z16 -cflags-y += -Wa,-I$(srctree)/arch/$(ARCH)/include +cflags-y += -Wa,-I$(srctree)arch/$(ARCH)/include # # Prevent tail-call optimizations, to get clearer backtraces:
arch/s390/boot/Makefile +1 -1
@@ -33,7 +33,7 @@ CFLAGS_REMOVE_sclp_early_core.o += $(CC_FLAGS_MARCH) CFLAGS_sclp_early_core.o += $(CC_FLAGS_MARCH_MINIMUM) endif -CFLAGS_sclp_early_core.o += -I$(srctree)/drivers/s390/char +CFLAGS_sclp_early_core.o += -I$(srctree)drivers/s390/char obj-y := head.o als.o startup.o physmem_info.o ipl_parm.o ipl_report.o vmem.o obj-y += string.o ebcdic.o sclp_early_core.o mem.o ipl_vmparm.o cmdline.o
arch/s390/kernel/syscalls/Makefile +2 -2
@@ -4,8 +4,8 @@ gen := arch/$(ARCH)/include/generated kapi := $(gen)/asm uapi := $(gen)/uapi/asm -syscall := $(srctree)/$(src)/syscall.tbl -systbl := $(srctree)/$(src)/syscalltbl +syscall := $(srctree)$(src)/syscall.tbl +systbl := $(srctree)$(src)/syscalltbl gen-y := $(kapi)/syscall_table.h kapi-hdrs-y := $(kapi)/unistd_nr.h
arch/s390/kernel/vdso32/Makefile +2 -2
@@ -4,7 +4,7 @@ KCOV_INSTRUMENT := n # Include the generic Makefile to check the built vdso. -include $(srctree)/lib/vdso/Makefile +include $(srctree)lib/vdso/Makefile obj-vdso32 = vdso_user_wrapper-32.o note-32.o # Build rules
@@ -62,7 +62,7 @@ quiet_cmd_vdso32cc = VDSO32C $@ cmd_vdso32cc = $(CC) $(c_flags) -c -o $@ $< # Generate VDSO offsets using helper script -gen-vdsosym := $(srctree)/$(src)/gen_vdso_offsets.sh +gen-vdsosym := $(srctree)$(src)/gen_vdso_offsets.sh quiet_cmd_vdsosym = VDSOSYM $@ cmd_vdsosym = $(NM) $< | $(gen-vdsosym) | LC_ALL=C sort > $@
arch/s390/kernel/vdso64/Makefile +2 -2
@@ -4,7 +4,7 @@ KCOV_INSTRUMENT := n # Include the generic Makefile to check the built vdso. -include $(srctree)/lib/vdso/Makefile +include $(srctree)lib/vdso/Makefile obj-vdso64 = vdso_user_wrapper.o note.o obj-cvdso64 = vdso64_generic.o getcpu.o VDSO_CFLAGS_REMOVE := -pg $(CC_FLAGS_FTRACE) $(CC_FLAGS_EXPOLINE) $(CC_FLAGS_CHECK_STACK)
@@ -71,7 +71,7 @@ quiet_cmd_vdso64cc = VDSO64C $@ cmd_vdso64cc = $(CC) $(c_flags) -c -o $@ $< # Generate VDSO offsets using helper script -gen-vdsosym := $(srctree)/$(src)/gen_vdso_offsets.sh +gen-vdsosym := $(srctree)$(src)/gen_vdso_offsets.sh quiet_cmd_vdsosym = VDSOSYM $@ cmd_vdsosym = $(NM) $< | $(gen-vdsosym) | LC_ALL=C sort > $@
arch/s390/kvm/Makefile +1 -1
@@ -3,7 +3,7 @@ # # Copyright IBM Corp. 2008 -include $(srctree)/virt/kvm/Makefile.kvm +include $(srctree)virt/kvm/Makefile.kvm ccflags-y := -Ivirt/kvm -Iarch/s390/kvm
arch/s390/purgatory/Makefile +2 -2
@@ -7,12 +7,12 @@ purgatory-y := head.o purgatory.o string.o sha256.o mem.o targets += $(purgatory-y) purgatory.lds purgatory purgatory.chk purgatory.ro PURGATORY_OBJS = $(addprefix $(obj)/,$(purgatory-y)) -$(obj)/sha256.o: $(srctree)/lib/crypto/sha256.c FORCE +$(obj)/sha256.o: $(srctree)lib/crypto/sha256.c FORCE $(call if_changed_rule,cc_o_c) CFLAGS_sha256.o := -D__DISABLE_EXPORTS -D__NO_FORTIFY -$(obj)/mem.o: $(srctree)/arch/s390/lib/mem.S FORCE +$(obj)/mem.o: $(srctree)arch/s390/lib/mem.S FORCE $(call if_changed_rule,as_o_S) KCOV_INSTRUMENT := n
arch/s390/tools/Makefile +1 -1
@@ -18,7 +18,7 @@ HOSTCFLAGS_gen_facilities.o += $(LINUXINCLUDE) filechk_facility-defs.h = $(obj)/gen_facilities filechk_dis-defs.h = \ - $(obj)/gen_opcode_table < $(srctree)/arch/$(ARCH)/tools/opcodes.txt + $(obj)/gen_opcode_table < $(srctree)arch/$(ARCH)/tools/opcodes.txt $(kapi)/facility-defs.h: $(obj)/gen_facilities FORCE $(call filechk,facility-defs.h)
arch/sh/Makefile +1 -1
@@ -145,7 +145,7 @@ cpuincdir-y += cpu-common # Must be last drivers-y += arch/sh/drivers/ -KBUILD_CPPFLAGS += $(addprefix -I $(srctree)/arch/sh/include/, $(cpuincdir-y) $(machdir-y)) +KBUILD_CPPFLAGS += $(addprefix -I $(srctree)arch/sh/include/, $(cpuincdir-y) $(machdir-y)) KBUILD_CFLAGS += -pipe $(cflags-y) KBUILD_AFLAGS += $(cflags-y)
arch/sh/kernel/syscalls/Makefile +2 -2
@@ -5,8 +5,8 @@ uapi := arch/$(SRCARCH)/include/generated/uapi/asm $(shell mkdir -p $(uapi) $(kapi)) syscall := $(src)/syscall.tbl -syshdr := $(srctree)/scripts/syscallhdr.sh -systbl := $(srctree)/scripts/syscalltbl.sh +syshdr := $(srctree)scripts/syscallhdr.sh +systbl := $(srctree)scripts/syscalltbl.sh quiet_cmd_syshdr = SYSHDR $@ cmd_syshdr = $(CONFIG_SHELL) $(syshdr) --emit-nr $< $@
arch/sparc/kernel/syscalls/Makefile +2 -2
@@ -5,8 +5,8 @@ uapi := arch/$(SRCARCH)/include/generated/uapi/asm $(shell mkdir -p $(uapi) $(kapi)) syscall := $(src)/syscall.tbl -syshdr := $(srctree)/scripts/syscallhdr.sh -systbl := $(srctree)/scripts/syscalltbl.sh +syshdr := $(srctree)scripts/syscallhdr.sh +systbl := $(srctree)scripts/syscalltbl.sh quiet_cmd_syshdr = SYSHDR $@ cmd_syshdr = $(CONFIG_SHELL) $(syshdr) --emit-nr --abis common,$* $< $@
arch/sparc/vdso/Makefile +2 -2
@@ -28,7 +28,7 @@ VDSO_LDFLAGS_vdso.lds = -m elf64_sparc -soname linux-vdso.so.1 --no-undefined \ $(obj)/vdso64.so.dbg: $(obj)/vdso.lds $(vobjs) FORCE $(call if_changed,vdso) -HOST_EXTRACFLAGS += -I$(srctree)/tools/include +HOST_EXTRACFLAGS += -I$(srctree)tools/include hostprogs += vdso2c quiet_cmd_vdso2c = VDSO2C $@
@@ -102,7 +102,7 @@ quiet_cmd_vdso = VDSO $@ cmd_vdso = $(LD) -nostdlib -o $@ \ $(VDSO_LDFLAGS) $(VDSO_LDFLAGS_$(filter %.lds,$(^F))) \ -T $(filter %.lds,$^) $(filter %.o,$^) && \ - sh $(srctree)/$(src)/checkundef.sh '$(OBJDUMP)' '$@' + sh $(srctree)$(src)/checkundef.sh '$(OBJDUMP)' '$@' VDSO_LDFLAGS = -shared --hash-style=both --build-id=sha1 -Bsymbolic GCOV_PROFILE := n
arch/um/Makefile +11 -11
@@ -22,7 +22,7 @@ ARCH_DIR := arch/um # features. SHELL := /bin/bash -MODE_INCLUDE += -I$(srctree)/$(ARCH_DIR)/include/shared/skas +MODE_INCLUDE += -I$(srctree)$(ARCH_DIR)/include/shared/skas HEADER_ARCH := $(SUBARCH)
@@ -36,15 +36,15 @@ endif HOST_DIR := arch/$(HEADER_ARCH) -include $(srctree)/$(ARCH_DIR)/Makefile-skas -include $(srctree)/$(HOST_DIR)/Makefile.um +include $(srctree)$(ARCH_DIR)/Makefile-skas +include $(srctree)$(HOST_DIR)/Makefile.um core-y += $(HOST_DIR)/um/ SHARED_HEADERS := $(ARCH_DIR)/include/shared -ARCH_INCLUDE := -I$(srctree)/$(SHARED_HEADERS) -ARCH_INCLUDE += -I$(srctree)/$(HOST_DIR)/um/shared -KBUILD_CPPFLAGS += -I$(srctree)/$(HOST_DIR)/um +ARCH_INCLUDE := -I$(srctree)$(SHARED_HEADERS) +ARCH_INCLUDE += -I$(srctree)$(HOST_DIR)/um/shared +KBUILD_CPPFLAGS += -I$(srctree)$(HOST_DIR)/um # -Dvmap=kernel_vmap prevents anything from referencing the libpcap.o symbol so # named - it's a common symbol in libpcap, so we get a binary which crashes.
@@ -69,14 +69,14 @@ KBUILD_AFLAGS += $(ARCH_INCLUDE) USER_CFLAGS = $(patsubst $(KERNEL_DEFINES),,$(patsubst -I%,,$(KBUILD_CFLAGS))) \ $(ARCH_INCLUDE) $(MODE_INCLUDE) $(filter -I%,$(CFLAGS)) \ - -D_FILE_OFFSET_BITS=64 -idirafter $(srctree)/include \ + -D_FILE_OFFSET_BITS=64 -idirafter $(srctree)include \ -idirafter $(objtree)/include -D__KERNEL__ -D__UM_HOST__ #This will adjust *FLAGS accordingly to the platform. -include $(srctree)/$(ARCH_DIR)/Makefile-os-Linux +include $(srctree)$(ARCH_DIR)/Makefile-os-Linux -KBUILD_CPPFLAGS += -I$(srctree)/$(HOST_DIR)/include \ - -I$(srctree)/$(HOST_DIR)/include/uapi \ +KBUILD_CPPFLAGS += -I$(srctree)$(HOST_DIR)/include \ + -I$(srctree)$(HOST_DIR)/include/uapi \ -I$(objtree)/$(HOST_DIR)/include/generated \ -I$(objtree)/$(HOST_DIR)/include/generated/uapi
@@ -109,7 +109,7 @@ define archhelp endef archheaders: - $(Q)$(MAKE) -f $(srctree)/Makefile ARCH=$(HEADER_ARCH) asm-generic archheaders + $(Q)$(MAKE) -f $(srctree)Makefile ARCH=$(HEADER_ARCH) asm-generic archheaders archprepare: $(Q)$(MAKE) $(build)=$(HOST_DIR)/um include/generated/user_constants.h
arch/um/drivers/Makefile +1 -1
@@ -74,4 +74,4 @@ CFLAGS_null.o = -DDEV_NULL=$(DEV_NULL_PATH) CFLAGS_xterm.o += '-DCONFIG_XTERM_CHAN_DEFAULT_EMULATOR="$(CONFIG_XTERM_CHAN_DEFAULT_EMULATOR)"' -include $(srctree)/arch/um/scripts/Makefile.rules +include $(srctree)arch/um/scripts/Makefile.rules
arch/um/kernel/Makefile +2 -2
@@ -29,7 +29,7 @@ obj-$(CONFIG_GENERIC_PCI_IOMAP) += ioport.o USER_OBJS := config.o -include $(srctree)/arch/um/scripts/Makefile.rules +include $(srctree)arch/um/scripts/Makefile.rules targets := config.c config.tmp capflags.c
@@ -47,7 +47,7 @@ $(obj)/config.c: $(src)/config.c.in $(obj)/config.tmp FORCE $(call if_changed,quote2) quiet_cmd_mkcapflags = MKCAP $@ - cmd_mkcapflags = $(CONFIG_SHELL) $(srctree)/$(src)/../../x86/kernel/cpu/mkcapflags.sh $@ $^ + cmd_mkcapflags = $(CONFIG_SHELL) $(srctree)$(src)/../../x86/kernel/cpu/mkcapflags.sh $@ $^ cpufeature = $(src)/../../x86/include/asm/cpufeatures.h vmxfeature = $(src)/../../x86/include/asm/vmxfeatures.h
arch/um/kernel/skas/Makefile +1 -1
@@ -14,4 +14,4 @@ UNPROFILE_OBJS := clone.o KCOV_INSTRUMENT := n -include $(srctree)/arch/um/scripts/Makefile.rules +include $(srctree)arch/um/scripts/Makefile.rules
arch/um/os-Linux/Makefile +1 -1
@@ -18,4 +18,4 @@ USER_OBJS := $(user-objs-y) elf_aux.o execvp.o file.o helper.o irq.o \ main.o mem.o process.o registers.o sigio.o signal.o start_up.o time.o \ tty.o umid.o util.o -include $(srctree)/arch/um/scripts/Makefile.rules +include $(srctree)arch/um/scripts/Makefile.rules
arch/um/os-Linux/drivers/Makefile +1 -1
@@ -10,4 +10,4 @@ obj-y = obj-$(CONFIG_UML_NET_ETHERTAP) += ethertap.o obj-$(CONFIG_UML_NET_TUNTAP) += tuntap.o -include $(srctree)/arch/um/scripts/Makefile.rules +include $(srctree)arch/um/scripts/Makefile.rules
arch/um/os-Linux/skas/Makefile +1 -1
@@ -7,4 +7,4 @@ obj-y := mem.o process.o USER_OBJS := $(obj-y) -include $(srctree)/arch/um/scripts/Makefile.rules +include $(srctree)arch/um/scripts/Makefile.rules
arch/um/scripts/Makefile.rules +1 -1
@@ -9,7 +9,7 @@ USER_OBJS += $(filter %_user.o,$(obj-y) $(USER_SINGLE_OBJS)) USER_OBJS := $(foreach file,$(USER_OBJS),$(obj)/$(file)) $(USER_OBJS:.o=.%): \ - c_flags = -Wp,-MD,$(depfile) $(USER_CFLAGS) -include $(srctree)/include/linux/kern_levels.h -include user.h $(CFLAGS_$(basetarget).o) + c_flags = -Wp,-MD,$(depfile) $(USER_CFLAGS) -include $(srctree)include/linux/kern_levels.h -include user.h $(CFLAGS_$(basetarget).o) # These are like USER_OBJS but filter USER_CFLAGS through unprofile instead of # using it directly.
arch/x86/Makefile +3 -3
@@ -106,7 +106,7 @@ ifeq ($(CONFIG_X86_32),y) KBUILD_CFLAGS += $(cc_stack_align4) # CPU-specific tuning. Anything which can be shared with UML should go here. - include $(srctree)/arch/x86/Makefile_32.cpu + include $(srctree)arch/x86/Makefile_32.cpu KBUILD_CFLAGS += $(cflags-y) # temporary until string.h is fixed
@@ -311,12 +311,12 @@ endif ifdef CONFIG_UNWINDER_ORC orc_hash_h := arch/$(SRCARCH)/include/generated/asm/orc_hash.h -orc_hash_sh := $(srctree)/scripts/orc_hash.sh +orc_hash_sh := $(srctree)scripts/orc_hash.sh targets += $(orc_hash_h) quiet_cmd_orc_hash = GEN $@ cmd_orc_hash = mkdir -p $(dir $@); \ $(CONFIG_SHELL) $(orc_hash_sh) < $< > $@ -$(orc_hash_h): $(srctree)/arch/x86/include/asm/orc_types.h $(orc_hash_sh) FORCE +$(orc_hash_h): $(srctree)arch/x86/include/asm/orc_types.h $(orc_hash_sh) FORCE $(call if_changed,orc_hash) archprepare: $(orc_hash_h) endif
arch/x86/Makefile.postlink +1 -1
@@ -10,7 +10,7 @@ PHONY := __archpost __archpost: -include include/config/auto.conf -include $(srctree)/scripts/Kbuild.include +include $(srctree)scripts/Kbuild.include CMD_RELOCS = arch/x86/tools/relocs OUT_RELOCS = arch/x86/boot/compressed
arch/x86/Makefile.um +1 -1
@@ -28,7 +28,7 @@ LDS_EXTRA := -Ui386 export LDS_EXTRA # First of all, tune CFLAGS for the specific CPU. This actually sets cflags-y. -include $(srctree)/arch/x86/Makefile_32.cpu +include $(srctree)arch/x86/Makefile_32.cpu # prevent gcc from keeping the stack 16 byte aligned. Taken from i386. cflags-y += $(call cc-option,-mpreferred-stack-boundary=2)
arch/x86/boot/Makefile +3 -3
@@ -51,7 +51,7 @@ targets += $(setup-y) hostprogs := tools/build hostprogs += mkcpustr -HOST_EXTRACFLAGS += -I$(srctree)/tools/include \ +HOST_EXTRACFLAGS += -I$(srctree)tools/include \ -include include/generated/autoconf.h \ -D__EXPORTED_HEADERS__
@@ -67,7 +67,7 @@ targets += cpustr.h KBUILD_CFLAGS := $(REALMODE_CFLAGS) -D_SETUP KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__ -KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)/=) +KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)=) KBUILD_CFLAGS += -fno-asynchronous-unwind-tables GCOV_PROFILE := n UBSAN_SANITIZE := n
@@ -129,7 +129,7 @@ targets += mtools.conf # genimage.sh requires bash, but it also has a bunch of other # external dependencies. quiet_cmd_genimage = GENIMAGE $3 -cmd_genimage = $(BASH) $(srctree)/$(src)/genimage.sh $2 $3 $(obj)/bzImage \ +cmd_genimage = $(BASH) $(srctree)$(src)/genimage.sh $2 $3 $(obj)/bzImage \ $(obj)/mtools.conf '$(FDARGS)' $(FDINITRD) PHONY += bzdisk fdimage fdimage144 fdimage288 hdimage isoimage
arch/x86/boot/compressed/Makefile +3 -3
@@ -46,12 +46,12 @@ KBUILD_CFLAGS += -fno-stack-protector KBUILD_CFLAGS += $(call cc-disable-warning, address-of-packed-member) KBUILD_CFLAGS += $(call cc-disable-warning, gnu) KBUILD_CFLAGS += -Wno-pointer-sign -KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)/=) +KBUILD_CFLAGS += $(call cc-option,-fmacro-prefix-map=$(srctree)=) KBUILD_CFLAGS += -fno-asynchronous-unwind-tables KBUILD_CFLAGS += -D__DISABLE_EXPORTS # Disable relocation relaxation in case the link is not PIE. KBUILD_CFLAGS += $(call cc-option,-Wa$(comma)-mrelax-relocations=no) -KBUILD_CFLAGS += -include $(srctree)/include/linux/hidden.h +KBUILD_CFLAGS += -include $(srctree)include/linux/hidden.h # sev.c indirectly includes inat-table.h which is generated during # compilation and stored in $(objtree). Add the directory to the includes so
@@ -82,7 +82,7 @@ endif LDFLAGS_vmlinux += -T hostprogs := mkpiggy -HOST_EXTRACFLAGS += -I$(srctree)/tools/include +HOST_EXTRACFLAGS += -I$(srctree)tools/include sed-voffset := -e 's/^\([0-9a-fA-F]*\) [ABCDGRSTVW] \(_text\|__bss_start\|_end\)$$/\#define VO_\2 _AC(0x\1,UL)/p'
arch/x86/entry/syscalls/Makefile +4 -4
@@ -8,8 +8,8 @@ $(shell mkdir -p $(out) $(uapi)) syscall32 := $(src)/syscall_32.tbl syscall64 := $(src)/syscall_64.tbl -syshdr := $(srctree)/scripts/syscallhdr.sh -systbl := $(srctree)/scripts/syscalltbl.sh +syshdr := $(srctree)scripts/syscallhdr.sh +systbl := $(srctree)scripts/syscalltbl.sh offset := prefix :=
@@ -57,10 +57,10 @@ $(out)/syscalls_x32.h: abis := common,x32 $(out)/syscalls_x32.h: $(syscall64) $(systbl) FORCE $(call if_changed,systbl) -$(out)/xen-hypercalls.h: $(srctree)/scripts/xen-hypercalls.sh FORCE +$(out)/xen-hypercalls.h: $(srctree)scripts/xen-hypercalls.sh FORCE $(call if_changed,hypercalls) -$(out)/xen-hypercalls.h: $(srctree)/include/xen/interface/xen*.h +$(out)/xen-hypercalls.h: $(srctree)include/xen/interface/xen*.h uapisyshdr-y += unistd_32.h unistd_64.h unistd_x32.h syshdr-y += syscalls_32.h
arch/x86/entry/vdso/Makefile +3 -3
@@ -4,7 +4,7 @@ # # Include the generic Makefile to check the built vdso. -include $(srctree)/lib/vdso/Makefile +include $(srctree)lib/vdso/Makefile # Sanitizer runtimes are unavailable and cannot be linked here. KASAN_SANITIZE := n
@@ -69,7 +69,7 @@ VDSO_LDFLAGS_vdso.lds = -m elf_x86_64 -soname linux-vdso.so.1 --no-undefined \ $(obj)/vdso64.so.dbg: $(obj)/vdso.lds $(vobjs) FORCE $(call if_changed,vdso_and_check) -HOST_EXTRACFLAGS += -I$(srctree)/tools/include -I$(srctree)/include/uapi -I$(srctree)/arch/$(SUBARCH)/include/uapi +HOST_EXTRACFLAGS += -I$(srctree)tools/include -I$(srctree)include/uapi -I$(srctree)arch/$(SUBARCH)/include/uapi hostprogs += vdso2c quiet_cmd_vdso2c = VDSO2C $@
@@ -182,7 +182,7 @@ quiet_cmd_vdso = VDSO $@ cmd_vdso = $(LD) -o $@ \ $(VDSO_LDFLAGS) $(VDSO_LDFLAGS_$(filter %.lds,$(^F))) \ -T $(filter %.lds,$^) $(filter %.o,$^) && \ - sh $(srctree)/$(src)/checkundef.sh '$(NM)' '$@' + sh $(srctree)$(src)/checkundef.sh '$(NM)' '$@' VDSO_LDFLAGS = -shared --hash-style=both --build-id=sha1 \ $(call ld-option, --eh-frame-hdr) -Bsymbolic -z noexecstack
arch/x86/kernel/Makefile +1 -1
@@ -39,7 +39,7 @@ KMSAN_SANITIZE_nmi.o := n KCOV_INSTRUMENT_head$(BITS).o := n KCOV_INSTRUMENT_sev.o := n -CFLAGS_irq.o := -I $(srctree)/$(src)/../include/asm/trace +CFLAGS_irq.o := -I $(srctree)$(src)/../include/asm/trace obj-y += head_$(BITS).o obj-y += head$(BITS).o
arch/x86/kernel/cpu/Makefile +1 -1
@@ -57,7 +57,7 @@ obj-$(CONFIG_ACRN_GUEST) += acrn.o obj-$(CONFIG_DEBUG_FS) += debugfs.o quiet_cmd_mkcapflags = MKCAP $@ - cmd_mkcapflags = $(CONFIG_SHELL) $(srctree)/$(src)/mkcapflags.sh $@ $^ + cmd_mkcapflags = $(CONFIG_SHELL) $(srctree)$(src)/mkcapflags.sh $@ $^ cpufeature = $(src)/../../include/asm/cpufeatures.h vmxfeature = $(src)/../../include/asm/vmxfeatures.h
arch/x86/kvm/Makefile +2 -2
@@ -1,13 +1,13 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-y += -I $(srctree)/arch/x86/kvm +ccflags-y += -I $(srctree)arch/x86/kvm ccflags-$(CONFIG_KVM_WERROR) += -Werror ifeq ($(CONFIG_FRAME_POINTER),y) OBJECT_FILES_NON_STANDARD_vmenter.o := y endif -include $(srctree)/virt/kvm/Makefile.kvm +include $(srctree)virt/kvm/Makefile.kvm kvm-y += x86.o emulate.o i8259.o irq.o lapic.o \ i8254.o ioapic.o irq_comm.o cpuid.o pmu.o mtrr.o \
arch/x86/lib/Makefile +2 -2
@@ -27,8 +27,8 @@ endif CFLAGS_cmdline.o := -fno-stack-protector -fno-jump-tables endif -inat_tables_script = $(srctree)/arch/x86/tools/gen-insn-attr-x86.awk -inat_tables_maps = $(srctree)/arch/x86/lib/x86-opcode-map.txt +inat_tables_script = $(srctree)arch/x86/tools/gen-insn-attr-x86.awk +inat_tables_maps = $(srctree)arch/x86/lib/x86-opcode-map.txt quiet_cmd_inat_tables = GEN $@ cmd_inat_tables = $(AWK) -f $(inat_tables_script) $(inat_tables_maps) > $@
arch/x86/mm/Makefile +1 -1
@@ -33,7 +33,7 @@ obj-y += pat/ CFLAGS_physaddr.o := -fno-stack-protector CFLAGS_mem_encrypt_identity.o := -fno-stack-protector -CFLAGS_fault.o := -I $(srctree)/$(src)/../include/asm/trace +CFLAGS_fault.o := -I $(srctree)$(src)/../include/asm/trace obj-$(CONFIG_X86_32) += pgtable_32.o iomap_32.o
arch/x86/purgatory/Makefile +2 -2
@@ -6,10 +6,10 @@ purgatory-y := purgatory.o stack.o setup-x86_$(BITS).o sha256.o entry64.o string targets += $(purgatory-y) PURGATORY_OBJS = $(addprefix $(obj)/,$(purgatory-y)) -$(obj)/string.o: $(srctree)/arch/x86/boot/compressed/string.c FORCE +$(obj)/string.o: $(srctree)arch/x86/boot/compressed/string.c FORCE $(call if_changed_rule,cc_o_c) -$(obj)/sha256.o: $(srctree)/lib/crypto/sha256.c FORCE +$(obj)/sha256.o: $(srctree)lib/crypto/sha256.c FORCE $(call if_changed_rule,cc_o_c) CFLAGS_sha256.o := -D__DISABLE_EXPORTS -D__NO_FORTIFY
arch/x86/realmode/rm/Makefile +1 -1
@@ -73,7 +73,7 @@ $(obj)/realmode.relocs: $(obj)/realmode.elf FORCE # --------------------------------------------------------------------------- KBUILD_CFLAGS := $(REALMODE_CFLAGS) -D_SETUP -D_WAKEUP \ - -I$(srctree)/arch/x86/boot + -I$(srctree)arch/x86/boot KBUILD_AFLAGS := $(KBUILD_CFLAGS) -D__ASSEMBLY__ KBUILD_CFLAGS += -fno-asynchronous-unwind-tables GCOV_PROFILE := n
arch/x86/tools/Makefile +7 -7
@@ -13,8 +13,8 @@ else posttest_64bit = -n endif -reformatter = $(srctree)/arch/x86/tools/objdump_reformat.awk -chkobjdump = $(srctree)/arch/x86/tools/chkobjdump.awk +reformatter = $(srctree)arch/x86/tools/objdump_reformat.awk +chkobjdump = $(srctree)arch/x86/tools/chkobjdump.awk quiet_cmd_posttest = TEST $@ cmd_posttest = $(OBJDUMP) -d -j .text $(objtree)/vmlinux | $(AWK) -f $(reformatter) | $(obj)/insn_decoder_test $(posttest_64bit) $(posttest_verbose)
@@ -29,16 +29,16 @@ posttest: $(obj)/insn_decoder_test vmlinux $(obj)/insn_sanity hostprogs += insn_decoder_test insn_sanity # -I needed for generated C source and C source which in the kernel tree. -HOSTCFLAGS_insn_decoder_test.o := -Wall -I$(srctree)/tools/arch/x86/lib/ -I$(srctree)/tools/arch/x86/include/ -I$(objtree)/arch/x86/lib/ +HOSTCFLAGS_insn_decoder_test.o := -Wall -I$(srctree)tools/arch/x86/lib/ -I$(srctree)tools/arch/x86/include/ -I$(objtree)/arch/x86/lib/ -HOSTCFLAGS_insn_sanity.o := -Wall -I$(srctree)/tools/arch/x86/lib/ -I$(srctree)/tools/arch/x86/include/ -I$(objtree)/arch/x86/lib/ +HOSTCFLAGS_insn_sanity.o := -Wall -I$(srctree)tools/arch/x86/lib/ -I$(srctree)tools/arch/x86/include/ -I$(objtree)/arch/x86/lib/ # Dependencies are also needed. -$(obj)/insn_decoder_test.o: $(srctree)/tools/arch/x86/lib/insn.c $(srctree)/tools/arch/x86/lib/inat.c $(srctree)/tools/arch/x86/include/asm/inat_types.h $(srctree)/tools/arch/x86/include/asm/inat.h $(srctree)/tools/arch/x86/include/asm/insn.h $(objtree)/arch/x86/lib/inat-tables.c +$(obj)/insn_decoder_test.o: $(srctree)tools/arch/x86/lib/insn.c $(srctree)tools/arch/x86/lib/inat.c $(srctree)tools/arch/x86/include/asm/inat_types.h $(srctree)tools/arch/x86/include/asm/inat.h $(srctree)tools/arch/x86/include/asm/insn.h $(objtree)/arch/x86/lib/inat-tables.c -$(obj)/insn_sanity.o: $(srctree)/tools/arch/x86/lib/insn.c $(srctree)/tools/arch/x86/lib/inat.c $(srctree)/tools/arch/x86/include/asm/inat_types.h $(srctree)/tools/arch/x86/include/asm/inat.h $(srctree)/tools/arch/x86/include/asm/insn.h $(objtree)/arch/x86/lib/inat-tables.c +$(obj)/insn_sanity.o: $(srctree)tools/arch/x86/lib/insn.c $(srctree)tools/arch/x86/lib/inat.c $(srctree)tools/arch/x86/include/asm/inat_types.h $(srctree)tools/arch/x86/include/asm/inat.h $(srctree)tools/arch/x86/include/asm/insn.h $(objtree)/arch/x86/lib/inat-tables.c -HOST_EXTRACFLAGS += -I$(srctree)/tools/include +HOST_EXTRACFLAGS += -I$(srctree)tools/include hostprogs += relocs relocs-objs := relocs_32.o relocs_64.o relocs_common.o PHONY += relocs
arch/x86/um/Makefile +1 -1
@@ -49,4 +49,4 @@ include/generated/user_constants.h: $(obj)/user-offsets.s FORCE UNPROFILE_OBJS := stub_segv.o CFLAGS_stub_segv.o := $(CFLAGS_NO_HARDENING) -include $(srctree)/arch/um/scripts/Makefile.rules +include $(srctree)arch/um/scripts/Makefile.rules
arch/x86/um/os-Linux/Makefile +1 -1
@@ -9,4 +9,4 @@ obj-$(CONFIG_X86_32) += tls.o USER_OBJS := $(obj-y) -include $(srctree)/arch/um/scripts/Makefile.rules +include $(srctree)arch/um/scripts/Makefile.rules
arch/x86/um/vdso/Makefile +1 -1
@@ -63,7 +63,7 @@ quiet_cmd_vdso = VDSO $@ cmd_vdso = $(CC) -nostdlib -o $@ \ $(CC_FLAGS_LTO) $(VDSO_LDFLAGS) $(VDSO_LDFLAGS_$(filter %.lds,$(^F))) \ -Wl,-T,$(filter %.lds,$^) $(filter %.o,$^) && \ - sh $(srctree)/$(src)/checkundef.sh '$(NM)' '$@' + sh $(srctree)$(src)/checkundef.sh '$(NM)' '$@' VDSO_LDFLAGS = -fPIC -shared -Wl,--hash-style=sysv -z noexecstack GCOV_PROFILE := n
arch/xtensa/Makefile +1 -1
@@ -55,7 +55,7 @@ CHECKFLAGS += -D$(if $(CONFIG_CPU_BIG_ENDIAN),__XTENSA_EB__,__XTENSA_EL__) vardirs := $(patsubst %,arch/xtensa/variants/%/,$(variant-y)) plfdirs := $(patsubst %,arch/xtensa/platforms/%/,$(platform-y)) -KBUILD_CPPFLAGS += $(patsubst %,-I$(srctree)/%include,$(vardirs) $(plfdirs)) +KBUILD_CPPFLAGS += $(patsubst %,-I$(srctree)%include,$(vardirs) $(plfdirs)) KBUILD_DEFCONFIG := iss_defconfig
arch/xtensa/boot/boot-redboot/Makefile +1 -1
@@ -20,7 +20,7 @@ $(obj)/zImage.o: $(obj)/../vmlinux.bin.gz $(OBJS) $(obj)/zImage.elf: $(obj)/zImage.o $(LIBS) $(Q)$(LD) $(KBUILD_LDFLAGS) \ - -T $(srctree)/$(obj)/boot.ld \ + -T $(srctree)$(obj)/boot.ld \ --build-id=none \ -o $@ $^
arch/xtensa/boot/dts/Makefile +1 -1
@@ -10,5 +10,5 @@ obj-$(CONFIG_OF) += $(addsuffix .dtb.o, $(CONFIG_BUILTIN_DTB_SOURCE)) # for CONFIG_OF_ALL_DTBS test -dtstree := $(srctree)/$(src) +dtstree := $(srctree)$(src) dtb- := $(patsubst $(dtstree)/%.dts,%.dtb, $(wildcard $(dtstree)/*.dts))
arch/xtensa/boot/lib/Makefile +2 -2
@@ -7,7 +7,7 @@ zlib := inffast.c inflate.c inftrees.c lib-y += $(zlib:.c=.o) zmem.o -ccflags-y := -I $(srctree)/lib/zlib_inflate +ccflags-y := -I $(srctree)lib/zlib_inflate ifdef CONFIG_FUNCTION_TRACER CFLAGS_REMOVE_inflate.o = -pg CFLAGS_REMOVE_zmem.o = -pg
@@ -28,7 +28,7 @@ CFLAGS_REMOVE_inffast.o += -fstack-protector -fstack-protector-strong quiet_cmd_copy_zlib = COPY $@ cmd_copy_zlib = cat $< > $@ -$(addprefix $(obj)/,$(zlib)): $(obj)/%: $(srctree)/lib/zlib_inflate/% +$(addprefix $(obj)/,$(zlib)): $(obj)/%: $(srctree)lib/zlib_inflate/% $(call cmd,copy_zlib) clean-files := $(zlib)
arch/xtensa/kernel/syscalls/Makefile +2 -2
@@ -5,8 +5,8 @@ uapi := arch/$(SRCARCH)/include/generated/uapi/asm $(shell mkdir -p $(uapi) $(kapi)) syscall := $(src)/syscall.tbl -syshdr := $(srctree)/scripts/syscallhdr.sh -systbl := $(srctree)/scripts/syscalltbl.sh +syshdr := $(srctree)scripts/syscallhdr.sh +systbl := $(srctree)scripts/syscalltbl.sh quiet_cmd_syshdr = SYSHDR $@ cmd_syshdr = $(CONFIG_SHELL) $(syshdr) --emit-nr $< $@
certs/Makefile +2 -2
@@ -13,7 +13,7 @@ CFLAGS_blacklist_hashes.o := -I $(obj) quiet_cmd_check_and_copy_blacklist_hash_list = GEN $@ cmd_check_and_copy_blacklist_hash_list = \ $(if $(CONFIG_SYSTEM_BLACKLIST_HASH_LIST), \ - $(AWK) -f $(srctree)/$(src)/check-blacklist-hashes.awk $(CONFIG_SYSTEM_BLACKLIST_HASH_LIST) >&2; \ + $(AWK) -f $(srctree)$(src)/check-blacklist-hashes.awk $(CONFIG_SYSTEM_BLACKLIST_HASH_LIST) >&2; \ { cat $(CONFIG_SYSTEM_BLACKLIST_HASH_LIST); echo $(comma) NULL; } > $@, \ echo NULL > $@)
@@ -55,7 +55,7 @@ $(obj)/signing_key.pem: $(obj)/x509.genkey FORCE targets += signing_key.pem quiet_cmd_copy_x509_config = COPY $@ - cmd_copy_x509_config = cat $(srctree)/$(src)/default_x509.genkey > $@ + cmd_copy_x509_config = cat $(srctree)$(src)/default_x509.genkey > $@ # You can provide your own config file. If not present, copy the default one. $(obj)/x509.genkey:
drivers/Makefile +1 -1
@@ -6,7 +6,7 @@ # Rewritten to use lists instead of if-statements. # -# Some driver Makefiles miss $(srctree)/ for include directive. +# Some driver Makefiles miss $(srctree) for include directive. ifdef building_out_of_srctree MAKEFLAGS += --include-dir=$(srctree) endif
drivers/accessibility/speakup/Makefile +1 -1
@@ -41,7 +41,7 @@ makemapdata-objs := makemapdata.o quiet_cmd_mkmap = MKMAP $@ cmd_mkmap = TOPDIR=$(srctree) \ - SPKDIR=$(if $(KBUILD_EXTMOD),$(KBUILD_EXTMOD),$(srctree)/drivers/accessibility/speakup) \ + SPKDIR=$(if $(KBUILD_EXTMOD),$(KBUILD_EXTMOD),$(srctree)drivers/accessibility/speakup) \ $(obj)/makemapdata > $@ $(obj)/mapdata.h: $(obj)/makemapdata
drivers/base/firmware_loader/builtin/Makefile +1 -1
@@ -4,7 +4,7 @@ obj-y += main.o # Create $(fwdir) from $(CONFIG_EXTRA_FIRMWARE_DIR) -- if it doesn't have a # leading /, it's relative to $(srctree). fwdir := $(CONFIG_EXTRA_FIRMWARE_DIR) -fwdir := $(addprefix $(srctree)/,$(filter-out /%,$(fwdir)))$(filter /%,$(fwdir)) +fwdir := $(addprefix $(srctree),$(filter-out /%,$(fwdir)))$(filter /%,$(fwdir)) firmware := $(addsuffix .gen.o, $(CONFIG_EXTRA_FIRMWARE)) obj-y += $(firmware)
drivers/block/rnbd/Makefile +1 -1
@@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0-or-later -ccflags-y := -I$(srctree)/drivers/infiniband/ulp/rtrs +ccflags-y := -I$(srctree)drivers/infiniband/ulp/rtrs rnbd-client-y := rnbd-clt.o \ rnbd-clt-sysfs.o
drivers/crypto/chelsio/Makefile +1 -1
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/drivers/net/ethernet/chelsio/cxgb4 +ccflags-y := -I $(srctree)drivers/net/ethernet/chelsio/cxgb4 obj-$(CONFIG_CRYPTO_DEV_CHELSIO) += chcr.o chcr-objs := chcr_core.o chcr_algo.o
drivers/crypto/intel/iaa/Makefile +1 -1
@@ -3,7 +3,7 @@ # Makefile for IAA crypto device drivers # -ccflags-y += -I $(srctree)/drivers/dma/idxd -DDEFAULT_SYMBOL_NAMESPACE=IDXD +ccflags-y += -I $(srctree)drivers/dma/idxd -DDEFAULT_SYMBOL_NAMESPACE=IDXD obj-$(CONFIG_CRYPTO_DEV_IAA_CRYPTO) := iaa_crypto.o
drivers/crypto/intel/qat/qat_420xx/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/$(src)/../qat_common +ccflags-y := -I $(srctree)$(src)/../qat_common obj-$(CONFIG_CRYPTO_DEV_QAT_420XX) += qat_420xx.o qat_420xx-objs := adf_drv.o adf_420xx_hw_data.o
drivers/crypto/intel/qat/qat_4xxx/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: (BSD-3-Clause OR GPL-2.0-only) -ccflags-y := -I $(srctree)/$(src)/../qat_common +ccflags-y := -I $(srctree)$(src)/../qat_common obj-$(CONFIG_CRYPTO_DEV_QAT_4XXX) += qat_4xxx.o qat_4xxx-objs := adf_drv.o adf_4xxx_hw_data.o
drivers/crypto/intel/qat/qat_c3xxx/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/$(src)/../qat_common +ccflags-y := -I $(srctree)$(src)/../qat_common obj-$(CONFIG_CRYPTO_DEV_QAT_C3XXX) += qat_c3xxx.o qat_c3xxx-objs := adf_drv.o adf_c3xxx_hw_data.o
drivers/crypto/intel/qat/qat_c3xxxvf/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/$(src)/../qat_common +ccflags-y := -I $(srctree)$(src)/../qat_common obj-$(CONFIG_CRYPTO_DEV_QAT_C3XXXVF) += qat_c3xxxvf.o qat_c3xxxvf-objs := adf_drv.o adf_c3xxxvf_hw_data.o
drivers/crypto/intel/qat/qat_c62x/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/$(src)/../qat_common +ccflags-y := -I $(srctree)$(src)/../qat_common obj-$(CONFIG_CRYPTO_DEV_QAT_C62X) += qat_c62x.o qat_c62x-objs := adf_drv.o adf_c62x_hw_data.o
drivers/crypto/intel/qat/qat_c62xvf/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/$(src)/../qat_common +ccflags-y := -I $(srctree)$(src)/../qat_common obj-$(CONFIG_CRYPTO_DEV_QAT_C62XVF) += qat_c62xvf.o qat_c62xvf-objs := adf_drv.o adf_c62xvf_hw_data.o
drivers/crypto/intel/qat/qat_dh895xcc/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/$(src)/../qat_common +ccflags-y := -I $(srctree)$(src)/../qat_common obj-$(CONFIG_CRYPTO_DEV_QAT_DH895xCC) += qat_dh895xcc.o qat_dh895xcc-objs := adf_drv.o adf_dh895xcc_hw_data.o
drivers/crypto/intel/qat/qat_dh895xccvf/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/$(src)/../qat_common +ccflags-y := -I $(srctree)$(src)/../qat_common obj-$(CONFIG_CRYPTO_DEV_QAT_DH895xCCVF) += qat_dh895xccvf.o qat_dh895xccvf-objs := adf_drv.o adf_dh895xccvf_hw_data.o
drivers/crypto/marvell/octeontx2/Makefile +1 -1
@@ -7,4 +7,4 @@ rvu_cptpf-objs := otx2_cptpf_main.o otx2_cptpf_mbox.o \ rvu_cptvf-objs := otx2_cptvf_main.o otx2_cptvf_mbox.o \ otx2_cptvf_reqmgr.o otx2_cptvf_algs.o -ccflags-y += -I$(srctree)/drivers/net/ethernet/marvell/octeontx2/af +ccflags-y += -I$(srctree)drivers/net/ethernet/marvell/octeontx2/af
drivers/cxl/core/Makefile +1 -1
@@ -2,7 +2,7 @@ obj-$(CONFIG_CXL_BUS) += cxl_core.o obj-$(CONFIG_CXL_SUSPEND) += suspend.o -ccflags-y += -I$(srctree)/drivers/cxl +ccflags-y += -I$(srctree)drivers/cxl CFLAGS_trace.o = -DTRACE_INCLUDE_PATH=. -I$(src) cxl_core-y := port.o
drivers/firmware/efi/libstub/Makefile +3 -3
@@ -31,11 +31,11 @@ cflags-$(CONFIG_ARM) += -DEFI_HAVE_STRLEN -DEFI_HAVE_STRNLEN \ cflags-$(CONFIG_RISCV) += -fpic -DNO_ALTERNATIVE -mno-relax cflags-$(CONFIG_LOONGARCH) += -fpie -cflags-$(CONFIG_EFI_PARAMS_FROM_FDT) += -I$(srctree)/scripts/dtc/libfdt +cflags-$(CONFIG_EFI_PARAMS_FROM_FDT) += -I$(srctree)scripts/dtc/libfdt KBUILD_CFLAGS := $(subst $(CC_FLAGS_FTRACE),,$(cflags-y)) \ -Os -DDISABLE_BRANCH_PROFILING \ - -include $(srctree)/include/linux/hidden.h \ + -include $(srctree)include/linux/hidden.h \ -D__NO_FORTIFY \ -ffreestanding \ -fno-stack-protector \
@@ -79,7 +79,7 @@ libfdt-deps := fdt_rw.c fdt_ro.c fdt_wip.c fdt.c \ lib-$(CONFIG_EFI_PARAMS_FROM_FDT) += fdt.o \ $(patsubst %.c,lib-%.o,$(libfdt-deps)) -$(obj)/lib-%.o: $(srctree)/lib/%.c FORCE +$(obj)/lib-%.o: $(srctree)lib/%.c FORCE $(call if_changed_rule,cc_o_c) lib-$(CONFIG_EFI_GENERIC_STUB) += efi-stub.o string.o intrinsics.o systable.o \
drivers/firmware/efi/libstub/Makefile.zboot +2 -2
@@ -47,12 +47,12 @@ AFLAGS_zboot-header.o += -DMACHINE_TYPE=IMAGE_FILE_MACHINE_$(EFI_ZBOOT_MACH_TYPE -DCOMP_TYPE="\"$(comp-type-y)\"" \ $(aflags-zboot-header-y) -$(obj)/zboot-header.o: $(srctree)/drivers/firmware/efi/libstub/zboot-header.S FORCE +$(obj)/zboot-header.o: $(srctree)drivers/firmware/efi/libstub/zboot-header.S FORCE $(call if_changed_rule,as_o_S) ZBOOT_DEPS := $(obj)/zboot-header.o $(objtree)/drivers/firmware/efi/libstub/lib.a -LDFLAGS_vmlinuz.efi.elf := -T $(srctree)/drivers/firmware/efi/libstub/zboot.lds +LDFLAGS_vmlinuz.efi.elf := -T $(srctree)drivers/firmware/efi/libstub/zboot.lds $(obj)/vmlinuz.efi.elf: $(obj)/vmlinuz.o $(ZBOOT_DEPS) FORCE $(call if_changed,ld)
drivers/gpu/drm/amd/amdgpu/Makefile +1 -1
@@ -23,7 +23,7 @@ # Makefile for the drm device driver. This driver provides support for the # Direct Rendering Infrastructure (DRI) in XFree86 4.1.0 and higher. -FULL_AMD_PATH=$(srctree)/$(src)/.. +FULL_AMD_PATH=$(srctree)$(src)/.. DISPLAY_FOLDER_NAME=display FULL_AMD_DISPLAY_PATH = $(FULL_AMD_PATH)/$(DISPLAY_FOLDER_NAME)
drivers/gpu/drm/arm/display/komeda/Makefile +2 -2
@@ -1,8 +1,8 @@ # SPDX-License-Identifier: GPL-2.0 ccflags-y := \ - -I $(srctree)/$(src)/../include \ - -I $(srctree)/$(src) + -I $(srctree)$(src)/../include \ + -I $(srctree)$(src) komeda-y := \ komeda_drv.o \
drivers/gpu/drm/i915/Makefile +4 -4
@@ -41,7 +41,7 @@ CFLAGS_display/intel_fbdev.o = $(call cc-disable-warning, override-init) # drivers. Define I915 when building i915. subdir-ccflags-y += -DI915 -subdir-ccflags-y += -I$(srctree)/$(src) +subdir-ccflags-y += -I$(srctree)$(src) # Please keep these build lists sorted!
@@ -419,7 +419,7 @@ obj-$(CONFIG_DRM_I915_GVT_KVMGT) += kvmgt.o # # Enable locally for CONFIG_DRM_I915_WERROR=y. See also scripts/Makefile.build ifdef CONFIG_DRM_I915_WERROR - cmd_checkdoc = $(srctree)/scripts/kernel-doc -none -Werror $< + cmd_checkdoc = $(srctree)scripts/kernel-doc -none -Werror $< endif # header test
@@ -430,11 +430,11 @@ no-header-test := \ always-$(CONFIG_DRM_I915_WERROR) += \ $(patsubst %.h,%.hdrtest, $(filter-out $(no-header-test), \ - $(shell cd $(srctree)/$(src) && find * -name '*.h'))) + $(shell cd $(srctree)$(src) && find * -name '*.h'))) quiet_cmd_hdrtest = HDRTEST $(patsubst %.hdrtest,%.h,$@) cmd_hdrtest = $(CC) $(filter-out $(CFLAGS_GCOV), $(c_flags)) -S -o /dev/null -x c /dev/null -include $<; \ - $(srctree)/scripts/kernel-doc -none -Werror $<; touch $@ + $(srctree)scripts/kernel-doc -none -Werror $<; touch $@ $(obj)/%.hdrtest: $(src)/%.h FORCE $(call if_changed_dep,hdrtest)
drivers/gpu/drm/imagination/Makefile +1 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0-only OR MIT # Copyright (c) 2023 Imagination Technologies Ltd. -subdir-ccflags-y := -I$(srctree)/$(src) +subdir-ccflags-y := -I$(srctree)$(src) powervr-y := \ pvr_ccb.o \
drivers/gpu/drm/msm/Makefile +4 -4
@@ -1,8 +1,8 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-y := -I $(srctree)/$(src) -ccflags-y += -I $(srctree)/$(src)/disp/dpu1 -ccflags-$(CONFIG_DRM_MSM_DSI) += -I $(srctree)/$(src)/dsi -ccflags-$(CONFIG_DRM_MSM_DP) += -I $(srctree)/$(src)/dp +ccflags-y := -I $(srctree)$(src) +ccflags-y += -I $(srctree)$(src)/disp/dpu1 +ccflags-$(CONFIG_DRM_MSM_DSI) += -I $(srctree)$(src)/dsi +ccflags-$(CONFIG_DRM_MSM_DP) += -I $(srctree)$(src)/dp msm-y := \ adreno/adreno_device.o \
drivers/gpu/drm/xe/Makefile +9 -9
@@ -32,7 +32,7 @@ endif # Enable -Werror in CI and development subdir-ccflags-$(CONFIG_DRM_XE_WERROR) += -Werror -subdir-ccflags-y += -I$(obj) -I$(srctree)/$(src) +subdir-ccflags-y += -I$(obj) -I$(srctree)$(src) # generated sources hostprogs := xe_gen_wa_oob
@@ -42,7 +42,7 @@ generated_oob := $(obj)/generated/xe_wa_oob.c $(obj)/generated/xe_wa_oob.h quiet_cmd_wa_oob = GEN $(notdir $(generated_oob)) cmd_wa_oob = mkdir -p $(@D); $^ $(generated_oob) -$(generated_oob) &: $(obj)/xe_gen_wa_oob $(srctree)/$(src)/xe_wa_oob.rules +$(generated_oob) &: $(obj)/xe_gen_wa_oob $(srctree)$(src)/xe_wa_oob.rules $(call cmd,wa_oob) uses_generated_oob := \
@@ -154,10 +154,10 @@ xe-$(CONFIG_PCI_IOV) += \ # i915 Display compat #defines and #includes subdir-ccflags-$(CONFIG_DRM_XE_DISPLAY) += \ - -I$(srctree)/$(src)/display/ext \ - -I$(srctree)/$(src)/compat-i915-headers \ - -I$(srctree)/drivers/gpu/drm/xe/display/ \ - -I$(srctree)/drivers/gpu/drm/i915/display/ \ + -I$(srctree)$(src)/display/ext \ + -I$(srctree)$(src)/compat-i915-headers \ + -I$(srctree)drivers/gpu/drm/xe/display/ \ + -I$(srctree)drivers/gpu/drm/i915/display/ \ -Ddrm_i915_gem_object=xe_bo \ -Ddrm_i915_private=xe_device
@@ -165,12 +165,12 @@ CFLAGS_i915-display/intel_fbdev.o = $(call cc-disable-warning, override-init) CFLAGS_i915-display/intel_display_device.o = $(call cc-disable-warning, override-init) # Rule to build SOC code shared with i915 -$(obj)/i915-soc/%.o: $(srctree)/drivers/gpu/drm/i915/soc/%.c FORCE +$(obj)/i915-soc/%.o: $(srctree)drivers/gpu/drm/i915/soc/%.c FORCE $(call cmd,force_checksrc) $(call if_changed_rule,cc_o_c) # Rule to build display code shared with i915 -$(obj)/i915-display/%.o: $(srctree)/drivers/gpu/drm/i915/display/%.c FORCE +$(obj)/i915-display/%.o: $(srctree)drivers/gpu/drm/i915/display/%.c FORCE $(call cmd,force_checksrc) $(call if_changed_rule,cc_o_c)
@@ -295,7 +295,7 @@ ifneq ($(CONFIG_DRM_XE_DISPLAY),y) endif always-$(CONFIG_DRM_XE_WERROR) += \ - $(patsubst %.h,%.hdrtest, $(shell cd $(srctree)/$(src) && find * -name '*.h' $(hdrtest_find_args))) + $(patsubst %.h,%.hdrtest, $(shell cd $(srctree)$(src) && find * -name '*.h' $(hdrtest_find_args))) quiet_cmd_hdrtest = HDRTEST $(patsubst %.hdrtest,%.h,$@) cmd_hdrtest = $(CC) -DHDRTEST $(filter-out $(CFLAGS_GCOV), $(c_flags)) -S -o /dev/null -x c /dev/null -include $<; touch $@
drivers/hid/amd-sfh-hid/Makefile +1 -1
@@ -13,4 +13,4 @@ amd_sfh-objs += sfh1_1/amd_sfh_init.o amd_sfh-objs += sfh1_1/amd_sfh_interface.o amd_sfh-objs += sfh1_1/amd_sfh_desc.o -ccflags-y += -I $(srctree)/$(src)/ +ccflags-y += -I $(srctree)$(src)/
drivers/hid/bpf/Makefile +1 -1
@@ -3,7 +3,7 @@ # Makefile for HID-BPF # -LIBBPF_INCLUDE = $(srctree)/tools/lib +LIBBPF_INCLUDE = $(srctree)tools/lib obj-$(CONFIG_HID_BPF) += hid_bpf.o CFLAGS_hid_bpf_dispatch.o += -I$(LIBBPF_INCLUDE)
drivers/hid/intel-ish-hid/Makefile +1 -1
@@ -23,4 +23,4 @@ intel-ishtp-hid-objs += ishtp-hid-client.o obj-$(CONFIG_INTEL_ISH_FIRMWARE_DOWNLOADER) += intel-ishtp-loader.o intel-ishtp-loader-objs += ishtp-fw-loader.o -ccflags-y += -I $(srctree)/$(src)/ishtp +ccflags-y += -I $(srctree)$(src)/ishtp
drivers/iio/humidity/Makefile +1 -1
@@ -20,4 +20,4 @@ obj-$(CONFIG_HTU21) += htu21.o obj-$(CONFIG_SI7005) += si7005.o obj-$(CONFIG_SI7020) += si7020.o -ccflags-y += -I$(srctree)/drivers/iio/common/hid-sensors +ccflags-y += -I$(srctree)drivers/iio/common/hid-sensors
drivers/infiniband/hw/bnxt_re/Makefile +1 -1
@@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-y := -I $(srctree)/drivers/net/ethernet/broadcom/bnxt +ccflags-y := -I $(srctree)drivers/net/ethernet/broadcom/bnxt obj-$(CONFIG_INFINIBAND_BNXT_RE) += bnxt_re.o bnxt_re-y := main.o ib_verbs.o \ qplib_res.o qplib_rcfw.o \
drivers/infiniband/hw/cxgb4/Makefile +2 -2
@@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/drivers/net/ethernet/chelsio/cxgb4 -ccflags-y += -I $(srctree)/drivers/net/ethernet/chelsio/libcxgb +ccflags-y := -I $(srctree)drivers/net/ethernet/chelsio/cxgb4 +ccflags-y += -I $(srctree)drivers/net/ethernet/chelsio/libcxgb obj-$(CONFIG_INFINIBAND_CXGB4) += iw_cxgb4.o
drivers/infiniband/hw/hns/Makefile +1 -1
@@ -3,7 +3,7 @@ # Makefile for the Hisilicon RoCE drivers. # -ccflags-y := -I $(srctree)/drivers/net/ethernet/hisilicon/hns3 +ccflags-y := -I $(srctree)drivers/net/ethernet/hisilicon/hns3 hns-roce-objs := hns_roce_main.o hns_roce_cmd.o hns_roce_pd.o \ hns_roce_ah.o hns_roce_hem.o hns_roce_mr.o hns_roce_qp.o \
drivers/infiniband/hw/ocrdma/Makefile +1 -1
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/drivers/net/ethernet/emulex/benet +ccflags-y := -I $(srctree)drivers/net/ethernet/emulex/benet obj-$(CONFIG_INFINIBAND_OCRDMA) += ocrdma.o
drivers/infiniband/hw/usnic/Makefile +1 -1
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-y := -I $(srctree)/drivers/net/ethernet/cisco/enic +ccflags-y := -I $(srctree)drivers/net/ethernet/cisco/enic obj-$(CONFIG_INFINIBAND_USNIC)+= usnic_verbs.o
drivers/media/common/b2c2/Makefile +2 -2
@@ -4,5 +4,5 @@ b2c2-flexcop-objs += flexcop-sram.o flexcop-eeprom.o flexcop-misc.o b2c2-flexcop-objs += flexcop-hw-filter.o obj-$(CONFIG_DVB_B2C2_FLEXCOP) += b2c2-flexcop.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends/ -ccflags-y += -I $(srctree)/drivers/media/tuners/ +ccflags-y += -I $(srctree)drivers/media/dvb-frontends/ +ccflags-y += -I $(srctree)drivers/media/tuners/
drivers/media/dvb-frontends/Makefile +2 -2
@@ -3,11 +3,11 @@ # Makefile for the kernel DVB frontend device drivers. # -ccflags-y += -I$(srctree)/drivers/media/tuners/ +ccflags-y += -I$(srctree)drivers/media/tuners/ # FIXME: RTL2832 SDR driver uses power management directly from USB IF driver ifdef CONFIG_DVB_RTL2832_SDR - ccflags-y += -I$(srctree)/drivers/media/usb/dvb-usb-v2 + ccflags-y += -I$(srctree)drivers/media/usb/dvb-usb-v2 endif cxd2820r-objs := cxd2820r_core.o cxd2820r_c.o cxd2820r_t.o cxd2820r_t2.o
drivers/media/dvb-frontends/drx39xyj/Makefile +1 -1
@@ -3,4 +3,4 @@ drx39xyj-objs := drxj.o obj-$(CONFIG_DVB_DRX39XYJ) += drx39xyj.o -ccflags-y += -I$(srctree)/drivers/media/tuners/ +ccflags-y += -I$(srctree)drivers/media/tuners/
drivers/media/i2c/ccs/Makefile +1 -1
@@ -3,4 +3,4 @@ ccs-objs += ccs-core.o ccs-reg-access.o \ ccs-quirk.o ccs-limits.o ccs-data.o obj-$(CONFIG_VIDEO_CCS) += ccs.o -ccflags-y += -I $(srctree)/drivers/media/i2c +ccflags-y += -I $(srctree)drivers/media/i2c
drivers/media/mmc/siano/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only obj-$(CONFIG_SMS_SDIO_DRV) += smssdio.o -ccflags-y += -I $(srctree)/drivers/media/common/siano +ccflags-y += -I $(srctree)drivers/media/common/siano
drivers/media/pci/b2c2/Makefile +1 -1
@@ -6,4 +6,4 @@ endif b2c2-flexcop-pci-objs += flexcop-pci.o obj-$(CONFIG_DVB_B2C2_FLEXCOP_PCI) += b2c2-flexcop-pci.o -ccflags-y += -I $(srctree)/drivers/media/common/b2c2/ +ccflags-y += -I $(srctree)drivers/media/common/b2c2/
drivers/media/pci/bt8xx/Makefile +2 -2
@@ -6,5 +6,5 @@ bttv-objs := bttv-driver.o bttv-cards.o bttv-if.o \ obj-$(CONFIG_VIDEO_BT848) += bttv.o obj-$(CONFIG_DVB_BT8XX) += bt878.o dvb-bt8xx.o dst.o dst_ca.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends -ccflags-y += -I $(srctree)/drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners
drivers/media/pci/cx18/Makefile +2 -2
@@ -9,5 +9,5 @@ cx18-alsa-objs := cx18-alsa-main.o cx18-alsa-pcm.o obj-$(CONFIG_VIDEO_CX18) += cx18.o obj-$(CONFIG_VIDEO_CX18_ALSA) += cx18-alsa.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends -ccflags-y += -I $(srctree)/drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners
drivers/media/pci/cx23885/Makefile +2 -2
@@ -8,7 +8,7 @@ cx23885-objs := cx23885-cards.o cx23885-video.o cx23885-vbi.o \ obj-$(CONFIG_VIDEO_CX23885) += cx23885.o obj-$(CONFIG_MEDIA_ALTERA_CI) += altera-ci.o -ccflags-y += -I $(srctree)/drivers/media/tuners -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/dvb-frontends ccflags-y += $(extra-cflags-y) $(extra-cflags-m)
drivers/media/pci/cx88/Makefile +2 -2
@@ -10,5 +10,5 @@ obj-$(CONFIG_VIDEO_CX88_ALSA) += cx88-alsa.o obj-$(CONFIG_VIDEO_CX88_BLACKBIRD) += cx88-blackbird.o obj-$(CONFIG_VIDEO_CX88_DVB) += cx88-dvb.o obj-$(CONFIG_VIDEO_CX88_VP3054) += cx88-vp3054-i2c.o -ccflags-y += -I $(srctree)/drivers/media/tuners -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/dvb-frontends
drivers/media/pci/ddbridge/Makefile +2 -2
@@ -9,5 +9,5 @@ ddbridge-objs := ddbridge-main.o ddbridge-core.o ddbridge-ci.o \ obj-$(CONFIG_DVB_DDBRIDGE) += ddbridge.o ddbridge-dummy-fe.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends/ -ccflags-y += -I $(srctree)/drivers/media/tuners/ +ccflags-y += -I $(srctree)drivers/media/dvb-frontends/ +ccflags-y += -I $(srctree)drivers/media/tuners/
drivers/media/pci/dm1105/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only obj-$(CONFIG_DVB_DM1105) += dm1105.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/dvb-frontends
drivers/media/pci/ivtv/Makefile +2 -2
@@ -10,6 +10,6 @@ obj-$(CONFIG_VIDEO_IVTV) += ivtv.o obj-$(CONFIG_VIDEO_IVTV_ALSA) += ivtv-alsa.o obj-$(CONFIG_VIDEO_FB_IVTV) += ivtvfb.o -ccflags-y += -I$(srctree)/drivers/media/tuners -ccflags-y += -I$(srctree)/drivers/media/dvb-frontends +ccflags-y += -I$(srctree)drivers/media/tuners +ccflags-y += -I$(srctree)drivers/media/dvb-frontends
drivers/media/pci/mantis/Makefile +1 -1
@@ -26,4 +26,4 @@ obj-$(CONFIG_MANTIS_CORE) += mantis_core.o obj-$(CONFIG_DVB_MANTIS) += mantis.o obj-$(CONFIG_DVB_HOPPER) += hopper.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends/ +ccflags-y += -I $(srctree)drivers/media/dvb-frontends/
drivers/media/pci/netup_unidvb/Makefile +1 -1
@@ -6,4 +6,4 @@ netup-unidvb-objs += netup_unidvb_spi.o obj-$(CONFIG_DVB_NETUP_UNIDVB) += netup-unidvb.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/dvb-frontends
drivers/media/pci/ngene/Makefile +2 -2
@@ -7,5 +7,5 @@ ngene-objs := ngene-core.o ngene-i2c.o ngene-cards.o ngene-dvb.o obj-$(CONFIG_DVB_NGENE) += ngene.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends/ -ccflags-y += -I $(srctree)/drivers/media/tuners/ +ccflags-y += -I $(srctree)drivers/media/dvb-frontends/ +ccflags-y += -I $(srctree)drivers/media/tuners/
drivers/media/pci/pluto2/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only obj-$(CONFIG_DVB_PLUTO2) += pluto2.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends/ +ccflags-y += -I $(srctree)drivers/media/dvb-frontends/
drivers/media/pci/pt1/Makefile +2 -2
@@ -3,5 +3,5 @@ earth-pt1-objs := pt1.o obj-$(CONFIG_DVB_PT1) += earth-pt1.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends -ccflags-y += -I $(srctree)/drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners
drivers/media/pci/pt3/Makefile +2 -2
@@ -4,5 +4,5 @@ earth-pt3-objs += pt3.o pt3_i2c.o pt3_dma.o obj-$(CONFIG_DVB_PT3) += earth-pt3.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends -ccflags-y += -I $(srctree)/drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners
drivers/media/pci/saa7134/Makefile +3 -3
@@ -12,6 +12,6 @@ obj-$(CONFIG_VIDEO_SAA7134_ALSA) += saa7134-alsa.o obj-$(CONFIG_VIDEO_SAA7134_DVB) += saa7134-dvb.o -ccflags-y += -I$(srctree)/drivers/media/tuners -ccflags-y += -I$(srctree)/drivers/media/dvb-frontends -ccflags-y += -I$(srctree)/drivers/media/usb/go7007 +ccflags-y += -I$(srctree)drivers/media/tuners +ccflags-y += -I$(srctree)drivers/media/dvb-frontends +ccflags-y += -I$(srctree)drivers/media/usb/go7007
drivers/media/pci/saa7146/Makefile +1 -1
@@ -3,4 +3,4 @@ obj-$(CONFIG_VIDEO_MXB) += mxb.o obj-$(CONFIG_VIDEO_HEXIUM_ORION) += hexium_orion.o obj-$(CONFIG_VIDEO_HEXIUM_GEMINI) += hexium_gemini.o -ccflags-y += -I$(srctree)/drivers/media/i2c +ccflags-y += -I$(srctree)drivers/media/i2c
drivers/media/pci/saa7164/Makefile +2 -2
@@ -5,5 +5,5 @@ saa7164-objs := saa7164-cards.o saa7164-core.o saa7164-i2c.o saa7164-dvb.o \ obj-$(CONFIG_VIDEO_SAA7164) += saa7164.o -ccflags-y += -I$(srctree)/drivers/media/tuners -ccflags-y += -I$(srctree)/drivers/media/dvb-frontends +ccflags-y += -I$(srctree)drivers/media/tuners +ccflags-y += -I$(srctree)drivers/media/dvb-frontends
drivers/media/pci/smipcie/Makefile +2 -2
@@ -4,5 +4,5 @@ smipcie-objs := smipcie-main.o smipcie-ir.o obj-$(CONFIG_DVB_SMIPCIE) += smipcie.o -ccflags-y += -I $(srctree)/drivers/media/tuners -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/dvb-frontends
drivers/media/pci/ttpci/Makefile +3 -3
@@ -8,6 +8,6 @@ obj-$(CONFIG_DVB_BUDGET) += budget.o obj-$(CONFIG_DVB_BUDGET_AV) += budget-av.o obj-$(CONFIG_DVB_BUDGET_CI) += budget-ci.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends/ -ccflags-y += -I $(srctree)/drivers/media/tuners -ccflags-y += -I $(srctree)/drivers/media/common +ccflags-y += -I $(srctree)drivers/media/dvb-frontends/ +ccflags-y += -I $(srctree)drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/common
drivers/media/platform/mediatek/mdp/Makefile +1 -1
@@ -7,4 +7,4 @@ mtk-mdp-y += mtk_mdp_vpu.o obj-$(CONFIG_VIDEO_MEDIATEK_MDP) += mtk-mdp.o -ccflags-y += -I$(srctree)/drivers/media/platform/mediatek/vpu +ccflags-y += -I$(srctree)drivers/media/platform/mediatek/vpu
drivers/media/platform/st/sti/c8sectpfe/Makefile +2 -2
@@ -4,5 +4,5 @@ c8sectpfe-y += c8sectpfe-core.o c8sectpfe-common.o c8sectpfe-dvb.o \ obj-$(CONFIG_DVB_C8SECTPFE) += c8sectpfe.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends/ -ccflags-y += -I $(srctree)/drivers/media/tuners/ +ccflags-y += -I $(srctree)drivers/media/dvb-frontends/ +ccflags-y += -I $(srctree)drivers/media/tuners/
drivers/media/spi/Makefile +1 -1
@@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends/cxd2880 +ccflags-y += -I $(srctree)drivers/media/dvb-frontends/cxd2880 # Please keep it alphabetically sorted by Kconfig name # (e. g. LC_ALL=C sort Makefile)
drivers/media/tuners/Makefile +1 -1
@@ -3,7 +3,7 @@ # Makefile for common V4L/DVB tuners # -ccflags-y += -I$(srctree)/drivers/media/dvb-frontends +ccflags-y += -I$(srctree)drivers/media/dvb-frontends tda18271-objs := tda18271-maps.o tda18271-common.o tda18271-fe.o # Please keep it alphabetically sorted by Kconfig name
drivers/media/usb/as102/Makefile +1 -1
@@ -4,4 +4,4 @@ dvb-as102-objs := as102_drv.o as102_fw.o as10x_cmd.o as10x_cmd_stream.o \ obj-$(CONFIG_DVB_AS102) += dvb-as102.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/dvb-frontends
drivers/media/usb/au0828/Makefile +2 -2
@@ -11,7 +11,7 @@ endif obj-$(CONFIG_VIDEO_AU0828) += au0828.o -ccflags-y += -I $(srctree)/drivers/media/tuners -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/dvb-frontends ccflags-y += $(extra-cflags-y) $(extra-cflags-m)
drivers/media/usb/b2c2/Makefile +1 -1
@@ -2,4 +2,4 @@ b2c2-flexcop-usb-objs := flexcop-usb.o obj-$(CONFIG_DVB_B2C2_FLEXCOP_USB) += b2c2-flexcop-usb.o -ccflags-y += -I $(srctree)/drivers/media/common/b2c2/ +ccflags-y += -I $(srctree)drivers/media/common/b2c2/
drivers/media/usb/cx231xx/Makefile +2 -2
@@ -9,5 +9,5 @@ obj-$(CONFIG_VIDEO_CX231XX) += cx231xx.o obj-$(CONFIG_VIDEO_CX231XX_ALSA) += cx231xx-alsa.o obj-$(CONFIG_VIDEO_CX231XX_DVB) += cx231xx-dvb.o -ccflags-y += -I $(srctree)/drivers/media/tuners -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/dvb-frontends
drivers/media/usb/dvb-usb-v2/Makefile +3 -3
@@ -44,6 +44,6 @@ obj-$(CONFIG_DVB_USB_DVBSKY) += dvb-usb-dvbsky.o dvb-usb-zd1301-objs := zd1301.o obj-$(CONFIG_DVB_USB_ZD1301) += zd1301.o -ccflags-y += -I$(srctree)/drivers/media/dvb-frontends -ccflags-y += -I$(srctree)/drivers/media/tuners -ccflags-y += -I$(srctree)/drivers/media/common +ccflags-y += -I$(srctree)drivers/media/dvb-frontends +ccflags-y += -I$(srctree)drivers/media/tuners +ccflags-y += -I$(srctree)drivers/media/common
drivers/media/usb/dvb-usb/Makefile +3 -3
@@ -80,7 +80,7 @@ obj-$(CONFIG_DVB_USB_AZ6027) += dvb-usb-az6027.o dvb-usb-technisat-usb2-objs := technisat-usb2.o obj-$(CONFIG_DVB_USB_TECHNISAT_USB2) += dvb-usb-technisat-usb2.o -ccflags-y += -I$(srctree)/drivers/media/dvb-frontends/ +ccflags-y += -I$(srctree)drivers/media/dvb-frontends/ # due to tuner-xc3028 -ccflags-y += -I$(srctree)/drivers/media/tuners -ccflags-y += -I$(srctree)/drivers/media/common +ccflags-y += -I$(srctree)drivers/media/tuners +ccflags-y += -I$(srctree)drivers/media/common
drivers/media/usb/em28xx/Makefile +2 -2
@@ -11,5 +11,5 @@ obj-$(CONFIG_VIDEO_EM28XX_ALSA) += em28xx-alsa.o obj-$(CONFIG_VIDEO_EM28XX_DVB) += em28xx-dvb.o obj-$(CONFIG_VIDEO_EM28XX_RC) += em28xx-rc.o -ccflags-y += -I $(srctree)/drivers/media/tuners -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/dvb-frontends
drivers/media/usb/go7007/Makefile +1 -1
@@ -9,4 +9,4 @@ go7007-y := go7007-v4l2.o go7007-driver.o go7007-i2c.o go7007-fw.o \ s2250-y := s2250-board.o -ccflags-$(CONFIG_VIDEO_GO7007_LOADER:m=y) += -I $(srctree)/drivers/media/common +ccflags-$(CONFIG_VIDEO_GO7007_LOADER:m=y) += -I $(srctree)drivers/media/common
drivers/media/usb/gspca/gl860/Makefile +1 -1
@@ -7,5 +7,5 @@ gspca_gl860-objs := gl860.o \ gl860-ov9655.o \ gl860-mi2020.o -ccflags-y += -I$(srctree)/drivers/media/usb/gspca +ccflags-y += -I$(srctree)drivers/media/usb/gspca
drivers/media/usb/gspca/m5602/Makefile +1 -1
@@ -9,4 +9,4 @@ gspca_m5602-objs := m5602_core.o \ m5602_s5k83a.o \ m5602_s5k4aa.o -ccflags-y += -I$(srctree)/drivers/media/usb/gspca +ccflags-y += -I$(srctree)drivers/media/usb/gspca
drivers/media/usb/gspca/stv06xx/Makefile +1 -1
@@ -7,5 +7,5 @@ gspca_stv06xx-objs := stv06xx.o \ stv06xx_pb0100.o \ stv06xx_st6422.o -ccflags-y += -I$(srctree)/drivers/media/usb/gspca +ccflags-y += -I$(srctree)drivers/media/usb/gspca
drivers/media/usb/pvrusb2/Makefile +2 -2
@@ -17,5 +17,5 @@ pvrusb2-objs := pvrusb2-i2c-core.o \ obj-$(CONFIG_VIDEO_PVRUSB2) += pvrusb2.o -ccflags-y += -I $(srctree)/drivers/media/tuners -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/dvb-frontends
drivers/media/usb/siano/Makefile +1 -1
@@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0-only obj-$(CONFIG_SMS_USB_DRV) += smsusb.o -ccflags-y += -I $(srctree)/drivers/media/common/siano +ccflags-y += -I $(srctree)drivers/media/common/siano ccflags-y += $(extra-cflags-y) $(extra-cflags-m)
drivers/media/usb/ttusb-budget/Makefile +1 -1
@@ -1,4 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only obj-$(CONFIG_DVB_TTUSB_BUDGET) += dvb-ttusb-budget.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/dvb-frontends
drivers/media/v4l2-core/Makefile +2 -2
@@ -3,8 +3,8 @@ # Makefile for the V4L2 core # -ccflags-y += -I$(srctree)/drivers/media/dvb-frontends -ccflags-y += -I$(srctree)/drivers/media/tuners +ccflags-y += -I$(srctree)drivers/media/dvb-frontends +ccflags-y += -I$(srctree)drivers/media/tuners tuner-objs := tuner-core.o
drivers/net/ethernet/aquantia/atlantic/Makefile +1 -1
@@ -8,7 +8,7 @@ obj-$(CONFIG_AQTION) += atlantic.o -ccflags-y += -I$(srctree)/$(src) +ccflags-y += -I$(srctree)$(src) atlantic-objs := aq_main.o \ aq_nic.o \
drivers/net/ethernet/chelsio/inline_crypto/ch_ipsec/Makefile +2 -2
@@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/drivers/net/ethernet/chelsio/cxgb4 \ - -I $(srctree)/drivers/crypto/chelsio +ccflags-y := -I $(srctree)drivers/net/ethernet/chelsio/cxgb4 \ + -I $(srctree)drivers/crypto/chelsio obj-$(CONFIG_CHELSIO_IPSEC_INLINE) += ch_ipsec.o ch_ipsec-objs := chcr_ipsec.o
drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/Makefile +1 -1
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/drivers/net/ethernet/chelsio/cxgb4 +ccflags-y := -I $(srctree)drivers/net/ethernet/chelsio/cxgb4 obj-$(CONFIG_CHELSIO_TLS_DEVICE) += ch_ktls.o ch_ktls-objs := chcr_ktls.o
drivers/net/ethernet/chelsio/inline_crypto/chtls/Makefile +2 -2
@@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/drivers/net/ethernet/chelsio/cxgb4 \ - -I $(srctree)/drivers/crypto/chelsio +ccflags-y := -I $(srctree)drivers/net/ethernet/chelsio/cxgb4 \ + -I $(srctree)drivers/crypto/chelsio obj-$(CONFIG_CRYPTO_DEV_CHELSIO_TLS) += chtls.o chtls-objs := chtls_main.o chtls_cm.o chtls_io.o chtls_hw.o
drivers/net/ethernet/chelsio/libcxgb/Makefile +1 -1
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y := -I $(srctree)/$(src)/../cxgb4 +ccflags-y := -I $(srctree)$(src)/../cxgb4 obj-$(CONFIG_CHELSIO_LIB) += libcxgb.o
drivers/net/ethernet/freescale/dpaa/Makefile +1 -1
@@ -4,7 +4,7 @@ # # Include FMan headers -FMAN = $(srctree)/drivers/net/ethernet/freescale/fman +FMAN = $(srctree)drivers/net/ethernet/freescale/fman ccflags-y += -I$(FMAN) obj-$(CONFIG_FSL_DPAA_ETH) += fsl_dpa.o
drivers/net/ethernet/freescale/fman/Makefile +1 -1
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0 -subdir-ccflags-y += -I$(srctree)/drivers/net/ethernet/freescale/fman +subdir-ccflags-y += -I$(srctree)drivers/net/ethernet/freescale/fman obj-$(CONFIG_FSL_FMAN) += fsl_dpaa_fman.o obj-$(CONFIG_FSL_FMAN) += fsl_dpaa_fman_port.o
drivers/net/ethernet/fungible/funeth/Makefile +1 -1
@@ -1,6 +1,6 @@ # SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause) -ccflags-y += -I$(srctree)/$(src)/../funcore -I$(srctree)/$(src) +ccflags-y += -I$(srctree)$(src)/../funcore -I$(srctree)$(src) obj-$(CONFIG_FUN_ETH) += funeth.o
drivers/net/ethernet/hisilicon/hns3/Makefile +4 -4
@@ -3,10 +3,10 @@ # Makefile for the HISILICON network device drivers. # -ccflags-y += -I$(srctree)/$(src) -ccflags-y += -I$(srctree)/drivers/net/ethernet/hisilicon/hns3/hns3pf -ccflags-y += -I$(srctree)/drivers/net/ethernet/hisilicon/hns3/hns3vf -ccflags-y += -I$(srctree)/drivers/net/ethernet/hisilicon/hns3/hns3_common +ccflags-y += -I$(srctree)$(src) +ccflags-y += -I$(srctree)drivers/net/ethernet/hisilicon/hns3/hns3pf +ccflags-y += -I$(srctree)drivers/net/ethernet/hisilicon/hns3/hns3vf +ccflags-y += -I$(srctree)drivers/net/ethernet/hisilicon/hns3/hns3_common obj-$(CONFIG_HNS3) += hnae3.o
drivers/net/ethernet/marvell/octeontx2/nic/Makefile +1 -1
@@ -15,4 +15,4 @@ rvu_nicpf-$(CONFIG_DCB) += otx2_dcbnl.o rvu_nicvf-$(CONFIG_DCB) += otx2_dcbnl.o rvu_nicpf-$(CONFIG_MACSEC) += cn10k_macsec.o -ccflags-y += -I$(srctree)/drivers/net/ethernet/marvell/octeontx2/af +ccflags-y += -I$(srctree)drivers/net/ethernet/marvell/octeontx2/af
drivers/net/ethernet/microchip/lan966x/Makefile +1 -1
@@ -19,4 +19,4 @@ lan966x-switch-$(CONFIG_LAN966X_DCB) += lan966x_dcb.o lan966x-switch-$(CONFIG_DEBUG_FS) += lan966x_vcap_debugfs.o # Provide include files -ccflags-y += -I$(srctree)/drivers/net/ethernet/microchip/vcap +ccflags-y += -I$(srctree)drivers/net/ethernet/microchip/vcap
drivers/net/ethernet/microchip/sparx5/Makefile +1 -1
@@ -16,4 +16,4 @@ sparx5-switch-$(CONFIG_SPARX5_DCB) += sparx5_dcb.o sparx5-switch-$(CONFIG_DEBUG_FS) += sparx5_vcap_debugfs.o # Provide include files -ccflags-y += -I$(srctree)/drivers/net/ethernet/microchip/vcap +ccflags-y += -I$(srctree)drivers/net/ethernet/microchip/vcap
drivers/net/wan/Makefile +1 -1
@@ -56,7 +56,7 @@ $(obj)/wanxlfw.bin: $(obj)/wanxlfw.o FORCE $(call if_changed,m68kld_bin_o) quiet_cmd_m68kas_o_S = M68KAS $@ - cmd_m68kas_o_S = $(M68KCC) -D__ASSEMBLY__ -Wp,-MD,$(depfile) -I$(srctree)/include/uapi -c -o $@ $< + cmd_m68kas_o_S = $(M68KCC) -D__ASSEMBLY__ -Wp,-MD,$(depfile) -I$(srctree)include/uapi -c -o $@ $< $(obj)/wanxlfw.o: $(src)/wanxlfw.S FORCE $(call if_changed_dep,m68kas_o_S)
drivers/net/wireless/broadcom/brcm80211/brcmfmac/Makefile +2 -2
@@ -6,8 +6,8 @@ # ccflags-y += \ - -I $(srctree)/$(src) \ - -I $(srctree)/$(src)/../include + -I $(srctree)$(src) \ + -I $(srctree)$(src)/../include obj-$(CONFIG_BRCMFMAC) += brcmfmac.o brcmfmac-objs += \
drivers/net/wireless/broadcom/brcm80211/brcmfmac/bca/Makefile +3 -3
@@ -3,9 +3,9 @@ # Copyright (c) 2022 Broadcom Corporation ccflags-y += \ - -I $(srctree)/$(src) \ - -I $(srctree)/$(src)/.. \ - -I $(srctree)/$(src)/../../include + -I $(srctree)$(src) \ + -I $(srctree)$(src)/.. \ + -I $(srctree)$(src)/../../include obj-m += brcmfmac-bca.o brcmfmac-bca-objs += \
drivers/net/wireless/broadcom/brcm80211/brcmfmac/cyw/Makefile +3 -3
@@ -3,9 +3,9 @@ # Copyright (c) 2022 Broadcom Corporation ccflags-y += \ - -I $(srctree)/$(src) \ - -I $(srctree)/$(src)/.. \ - -I $(srctree)/$(src)/../../include + -I $(srctree)$(src) \ + -I $(srctree)$(src)/.. \ + -I $(srctree)$(src)/../../include obj-m += brcmfmac-cyw.o brcmfmac-cyw-objs += \
drivers/net/wireless/broadcom/brcm80211/brcmfmac/wcc/Makefile +3 -3
@@ -3,9 +3,9 @@ # Copyright (c) 2022 Broadcom Corporation ccflags-y += \ - -I $(srctree)/$(src) \ - -I $(srctree)/$(src)/.. \ - -I $(srctree)/$(src)/../../include + -I $(srctree)$(src) \ + -I $(srctree)$(src)/.. \ + -I $(srctree)$(src)/../../include obj-m += brcmfmac-wcc.o brcmfmac-wcc-objs += \
drivers/net/wireless/broadcom/brcm80211/brcmsmac/Makefile +3 -3
@@ -16,9 +16,9 @@ # CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ccflags-y := \ - -I $(srctree)/$(src) \ - -I $(srctree)/$(src)/phy \ - -I $(srctree)/$(src)/../include + -I $(srctree)$(src) \ + -I $(srctree)$(src)/phy \ + -I $(srctree)$(src)/../include brcmsmac-y := \ mac80211_if.o \
drivers/net/wireless/broadcom/brcm80211/brcmutil/Makefile +1 -1
@@ -4,7 +4,7 @@ # # Copyright (c) 2011 Broadcom Corporation # -ccflags-y := -I $(srctree)/$(src)/../include +ccflags-y := -I $(srctree)$(src)/../include obj-$(CONFIG_BRCMUTIL) += brcmutil.o brcmutil-objs = utils.o d11.o
drivers/net/wireless/intel/iwlwifi/dvm/Makefile +1 -1
@@ -11,4 +11,4 @@ iwldvm-objs += rxon.o devices.o iwldvm-$(CONFIG_IWLWIFI_LEDS) += led.o iwldvm-$(CONFIG_IWLWIFI_DEBUGFS) += debugfs.o -ccflags-y += -I $(srctree)/$(src)/../ +ccflags-y += -I $(srctree)$(src)/../
drivers/net/wireless/intel/iwlwifi/mei/Makefile +1 -1
@@ -5,4 +5,4 @@ iwlmei-y += net.o iwlmei-$(CONFIG_IWLWIFI_DEVICE_TRACING) += trace.o CFLAGS_trace.o := -I$(src) -ccflags-y += -I $(srctree)/$(src)/../ +ccflags-y += -I $(srctree)$(src)/../
drivers/net/wireless/intel/iwlwifi/mvm/Makefile +1 -1
@@ -15,4 +15,4 @@ iwlmvm-$(CONFIG_IWLWIFI_LEDS) += led.o iwlmvm-$(CONFIG_PM) += d3.o iwlmvm-$(CONFIG_IWLMEI) += vendor-cmd.o -ccflags-y += -I $(srctree)/$(src)/../ +ccflags-y += -I $(srctree)$(src)/../
drivers/net/wireless/realtek/rtl818x/rtl8180/Makefile +1 -1
@@ -3,4 +3,4 @@ rtl818x_pci-objs := dev.o rtl8225.o sa2400.o max2820.o grf5101.o rtl8225se.o obj-$(CONFIG_RTL8180) += rtl818x_pci.o -ccflags-y += -I $(srctree)/$(src)/.. +ccflags-y += -I $(srctree)$(src)/..
drivers/net/wireless/realtek/rtl818x/rtl8187/Makefile +1 -1
@@ -3,4 +3,4 @@ rtl8187-objs := dev.o rtl8225.o leds.o rfkill.o obj-$(CONFIG_RTL8187) += rtl8187.o -ccflags-y += -I $(srctree)/$(src)/.. +ccflags-y += -I $(srctree)$(src)/..
drivers/pinctrl/renesas/Makefile +12 -12
@@ -52,16 +52,16 @@ obj-$(CONFIG_PINCTRL_RZN1) += pinctrl-rzn1.o obj-$(CONFIG_PINCTRL_RZV2M) += pinctrl-rzv2m.o ifeq ($(CONFIG_COMPILE_TEST),y) -CFLAGS_pfc-sh7203.o += -I$(srctree)/arch/sh/include/cpu-sh2a -CFLAGS_pfc-sh7264.o += -I$(srctree)/arch/sh/include/cpu-sh2a -CFLAGS_pfc-sh7269.o += -I$(srctree)/arch/sh/include/cpu-sh2a -CFLAGS_pfc-sh7720.o += -I$(srctree)/arch/sh/include/cpu-sh3 -CFLAGS_pfc-sh7722.o += -I$(srctree)/arch/sh/include/cpu-sh4 -CFLAGS_pfc-sh7723.o += -I$(srctree)/arch/sh/include/cpu-sh4 -CFLAGS_pfc-sh7724.o += -I$(srctree)/arch/sh/include/cpu-sh4 -CFLAGS_pfc-sh7734.o += -I$(srctree)/arch/sh/include/cpu-sh4 -CFLAGS_pfc-sh7757.o += -I$(srctree)/arch/sh/include/cpu-sh4 -CFLAGS_pfc-sh7785.o += -I$(srctree)/arch/sh/include/cpu-sh4 -CFLAGS_pfc-sh7786.o += -I$(srctree)/arch/sh/include/cpu-sh4 -CFLAGS_pfc-shx3.o += -I$(srctree)/arch/sh/include/cpu-sh4 +CFLAGS_pfc-sh7203.o += -I$(srctree)arch/sh/include/cpu-sh2a +CFLAGS_pfc-sh7264.o += -I$(srctree)arch/sh/include/cpu-sh2a +CFLAGS_pfc-sh7269.o += -I$(srctree)arch/sh/include/cpu-sh2a +CFLAGS_pfc-sh7720.o += -I$(srctree)arch/sh/include/cpu-sh3 +CFLAGS_pfc-sh7722.o += -I$(srctree)arch/sh/include/cpu-sh4 +CFLAGS_pfc-sh7723.o += -I$(srctree)arch/sh/include/cpu-sh4 +CFLAGS_pfc-sh7724.o += -I$(srctree)arch/sh/include/cpu-sh4 +CFLAGS_pfc-sh7734.o += -I$(srctree)arch/sh/include/cpu-sh4 +CFLAGS_pfc-sh7757.o += -I$(srctree)arch/sh/include/cpu-sh4 +CFLAGS_pfc-sh7785.o += -I$(srctree)arch/sh/include/cpu-sh4 +CFLAGS_pfc-sh7786.o += -I$(srctree)arch/sh/include/cpu-sh4 +CFLAGS_pfc-shx3.o += -I$(srctree)arch/sh/include/cpu-sh4 endif
drivers/scsi/aic7xxx/Makefile +6 -6
@@ -55,9 +55,9 @@ aicasm-7xxx-opts-$(CONFIG_AIC7XXX_REG_PRETTY_PRINT) := \ ifeq ($(CONFIG_AIC7XXX_BUILD_FIRMWARE),y) $(obj)/aic7xxx_seq.h: $(src)/aic7xxx.seq $(src)/aic7xxx.reg $(obj)/aicasm/aicasm - $(obj)/aicasm/aicasm -I$(srctree)/$(src) -r $(obj)/aic7xxx_reg.h \ + $(obj)/aicasm/aicasm -I$(srctree)$(src) -r $(obj)/aic7xxx_reg.h \ $(aicasm-7xxx-opts-y) -o $(obj)/aic7xxx_seq.h \ - $(srctree)/$(src)/aic7xxx.seq + $(srctree)$(src)/aic7xxx.seq $(aic7xxx-gen-y): $(objtree)/$(obj)/aic7xxx_seq.h @true
@@ -73,9 +73,9 @@ aicasm-79xx-opts-$(CONFIG_AIC79XX_REG_PRETTY_PRINT) := \ ifeq ($(CONFIG_AIC79XX_BUILD_FIRMWARE),y) $(obj)/aic79xx_seq.h: $(src)/aic79xx.seq $(src)/aic79xx.reg $(obj)/aicasm/aicasm - $(obj)/aicasm/aicasm -I$(srctree)/$(src) -r $(obj)/aic79xx_reg.h \ + $(obj)/aicasm/aicasm -I$(srctree)$(src) -r $(obj)/aic79xx_reg.h \ $(aicasm-79xx-opts-y) -o $(obj)/aic79xx_seq.h \ - $(srctree)/$(src)/aic79xx.seq + $(srctree)$(src)/aic79xx.seq $(aic79xx-gen-y): $(objtree)/$(obj)/aic79xx_seq.h @true
@@ -83,5 +83,5 @@ else $(obj)/aic79xx_reg_print.c: $(src)/aic79xx_reg_print.c_shipped endif -$(obj)/aicasm/aicasm: $(srctree)/$(src)/aicasm/*.[chyl] - $(MAKE) -C $(srctree)/$(src)/aicasm OUTDIR=$(shell pwd)/$(obj)/aicasm/ +$(obj)/aicasm/aicasm: $(srctree)$(src)/aicasm/*.[chyl] + $(MAKE) -C $(srctree)$(src)/aicasm OUTDIR=$(shell pwd)/$(obj)/aicasm/
drivers/scsi/csiostor/Makefile +1 -1
@@ -4,7 +4,7 @@ # ## -ccflags-y += -I$(srctree)/drivers/net/ethernet/chelsio/cxgb4 +ccflags-y += -I$(srctree)drivers/net/ethernet/chelsio/cxgb4 obj-$(CONFIG_SCSI_CHELSIO_FCOE) += csiostor.o
drivers/scsi/cxgbi/Makefile +1 -1
@@ -1,5 +1,5 @@ # SPDX-License-Identifier: GPL-2.0-only -ccflags-y += -I $(srctree)/drivers/net/ethernet/chelsio/libcxgb +ccflags-y += -I $(srctree)drivers/net/ethernet/chelsio/libcxgb obj-$(CONFIG_SCSI_CXGB3_ISCSI) += libcxgbi.o cxgb3i/ obj-$(CONFIG_SCSI_CXGB4_ISCSI) += libcxgbi.o cxgb4i/
drivers/scsi/libsas/Makefile +1 -1
@@ -18,4 +18,4 @@ libsas-y += sas_init.o \ libsas-$(CONFIG_SCSI_SAS_ATA) += sas_ata.o libsas-$(CONFIG_SCSI_SAS_HOST_SMP) += sas_host_smp.o -ccflags-y := -DDEBUG -I$(srctree)/drivers/scsi +ccflags-y := -DDEBUG -I$(srctree)drivers/scsi
drivers/scsi/pcmcia/Makefile +1 -1
@@ -1,6 +1,6 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-y := -I $(srctree)/drivers/scsi +ccflags-y := -I $(srctree)drivers/scsi # 16-bit client drivers obj-$(CONFIG_PCMCIA_QLOGIC) += qlogic_cs.o
drivers/staging/media/atomisp/Makefile +1 -1
@@ -9,7 +9,7 @@ obj-$(CONFIG_VIDEO_ATOMISP) += pci/atomisp_gmin_platform.o # While on staging, keep debug enabled DEFINES += -DDEBUG -atomisp = $(srctree)/drivers/staging/media/atomisp/ +atomisp = $(srctree)drivers/staging/media/atomisp/ # SPDX-License-Identifier: GPL-2.0 atomisp-objs += \
drivers/staging/media/av7110/Makefile +4 -4
@@ -16,7 +16,7 @@ obj-$(CONFIG_DVB_AV7110) += dvb-ttpci.o obj-$(CONFIG_DVB_SP8870) += sp8870.o -ccflags-y += -I $(srctree)/drivers/media/dvb-frontends -ccflags-y += -I $(srctree)/drivers/media/tuners -ccflags-y += -I $(srctree)/drivers/media/pci/ttpci -ccflags-y += -I $(srctree)/drivers/media/common +ccflags-y += -I $(srctree)drivers/media/dvb-frontends +ccflags-y += -I $(srctree)drivers/media/tuners +ccflags-y += -I $(srctree)drivers/media/pci/ttpci +ccflags-y += -I $(srctree)drivers/media/common
drivers/staging/rtl8723bs/Makefile +1 -1
@@ -62,4 +62,4 @@ r8723bs-y = \ obj-$(CONFIG_RTL8723BS) := r8723bs.o -ccflags-y += -I$(srctree)/$(src)/include -I$(srctree)/$(src)/hal +ccflags-y += -I$(srctree)$(src)/include -I$(srctree)$(src)/hal
drivers/target/iscsi/cxgbit/Makefile +3 -3
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 -ccflags-y := -I $(srctree)/drivers/net/ethernet/chelsio/cxgb4 -ccflags-y += -I $(srctree)/drivers/net/ethernet/chelsio/libcxgb -ccflags-y += -I $(srctree)/drivers/target/iscsi +ccflags-y := -I $(srctree)drivers/net/ethernet/chelsio/cxgb4 +ccflags-y += -I $(srctree)drivers/net/ethernet/chelsio/libcxgb +ccflags-y += -I $(srctree)drivers/target/iscsi obj-$(CONFIG_ISCSI_TARGET_CXGB4) += cxgbit.o
drivers/tty/serial/8250/Makefile +1 -1
@@ -50,4 +50,4 @@ obj-$(CONFIG_SERIAL_8250_CS) += serial_cs.o obj-$(CONFIG_SERIAL_8250_UNIPHIER) += 8250_uniphier.o obj-$(CONFIG_SERIAL_8250_TEGRA) += 8250_tegra.o -CFLAGS_8250_ingenic.o += -I$(srctree)/scripts/dtc/libfdt +CFLAGS_8250_ingenic.o += -I$(srctree)scripts/dtc/libfdt
drivers/usb/gadget/function/Makefile +2 -2
@@ -3,8 +3,8 @@ # USB peripheral controller drivers # -ccflags-y := -I$(srctree)/drivers/usb/gadget/ -ccflags-y += -I$(srctree)/drivers/usb/gadget/udc/ +ccflags-y := -I$(srctree)drivers/usb/gadget/ +ccflags-y += -I$(srctree)drivers/usb/gadget/udc/ # USB Functions usb_f_acm-y := f_acm.o
drivers/usb/gadget/legacy/Makefile +3 -3
@@ -3,9 +3,9 @@ # USB gadget drivers # -ccflags-y := -I$(srctree)/drivers/usb/gadget/ -ccflags-y += -I$(srctree)/drivers/usb/gadget/udc/ -ccflags-y += -I$(srctree)/drivers/usb/gadget/function/ +ccflags-y := -I$(srctree)drivers/usb/gadget/ +ccflags-y += -I$(srctree)drivers/usb/gadget/udc/ +ccflags-y += -I$(srctree)drivers/usb/gadget/function/ g_zero-y := zero.o g_audio-y := audio.o
drivers/usb/storage/Makefile +1 -1
@@ -6,7 +6,7 @@ # Rewritten to use lists instead of if-statements. # -ccflags-y := -I $(srctree)/drivers/scsi +ccflags-y := -I $(srctree)drivers/scsi ccflags-y += -DDEFAULT_SYMBOL_NAMESPACE=USB_STORAGE
drivers/vdpa/mlx5/Makefile +1 -1
@@ -1,4 +1,4 @@ -subdir-ccflags-y += -I$(srctree)/drivers/vdpa/mlx5/core +subdir-ccflags-y += -I$(srctree)drivers/vdpa/mlx5/core obj-$(CONFIG_MLX5_VDPA_NET) += mlx5_vdpa.o mlx5_vdpa-$(CONFIG_MLX5_VDPA_NET) += net/mlx5_vnet.o core/resources.o core/mr.o net/debug.o
fs/hostfs/Makefile +1 -1
@@ -10,4 +10,4 @@ hostfs-builtin-$(CONFIG_HOSTFS) += hostfs_user.o hostfs_user_exp.o obj-y := $(hostfs-builtin-y) $(hostfs-builtin-m) obj-$(CONFIG_HOSTFS) += hostfs.o -include $(srctree)/arch/um/scripts/Makefile.rules +include $(srctree)arch/um/scripts/Makefile.rules
fs/iomap/Makefile +1 -1
@@ -4,7 +4,7 @@ # All Rights Reserved. # -ccflags-y += -I $(srctree)/$(src) # needed for trace events
Lines of this file are not shown. View the raw message.
tools/perf/Makefile.perf +66 -66
132 lines not on this page · raw message
tools/power/acpi/tools/acpidump/Makefile +1 -1
Lines of this file are not shown. View the raw message.
tools/power/x86/intel-speed-select/Makefile +1 -1
Lines of this file are not shown. View the raw message.
tools/testing/selftests/nolibc/Makefile +6 -6
Lines of this file are not shown. View the raw message.
The rest of this diff is not shown. View the raw message.
Signature · 1 line
2.39.2
Part of the diff is not shown here. View the raw message.
RFC PATCH 3/3 build: change $(srctree) to empty for current directory
In reply to Elliott MitchellSplit out to highlight the actual changes. This would break things if done in the first commit, so do this as the final step.
--- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Makefile +1 -1
@@ -246,7 +246,7 @@ else # need-sub-make ifeq ($(abs_srctree),$(abs_objtree)) # building in the source tree - srctree := ./ + srctree := building_out_of_srctree := else ifeq ($(abs_srctree)/,$(dir $(abs_objtree)))
Signature · 1 line
2.39.2
Quoted 9 lines · Elliott Mitchell
The subject states exactly what I'm suggesting.
The reason is the fallback value for $(srctree) of "." doesn't work properly in several places under some conditions. In particular in several places a pattern of "$(srctree)/$(src)" is used. If $(srctree) ends up with the value "." and $(src) ends up with the value
pwd, the build breaks. This can be triggered via in-tree/out-of-tree build mechanisms.
I really do not understand what you are trying to achieve, but this is just about
"Do not try to build upstream drivers with M=".
If you hack it, it is what you should do locally.
Quoted 16 lines
As such, assuming $(srctree) includes the trailing slash and setting the fallback for $(srctree) to "" fixes things. This is untested, I'm proposing this since I wanted to use a build approach which triggers this. This is really a single patch, but it has been split into 3 to emphasize where the real work is done.
I'm suspicious of the fallback settings of $(srctree) found in several Makefiles. This might be a distinct workaround for the same situation. I was wondering about adjusting some of those comments too. I think $(src) needs similar treatment, but that is rather messier.
Note, this is basically untested. I'm hopeful this actually works, but if it breaks then this was mostly to alert the maintainers of this troublesome condition.
Quoted 5 lines
Elliott Mitchell (3):
build: add trailing slash to $(srctree)
build: modify uses of $(srctree) to assume trailing slash
build: change $(srctree) to empty for current directory
--
Best Regards
Masahiro Yamada
Quoted 12 lines · Masahiro Yamada
Quoted 9 lines · Elliott Mitchell
The subject states exactly what I'm suggesting.
The reason is the fallback value for $(srctree) of "." doesn't work properly in several places under some conditions. In particular in several places a pattern of "$(srctree)/$(src)" is used. If $(srctree) ends up with the value "." and $(src) ends up with the value
pwd, the build breaks. This can be triggered via in-tree/out-of-tree build mechanisms.
Quoted 6 lines
I really do not understand what you are trying to achieve, but this is just about
"Do not try to build upstream drivers with M=".If you hack it, it is what you should do locally.
I think it is acceptable to state this usage of the build system is unsupported. This is not an acceptable reason to reject proposed patches.
While this use of M= might be considered a hack, adjusting $(srctree) to include the trailing slash is entirely appropriate. Everything which worked before still works and more situations now work. This also slightly shrinks the Makefiles.
Notice 306 Makefiles (excluding the top-level) reference $(srctree). Of those 26 include the construct which appears to be working around this problem. So 8.5% of Makefiles work around this problem, which seems a pretty good hint the feature is desired.
This doesn't account for Makefiles which had such during development, but was removed before submission. This also doesn't account for ones which had it removed after being brought into the Linux source tree. The differences between implementations suggest it might have been independently implemented as many as 3-4 times.
That seems a good hint this is desired by a notable percentage of developers.
In other news, examination of tools/testing/selftests/nolibc/Makefile suggests $(objtree) needs similar treatment.
Signature · 4 lines
(\___(\___(\______ --=> 8-) EHM <=-- ______/)___/)___/) \BS ( | [email protected] PGP 87145445 | ) / \_CS\ | _____ -O #include <stddisclaimer.h> O- _____ | / _/ 8A19\___\_|_/58D2 7E3D DDF4 7BA6 <-PGP-> 41D1 B375 37D0 8714\_|_/___/5445