summaryrefslogtreecommitdiff
path: root/test/windows/unpack
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2014-05-16 07:26:08 -0700
committerBoris Kolpackov <boris@codesynthesis.com>2014-05-16 07:26:08 -0700
commit384d384d1b84142a23785c6c423064a29342f532 (patch)
treee23db009c09ba2cea86da8d94d4b12600445b8b2 /test/windows/unpack
Add test scripts for Windows (VC++, MinGW)
Diffstat (limited to 'test/windows/unpack')
-rwxr-xr-xtest/windows/unpack43
1 files changed, 43 insertions, 0 deletions
diff --git a/test/windows/unpack b/test/windows/unpack
new file mode 100755
index 0000000..bf8477a
--- /dev/null
+++ b/test/windows/unpack
@@ -0,0 +1,43 @@
+#! /usr/bin/env bash
+
+# Unpack libstudxml for Windows.
+#
+# -mingw unpack for MinGW
+#
+
+trap 'exit 1' ERR
+
+function error ()
+{
+ echo "$*" 1>&2
+}
+
+mingw=n
+
+while [ $# -gt 0 ]; do
+ case $1 in
+ -mingw)
+ mingw=y
+ shift
+ ;;
+ *)
+ error "unknown option: $1"
+ exit 1
+ ;;
+ esac
+done
+
+if [ $mingw = y ]; then
+ base=/t/libstudxml
+else
+ base=/cygdrive/t/libstudxml
+fi
+
+rm -rf libstudxml libstudxml-*
+
+v=`echo $base/libstudxml-*.*.*.zip | sed -e "s%$base/libstudxml-\([^-]*\).*.zip%\1%"`
+
+echo unpacking libstudxml-$v from $base
+
+unzip -q $base/libstudxml-$v.zip
+mv libstudxml-$v libstudxml