blob: 1e0f6863aab778bbc1cfe2f4ce9fa3a0963ae96d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
#!/bin/sh
usage() {
echo "Usage: $0 lzmaVERSION.tar.bz2" >&2
echo >&2
exit 1
}
if [ "$1" = "" ] ; then
usage
fi
if [ ! -f $1 ] ; then
echo "$1 doesn't exist!" >&2
exit 1
fi
BASENAME=`basename $1 .tar.bz2`
TMPDIR=/tmp/tmp_lib_$BASENAME
FILES="C/LzmaDec.h
C/Types.h
C/LzmaDec.c
history.txt
lzma.txt"
mkdir -p $TMPDIR
echo "Untar $1 -> $TMPDIR"
tar -jxf $1 -C $TMPDIR
for i in $FILES; do
echo Copying $TMPDIR/$i \-\> `basename $i`
cp $TMPDIR/$i .
chmod -x `basename $i`
done
echo "done!"
|