Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

kbuild: /bin/pwd -> pwd

Most places use pwd and rely on $PATH lookup. Moving the remaining
absolute path /bin/pwd users over for consistency.

Also, a reason for doing /bin/pwd -> pwd instead of the other way around
is because I believe build systems should make little assumptions on
host filesystem layout. Case in point, we do this kind of patching
already in NixOS.

Ref. commit 028568d84da3cfca49f5f846eeeef01441d70451
("kbuild: revert $(realpath ...) to $(shell cd ... && /bin/pwd)").

Signed-off-by: Bjørn Forsman <bjorn.forsman@gmail.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>

authored by

Bjørn Forsman and committed by
Masahiro Yamada
16f8259c 2ce079f0

+4 -4
+1 -1
Documentation/ia64/xen.txt
··· 41 41 42 42 5. make initrd for Dom0/DomU 43 43 # make -C linux-2.6.18-xen.hg ARCH=ia64 modules_install \ 44 - O=$(/bin/pwd)/build-linux-2.6.18-xen_ia64 44 + O=$(pwd)/build-linux-2.6.18-xen_ia64 45 45 # mkinitrd -f /boot/efi/efi/redhat/initrd-2.6.18.8-xen.img \ 46 46 2.6.18.8-xen --builtin mptspi --builtin mptbase \ 47 47 --builtin mptscsih --builtin uhci-hcd --builtin ohci-hcd \
+1 -1
Makefile
··· 132 132 # check that the output directory actually exists 133 133 saved-output := $(KBUILD_OUTPUT) 134 134 KBUILD_OUTPUT := $(shell mkdir -p $(KBUILD_OUTPUT) && cd $(KBUILD_OUTPUT) \ 135 - && /bin/pwd) 135 + && pwd) 136 136 $(if $(KBUILD_OUTPUT),, \ 137 137 $(error failed to create output directory "$(saved-output)")) 138 138
+1 -1
tools/power/cpupower/Makefile
··· 26 26 27 27 ifneq ($(OUTPUT),) 28 28 # check that the output directory actually exists 29 - OUTDIR := $(shell cd $(OUTPUT) && /bin/pwd) 29 + OUTDIR := $(shell cd $(OUTPUT) && pwd) 30 30 $(if $(OUTDIR),, $(error output directory "$(OUTPUT)" does not exist)) 31 31 endif 32 32
+1 -1
tools/scripts/Makefile.include
··· 13 13 14 14 # check that the output directory actually exists 15 15 ifneq ($(OUTPUT),) 16 - OUTDIR := $(shell cd $(OUTPUT) && /bin/pwd) 16 + OUTDIR := $(shell cd $(OUTPUT) && pwd) 17 17 $(if $(OUTDIR),, $(error output directory "$(OUTPUT)" does not exist)) 18 18 endif 19 19