diff options
author | Michael Neves | 2012-09-28 17:11:09 +0200 |
---|---|---|
committer | Michael Neves | 2012-09-28 17:11:09 +0200 |
commit | b313ba8246db67e0ecd1ed73b46ccdd5d345c4b5 (patch) | |
tree | f1e43a321c66b03115882d4dd4f48ebd6d2bf7f4 /remote/setup-tools.sh | |
parent | busybox required files (diff) | |
download | tm-scripts-b313ba8246db67e0ecd1ed73b46ccdd5d345c4b5.tar.gz tm-scripts-b313ba8246db67e0ecd1ed73b46ccdd5d345c4b5.tar.xz tm-scripts-b313ba8246db67e0ecd1ed73b46ccdd5d345c4b5.zip |
copy required files
Diffstat (limited to 'remote/setup-tools.sh')
-rwxr-xr-x | remote/setup-tools.sh | 25 |
1 files changed, 21 insertions, 4 deletions
diff --git a/remote/setup-tools.sh b/remote/setup-tools.sh index e532600d..164ac689 100755 --- a/remote/setup-tools.sh +++ b/remote/setup-tools.sh @@ -61,8 +61,8 @@ copyfileswithdependencies () COPYFILES_LIST="copyfiles.list" - for FILENAME in $REQUIRED_BINARIES $REQUIRED_FILES - do + for FILENAME in $REQUIRED_BINARIES + do for f in $(find . -name $FILENAME -type f -executable) do [ $(file $f |grep -i Executable |grep -c ELF) -eq 1 ] && FILE=$f @@ -75,9 +75,26 @@ copyfileswithdependencies () filename_path=$(dirname $i) echo "$filename_path/$filename_base*" >> $COPYFILES_LIST done - #copy to initramfsdir - tar -cpv $(cat $COPYFILES_LIST) | tar -xpv -C $INIT_DIR done + + # fast hack + #LDLINUX=$(ldd $FILE | grep ld-linux | awk '{print $1}' |cut -c2-) + #case $LDLINUX in + # *lib/*) cp -a /lib/ld-* lib ;; + # *lib64/*) cp -a /lib64/ld-* lib64 ;; + #esac + + for FILENAME in $REQUIRED_FILES + do + for f in $(find . -name $FILENAME -type f -executable) + do + [ $(file $f |grep -i Executable |grep -c ELF) -eq 1 ] && FILE=$f + done + echo $FILE >> $COPYFILES_LIST + done + + #copy to initramfsdir + tar -cpv $(cat $COPYFILES_LIST) | tar -xpv -C $INIT_DIR } main () { |