1<?xml version="1.0" encoding="UTF-8"?>
2<!--***********************************************************
3 *
4 * Licensed to the Apache Software Foundation (ASF) under one
5 * or more contributor license agreements.  See the NOTICE file
6 * distributed with this work for additional information
7 * regarding copyright ownership.  The ASF licenses this file
8 * to you under the Apache License, Version 2.0 (the
9 * "License"); you may not use this file except in compliance
10 * with the License.  You may obtain a copy of the License at
11 *
12 *   http://www.apache.org/licenses/LICENSE-2.0
13 *
14 * Unless required by applicable law or agreed to in writing,
15 * software distributed under the License is distributed on an
16 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
17 * KIND, either express or implied.  See the License for the
18 * specific language governing permissions and limitations
19 * under the License.
20 *
21 ***********************************************************-->
22<project name="MinimalComponent" basedir="." default="all">
23
24  <target name="init">
25        <!--
26         In this target you have to change all parts, so that the properties
27         fit to your odk installation and to your service
28         -->
29         <property name="ODKPATH" value="D:/cvs/api/odk"/>
30         <property name="OUTPUTPATH" value="D:/cvs/api/odk/WINexample.out"/>
31         <property name="PACKAGE_NAME" value="org.OpenOffice."/>
32         <property name="JAR_FILE_NAME" value="MinimalComponent"/>
33         <property name="INTERFACE_NAME" value="MinimalComponent"/>
34         <property name="RDB_NAME" value="MinimalComponent.rdb"/>
35   </target>
36   <target depends="init" name="unoidl">
37
38       <exec dir="${ODKPATH}/WINexample.out/misc/" executable="${ODKPATH}/windows/bin/idlc.exe" timeout="600">
39             <arg line="-I. -I${ODKPATH}/idl ${ODKPATH}/examples/java/MinimalComponent/${INTERFACE_NAME}.idl"/>
40       </exec>
41
42       <exec dir="." executable="${ODKPATH}/windows/bin/regmerge.exe" timeout="600">
43             <arg line="./${RDB_NAME} /UCR ./${INTERFACE_NAME}.urd"/>
44       </exec>
45
46       <exec dir="." executable="${ODKPATH}/windows/bin/regmerge.exe" timeout="600">
47             <arg line="./${RDB_NAME} / ${ODKPATH}/windows/bin/applicat.rdb"/>
48       </exec>
49
50       <exec dir="." executable="${ODKPATH}/windows/bin/javamaker.exe" timeout="600">
51             <arg line="-BUCR -O${OUTPUTPATH}/class/${INTERFACE_NAME} -nD ./${RDB_NAME}"/>
52<!--
53             <arg line="-BUCR -T${PACKAGE_NAME}${INTERFACE_NAME} -O${OUTPUTPATH}/class/${INTERFACE_NAME} -nD ./${INTERFACE_NAME}.urd"/>
54 -->
55       </exec>
56
57   </target>
58
59   <target depends="init,unoidl" name="compile">
60       <mkdir dir="classes"/>
61       <javac debug="on" destdir="./classes" srcdir="." >
62               <classpath>
63                   <fileset dir="${ODKPATH}/classes/">
64                           <include name="**/*.jar"/>
65                   </fileset>
66                   <pathelement location="./classes"/>
67               </classpath>
68         </javac>
69    </target>
70
71     <target depends="compile,init" name="jar">
72        <jar basedir="./classes" compress="true" jarfile="${JAR_FILE_NAME}.jar" manifest="Manifest">
73        </jar>
74     </target>
75
76    <target depends="compile,init,jar" name="all">
77        <!-- WRITEME -->
78    </target>
79</project>
80