summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2012-09-30 22:22:22 +0000
committerJorge Manuel B. S. Vicetto (jmbsvicetto) <jmbsvicetto@gentoo.org>2012-09-30 22:28:26 +0000
commitc57b514c2295df27eafe57dfb1452b486e9c547b (patch)
tree4c5aa2e6293b975de028fa2d1ce16842aae0bc33 /targets
parentmips.py: Add loongson3a classes (diff)
downloadcatalyst-c57b514c2295df27eafe57dfb1452b486e9c547b.tar.gz
catalyst-c57b514c2295df27eafe57dfb1452b486e9c547b.tar.bz2
catalyst-c57b514c2295df27eafe57dfb1452b486e9c547b.zip
Apply Mike's suggested patch to fix the setting of +x on copy_to_chroot - bug 434252.
Diffstat (limited to 'targets')
-rw-r--r--targets/support/functions.sh21
1 files changed, 5 insertions, 16 deletions
diff --git a/targets/support/functions.sh b/targets/support/functions.sh
index 0bc5d69c..4ccad4ce 100644
--- a/targets/support/functions.sh
+++ b/targets/support/functions.sh
@@ -1,19 +1,8 @@
-copy_to_chroot(){
- local file_name=$(basename ${1})
- local dest_dir=${clst_chroot_path}${2}
- if [ "${2}" != "" ]
- then
- echo "copying ${file_name} to ${dest_dir}"
- mkdir -p ${dest_dir}
- cp -pPR ${1} ${dest_dir}
- [ "${file_name}" != "make.profile" ] && \
- chmod 755 ${dest_dir}/${file_name}
- else
- echo "copying ${file_name} to ${clst_chroot_path}/tmp"
- mkdir -p ${chroot_path}/tmp
- cp -pPR ${1} ${clst_chroot_path}/tmp
- chmod 755 ${clst_chroot_path}/tmp/${file_name}
- fi
+copy_to_chroot() {
+ local src_file=$1
+ local dest_dir=${clst_chroot_path}${2:-/tmp}
+ echo "copying ${src_file##*/} to ${dest_dir}"
+ cp -pPR "${src_file}" "${dest_dir}"/
}
delete_from_chroot(){