busybox: ensure $(BUSYBOX_BUILD_CONFIG) is writable
authorNathan Lynch <ntl@pobox.com>
Tue, 28 Jan 2014 20:11:22 +0000 (21:11 +0100)
committerPeter Korsgaard <peter@korsgaard.com>
Tue, 28 Jan 2014 21:55:55 +0000 (22:55 +0100)
If $(BUSYBOX_CONFIG_FILE) is read-only (eg. because Buildroot's
source dir is), the sed fixups to $(BUSYBOX_BUILD_CONFIG) fail.

Fixes: #4363
Signed-off-by: Nathan Lynch <ntl@pobox.com>
[yann.morin.1998@free.fr: use $(INSTALL) instead of cp]
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Arnout Vandecappelle <arnout@mind.be>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
package/busybox/busybox.mk

index f6f542e22d5e6d8b1d148411c77083bf7bde35e2..948f3e42d349b78015c80e665f5eb6438af58b00 100644 (file)
@@ -135,7 +135,7 @@ endef
 endif
 
 define BUSYBOX_COPY_CONFIG
-       cp -f $(BUSYBOX_CONFIG_FILE) $(BUSYBOX_BUILD_CONFIG)
+       $(INSTALL) -D -m 0644 $(BUSYBOX_CONFIG_FILE) $(BUSYBOX_BUILD_CONFIG)
 endef
 
 # Disable shadow passwords support if unsupported by the C library