summaryrefslogtreecommitdiff
path: root/lib/lzma/import_lzmasdk.sh
diff options
context:
space:
mode:
authorPeter Tyser <ptyser@xes-inc.com>2010-04-12 22:28:05 -0500
committerWolfgang Denk <wd@denx.de>2010-04-13 09:13:04 +0200
commit78acc472d9719316f22e002a009a998d9ceec29d (patch)
treeaa99461b3d693cf3691869abea485091860a66d0 /lib/lzma/import_lzmasdk.sh
parentea0364f1bbfed1e3ea711147420875cf338fe77a (diff)
downloadu-boot-imx-78acc472d9719316f22e002a009a998d9ceec29d.zip
u-boot-imx-78acc472d9719316f22e002a009a998d9ceec29d.tar.gz
u-boot-imx-78acc472d9719316f22e002a009a998d9ceec29d.tar.bz2
Rename lib_generic/ to lib/
Now that the other architecture-specific lib directories have been moved out of the top-level directory there's not much reason to have the '_generic' suffix on the common lib directory. Signed-off-by: Peter Tyser <ptyser@xes-inc.com>
Diffstat (limited to 'lib/lzma/import_lzmasdk.sh')
-rw-r--r--lib/lzma/import_lzmasdk.sh36
1 files changed, 36 insertions, 0 deletions
diff --git a/lib/lzma/import_lzmasdk.sh b/lib/lzma/import_lzmasdk.sh
new file mode 100644
index 0000000..1e0f686
--- /dev/null
+++ b/lib/lzma/import_lzmasdk.sh
@@ -0,0 +1,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!"