forked from Yubico/ykneo-openpgp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
41 lines (41 loc) · 1.8 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
<?xml version="1.0"?>
<project name="ykneo-openpgp" default="convert" basedir=".">
<description>Ant build for ykneo-oath applet</description>
<property name="src" location="src"/>
<property name="build" location="bin"/>
<!-- Load user specified extra properties -->
<property file="${user.home}/javacard.properties"/>
<property name="JAVA_PACKAGE" value="openpgpcard"/>
<property name="JAVA_PACKAGE_DIR" value="openpgpcard/"/>
<property name="APPLET_NAME" value="OpenPGPApplet"/>
<property name="PACKAGE_AID" value="0xd2:0x76:0x00:0x01:0x24:0x01"/>
<property name="APPLET_AID" value="0xd2:0x76:0x00:0x01:0x24:0x01:0x02:0x00:0x00:0x00:0x00:0x00:0x00:0x01:0x00:0x00"/>
<property name="VERSION" value="0.1"/>
<target name="init">
<mkdir dir="${build}"/>
</target>
<target name="compile" depends="init" description="compile the source ">
<javac srcdir="${src}" destdir="${build}" source="1.2" target="1.1" includeantruntime="false">
<classpath>
<pathelement path="${JAVACARD_HOME}/lib/api.jar"/>
</classpath>
</javac>
</target>
<target depends="compile" name="convert" description="convert to .cap">
<java classname="com.sun.javacard.converter.Converter" fork="true" failonerror="true">
<arg line="-classdir ${build}"/>
<arg line="-verbose"/>
<arg line="-exportpath ${JAVACARD_HOME}/api_export_files"/>
<arg line="-out CAP JCA EXP"/>
<arg line="-applet ${APPLET_AID} ${APPLET_NAME}"/>
<arg line="${JAVA_PACKAGE} ${PACKAGE_AID} ${VERSION}"/>
<classpath>
<pathelement location="${JAVACARD_HOME}/lib/converter.jar"/>
<pathelement location="${JAVACARD_HOME}/lib/offcardverifier.jar"/>
</classpath>
</java>
</target>
<target name="clean" description="clean up">
<delete dir="${build}"/>
</target>
</project>