Gentoo Archives: gentoo-commits

From: Richard Farina <zerochaos@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/catalyst:master commit in: targets/support/
Date: Fri, 02 Nov 2012 00:07:48
Message-Id: 1351814409.3757d1f33bb04e5eabcfb0de714680b23ba64214.zerochaos@gentoo
1 commit: 3757d1f33bb04e5eabcfb0de714680b23ba64214
2 Author: Rick Farina (Zero_Chaos) <zerochaos <AT> gentoo <DOT> org>
3 AuthorDate: Fri Nov 2 00:00:09 2012 +0000
4 Commit: Richard Farina <zerochaos <AT> gentoo <DOT> org>
5 CommitDate: Fri Nov 2 00:00:09 2012 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/catalyst.git;a=commit;h=3757d1f3
7
8 Revert "Apply Mike's suggested patch to fix the setting of +x on copy_to_chroot - bug 434252."
9
10 This reverts commit c57b514c2295df27eafe57dfb1452b486e9c547b.
11
12 ---
13 targets/support/functions.sh | 21 ++++++++++++++++-----
14 1 files changed, 16 insertions(+), 5 deletions(-)
15
16 diff --git a/targets/support/functions.sh b/targets/support/functions.sh
17 index a0eaae2..cb70bdd 100644
18 --- a/targets/support/functions.sh
19 +++ b/targets/support/functions.sh
20 @@ -1,8 +1,19 @@
21 -copy_to_chroot() {
22 - local src_file=$1
23 - local dest_dir=${clst_chroot_path}${2:-/tmp}
24 - echo "copying ${src_file##*/} to ${dest_dir}"
25 - cp -pPR "${src_file}" "${dest_dir}"/
26 +copy_to_chroot(){
27 + local file_name=$(basename ${1})
28 + local dest_dir=${clst_chroot_path}${2}
29 + if [ "${2}" != "" ]
30 + then
31 + echo "copying ${file_name} to ${dest_dir}"
32 + mkdir -p ${dest_dir}
33 + cp -pPR ${1} ${dest_dir}
34 + [ "${file_name}" != "make.profile" ] && \
35 + chmod 755 ${dest_dir}/${file_name}
36 + else
37 + echo "copying ${file_name} to ${clst_chroot_path}/tmp"
38 + mkdir -p ${chroot_path}/tmp
39 + cp -pPR ${1} ${clst_chroot_path}/tmp
40 + chmod 755 ${clst_chroot_path}/tmp/${file_name}
41 + fi
42 }
43
44 delete_from_chroot(){