-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathbuild.xml
94 lines (76 loc) · 2.96 KB
/
build.xml
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
<?xml version="1.0" ?>
<project name="Minechem 2" basedir="" default="main">
<!-- CHANGE THE PATHS HERE TO MATCH YOUR SYSTEM -->
<property name="minechem-version" value="2.0.0pr6.1"/>
<property name="build-dir" location="../minechem-build"/>
<property name="forge-dir" location="T:/Modding/Minecraft Src/forge"/>
<!-- DONT CHANGE THESE -->
<property name="minechem-src-dir" location="."/>
<property name="apis-dir" location="${minechem-src-dir}/apis"/>
<property name="mcp-dir" location="${forge-dir}/mcp"/>
<property name="src-dir" location="${mcp-dir}/src/minecraft"/>
<property name="reobf-dir" location="${mcp-dir}/reobf/minecraft"/>
<target name="move-to-mcp">
<!-- Copy Minechem classes -->
<copy todir="${src-dir}/ljdp">
<fileset dir="${minechem-src-dir}/ljdp"/>
<filterset>
<filter token="VERSION" value="${minechem-version}" />
</filterset>
</copy>
<!-- Copy NEI API -->
<copy todir="${src-dir}/codechicken">
<fileset dir="${apis-dir}/NEI/codechicken"/>
</copy>
<!-- Copy BUILDCRAFT API -->
<copy todir="${src-dir}/buildcraft">
<fileset dir="${apis-dir}/BuildCraft"/>
</copy>
<!-- Copy ComputerCraft API -->
<copy todir="${src-dir}/dan200">
<fileset dir="${apis-dir}/dan200/dan200"/>
</copy>
<!-- Copy EasyPacket API -->
<copy todir="${src-dir}/ljdp">
<fileset dir="${apis-dir}/EasyPacket/ljdp"/>
</copy>
</target>
<target name="compile">
<exec dir="${mcp-dir}" executable="cmd" osfamily="windows">
<arg line="/c recompile.bat"/>
</exec>
<exec dir="${mcp-dir}" executable="cmd" osfamily="windows">
<arg line="/c reobfuscate.bat"/>
</exec>
</target>
<target name="move-to-build">
<delete dir="${build-dir}"/>
<!-- Copy LJDP classes -->
<copy todir="${build-dir}/ljdp">
<fileset dir="${reobf-dir}/ljdp"/>
</copy>
<!-- Copy NEI API -->
<copy todir="${build-dir}/codechicken">
<fileset dir="${reobf-dir}/codechicken"/>
</copy>
<!-- Copy BUILDCRAFT API -->
<copy todir="${build-dir}/buildcraft/api">
<fileset dir="${reobf-dir}/buildcraft/api"/>
</copy>
<!-- Copy Minechem Resources -->
<copy todir="${build-dir}">
<fileset dir="${minechem-src-dir}/resources">
</fileset>
</copy>
<!-- delete from src dir -->
<delete dir="${src-dir}/ljdp"/>
<delete dir="${src-dir}/buildcraft"/>
<delete dir="${src-dir}/codechicken"/>
<delete dir="${src-dir}/dan200"/>
</target>
<target name="package">
<delete file="${build-dir}/MineChem-${minechem-version}.zip" />
<zip destfile="${build-dir}/MineChem-${minechem-version}.zip" basedir="${build-dir}"/>
</target>
<target name="main" depends="move-to-mcp,compile,move-to-build,package"/>
</project>