-
Notifications
You must be signed in to change notification settings - Fork 244
/
Copy pathsetup-mac.xml
126 lines (117 loc) · 7.02 KB
/
setup-mac.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
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
125
126
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project default="all" name="Create Mac Package">
<target name="all" depends="loadprops, binaries, dotar"/>
<target name="main_lib" depends="loadprops">
<jar destfile="../../Deploy/FlashTool/x10flasher.jar">
<manifest>
<attribute name="Main-Class" value="gui.Main"/>
<attribute name="Class-Path" value=". x10flasher.jar x10flasher_lib/AXMLPrinter2.jar x10flasher_lib/commons-io-2.4.jar x10flasher_lib/hsqldb2_2.0.0.jar x10flasher_lib/ini4j-0.5.2.jar x10flasher_lib/jdom-1.1.1.jar x10flasher_lib/jgit.jar x10flasher_lib/jgit.ant.jar x10flasher_lib/jna-4.1.0.jar x10flasher_lib/jna-platform-4.1.0.jar x10flasher_lib/jopt-simple-4.7.jar x10flasher_lib/jsch-0.1.51.jar x10flasher_lib/js.jar x10flasher_lib/log4j-1.2.17.jar x10flasher_lib/jbbp-1.0.jar x10flasher_lib/nsisant-1.3.jar x10flasher_lib/sony.jar x10flasher_lib/x10flasher-res.jar x10flasher_lib/xstream_1.4.2.jar x10flasher_lib/com.ibm.icu.jar x10flasher_lib/core.commands.jar x10flasher_lib/core.contenttype.jar x10flasher_lib/core.jobs.jar x10flasher_lib/core.runtime.jar x10flasher_lib/equinox.app.jar x10flasher_lib/equinox.common.jar x10flasher_lib/equinox.preferences.jar x10flasher_lib/equinox.registry.jar x10flasher_lib/javax.annotation.jar x10flasher_lib/javax.inject.jar x10flasher_lib/jface.jar x10flasher_lib/jface.text.jar x10flasher_lib/osgi.jar x10flasher_lib/runtime_registry_compatibility.jar x10flasher_lib/swtmac/swt.jar x10flasher_lib/text.jar x10flasher_lib/ui.forms.jar x10flasher_lib/ui.workbench.jar"/>
<attribute name="Implementation-Version" value="Version ${Internal-Version} built on ${Internal-Date}"/>
<attribute name="Internal-Version" value="${Internal-Version}"/>
<attribute name="Internal-Channel" value="${Internal-Channel}"/>
</manifest>
<fileset dir="../bin" excludes="/gui/ressources/icons/**"/>
</jar>
</target>
<target name="clean">
<delete dir="../../Deploy/FlashTool/x10flasher_lib/winjre32"/>
<delete dir="../../Deploy/FlashTool/x10flasher_lib/winjre64"/>
<delete dir="../../Deploy/FlashTool/x10flasher_lib/linjre32"/>
<delete dir="../../Deploy/FlashTool/x10flasher_lib/linjre64"/>
<delete dir="../../Deploy/FlashTool/x10flasher_lib/macjre64"/>
<delete file="../../Deploy/FlashTool/FlashTool.exe"/>
<delete file="../../Deploy/FlashTool/FlashTool64.exe"/>
<delete file="../../Deploy/FlashTool/FlashToolConsole"/>
<delete file="../../Deploy/FlashTool/FlashTool"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/7z.exe"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/adb.exe"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/bin2elf.exe"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/bin2sin.exe"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/fastboot.exe"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/unyaffs.windows.exe"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/7z.dll"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/AdbWinApi.dll"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/AdbWinUsbApi.dll"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/cygwin1.dll"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/adb.linux"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/fastboot.linux"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/unyaffs.linux"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/bin2elf"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/bin2sin"/>
<delete dir="../../Deploy/FlashTool/x10flasher_lib/linux"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/adb.mac"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/fastboot.mac"/>
<delete file="../../Deploy/FlashTool/x10flasher_lib/unyaffs.mac"/>
<delete dir="../../Deploy/FlashTool/x10flasher_lib/swtlin"/>
<delete dir="../../Deploy/FlashTool/x10flasher_lib/swtwin"/>
<delete dir="../../Deploy/FlashTool/x10flasher_lib/mac"/>
<delete file="../../Deploy/FlashTool/config.properties"/>
<delete dir="../../Deploy/FlashTool/drivers"/>
</target>
<target name="JRE">
<exec executable="tar" dir="../../Deploy/FlashTool/x10flasher_lib">
<arg value="xf"/>
<arg value="../../../Flashtool/jre/macjre.tar"/>
</exec>
<chmod dir="../../Deploy/FlashTool/x10flasher_lib/macjre64/bin" perm="755" includes="**/*"/>
<chmod file="../../Deploy/FlashTool/x10flasher_lib/macjre64/lib/jexec" perm="755"/>
<chmod dir="../../Deploy/FlashTool/x10flasher_lib/macjre64/lib" perm="755" includes="**/*.so"/>
</target>
<target name="binaries" depends="clean, main_lib, JRE">
<copy file="../ProgramExe/FlashTool" todir="../../Deploy/FlashTool"/>
<copy file="../ProgramExe/FlashToolConsole" todir="../../Deploy/FlashTool"/>
<copy file="../ProgramExe/xperifirm" todir="../../Deploy/FlashTool/x10flasher_lib"/>
<copy todir="../../Deploy/FlashTool/x10flasher_lib">
<fileset dir="../mac"
excludes="**/.svn"/>
</copy>
<chmod file="../../Deploy/FlashTool/FlashTool" perm="755" />
<chmod file="../../Deploy/FlashTool/FlashToolConsole" perm="755"/>
<chmod file="../../Deploy/FlashTool/x10flasher_lib/xperifirm" perm="755"/>
<chmod file="../../Deploy/FlashTool/x10flasher_lib/adb.mac" perm="755" />
<chmod file="../../Deploy/FlashTool/x10flasher_lib/fastboot.mac" perm="755" />
<chmod file="../../Deploy/FlashTool/x10flasher_lib/unyaffs.mac" perm="755" />
<chmod file="../../Deploy/FlashTool/x10flasher_lib/mac/lib64/libusb-1.0.0.dylib" perm="755" />
<chmod file="../../Deploy/FlashTool/x10flasher_lib/mac/lib32/libusb-1.0.0.dylib" perm="755" />
</target>
<target name="loadprops">
<loadmf jar="../../Deploy/FlashTool/x10flasher_lib/x10flasher-res.jar" prefix=""/>
</target>
<target name="dotar">
<delete dir="../../Deploy/FlashTool.app"/>
<copy todir="../../Deploy/FlashTool.app">
<fileset dir="../ProgramExe/FlashTool.app"
excludes="**/.svn"/>
</copy>
<move todir="../../Deploy/FlashTool.app/Contents/MacOS" includeEmptyDirs="yes">
<fileset dir="../../Deploy/FlashTool">
<include name="**/*" />
</fileset>
</move>
<exec executable="hdiutil" dir="../../Deploy">
<arg value="create"/>
<arg value="flashtool-${Internal-Version}-mac.dmg"/>
<arg value="-srcFolder"/>
<arg value="FlashTool.app"/>
</exec>
</target>
<!--
Loads entries from a manifest file.
@jar The jar from where to read
@prefix A prefix to prepend
-->
<macrodef name="loadmf">
<attribute name="jar"/>
<attribute name="prefix" default=""/>
<sequential>
<loadproperties>
<!-- Load the manifest entries -->
<zipentry zipfile="@{jar}" name="META-INF/MANIFEST.MF"/>
<!-- Add the prefix -->
<filterchain>
<prefixlines prefix="@{prefix}"/>
</filterchain>
</loadproperties>
</sequential>
</macrodef>
</project>