coreutils: add error handling to for loop
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Sun, 30 Nov 2014 14:18:27 +0000 (15:18 +0100)
committerPeter Korsgaard <peter@korsgaard.com>
Mon, 1 Dec 2014 22:29:03 +0000 (23:29 +0100)
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
package/coreutils/coreutils.mk

index db0d8a941f5a8bf90fccb619cd669605f5e1eb05..8901d2337cd29a0bef4ca70aebfcf9377920e6f1 100644 (file)
@@ -102,7 +102,7 @@ endif
 define COREUTILS_POST_INSTALL
        # some things go in root rather than usr
        for f in $(COREUTILS_BIN_PROGS); do \
-               mv -f $(TARGET_DIR)/usr/bin/$$f $(TARGET_DIR)/bin/$$f; \
+               mv -f $(TARGET_DIR)/usr/bin/$$f $(TARGET_DIR)/bin/$$f || exit 1; \
        done
        # link for archaic shells
        ln -fs test $(TARGET_DIR)/usr/bin/[