src-db/build.xml
author Adrián Romero <adrian.romero@openbravo.com>
Thu, 24 Jan 2008 08:41:36 +0000
changeset 359 5f37a9ca5773
parent 213 7bc683ea98e9
child 800 1ad8094b366f
permissions -rw-r--r--
Added modifications to isolate DBSourcesManager
carlos@0
     1
<?xml version="1.0" encoding="UTF-8" ?>
carlos@0
     2
<!--
carlos@0
     3
************************************************************************************
carlos@0
     4
* Copyright (C) 2001-2006 Openbravo S.L.
carlos@0
     5
* Licensed under the Apache Software License version 2.0
carlos@0
     6
* You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
carlos@0
     7
* Unless required by applicable law or agreed to  in writing,  software  distributed
carlos@0
     8
* under the License is distributed  on  an  "AS IS"  BASIS,  WITHOUT  WARRANTIES  OR
carlos@0
     9
* CONDITIONS OF ANY KIND, either  express  or  implied.  See  the  License  for  the
carlos@0
    10
* specific language governing permissions and limitations under the License.
carlos@0
    11
************************************************************************************
carlos@0
    12
-->
adrian@359
    13
<project default="jar" basedir="." name="dbmanager">
carlos@0
    14
carlos@0
    15
    <property name="build.db.classes" value="${basedir}/build/classes"/>
carlos@0
    16
    <property name="build.db.lib" value="${basedir}/build/lib"/>
carlos@0
    17
    <property name="build.db.docs" value="${basedir}/docs"/>
carlos@0
    18
    <property name="build.db.src" value="${basedir}/src"/>
carlos@0
    19
 
carlos@0
    20
    <path id="db.class.path">
carlos@0
    21
        <fileset dir="${basedir}/lib">
carlos@0
    22
            <include name="**/*.jar"/>
carlos@0
    23
        </fileset>
juanpablo@213
    24
    </path>
juanpablo@213
    25
carlos@0
    26
    <target name="init">
carlos@0
    27
        <mkdir dir="${build.db.classes}"/>
carlos@0
    28
        <mkdir dir="${build.db.lib}"/>
carlos@0
    29
        <mkdir dir="${build.db.docs}"/>
carlos@0
    30
    </target>
carlos@0
    31
carlos@0
    32
    <target name="clean">
carlos@0
    33
        <delete dir="${build.db.classes}" failonerror="false" includeemptydirs="true"/>
carlos@0
    34
        <delete dir="${build.db.lib}" failonerror="false" includeemptydirs="true"/>
carlos@0
    35
        <delete dir="${build.db.docs}" failonerror="false" includeemptydirs="true"/>
carlos@0
    36
    </target>
carlos@0
    37
carlos@0
    38
    <target name="compile" depends="clean, init">
carlos@0
    39
        <javac srcdir="${build.db.src}" destdir="${build.db.classes}" deprecation="on" encoding="UTF-8" debug="${debug.level}">
carlos@0
    40
            <classpath refid="db.class.path"/>  
carlos@0
    41
        </javac>
carlos@0
    42
        <copy todir="${build.db.classes}" >
carlos@0
    43
            <fileset dir="${build.db.src}" excludes="**/*.java,**/*.form"/>
carlos@0
    44
        </copy>
carlos@0
    45
    </target>
carlos@0
    46
carlos@0
    47
    <target name="build.jar">
carlos@0
    48
        <jar destfile="${build.db.lib}/dbmanager.jar">
carlos@0
    49
            <fileset dir="${build.db.classes}"/>
carlos@0
    50
            <manifest>
carlos@0
    51
                <attribute name="Built-By" value="Openbravo S.L."/>
carlos@0
    52
            </manifest>
carlos@0
    53
        </jar> 
carlos@0
    54
    </target>
carlos@0
    55
carlos@0
    56
carlos@0
    57
    <target name="doc" depends="init" description="Generate api">
adrian@359
    58
        <javadoc packagenames="com.openbravo.*" 
carlos@0
    59
            sourcepath="${build.db.src}"
carlos@0
    60
            destdir="${build.db.docs}"
carlos@0
    61
            author="true"
carlos@0
    62
            version="true"
carlos@0
    63
            use="true"
carlos@0
    64
            docencoding="UTF-8"
carlos@0
    65
            encoding="UTF-8"
carlos@0
    66
            failonerror="false"
carlos@0
    67
            windowtitle="${ant.project.name}">
carlos@0
    68
            <classpath refid="db.class.path"/>
carlos@0
    69
        </javadoc>
carlos@0
    70
    </target>
carlos@0
    71
carlos@0
    72
    <target name="jar" depends="compile, build.jar">
carlos@0
    73
    </target>
carlos@0
    74
carlos@0
    75
    <target name="build" depends="jar, doc">
carlos@0
    76
    </target>
carlos@0
    77
carlos@0
    78
</project>