src/Tools/JVM/build
author Rafal Kolanski <rafal.kolanski@nicta.com.au>
Tue, 19 Jun 2012 11:16:41 +0200
changeset 48108 f93433b451b8
parent 45385 7c1375ba1424
permissions -rwxr-xr-x
Improved tactic for rewriting set comprehensions into pointfree form. Currently the simproc targets a term with an arbitrary number of conjuncts of form "x : S". The tactic should now handle all cases of this form.

#!/usr/bin/env bash
#
# Author: Makarius
#
# Offline build script for JVM tools.

## diagnostics

function fail()
{
  echo "$1" >&2
  exit 2
}


## build

cd "$(dirname "$0")"

SOURCE="Java_Ext_Dirs.java"
TARGET="java_ext_dirs.jar"

BUILD="build_dir$$"
TMP_JAR="java_ext_dirs$$.jar"

rm -rf "$BUILD" && mkdir "$BUILD"
javac -source 1.4 -target 1.4 -d "$BUILD" "$SOURCE" || fail "Failed to compile sources"
jar cf "$TMP_JAR" -C "$BUILD" . || fail "Failed to produce \"$TMP_JAR\""
mv "$TMP_JAR" "$TARGET"
rm -rf "$BUILD"