Commit 77460bbd authored by Jonathan Shahen's avatar Jonathan Shahen
Browse files

fixed NuSMV default path

parent 4f022868
......@@ -5,59 +5,61 @@
<description>Mohawk Tool Implementation.</description>
<!-- set global properties for this build -->
<property name="src" location="src"/>
<property name="lib" location="lib"/>
<property name="src" location="src" />
<property name="lib" location="lib" />
<property name="bin" location="bin" />
<property name="data" location="data"/>
<property name="build" location="${bin}/build"/>
<property name="dist" location="${bin}/dist"/>
<property name="qtest" location="${data}/testcases"/>
<property name="mohawksrc" location="${src}/mohawk"/>
<property name="rbac" location="${mohawksrc}/rbac/generated"/>
<property name="data" location="data" />
<property name="build" location="${bin}/build" />
<property name="dist" location="${bin}/dist" />
<property name="qtest" location="${data}/testcases" />
<property name="mohawksrc" location="${src}/mohawk" />
<property name="template" location="${mohawksrc}/output" />
<property name="rbac" location="${mohawksrc}/rbac/generated" />
<property name="antlr" location="${lib}/antlr-3.2.jar" />
<target name="init">
<!-- create the bin directory -->
<mkdir dir="${bin}"/>
<mkdir dir="${bin}" />
<!-- create the build directory -->
<mkdir dir="${build}"/>
<mkdir dir="${build}" />
<!-- create the distribution directory -->
<mkdir dir="${dist}"/>
<mkdir dir="${dist}" />
</target>
<target name="parser" depends="init" description="generate parser files" >
<target name="parser" depends="init" description="generate parser files">
<!-- Create the parser files -->
<antlr target="${lib}/rbac.g" outputdirectory="${rbac}" >
<antlr target="${rbac}/rbac.g" outputdirectory="${rbac}">
<classpath>
<pathelement location="${lib}/antlr-3.2.jar" />
<pathelement location="${antlr}" />
</classpath>
</antlr>
</target>
<target name="compile" depends="parser" description="compile the source " >
<target name="compile" depends="parser" description="compile the source ">
<!-- compile the java code from ${src} into ${build} -->
<javac srcdir="${src}" destdir="${build}" debug="on" deprecation="true">
<classpath>
<fileset dir="${lib}">
<include name="**/*.jar"/>
<include name="**/*.jar" />
</fileset>
</classpath>
</javac>
<!--<copy file="${lib}/smvtemplate.st" todir="${build}/mohawk" />
<copy file="${lib}/transitions.st" todir="${build}/mohawk" />
<copy file="${lib}/rbac.st" todir="${build}/mohawk" /> -->
<copy file="${template}/smvtemplate.st" todir="${build}/mohawk/output" />
<copy file="${template}/transitions.st" todir="${build}/mohawk/output" />
<copy file="${template}/rbac.st" todir="${build}/mohawk/output" />
</target>
<target name="dist" depends="compile" description="generate the distribution" >
<target name="dist" depends="compile" description="generate the distribution">
<!-- put everything in ${build} into the jar file -->
<jar destfile="${dist}/${ant.project.name}.jar" basedir="${build}">
<manifest>
<attribute name="Built-By" value="${user.name}"/>
<attribute name="Built-By" value="${user.name}" />
<attribute name="Main-Class" value="mohawk.Mohawk" />
<attribute name="Class-Path" value="."/>
<attribute name="Class-Path" value="." />
</manifest>
<fileset dir="${build}" />
<zipfileset src="${lib}/stringtemplate.jar" />
<zipfileset src="${lib}/antlr-3.2.jar" />
<zipfileset src="${antlr}" />
<zipfileset src="${lib}/commons-cli-1.2.jar" />
<zipfileset src="${lib}/commons-lang3-3.3.2.jar" />
<zipfileset src="${lib}/hamcrest-core-1.3.jar" />
......@@ -65,27 +67,26 @@
</jar>
</target>
<target name="qtest" depends="compile" description="generate a JAR file that will be placed close to the data for quick testing" >
<target name="qtest" depends="dist" description="generate a JAR file that will be placed close to the data for quick testing">
<!-- @author Jonathan Shahen -->
<!-- put everything in ${build} into the jar file -->
<jar destfile="${qtest}/${ant.project.name}.jar" basedir="${build}">
<manifest>
<attribute name="Built-By" value="${user.name}"/>
<attribute name="Main-Class" value="mohawk.MohawkMain" />
<attribute name="Class-Path" value="."/>
</manifest>
<fileset dir="${build}" />
<zipfileset src="${lib}/stringtemplate.jar" />
<zipfileset src="${lib}/antlr-3.2.jar" />
</jar>
<copy file="${dist}/${ant.project.name}.jar" tofile=""/>
</target>
<target name="regression" depends="dist" description="Performs a regression test">
<!-- @author Jonathan Shahen -->
<exec executable="cmd" dir="${dist}">
<arg value="/c" />
<arg value="java -jar mohawk.jar -mode bmc -run all -rbacspec ../../data/regressiontests/positive1.spec" />
</exec>
</target>
<target name="clean" description="clean up">
<!-- delete the ${build} and ${dist} directory trees -->
<delete dir="${bin}"/>
<delete dir="${bin}" />
<delete>
<fileset dir="." defaultexcludes="no">
<include name="**/*.*~"/>
<include name="**/*.*~" />
</fileset>
</delete>
</target>
......
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment