Dees_Troy | 51a0e82 | 2012-09-05 15:24:24 -0400 | [diff] [blame] | 1 | #!/bin/bash |
2 | |||||
3 | process_file() | ||||
4 | { | ||||
5 | src=$1 | ||||
6 | dst=$1-1 #/$(basename $2) | ||||
7 | cp -f -p $src $dst | ||||
8 | |||||
9 | sed "s|/system/bin/linker\x0|/sbin/linker\x0\x0\x0\x0\x0\x0\x0|g" $dst | sed "s|/system/bin/sh\x0|/sbin/sh\x0\x0\x0\x0\x0\x0\x0|g" > $dst-mod | ||||
10 | #sed "s|/sbin/linker\x0|/system/bin/linker\x0\x0\x0\x0\x0\x0\x0|g" $dst | sed "s|/sbin/sh\x0|/system/bin/sh\x0\x0\x0\x0\x0\x0\x0|g" > $dst-mod | ||||
11 | rm $dst | ||||
12 | } | ||||
13 | |||||
14 | |||||
15 | dest=$1 | ||||
16 | for ARG in $* | ||||
17 | do | ||||
18 | process_file $dest $ARG | ||||
19 | done |