aboutsummaryrefslogtreecommitdiff
path: root/support
diff options
context:
space:
mode:
authorGravatar Yann E. MORIN <yann.morin.1998@free.fr>2014-07-02 23:11:26 +0200
committerGravatar Peter Korsgaard <peter@korsgaard.com>2014-07-03 00:07:57 +0200
commit283b8b7feaccbe23decc69c2b3300b2a2d74d02d (patch)
tree27284ce46946436020a64b836b8afa02e3fb8b93 /support
parent54adff55d5759c6b5143165e6ffe1e12e402161d (diff)
downloadbuildroot-283b8b7feaccbe23decc69c2b3300b2a2d74d02d.tar.gz
buildroot-283b8b7feaccbe23decc69c2b3300b2a2d74d02d.tar.bz2
pkg-infra: move the cp (aka localfiles) download helper to a script
Maintaining the download helpers in the Makefile has proved to be a bit complex, so move it to a shell script. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Diffstat (limited to 'support')
-rwxr-xr-xsupport/download/cp16
1 files changed, 16 insertions, 0 deletions
diff --git a/support/download/cp b/support/download/cp
new file mode 100755
index 0000000000..3e9f54847f
--- /dev/null
+++ b/support/download/cp
@@ -0,0 +1,16 @@
+#!/bin/bash
+
+# We want to catch any command failure, and exit immediately
+set -e
+
+# Download helper for cp
+# Call it with:
+# $1: source file
+# $2: output file
+# And this environment:
+# LOCALFILES: the cp command to call
+
+source="${1}"
+output="${2}"
+
+${LOCALFILES} "${source}" "${output}"