dtbsinstall: don't move target directory out of the way
authorRussell King <rmk+kernel@arm.linux.org.uk>
Tue, 20 Oct 2015 13:01:32 +0000 (14:01 +0100)
committerMichal Marek <mmarek@suse.com>
Thu, 28 Jan 2016 10:40:32 +0000 (11:40 +0100)
No other kernel installation target moves the target directory out of
the way, even deleting an old version of it.  These are destructive
operations, ones which the kernel build system should not be making.

This behaviour prevents being able to do:

make install INSTALL_PATH=/some/path/boot
make dtbs_install INSTALL_DTBS_PATH=/some/path/boot

As it causes the boot directory containing the kernel installed in
step 1 to be moved to /some/path/boot.old.  Things get even more fun
if you do:

make install dtbs_install INSTALL_PATH=/some/path/boot INSTALL_DTBS_PATH=/some/path/boot

The kernel gets installed into /some/path/boot, then the directory gets
renamed to /some/path/boot.old, and a new directory created to hold the
dtbs.  Even more fun if you supply -j2 when we end up with races in
make.

Remove this behaviour.

If this behaviour is required at installation time, this should be
done by the installation external to the kernel makefiles, just like
it would be done for 'make modules_install'.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: Jason Cooper <jason@lakedaemon.net>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Michal Marek <mmarek@suse.com>
scripts/Makefile.dtbinst

index 1c15717e0d5686972c1130fb718d0bc445c08dad..a1be75d0a5fd3fbf4742e555046896ea6fa6fe65 100644 (file)
@@ -23,8 +23,6 @@ include $(src)/Makefile
 PHONY += __dtbs_install_prep
 __dtbs_install_prep:
 ifeq ("$(dtbinst-root)", "$(obj)")
-       $(Q)if [ -d $(INSTALL_DTBS_PATH).old ]; then rm -rf $(INSTALL_DTBS_PATH).old; fi
-       $(Q)if [ -d $(INSTALL_DTBS_PATH) ]; then mv $(INSTALL_DTBS_PATH) $(INSTALL_DTBS_PATH).old; fi
        $(Q)mkdir -p $(INSTALL_DTBS_PATH)
 endif
 
This page took 0.025565 seconds and 5 git commands to generate.