-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.xml
More file actions
124 lines (102 loc) · 5.79 KB
/
build.xml
File metadata and controls
124 lines (102 loc) · 5.79 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
<?xml version="1.0" encoding="UTF-8"?>
<project name="aeminium-tests" basedir="." default="run">
<!-- aeminium.compiler -->
<property name="compiler.src.dir" value="compiler/src" />
<property name="compiler.lib.dir" value="compiler/lib" />
<property name="compiler.build.dir" value="compiler/build" />
<property name="compiler.dist.dir" value="compiler/dist" />
<property name="compiler.jar" value="compiler/compiler.jar" />
<!-- aeminium.runtime -->
<property name="runtime.dir" value="runtime/src" />
<property name="runtime.jar" value="runtime/dist/AeminiumRuntime.jar" />
<!-- aeminium.tests -->
<property name="tests.src.dir" value="tests/src" />
<property name="tests.target.dir" value="tests/target" />
<property name="tests.build.dir" value="tests/build" />
<property name="tests.lib.dir" value="tests/lib" />
<property name="tests.class" value="aeminium.compiler.tests.Fibonacci" />
<property name="tests.jar" value="tests/test.jar" />
<!-- aeminium.tests -->
<property name="profile.agentpath" value="/home/Tools/jprofiler7/bin/linux-x64/libjprofilerti.so=port=8849" />
<path id="compiler.classpath">
<fileset dir="${compiler.lib.dir}" includes="**/*.jar" />
</path>
<path id="tests.classpath">
<fileset dir="${tests.lib.dir}" includes="**/*.jar" />
<pathelement location="${runtime.jar}" />
<pathelement location="${tests.build.dir}" />
</path>
<target name="compile.compiler.classes">
<delete dir="${compiler.build.dir}" />
<mkdir dir="${compiler.build.dir}" />
<javac srcdir="${compiler.src.dir}" destdir="${compiler.build.dir}" classpathref="compiler.classpath" includeantruntime="false" debug="true"/>
</target>
<target name="compile.compiler" depends="compile.compiler.classes">
<jar destfile="${compiler.jar}">
<manifest>
<attribute name="Main-Class" value="org.eclipse.jdt.internal.jarinjarloader.JarRsrcLoader"/>
<attribute name="Rsrc-Main-Class" value="aeminium.compiler.Compiler"/>
<attribute name="Class-Path" value="." />
<attribute name="Rsrc-Class-Path" value="./ org.eclipse.osgi_3.6.2.R36x_v20110210.jar org.eclipse.jdt.core_3.6.2.v_A76_R36x.jar org.eclipse.equinox.preferences_3.3.0.v20100503.jar org.eclipse.equinox.common_3.6.0.v20100503.jar org.eclipse.core.runtime_3.6.0.v20100505.jar org.eclipse.core.resources_3.6.1.R36x_v20110131-1630.jar org.eclipse.core.jobs_3.5.1.R36x_v20100824.jar org.eclipse.core.contenttype_3.4.100.v20100505-1235.jar org.eclipse.core.contenttype_3.4.100.v20100505-1235.jar org.eclipse.jface_3.6.2.M20110210-1200.jar org.eclipse.text_3.5.0.v20100601-1300.jar org.eclipse.jface.text_3.6.1.r361_v20100825-0800.jar"/>
</manifest>
<zipfileset src="jar-in-jar-loader.zip"/>
<fileset dir="${compiler.build.dir}"/>
<zipfileset dir="${compiler.lib.dir}" includes="org.eclipse.osgi_3.6.2.R36x_v20110210.jar"/>
<zipfileset dir="${compiler.lib.dir}" includes="org.eclipse.jdt.core_3.6.2.v_A76_R36x.jar"/>
<zipfileset dir="${compiler.lib.dir}" includes="org.eclipse.equinox.preferences_3.3.0.v20100503.jar"/>
<zipfileset dir="${compiler.lib.dir}" includes="org.eclipse.equinox.common_3.6.0.v20100503.jar"/>
<zipfileset dir="${compiler.lib.dir}" includes="org.eclipse.core.runtime_3.6.0.v20100505.jar"/>
<zipfileset dir="${compiler.lib.dir}" includes="org.eclipse.core.resources_3.6.1.R36x_v20110131-1630.jar"/>
<zipfileset dir="${compiler.lib.dir}" includes="org.eclipse.core.jobs_3.5.1.R36x_v20100824.jar"/>
<zipfileset dir="${compiler.lib.dir}" includes="org.eclipse.core.contenttype_3.4.100.v20100505-1235.jar"/>
<zipfileset dir="${compiler.lib.dir}" includes="org.eclipse.text_3.5.0.v20100601-1300.jar"/>
<zipfileset dir="${compiler.lib.dir}" includes="org.eclipse.jface_3.6.2.M20110210-1200.jar"/>
<zipfileset dir="${compiler.lib.dir}" includes="org.eclipse.jface.text_3.6.1.r361_v20100825-0800.jar"/>
</jar>
</target>
<target name="compile.runtime" depends="">
<ant dir="runtime" target="jar"/>
</target>
<target name="translate.tests" depends="compile.compiler,compile.runtime">
<delete dir="${tests.target.dir}" />
<mkdir dir="${tests.target.dir}" />
<java jar="${compiler.jar}" fork="true">
<arg value="${tests.src.dir}" />
<arg value="${tests.target.dir}" />
<jvmarg value="-ea" />
</java>
</target>
<!--<target name="precompile.tests" depends="translate.tests">-->
<target name="precompile.tests" depends="translate.tests">
<copy todir="${tests.target.dir}/aeminium/runtime" >
<fileset dir="${compiler.dist.dir}/"/>
</copy>
<copy file="${runtime.jar}" todir="${tests.lib.dir}" />
<mkdir dir="${tests.build.dir}" />
</target>
<target name="compile.tests" depends="precompile.tests">
<delete dir="${tests.build.dir}" />
<mkdir dir="${tests.build.dir}" />
<javac srcdir="${tests.target.dir}" destdir="${tests.build.dir}" classpathref="tests.classpath" includeantruntime="false" debug="true"/>
<jar destfile="${tests.jar}">
<manifest>
<attribute name="Main-Class" value="${tests.class}"/>
<attribute name="Rsrc-Class-Path" value="./ ${runtime.jar}"/>
</manifest>
<zipfileset src="jar-in-jar-loader.zip"/>
<zipfileset src="${runtime.jar}"/>
<fileset dir="${tests.build.dir}"/>
</jar>
</target>
<target name="run" depends="compile.tests">
<java jar="${tests.jar}" fork="true">
<jvmarg value="-Xms32m"/>
</java>
</target>
<target name="profile" depends="compile.tests">
<java jar="${tests.jar}" fork="true">
<jvmarg value="-agentpath:${profile.agentpath}" />
<jvmarg value="-Djprofiler.probeProvider=aeminium.runtime.profiler.AeminiumProbeProvider" />
</java>
</target>
</project>