<?xml version="1.0" encoding="UTF-8"?>
<project name ="Vezbe1_Grananje_EngineCode_run_script" default="all" basedir="../../EngineCode">
	<property environment="env"/>
	<condition property="maxcompilerdirpath" value="${env.MAXCOMPILERJCP}">
		<isset property="env.MAXCOMPILERJCP" />
	</condition>
	<condition property="maxcompilerdirpath" value="${env.MAXCOMPILERDIR}/lib/MaxCompiler.jar">
		<not>
			<isset property="maxcompilerdirpath" />
		</not>
	</condition>
	<target name="all" depends="run"/>
	<target name="build">
		<ant inheritAll="false" antfile="../RunRules/DFE/CpuStream_Build.xml"/>
	</target>
	<target name="run" depends="build">
		<condition property="args" value="">
			<not>
				<isset property="args"/>
			</not>
		</condition>
		<java classname="cpustream.CpuStreamManager" fork="true" failonerror="true">
			<env key="MAXSOURCEDIRS" value="src"/>
			<jvmarg value="-Xmx2048m"/>
			<arg line="${args}" />
			<classpath>
				<pathelement path="${env.ANT_MAXELER_INTERNAL_MAXIDE_JARS}"/><pathelement path="../RunRules/DFE/dist/bin"/>
				<pathelement path="${maxcompilerdirpath}"/>
			</classpath>
		</java>
	</target>
	<target name="clean">
		<ant inheritAll="false" antfile="../RunRules/DFE/CpuStream_Build.xml" target="clean"/>
	</target>
	<target name="jar" depends="build">
		<mkdir dir="../RunRules/DFE/dist/jar"/>
		<copy includeemptydirs="false" todir="../RunRules/DFE/dist/jar">
			<fileset dir="../RunRules/DFE/dist/bin" excludes="**/*.uad, **/*.ucd, **/*.uld, **/*.upd, **/*.udd, **/*.uod, **/*.usd, **/*.utd, **/*.uud, **/*.odd, **/*.ead, **/*.ecd, **/*.eld, **/*.epd, **/*.edd, **/*.eod, **/*.esd, **/*.etd, **/*.eud, **/*.urd*.uml, **/*.ecore, **/*.launch, **/*.java, **/*.maxj, **/package.html"/>
		</copy>
		<jar destfile="CpuStreamManager.jar" basedir="../RunRules/DFE/dist/jar">
			<manifest>
				<attribute name="Main-Class" value="cpustream.CpuStreamManager"/>
			</manifest>
		</jar>
	</target>
	<target name="help">
		<echo message="ant -f CpuStream.xml -Dargs=&quot;${Value}&quot;&#9;Run project" />
		<echo message="ant -f CpuStream.xml build&#9;&#9;&#9;Compile project" />
		<echo message="ant -f CpuStream.xml run -Dargs=&quot;${Value}&quot;&#9;Run project" />
		<echo message="ant -f CpuStream.xml clean&#9;&#9;&#9;Delete temp folders" />
		<echo message="ant -f CpuStream.xml jar&#9;&#9;&#9;Create jar package" />
		<echo message="ant -f CpuStream.xml help&#9;&#9;&#9;Print help message" />
	</target>
</project>
